From 8fade348d72900ac47b2132594acdb4a138ec753 Mon Sep 17 00:00:00 2001 From: "Anash P. Oommen" Date: Wed, 4 Mar 2020 12:55:48 -0500 Subject: [PATCH] Release v2.8 of the client library. (#155) * Release v2.8 of the client library. --- ChangeLog | 27 +- custom_nupkg/.gitignore | 2 + examples/AccountManagement/CreateCustomer.cs | 10 +- .../AccountManagement/GetAccountChanges.cs | 10 +- .../GetAccountInformation.cs | 10 +- .../AccountManagement/LinkManagerToClient.cs | 16 +- .../ListAccessibleCustomers.cs | 8 +- .../AdvancedOperations/AddAdCustomizer.cs | 32 +- .../AddAdGroupBidModifier.cs | 14 +- examples/AdvancedOperations/AddAppCampaign.cs | 418 + .../AdvancedOperations/AddDynamicPageFeed.cs | 34 +- .../AdvancedOperations/AddDynamicSearchAds.cs | 40 +- .../AddExpandedTextAdWithUpgradedUrls.cs | 14 +- examples/AdvancedOperations/AddGmailAd.cs | 22 +- .../AdvancedOperations/AddSmartDisplayAd.cs | 38 +- .../CreateAndAttachSharedKeywordSet.cs | 20 +- .../FindAndRemoveCriteriaFromSharedSet.cs | 14 +- .../GetAdGroupBidModifiers.cs | 10 +- .../UsePortfolioBiddingStrategy.cs | 24 +- .../AuthenticateInWebApplication.csproj | 4 +- .../Default.aspx.cs | 4 +- .../AuthenticateInWebApplication/Web.config | 110 +- .../packages.config | 2 +- examples/BasicOperations/AddAdGroups.cs | 12 +- examples/BasicOperations/AddCampaigns.cs | 22 +- .../BasicOperations/AddExpandedTextAds.cs | 14 +- examples/BasicOperations/AddKeywords.cs | 16 +- .../BasicOperations/AddResponsiveSearchAd.cs | 16 +- examples/BasicOperations/GetAdGroups.cs | 10 +- .../BasicOperations/GetArtifactMetadata.cs | 10 +- examples/BasicOperations/GetCampaigns.cs | 55 +- .../BasicOperations/GetExpandedTextAds.cs | 12 +- examples/BasicOperations/GetKeywords.cs | 8 +- examples/BasicOperations/PauseAd.cs | 12 +- examples/BasicOperations/RemoveAd.cs | 8 +- examples/BasicOperations/RemoveAdGroup.cs | 8 +- examples/BasicOperations/RemoveCampaign.cs | 8 +- examples/BasicOperations/RemoveKeyword.cs | 8 +- examples/BasicOperations/UpdateAdGroup.cs | 12 +- examples/BasicOperations/UpdateCampaign.cs | 14 +- examples/BasicOperations/UpdateKeyword.cs | 12 +- examples/Billing/AddAccountBudgetProposal.cs | 14 +- examples/Billing/GetAccountBudgetProposals.cs | 10 +- examples/Billing/GetAccountBudgets.cs | 10 +- examples/Billing/GetBillingSetup.cs | 10 +- examples/Billing/RemoveBillingSetup.cs | 8 +- .../AddCampaignBidModifier.cs | 14 +- .../CampaignManagement/AddCampaignDraft.cs | 16 +- .../CampaignManagement/AddCampaignLabels.cs | 10 +- .../CreateCampaignExperiment.cs | 14 +- .../GetAllDisapprovedAds.cs | 12 +- .../CampaignManagement/GetCampaignsByLabel.cs | 8 +- .../CampaignManagement/SetAdParameters.cs | 10 +- .../UpdateCampaignCriterionBidModifier.cs | 119 + examples/CampaignManagement/ValidateTextAd.cs | 18 +- .../ErrorHandling/HandlePartialFailures.cs | 10 +- .../ErrorHandling/HandleRateExceededError.cs | 18 +- .../AddGoogleMyBusinessLocationExtensions.cs | 467 + examples/Extensions/AddPrices.cs | 270 + examples/Extensions/AddSitelinks.cs | 24 +- .../UpdateFeedItemAttributeValue.cs | 18 +- examples/HotelAds/AddHotelAd.cs | 34 +- .../HotelAds/AddHotelAdGroupBidModifiers.cs | 14 +- .../CreateCompleteCampaignAdWordsApiOnly.cs | 2 +- .../CreateCompleteCampaignBothApisPhase1.cs | 12 +- .../CreateCompleteCampaignBothApisPhase2.cs | 26 +- .../CreateCompleteCampaignBothApisPhase3.cs | 38 +- .../CreateCompleteCampaignBothApisPhase4.cs | 44 +- .../CreateCompleteCampaignGoogleAdsApiOnly.cs | 52 +- examples/Misc/GetAllImageAssets.cs | 12 +- examples/Misc/GetAllVideosAndImages.cs | 10 +- examples/Misc/UploadImage.cs | 12 +- examples/Misc/UploadImageAsset.cs | 16 +- examples/Misc/UploadMediaBundle.cs | 12 +- examples/Planning/AddKeywordPlan.cs | 24 +- examples/Planning/ForecastReach.cs | 24 +- examples/Planning/GenerateForecastMetrics.cs | 8 +- examples/Planning/GenerateKeywordIdeas.cs | 12 +- .../Recommendations/ApplyRecommendation.cs | 8 +- .../Recommendations/DismissRecommendation.cs | 12 +- .../GetTextAdRecommendations.cs | 12 +- examples/Remarketing/AddConversionAction.cs | 16 +- examples/Remarketing/AddFlightsFeed.cs | 24 +- examples/Remarketing/AddRealEstateFeed.cs | 26 +- examples/Remarketing/AddRemarketingAction.cs | 14 +- .../Remarketing/UploadConversionAdjustment.cs | 10 +- .../Remarketing/UploadOfflineConversion.cs | 8 +- examples/Reporting/GetHotelAdsPerformance.cs | 8 +- examples/Reporting/GetKeywordStats.cs | 56 +- examples/ShoppingAds/AddListingScope.cs | 179 + examples/ShoppingAds/AddShoppingProductAd.cs | 40 +- .../AddShoppingProductListingGroupTree.cs | 28 +- examples/ShoppingAds/AddShoppingSmartAd.cs | 42 +- .../GetProductBiddingCategoryConstant.cs | 10 +- .../Targeting/AddCampaignTargetingCriteria.cs | 16 +- .../Targeting/AddCustomerNegativeCriteria.cs | 14 +- .../AddDemographicTargetingCriteria.cs | 16 +- .../Targeting/GetCampaignTargetingCriteria.cs | 12 +- .../Targeting/GetGeoTargetConstantsByName.cs | 8 +- src/Config/GoogleAdsConfig.cs | 152 +- src/Google.Ads.GoogleAds.csproj | 11 +- src/Interceptors/GoogleAdsGrpcInterceptor.cs | 146 + src/Interceptors/StreamingRpcInterceptor.cs | 126 + src/Interceptors/UnaryRpcInterceptor.cs | 213 + src/Lib/GoogleAdsBaseException.cs | 139 + src/Lib/GoogleAdsServiceClientFactory.cs | 12 +- src/Lib/MetadataKeyNames.cs | 53 + src/Logging/LogEntry.cs | 16 +- src/Logging/LoggingHandler.cs | 246 + src/Logging/LoggingInterceptor.cs | 243 - src/Util/Examples/ExampleRunner.cs | 15 +- src/V1/GoogleAdsException.cs | 89 +- ...osalServiceClientExceptionCustomization.cs | 28 - ...dgetServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...upAdServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...fierServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...rionServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...tingServiceClientExceptionCustomization.cs | 28 - ...FeedServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...roupServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...eterServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ssetServiceClientExceptionCustomization.cs | 28 - ...tegyServiceClientExceptionCustomization.cs | 28 - ...etupServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...fierServiceClientExceptionCustomization.cs | 28 - ...dgetServiceClientExceptionCustomization.cs | 28 - ...rionServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...raftServiceClientExceptionCustomization.cs | 28 - ...mentServiceClientExceptionCustomization.cs | 28 - ...tingServiceClientExceptionCustomization.cs | 28 - ...FeedServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...aignServiceClientExceptionCustomization.cs | 28 - ...dSetServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...atusServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...loadServiceClientExceptionCustomization.cs | 28 - ...loadServiceClientExceptionCustomization.cs | 28 - ...restServiceClientExceptionCustomization.cs | 28 - ...LinkServiceClientExceptionCustomization.cs | 28 - ...ientServiceClientExceptionCustomization.cs | 28 - ...tingServiceClientExceptionCustomization.cs | 28 - ...FeedServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...LinkServiceClientExceptionCustomization.cs | 28 - ...rionServiceClientExceptionCustomization.cs | 28 - ...omerServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...goryServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ItemServiceClientExceptionCustomization.cs | 28 - ...ItemServiceClientExceptionCustomization.cs | 28 - ...rgetServiceClientExceptionCustomization.cs | 28 - ...pingServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...FeedServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ieldServiceClientExceptionCustomization.cs | 28 - ...eAdsServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...roupServiceClientExceptionCustomization.cs | 28 - ...aignServiceClientExceptionCustomization.cs | 28 - ...IdeaServiceClientExceptionCustomization.cs | 28 - ...wordServiceClientExceptionCustomization.cs | 28 - ...wordServiceClientExceptionCustomization.cs | 28 - ...PlanServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...FileServiceClientExceptionCustomization.cs | 28 - ...LinkServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...eJobServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ountServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...rionServiceClientExceptionCustomization.cs | 28 - ...dSetServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...restServiceClientExceptionCustomization.cs | 28 - ...ListServiceClientExceptionCustomization.cs | 28 - ...ideoServiceClientExceptionCustomization.cs | 28 - src/V2/GoogleAdsException.cs | 87 +- ...osalServiceClientExceptionCustomization.cs | 28 - ...dgetServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...upAdServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...fierServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...rionServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...tingServiceClientExceptionCustomization.cs | 28 - ...FeedServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...roupServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...eterServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - .../AdServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ssetServiceClientExceptionCustomization.cs | 28 - ...tegyServiceClientExceptionCustomization.cs | 28 - ...etupServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...fierServiceClientExceptionCustomization.cs | 28 - ...dgetServiceClientExceptionCustomization.cs | 28 - ...rionServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...raftServiceClientExceptionCustomization.cs | 28 - ...mentServiceClientExceptionCustomization.cs | 28 - ...tingServiceClientExceptionCustomization.cs | 28 - ...FeedServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...aignServiceClientExceptionCustomization.cs | 28 - ...dSetServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...atusServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...loadServiceClientExceptionCustomization.cs | 28 - ...loadServiceClientExceptionCustomization.cs | 28 - ...restServiceClientExceptionCustomization.cs | 28 - ...LinkServiceClientExceptionCustomization.cs | 28 - ...ientServiceClientExceptionCustomization.cs | 28 - ...tingServiceClientExceptionCustomization.cs | 28 - ...FeedServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...LinkServiceClientExceptionCustomization.cs | 28 - ...rionServiceClientExceptionCustomization.cs | 28 - ...omerServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...goryServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ItemServiceClientExceptionCustomization.cs | 28 - ...ItemServiceClientExceptionCustomization.cs | 28 - ...rgetServiceClientExceptionCustomization.cs | 28 - ...pingServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...FeedServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ieldServiceClientExceptionCustomization.cs | 28 - ...eAdsServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...oiceServiceClientExceptionCustomization.cs | 28 - ...roupServiceClientExceptionCustomization.cs | 28 - ...aignServiceClientExceptionCustomization.cs | 28 - ...IdeaServiceClientExceptionCustomization.cs | 28 - ...wordServiceClientExceptionCustomization.cs | 28 - ...wordServiceClientExceptionCustomization.cs | 28 - ...PlanServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...abelServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...FileServiceClientExceptionCustomization.cs | 28 - ...LinkServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...eJobServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ountServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...PlanServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...tionServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...rionServiceClientExceptionCustomization.cs | 28 - ...dSetServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...tantServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...restServiceClientExceptionCustomization.cs | 28 - ...ListServiceClientExceptionCustomization.cs | 28 - ...ViewServiceClientExceptionCustomization.cs | 28 - ...ideoServiceClientExceptionCustomization.cs | 28 - src/V3/GoogleAdsException.cs | 69 + src/V3/GoogleAdsFailureExtensions.cs | 73 + src/V3/ResourceNames.cs | 519 + src/V3/ServiceExtensions.cs | 130 + src/V3/ServiceHelperMethods.cs | 150 + src/V3/Services.V3.cs | 1334 +++ src/V3/Stubs/AccessInvitationError.cs | 186 + src/V3/Stubs/AccessReason.cs | 197 + src/V3/Stubs/AccessRole.cs | 189 + src/V3/Stubs/AccountBudget.cs | 1740 +++ src/V3/Stubs/AccountBudgetProposal.cs | 1122 ++ src/V3/Stubs/AccountBudgetProposalError.cs | 286 + src/V3/Stubs/AccountBudgetProposalService.cs | 956 ++ .../AccountBudgetProposalServiceClient.cs | 874 ++ .../Stubs/AccountBudgetProposalServiceGrpc.cs | 242 + src/V3/Stubs/AccountBudgetProposalStatus.cs | 203 + src/V3/Stubs/AccountBudgetProposalType.cs | 194 + src/V3/Stubs/AccountBudgetService.cs | 196 + src/V3/Stubs/AccountBudgetServiceClient.cs | 561 + src/V3/Stubs/AccountBudgetServiceGrpc.cs | 160 + src/V3/Stubs/AccountBudgetStatus.cs | 189 + src/V3/Stubs/Ad.cs | 1484 +++ src/V3/Stubs/AdAsset.cs | 660 ++ src/V3/Stubs/AdCustomizerError.cs | 200 + src/V3/Stubs/AdCustomizerPlaceholderField.cs | 194 + src/V3/Stubs/AdError.cs | 843 ++ src/V3/Stubs/AdGroup.cs | 1133 ++ src/V3/Stubs/AdGroupAd.cs | 581 + src/V3/Stubs/AdGroupAdAssetView.cs | 583 + src/V3/Stubs/AdGroupAdAssetViewService.cs | 196 + .../Stubs/AdGroupAdAssetViewServiceClient.cs | 561 + src/V3/Stubs/AdGroupAdAssetViewServiceGrpc.cs | 158 + src/V3/Stubs/AdGroupAdError.cs | 216 + src/V3/Stubs/AdGroupAdLabel.cs | 272 + src/V3/Stubs/AdGroupAdLabelService.cs | 953 ++ src/V3/Stubs/AdGroupAdLabelServiceClient.cs | 898 ++ src/V3/Stubs/AdGroupAdLabelServiceGrpc.cs | 229 + src/V3/Stubs/AdGroupAdRotationMode.cs | 188 + src/V3/Stubs/AdGroupAdService.cs | 1071 ++ src/V3/Stubs/AdGroupAdServiceClient.cs | 887 ++ src/V3/Stubs/AdGroupAdServiceGrpc.cs | 224 + src/V3/Stubs/AdGroupAdStatus.cs | 191 + src/V3/Stubs/AdGroupAudienceView.cs | 198 + src/V3/Stubs/AdGroupAudienceViewService.cs | 196 + .../Stubs/AdGroupAudienceViewServiceClient.cs | 561 + .../Stubs/AdGroupAudienceViewServiceGrpc.cs | 158 + src/V3/Stubs/AdGroupBidModifier.cs | 683 ++ src/V3/Stubs/AdGroupBidModifierError.cs | 188 + src/V3/Stubs/AdGroupBidModifierService.cs | 1037 ++ .../Stubs/AdGroupBidModifierServiceClient.cs | 898 ++ src/V3/Stubs/AdGroupBidModifierServiceGrpc.cs | 229 + src/V3/Stubs/AdGroupCriterion.cs | 2540 +++++ .../Stubs/AdGroupCriterionApprovalStatus.cs | 195 + src/V3/Stubs/AdGroupCriterionError.cs | 369 + src/V3/Stubs/AdGroupCriterionLabel.cs | 273 + src/V3/Stubs/AdGroupCriterionLabelService.cs | 957 ++ .../AdGroupCriterionLabelServiceClient.cs | 898 ++ .../Stubs/AdGroupCriterionLabelServiceGrpc.cs | 229 + src/V3/Stubs/AdGroupCriterionService.cs | 1069 ++ src/V3/Stubs/AdGroupCriterionServiceClient.cs | 887 ++ src/V3/Stubs/AdGroupCriterionServiceGrpc.cs | 224 + src/V3/Stubs/AdGroupCriterionSimulation.cs | 495 + .../AdGroupCriterionSimulationService.cs | 198 + ...AdGroupCriterionSimulationServiceClient.cs | 561 + .../AdGroupCriterionSimulationServiceGrpc.cs | 158 + src/V3/Stubs/AdGroupCriterionStatus.cs | 192 + src/V3/Stubs/AdGroupError.cs | 238 + src/V3/Stubs/AdGroupExtensionSetting.cs | 336 + .../Stubs/AdGroupExtensionSettingService.cs | 1044 ++ .../AdGroupExtensionSettingServiceClient.cs | 910 ++ .../AdGroupExtensionSettingServiceGrpc.cs | 229 + src/V3/Stubs/AdGroupFeed.cs | 377 + src/V3/Stubs/AdGroupFeedError.cs | 213 + src/V3/Stubs/AdGroupFeedService.cs | 1033 ++ src/V3/Stubs/AdGroupFeedServiceClient.cs | 898 ++ src/V3/Stubs/AdGroupFeedServiceGrpc.cs | 229 + src/V3/Stubs/AdGroupLabel.cs | 271 + src/V3/Stubs/AdGroupLabelService.cs | 951 ++ src/V3/Stubs/AdGroupLabelServiceClient.cs | 898 ++ src/V3/Stubs/AdGroupLabelServiceGrpc.cs | 229 + src/V3/Stubs/AdGroupService.cs | 1030 ++ src/V3/Stubs/AdGroupServiceClient.cs | 887 ++ src/V3/Stubs/AdGroupServiceGrpc.cs | 224 + src/V3/Stubs/AdGroupSimulation.cs | 549 + src/V3/Stubs/AdGroupSimulationService.cs | 196 + .../Stubs/AdGroupSimulationServiceClient.cs | 561 + src/V3/Stubs/AdGroupSimulationServiceGrpc.cs | 158 + src/V3/Stubs/AdGroupStatus.cs | 191 + src/V3/Stubs/AdGroupType.cs | 239 + src/V3/Stubs/AdNetworkType.cs | 202 + src/V3/Stubs/AdParameter.cs | 327 + src/V3/Stubs/AdParameterError.cs | 186 + src/V3/Stubs/AdParameterService.cs | 1033 ++ src/V3/Stubs/AdParameterServiceClient.cs | 898 ++ src/V3/Stubs/AdParameterServiceGrpc.cs | 229 + src/V3/Stubs/AdScheduleView.cs | 195 + src/V3/Stubs/AdScheduleViewService.cs | 195 + src/V3/Stubs/AdScheduleViewServiceClient.cs | 561 + src/V3/Stubs/AdScheduleViewServiceGrpc.cs | 158 + src/V3/Stubs/AdService.cs | 841 ++ src/V3/Stubs/AdServiceClient.cs | 770 ++ src/V3/Stubs/AdServiceGrpc.cs | 224 + src/V3/Stubs/AdServingOptimizationStatus.cs | 204 + src/V3/Stubs/AdSharingError.cs | 191 + src/V3/Stubs/AdStrength.cs | 201 + src/V3/Stubs/AdType.cs | 264 + src/V3/Stubs/AdTypeInfos.cs | 7495 +++++++++++++ src/V3/Stubs/AdvertisingChannelSubType.cs | 240 + src/V3/Stubs/AdvertisingChannelType.cs | 205 + src/V3/Stubs/AdxError.cs | 180 + .../AffiliateLocationFeedRelationshipType.cs | 184 + .../AffiliateLocationPlaceholderField.cs | 226 + src/V3/Stubs/AgeRangeType.cs | 208 + src/V3/Stubs/AgeRangeView.cs | 193 + src/V3/Stubs/AgeRangeViewService.cs | 195 + src/V3/Stubs/AgeRangeViewServiceClient.cs | 561 + src/V3/Stubs/AgeRangeViewServiceGrpc.cs | 158 + src/V3/Stubs/AppCampaignAppStore.cs | 185 + .../AppCampaignBiddingStrategyGoalType.cs | 206 + src/V3/Stubs/AppPaymentModelType.cs | 181 + src/V3/Stubs/AppPlaceholderField.cs | 218 + src/V3/Stubs/AppStore.cs | 184 + src/V3/Stubs/AppUrlOperatingSystemType.cs | 186 + ...mmendationResponsePartialFailureSupport.cs | 46 + src/V3/Stubs/Asset.cs | 505 + src/V3/Stubs/AssetError.cs | 201 + src/V3/Stubs/AssetFieldType.cs | 203 + src/V3/Stubs/AssetPerformanceLabel.cs | 201 + src/V3/Stubs/AssetService.cs | 803 ++ src/V3/Stubs/AssetServiceClient.cs | 770 ++ src/V3/Stubs/AssetServiceGrpc.cs | 226 + src/V3/Stubs/AssetType.cs | 193 + src/V3/Stubs/AssetTypes.cs | 957 ++ src/V3/Stubs/AttributionModel.cs | 219 + src/V3/Stubs/AuthenticationError.cs | 266 + src/V3/Stubs/AuthorizationError.cs | 241 + src/V3/Stubs/BidModifierSource.cs | 186 + src/V3/Stubs/Bidding.cs | 2068 ++++ src/V3/Stubs/BiddingError.cs | 301 + src/V3/Stubs/BiddingSource.cs | 191 + src/V3/Stubs/BiddingStrategy.cs | 680 ++ src/V3/Stubs/BiddingStrategyError.cs | 203 + src/V3/Stubs/BiddingStrategyService.cs | 1036 ++ src/V3/Stubs/BiddingStrategyServiceClient.cs | 898 ++ src/V3/Stubs/BiddingStrategyServiceGrpc.cs | 229 + src/V3/Stubs/BiddingStrategyStatus.cs | 187 + src/V3/Stubs/BiddingStrategyType.cs | 264 + src/V3/Stubs/BillingSetup.cs | 870 ++ src/V3/Stubs/BillingSetupError.cs | 269 + src/V3/Stubs/BillingSetupService.cs | 872 ++ src/V3/Stubs/BillingSetupServiceClient.cs | 770 ++ src/V3/Stubs/BillingSetupServiceGrpc.cs | 232 + src/V3/Stubs/BillingSetupStatus.cs | 196 + src/V3/Stubs/BrandSafetySuitability.cs | 210 + src/V3/Stubs/BudgetDeliveryMethod.cs | 188 + src/V3/Stubs/BudgetPeriod.cs | 180 + src/V3/Stubs/BudgetStatus.cs | 184 + src/V3/Stubs/BudgetType.cs | 202 + src/V3/Stubs/CallConversionReportingState.cs | 195 + src/V3/Stubs/CallPlaceholderField.cs | 206 + src/V3/Stubs/CalloutPlaceholderField.cs | 181 + src/V3/Stubs/Campaign.cs | 3729 +++++++ src/V3/Stubs/CampaignAudienceView.cs | 199 + src/V3/Stubs/CampaignAudienceViewService.cs | 196 + .../CampaignAudienceViewServiceClient.cs | 561 + .../Stubs/CampaignAudienceViewServiceGrpc.cs | 158 + src/V3/Stubs/CampaignBidModifier.cs | 383 + src/V3/Stubs/CampaignBidModifierService.cs | 1038 ++ .../Stubs/CampaignBidModifierServiceClient.cs | 898 ++ .../Stubs/CampaignBidModifierServiceGrpc.cs | 229 + src/V3/Stubs/CampaignBudget.cs | 846 ++ src/V3/Stubs/CampaignBudgetError.cs | 256 + src/V3/Stubs/CampaignBudgetService.cs | 1034 ++ src/V3/Stubs/CampaignBudgetServiceClient.cs | 898 ++ src/V3/Stubs/CampaignBudgetServiceGrpc.cs | 229 + src/V3/Stubs/CampaignCriterion.cs | 1628 +++ src/V3/Stubs/CampaignCriterionError.cs | 234 + src/V3/Stubs/CampaignCriterionService.cs | 1035 ++ .../Stubs/CampaignCriterionServiceClient.cs | 887 ++ src/V3/Stubs/CampaignCriterionServiceGrpc.cs | 224 + src/V3/Stubs/CampaignCriterionSimulation.cs | 496 + .../CampaignCriterionSimulationService.cs | 199 + ...ampaignCriterionSimulationServiceClient.cs | 561 + .../CampaignCriterionSimulationServiceGrpc.cs | 158 + src/V3/Stubs/CampaignCriterionStatus.cs | 192 + src/V3/Stubs/CampaignDraft.cs | 475 + src/V3/Stubs/CampaignDraftError.cs | 230 + src/V3/Stubs/CampaignDraftService.cs | 1554 +++ src/V3/Stubs/CampaignDraftServiceClient.cs | 1417 +++ src/V3/Stubs/CampaignDraftServiceGrpc.cs | 411 + src/V3/Stubs/CampaignDraftStatus.cs | 204 + src/V3/Stubs/CampaignError.cs | 388 + src/V3/Stubs/CampaignExperiment.cs | 636 ++ src/V3/Stubs/CampaignExperimentError.cs | 233 + src/V3/Stubs/CampaignExperimentService.cs | 2328 ++++ .../Stubs/CampaignExperimentServiceClient.cs | 2247 ++++ src/V3/Stubs/CampaignExperimentServiceGrpc.cs | 657 ++ src/V3/Stubs/CampaignExperimentStatus.cs | 222 + .../CampaignExperimentTrafficSplitType.cs | 190 + src/V3/Stubs/CampaignExperimentType.cs | 196 + src/V3/Stubs/CampaignExtensionSetting.cs | 336 + .../Stubs/CampaignExtensionSettingService.cs | 1044 ++ .../CampaignExtensionSettingServiceClient.cs | 910 ++ .../CampaignExtensionSettingServiceGrpc.cs | 229 + src/V3/Stubs/CampaignFeed.cs | 377 + src/V3/Stubs/CampaignFeedError.cs | 213 + src/V3/Stubs/CampaignFeedService.cs | 1033 ++ src/V3/Stubs/CampaignFeedServiceClient.cs | 898 ++ src/V3/Stubs/CampaignFeedServiceGrpc.cs | 229 + src/V3/Stubs/CampaignLabel.cs | 271 + src/V3/Stubs/CampaignLabelService.cs | 951 ++ src/V3/Stubs/CampaignLabelServiceClient.cs | 898 ++ src/V3/Stubs/CampaignLabelServiceGrpc.cs | 229 + src/V3/Stubs/CampaignService.cs | 1031 ++ src/V3/Stubs/CampaignServiceClient.cs | 887 ++ src/V3/Stubs/CampaignServiceGrpc.cs | 224 + src/V3/Stubs/CampaignServingStatus.cs | 200 + src/V3/Stubs/CampaignSharedSet.cs | 314 + src/V3/Stubs/CampaignSharedSetError.cs | 182 + src/V3/Stubs/CampaignSharedSetService.cs | 953 ++ .../Stubs/CampaignSharedSetServiceClient.cs | 887 ++ src/V3/Stubs/CampaignSharedSetServiceGrpc.cs | 224 + src/V3/Stubs/CampaignSharedSetStatus.cs | 185 + src/V3/Stubs/CampaignStatus.cs | 189 + src/V3/Stubs/CarrierConstant.cs | 310 + src/V3/Stubs/CarrierConstantService.cs | 195 + src/V3/Stubs/CarrierConstantServiceClient.cs | 561 + src/V3/Stubs/CarrierConstantServiceGrpc.cs | 158 + src/V3/Stubs/ChangeStatus.cs | 696 ++ src/V3/Stubs/ChangeStatusError.cs | 181 + src/V3/Stubs/ChangeStatusOperation.cs | 190 + src/V3/Stubs/ChangeStatusResourceType.cs | 223 + src/V3/Stubs/ChangeStatusService.cs | 195 + src/V3/Stubs/ChangeStatusServiceClient.cs | 561 + src/V3/Stubs/ChangeStatusServiceGrpc.cs | 158 + src/V3/Stubs/ClickLocation.cs | 345 + src/V3/Stubs/ClickType.cs | 421 + src/V3/Stubs/ClickView.cs | 395 + src/V3/Stubs/ClickViewService.cs | 194 + src/V3/Stubs/ClickViewServiceClient.cs | 561 + src/V3/Stubs/ClickViewServiceGrpc.cs | 158 + src/V3/Stubs/CollectionSizeError.cs | 185 + src/V3/Stubs/ContentLabelType.cs | 243 + src/V3/Stubs/ContextError.cs | 186 + src/V3/Stubs/ConversionAction.cs | 1165 ++ src/V3/Stubs/ConversionActionCategory.cs | 204 + src/V3/Stubs/ConversionActionCountingType.cs | 188 + src/V3/Stubs/ConversionActionError.cs | 222 + src/V3/Stubs/ConversionActionService.cs | 1036 ++ src/V3/Stubs/ConversionActionServiceClient.cs | 898 ++ src/V3/Stubs/ConversionActionServiceGrpc.cs | 229 + src/V3/Stubs/ConversionActionStatus.cs | 191 + src/V3/Stubs/ConversionActionType.cs | 217 + src/V3/Stubs/ConversionAdjustmentType.cs | 188 + .../Stubs/ConversionAdjustmentUploadError.cs | 238 + .../ConversionAdjustmentUploadService.cs | 1532 +++ ...ConversionAdjustmentUploadServiceClient.cs | 691 ++ .../ConversionAdjustmentUploadServiceGrpc.cs | 158 + .../Stubs/ConversionAttributionEventType.cs | 186 + src/V3/Stubs/ConversionLagBucket.cs | 281 + .../Stubs/ConversionOrAdjustmentLagBucket.cs | 416 + src/V3/Stubs/ConversionUploadError.cs | 301 + src/V3/Stubs/ConversionUploadService.cs | 2260 ++++ src/V3/Stubs/ConversionUploadServiceClient.cs | 1017 ++ src/V3/Stubs/ConversionUploadServiceGrpc.cs | 224 + src/V3/Stubs/CountryCodeError.cs | 181 + src/V3/Stubs/Criteria.cs | 9472 +++++++++++++++++ src/V3/Stubs/CriterionCategoryAvailability.cs | 694 ++ ...riterionCategoryChannelAvailabilityMode.cs | 197 + ...CriterionCategoryLocaleAvailabilityMode.cs | 202 + src/V3/Stubs/CriterionError.cs | 685 ++ src/V3/Stubs/CriterionSystemServingStatus.cs | 186 + src/V3/Stubs/CriterionType.cs | 308 + src/V3/Stubs/CurrencyCodeError.cs | 181 + src/V3/Stubs/CurrencyConstant.cs | 348 + src/V3/Stubs/CurrencyConstantService.cs | 195 + src/V3/Stubs/CurrencyConstantServiceClient.cs | 561 + src/V3/Stubs/CurrencyConstantServiceGrpc.cs | 158 + src/V3/Stubs/CustomInterest.cs | 588 + src/V3/Stubs/CustomInterestError.cs | 212 + src/V3/Stubs/CustomInterestMemberType.cs | 185 + src/V3/Stubs/CustomInterestService.cs | 922 ++ src/V3/Stubs/CustomInterestServiceClient.cs | 863 ++ src/V3/Stubs/CustomInterestServiceGrpc.cs | 224 + src/V3/Stubs/CustomInterestStatus.cs | 186 + src/V3/Stubs/CustomInterestType.cs | 185 + src/V3/Stubs/CustomParameter.cs | 232 + src/V3/Stubs/CustomPlaceholderField.cs | 290 + src/V3/Stubs/Customer.cs | 1286 +++ src/V3/Stubs/CustomerClient.cs | 544 + src/V3/Stubs/CustomerClientLink.cs | 345 + src/V3/Stubs/CustomerClientLinkError.cs | 211 + src/V3/Stubs/CustomerClientLinkService.cs | 917 ++ .../Stubs/CustomerClientLinkServiceClient.cs | 770 ++ src/V3/Stubs/CustomerClientLinkServiceGrpc.cs | 224 + src/V3/Stubs/CustomerClientService.cs | 195 + src/V3/Stubs/CustomerClientServiceClient.cs | 561 + src/V3/Stubs/CustomerClientServiceGrpc.cs | 158 + src/V3/Stubs/CustomerError.cs | 188 + src/V3/Stubs/CustomerExtensionSetting.cs | 293 + .../Stubs/CustomerExtensionSettingService.cs | 1044 ++ .../CustomerExtensionSettingServiceClient.cs | 910 ++ .../CustomerExtensionSettingServiceGrpc.cs | 229 + src/V3/Stubs/CustomerFeed.cs | 338 + src/V3/Stubs/CustomerFeedError.cs | 212 + src/V3/Stubs/CustomerFeedService.cs | 1033 ++ src/V3/Stubs/CustomerFeedServiceClient.cs | 898 ++ src/V3/Stubs/CustomerFeedServiceGrpc.cs | 229 + src/V3/Stubs/CustomerLabel.cs | 276 + src/V3/Stubs/CustomerLabelService.cs | 951 ++ src/V3/Stubs/CustomerLabelServiceClient.cs | 898 ++ src/V3/Stubs/CustomerLabelServiceGrpc.cs | 229 + src/V3/Stubs/CustomerManagerLink.cs | 305 + src/V3/Stubs/CustomerManagerLinkError.cs | 225 + src/V3/Stubs/CustomerManagerLinkService.cs | 1199 +++ .../Stubs/CustomerManagerLinkServiceClient.cs | 1035 ++ .../Stubs/CustomerManagerLinkServiceGrpc.cs | 310 + src/V3/Stubs/CustomerMatchUploadKeyType.cs | 192 + src/V3/Stubs/CustomerNegativeCriterion.cs | 558 + .../Stubs/CustomerNegativeCriterionService.cs | 957 ++ .../CustomerNegativeCriterionServiceClient.cs | 887 ++ .../CustomerNegativeCriterionServiceGrpc.cs | 224 + ...ayPerConversionEligibilityFailureReason.cs | 215 + src/V3/Stubs/CustomerService.cs | 1505 +++ src/V3/Stubs/CustomerServiceClient.cs | 1329 +++ src/V3/Stubs/CustomerServiceGrpc.cs | 361 + src/V3/Stubs/DataDrivenModelStatus.cs | 200 + src/V3/Stubs/DatabaseError.cs | 193 + src/V3/Stubs/DateError.cs | 224 + src/V3/Stubs/DateRangeError.cs | 200 + src/V3/Stubs/Dates.cs | 230 + src/V3/Stubs/DayOfWeek.cs | 206 + src/V3/Stubs/DetailPlacementView.cs | 387 + src/V3/Stubs/DetailPlacementViewService.cs | 196 + .../Stubs/DetailPlacementViewServiceClient.cs | 561 + .../Stubs/DetailPlacementViewServiceGrpc.cs | 158 + src/V3/Stubs/Device.cs | 197 + ...mmendationResponsePartialFailureSupport.cs | 46 + src/V3/Stubs/DisplayAdFormatSetting.cs | 191 + src/V3/Stubs/DisplayKeywordView.cs | 194 + src/V3/Stubs/DisplayKeywordViewService.cs | 196 + .../Stubs/DisplayKeywordViewServiceClient.cs | 561 + src/V3/Stubs/DisplayKeywordViewServiceGrpc.cs | 158 + src/V3/Stubs/DisplayUploadProductType.cs | 246 + src/V3/Stubs/DistanceBucket.cs | 297 + src/V3/Stubs/DistanceView.cs | 271 + src/V3/Stubs/DistanceViewService.cs | 195 + src/V3/Stubs/DistanceViewServiceClient.cs | 561 + src/V3/Stubs/DistanceViewServiceGrpc.cs | 158 + src/V3/Stubs/DistinctError.cs | 185 + src/V3/Stubs/DomainCategory.cs | 512 + src/V3/Stubs/DomainCategoryService.cs | 196 + src/V3/Stubs/DomainCategoryServiceClient.cs | 561 + src/V3/Stubs/DomainCategoryServiceGrpc.cs | 158 + src/V3/Stubs/DsaPageFeedCriterionField.cs | 187 + .../Stubs/DynamicSearchAdsSearchTermView.cs | 479 + .../DynamicSearchAdsSearchTermViewService.cs | 199 + ...micSearchAdsSearchTermViewServiceClient.cs | 561 + ...namicSearchAdsSearchTermViewServiceGrpc.cs | 158 + src/V3/Stubs/EducationPlaceholderField.cs | 269 + src/V3/Stubs/EnumError.cs | 180 + src/V3/Stubs/Errors.cs | 5677 ++++++++++ src/V3/Stubs/ExpandedLandingPageView.cs | 235 + .../Stubs/ExpandedLandingPageViewService.cs | 198 + .../ExpandedLandingPageViewServiceClient.cs | 561 + .../ExpandedLandingPageViewServiceGrpc.cs | 158 + src/V3/Stubs/ExplorerAutoOptimizerSetting.cs | 196 + src/V3/Stubs/ExtensionFeedItem.cs | 1136 ++ src/V3/Stubs/ExtensionFeedItemError.cs | 410 + src/V3/Stubs/ExtensionFeedItemService.cs | 1038 ++ .../Stubs/ExtensionFeedItemServiceClient.cs | 904 ++ src/V3/Stubs/ExtensionFeedItemServiceGrpc.cs | 229 + src/V3/Stubs/ExtensionSettingDevice.cs | 187 + src/V3/Stubs/ExtensionSettingError.cs | 509 + src/V3/Stubs/ExtensionType.cs | 229 + src/V3/Stubs/Extensions.cs | 4152 ++++++++ src/V3/Stubs/ExternalConversionSource.cs | 295 + src/V3/Stubs/Feed.cs | 1694 +++ src/V3/Stubs/FeedAttributeReferenceError.cs | 191 + src/V3/Stubs/FeedAttributeType.cs | 232 + src/V3/Stubs/FeedCommon.cs | 231 + src/V3/Stubs/FeedError.cs | 282 + src/V3/Stubs/FeedItem.cs | 1606 +++ src/V3/Stubs/FeedItemError.cs | 219 + src/V3/Stubs/FeedItemQualityApprovalStatus.cs | 188 + .../Stubs/FeedItemQualityDisapprovalReason.cs | 268 + src/V3/Stubs/FeedItemService.cs | 1031 ++ src/V3/Stubs/FeedItemServiceClient.cs | 898 ++ src/V3/Stubs/FeedItemServiceGrpc.cs | 229 + src/V3/Stubs/FeedItemStatus.cs | 185 + src/V3/Stubs/FeedItemTarget.cs | 602 ++ src/V3/Stubs/FeedItemTargetDevice.cs | 182 + src/V3/Stubs/FeedItemTargetError.cs | 217 + src/V3/Stubs/FeedItemTargetService.cs | 843 ++ src/V3/Stubs/FeedItemTargetServiceClient.cs | 770 ++ src/V3/Stubs/FeedItemTargetServiceGrpc.cs | 224 + src/V3/Stubs/FeedItemTargetStatus.cs | 185 + src/V3/Stubs/FeedItemTargetType.cs | 189 + src/V3/Stubs/FeedItemValidationError.cs | 655 ++ src/V3/Stubs/FeedItemValidationStatus.cs | 190 + src/V3/Stubs/FeedLinkStatus.cs | 185 + src/V3/Stubs/FeedMapping.cs | 1433 +++ src/V3/Stubs/FeedMappingCriterionType.cs | 186 + src/V3/Stubs/FeedMappingError.cs | 265 + src/V3/Stubs/FeedMappingService.cs | 949 ++ src/V3/Stubs/FeedMappingServiceClient.cs | 898 ++ src/V3/Stubs/FeedMappingServiceGrpc.cs | 229 + src/V3/Stubs/FeedMappingStatus.cs | 185 + src/V3/Stubs/FeedOrigin.cs | 187 + src/V3/Stubs/FeedPlaceholderView.cs | 229 + src/V3/Stubs/FeedPlaceholderViewService.cs | 196 + .../Stubs/FeedPlaceholderViewServiceClient.cs | 561 + .../Stubs/FeedPlaceholderViewServiceGrpc.cs | 158 + src/V3/Stubs/FeedService.cs | 1030 ++ src/V3/Stubs/FeedServiceClient.cs | 898 ++ src/V3/Stubs/FeedServiceGrpc.cs | 229 + src/V3/Stubs/FeedStatus.cs | 184 + src/V3/Stubs/FieldError.cs | 207 + src/V3/Stubs/FieldMaskError.cs | 196 + src/V3/Stubs/FinalAppUrl.cs | 233 + src/V3/Stubs/FlightPlaceholderField.cs | 276 + src/V3/Stubs/FrequencyCap.cs | 482 + src/V3/Stubs/FrequencyCapEventType.cs | 185 + src/V3/Stubs/FrequencyCapLevel.cs | 190 + src/V3/Stubs/FrequencyCapTimeUnit.cs | 189 + src/V3/Stubs/FunctionError.cs | 252 + src/V3/Stubs/FunctionParsingError.cs | 228 + src/V3/Stubs/GenderType.cs | 189 + src/V3/Stubs/GenderView.cs | 193 + src/V3/Stubs/GenderViewService.cs | 194 + src/V3/Stubs/GenderViewServiceClient.cs | 561 + src/V3/Stubs/GenderViewServiceGrpc.cs | 158 + src/V3/Stubs/GeoTargetConstant.cs | 421 + src/V3/Stubs/GeoTargetConstantService.cs | 1184 +++ .../Stubs/GeoTargetConstantServiceClient.cs | 775 ++ src/V3/Stubs/GeoTargetConstantServiceGrpc.cs | 224 + src/V3/Stubs/GeoTargetConstantStatus.cs | 188 + .../Stubs/GeoTargetConstantSuggestionError.cs | 198 + src/V3/Stubs/GeoTargetingRestriction.cs | 183 + src/V3/Stubs/GeoTargetingType.cs | 185 + src/V3/Stubs/GeographicView.cs | 272 + src/V3/Stubs/GeographicViewService.cs | 195 + src/V3/Stubs/GeographicViewServiceClient.cs | 561 + src/V3/Stubs/GeographicViewServiceGrpc.cs | 158 + src/V3/Stubs/GoogleAdsField.cs | 639 ++ src/V3/Stubs/GoogleAdsFieldCategory.cs | 199 + src/V3/Stubs/GoogleAdsFieldDataType.cs | 249 + src/V3/Stubs/GoogleAdsFieldService.cs | 599 ++ src/V3/Stubs/GoogleAdsFieldServiceClient.cs | 755 ++ src/V3/Stubs/GoogleAdsFieldServiceGrpc.cs | 224 + src/V3/Stubs/GoogleAdsService.cs | 9329 ++++++++++++++++ src/V3/Stubs/GoogleAdsServiceClient.cs | 1515 +++ src/V3/Stubs/GoogleAdsServiceGrpc.cs | 519 + src/V3/Stubs/GroupPlacementView.cs | 346 + src/V3/Stubs/GroupPlacementViewService.cs | 196 + .../Stubs/GroupPlacementViewServiceClient.cs | 561 + src/V3/Stubs/GroupPlacementViewServiceGrpc.cs | 158 + src/V3/Stubs/HeaderError.cs | 181 + src/V3/Stubs/HotelDateSelectionType.cs | 186 + src/V3/Stubs/HotelGroupView.cs | 194 + src/V3/Stubs/HotelGroupViewService.cs | 195 + src/V3/Stubs/HotelGroupViewServiceClient.cs | 561 + src/V3/Stubs/HotelGroupViewServiceGrpc.cs | 158 + src/V3/Stubs/HotelPerformanceView.cs | 194 + src/V3/Stubs/HotelPerformanceViewService.cs | 196 + .../HotelPerformanceViewServiceClient.cs | 561 + .../Stubs/HotelPerformanceViewServiceGrpc.cs | 158 + src/V3/Stubs/HotelPlaceholderField.cs | 285 + src/V3/Stubs/HotelPriceBucket.cs | 187 + src/V3/Stubs/HotelRateType.cs | 200 + src/V3/Stubs/IdError.cs | 180 + src/V3/Stubs/ImageError.cs | 353 + src/V3/Stubs/IncomeRangeType.cs | 208 + src/V3/Stubs/InteractionEventType.cs | 200 + src/V3/Stubs/InteractionType.cs | 180 + src/V3/Stubs/InternalError.cs | 196 + src/V3/Stubs/Invoice.cs | 1321 +++ src/V3/Stubs/InvoiceError.cs | 185 + src/V3/Stubs/InvoiceService.cs | 426 + src/V3/Stubs/InvoiceServiceClient.cs | 615 ++ src/V3/Stubs/InvoiceServiceGrpc.cs | 158 + src/V3/Stubs/InvoiceType.cs | 184 + src/V3/Stubs/JobPlaceholderField.cs | 271 + src/V3/Stubs/KeywordMatchType.cs | 189 + src/V3/Stubs/KeywordPlan.cs | 531 + src/V3/Stubs/KeywordPlanAdGroup.cs | 355 + src/V3/Stubs/KeywordPlanAdGroupError.cs | 189 + src/V3/Stubs/KeywordPlanAdGroupService.cs | 1038 ++ .../Stubs/KeywordPlanAdGroupServiceClient.cs | 898 ++ src/V3/Stubs/KeywordPlanAdGroupServiceGrpc.cs | 229 + src/V3/Stubs/KeywordPlanCampaign.cs | 592 ++ src/V3/Stubs/KeywordPlanCampaignError.cs | 202 + src/V3/Stubs/KeywordPlanCampaignService.cs | 1040 ++ .../Stubs/KeywordPlanCampaignServiceClient.cs | 898 ++ .../Stubs/KeywordPlanCampaignServiceGrpc.cs | 229 + src/V3/Stubs/KeywordPlanCommon.cs | 229 + src/V3/Stubs/KeywordPlanCompetitionLevel.cs | 194 + src/V3/Stubs/KeywordPlanError.cs | 244 + src/V3/Stubs/KeywordPlanForecastInterval.cs | 193 + src/V3/Stubs/KeywordPlanIdeaError.cs | 186 + src/V3/Stubs/KeywordPlanIdeaService.cs | 1207 +++ src/V3/Stubs/KeywordPlanIdeaServiceClient.cs | 612 ++ src/V3/Stubs/KeywordPlanIdeaServiceGrpc.cs | 158 + src/V3/Stubs/KeywordPlanKeyword.cs | 385 + src/V3/Stubs/KeywordPlanKeywordError.cs | 207 + src/V3/Stubs/KeywordPlanKeywordService.cs | 1038 ++ .../Stubs/KeywordPlanKeywordServiceClient.cs | 898 ++ src/V3/Stubs/KeywordPlanKeywordServiceGrpc.cs | 229 + src/V3/Stubs/KeywordPlanNegativeKeyword.cs | 347 + .../Stubs/KeywordPlanNegativeKeywordError.cs | 180 + .../KeywordPlanNegativeKeywordService.cs | 1046 ++ ...KeywordPlanNegativeKeywordServiceClient.cs | 904 ++ .../KeywordPlanNegativeKeywordServiceGrpc.cs | 229 + src/V3/Stubs/KeywordPlanNetwork.cs | 185 + src/V3/Stubs/KeywordPlanService.cs | 2676 +++++ src/V3/Stubs/KeywordPlanServiceClient.cs | 1291 +++ src/V3/Stubs/KeywordPlanServiceGrpc.cs | 361 + src/V3/Stubs/KeywordView.cs | 193 + src/V3/Stubs/KeywordViewService.cs | 194 + src/V3/Stubs/KeywordViewServiceClient.cs | 561 + src/V3/Stubs/KeywordViewServiceGrpc.cs | 158 + src/V3/Stubs/Label.cs | 345 + src/V3/Stubs/LabelError.cs | 222 + src/V3/Stubs/LabelService.cs | 1029 ++ src/V3/Stubs/LabelServiceClient.cs | 887 ++ src/V3/Stubs/LabelServiceGrpc.cs | 224 + src/V3/Stubs/LabelStatus.cs | 184 + src/V3/Stubs/LandingPageView.cs | 234 + src/V3/Stubs/LandingPageViewService.cs | 195 + src/V3/Stubs/LandingPageViewServiceClient.cs | 561 + src/V3/Stubs/LandingPageViewServiceGrpc.cs | 158 + src/V3/Stubs/LanguageCodeError.cs | 186 + src/V3/Stubs/LanguageConstant.cs | 348 + src/V3/Stubs/LanguageConstantService.cs | 195 + src/V3/Stubs/LanguageConstantServiceClient.cs | 561 + src/V3/Stubs/LanguageConstantServiceGrpc.cs | 158 + src/V3/Stubs/LegacyAppInstallAdAppStore.cs | 199 + src/V3/Stubs/ListOperationError.cs | 186 + src/V3/Stubs/ListingGroupType.cs | 187 + src/V3/Stubs/LocalPlaceholderField.cs | 278 + ...ocationExtensionTargetingCriterionField.cs | 205 + src/V3/Stubs/LocationGroupRadiusUnits.cs | 185 + src/V3/Stubs/LocationPlaceholderField.cs | 212 + src/V3/Stubs/LocationView.cs | 194 + src/V3/Stubs/LocationViewService.cs | 195 + src/V3/Stubs/LocationViewServiceClient.cs | 561 + src/V3/Stubs/LocationViewServiceGrpc.cs | 158 + src/V3/Stubs/ManagedPlacementView.cs | 195 + src/V3/Stubs/ManagedPlacementViewService.cs | 196 + .../ManagedPlacementViewServiceClient.cs | 561 + .../Stubs/ManagedPlacementViewServiceGrpc.cs | 158 + src/V3/Stubs/ManagerLinkError.cs | 249 + src/V3/Stubs/ManagerLinkStatus.cs | 200 + src/V3/Stubs/MatchingFunction.cs | 1350 +++ src/V3/Stubs/MatchingFunctionContextType.cs | 186 + src/V3/Stubs/MatchingFunctionOperator.cs | 204 + src/V3/Stubs/MediaBundleError.cs | 278 + src/V3/Stubs/MediaFile.cs | 1307 +++ src/V3/Stubs/MediaFileError.cs | 284 + src/V3/Stubs/MediaFileService.cs | 911 ++ src/V3/Stubs/MediaFileServiceClient.cs | 887 ++ src/V3/Stubs/MediaFileServiceGrpc.cs | 224 + src/V3/Stubs/MediaType.cs | 203 + src/V3/Stubs/MediaUploadError.cs | 209 + src/V3/Stubs/MerchantCenterLink.cs | 309 + src/V3/Stubs/MerchantCenterLinkService.cs | 1186 +++ .../Stubs/MerchantCenterLinkServiceClient.cs | 968 ++ src/V3/Stubs/MerchantCenterLinkServiceGrpc.cs | 291 + src/V3/Stubs/MerchantCenterLinkStatus.cs | 188 + src/V3/Stubs/MessagePlaceholderField.cs | 201 + src/V3/Stubs/Metrics.cs | 4562 ++++++++ src/V3/Stubs/MimeType.cs | 229 + src/V3/Stubs/MinuteOfHour.cs | 193 + src/V3/Stubs/MobileAppCategoryConstant.cs | 272 + .../Stubs/MobileAppCategoryConstantService.cs | 198 + .../MobileAppCategoryConstantServiceClient.cs | 561 + .../MobileAppCategoryConstantServiceGrpc.cs | 158 + src/V3/Stubs/MobileDeviceConstant.cs | 382 + src/V3/Stubs/MobileDeviceConstantService.cs | 196 + .../MobileDeviceConstantServiceClient.cs | 561 + .../Stubs/MobileDeviceConstantServiceGrpc.cs | 158 + src/V3/Stubs/MobileDeviceType.cs | 185 + src/V3/Stubs/MonthOfYear.cs | 227 + src/V3/Stubs/MultiplierError.cs | 237 + ...upAdLabelsResponsePartialFailureSupport.cs | 46 + ...AdGroupAdsResponsePartialFailureSupport.cs | 46 + ...dModifiersResponsePartialFailureSupport.cs | 46 + ...upCriteriaResponsePartialFailureSupport.cs | 46 + ...rionLabelsResponsePartialFailureSupport.cs | 46 + ...onSettingsResponsePartialFailureSupport.cs | 46 + ...GroupFeedsResponsePartialFailureSupport.cs | 46 + ...roupLabelsResponsePartialFailureSupport.cs | 46 + ...teAdGroupsResponsePartialFailureSupport.cs | 46 + ...ParametersResponsePartialFailureSupport.cs | 46 + ...StrategiesResponsePartialFailureSupport.cs | 46 + ...dModifiersResponsePartialFailureSupport.cs | 46 + ...ignBudgetsResponsePartialFailureSupport.cs | 46 + ...gnCriteriaResponsePartialFailureSupport.cs | 46 + ...aignDraftsResponsePartialFailureSupport.cs | 46 + ...xperimentsResponsePartialFailureSupport.cs | 46 + ...onSettingsResponsePartialFailureSupport.cs | 46 + ...paignFeedsResponsePartialFailureSupport.cs | 46 + ...aignLabelsResponsePartialFailureSupport.cs | 46 + ...SharedSetsResponsePartialFailureSupport.cs | 46 + ...eCampaignsResponsePartialFailureSupport.cs | 46 + ...ionActionsResponsePartialFailureSupport.cs | 46 + ...onSettingsResponsePartialFailureSupport.cs | 46 + ...tomerFeedsResponsePartialFailureSupport.cs | 46 + ...omerLabelsResponsePartialFailureSupport.cs | 46 + ...veCriteriaResponsePartialFailureSupport.cs | 46 + src/V3/Stubs/MutateError.cs | 205 + ...eFeedItemsResponsePartialFailureSupport.cs | 46 + ...edMappingsResponsePartialFailureSupport.cs | 46 + ...utateFeedsResponsePartialFailureSupport.cs | 46 + ...eGoogleAdsResponsePartialFailureSupport.cs | 46 + src/V3/Stubs/MutateJob.cs | 695 ++ src/V3/Stubs/MutateJobError.cs | 200 + src/V3/Stubs/MutateJobService.cs | 1593 +++ src/V3/Stubs/MutateJobServiceClient.cs | 1502 +++ src/V3/Stubs/MutateJobServiceGrpc.cs | 447 + src/V3/Stubs/MutateJobStatus.cs | 189 + ...anAdGroupsResponsePartialFailureSupport.cs | 46 + ...nCampaignsResponsePartialFailureSupport.cs | 46 + ...anKeywordsResponsePartialFailureSupport.cs | 46 + ...veKeywordsResponsePartialFailureSupport.cs | 46 + ...ywordPlansResponsePartialFailureSupport.cs | 46 + ...tateLabelsResponsePartialFailureSupport.cs | 46 + ...MediaFilesResponsePartialFailureSupport.cs | 46 + ...ingActionsResponsePartialFailureSupport.cs | 46 + ...edCriteriaResponsePartialFailureSupport.cs | 46 + ...SharedSetsResponsePartialFailureSupport.cs | 46 + ...eUserListsResponsePartialFailureSupport.cs | 46 + src/V3/Stubs/NegativeGeoTargetType.cs | 188 + src/V3/Stubs/NewResourceCreationError.cs | 192 + src/V3/Stubs/NotEmptyError.cs | 180 + src/V3/Stubs/NotWhitelistedError.cs | 182 + src/V3/Stubs/NullError.cs | 180 + .../Stubs/OperatingSystemVersionConstant.cs | 388 + .../OperatingSystemVersionConstantService.cs | 199 + ...atingSystemVersionConstantServiceClient.cs | 561 + ...eratingSystemVersionConstantServiceGrpc.cs | 158 + .../OperatingSystemVersionOperatorType.cs | 187 + src/V3/Stubs/OperationAccessDeniedError.cs | 226 + src/V3/Stubs/OperatorError.cs | 181 + src/V3/Stubs/PageOnePromotedStrategyGoal.cs | 45 + src/V3/Stubs/PaidOrganicSearchTermView.cs | 237 + .../Stubs/PaidOrganicSearchTermViewService.cs | 198 + .../PaidOrganicSearchTermViewServiceClient.cs | 561 + .../PaidOrganicSearchTermViewServiceGrpc.cs | 158 + src/V3/Stubs/ParentalStatusType.cs | 189 + src/V3/Stubs/ParentalStatusView.cs | 194 + src/V3/Stubs/ParentalStatusViewService.cs | 196 + .../Stubs/ParentalStatusViewServiceClient.cs | 561 + src/V3/Stubs/ParentalStatusViewServiceGrpc.cs | 158 + src/V3/Stubs/PartialFailureError.cs | 182 + src/V3/Stubs/PaymentMode.cs | 201 + src/V3/Stubs/PaymentsAccount.cs | 390 + src/V3/Stubs/PaymentsAccountError.cs | 182 + src/V3/Stubs/PaymentsAccountService.cs | 326 + src/V3/Stubs/PaymentsAccountServiceClient.cs | 576 + src/V3/Stubs/PaymentsAccountServiceGrpc.cs | 169 + src/V3/Stubs/PlaceholderType.cs | 279 + src/V3/Stubs/PlacementType.cs | 198 + src/V3/Stubs/Policy.cs | 2631 +++++ src/V3/Stubs/PolicyApprovalStatus.cs | 199 + src/V3/Stubs/PolicyFindingError.cs | 187 + src/V3/Stubs/PolicyReviewStatus.cs | 198 + src/V3/Stubs/PolicyTopicEntryType.cs | 207 + ...TopicEvidenceDestinationMismatchUrlType.cs | 204 + ...opicEvidenceDestinationNotWorkingDevice.cs | 195 + ...idenceDestinationNotWorkingDnsErrorType.cs | 194 + .../Stubs/PolicyValidationParameterError.cs | 195 + src/V3/Stubs/PolicyViolationError.cs | 181 + src/V3/Stubs/PositiveGeoTargetType.cs | 193 + src/V3/Stubs/PreferredContentType.cs | 181 + src/V3/Stubs/PriceExtensionPriceQualifier.cs | 190 + src/V3/Stubs/PriceExtensionPriceUnit.cs | 203 + src/V3/Stubs/PriceExtensionType.cs | 216 + src/V3/Stubs/PricePlaceholderField.cs | 452 + .../Stubs/ProductBiddingCategoryConstant.cs | 464 + .../ProductBiddingCategoryConstantService.cs | 199 + ...uctBiddingCategoryConstantServiceClient.cs | 561 + ...oductBiddingCategoryConstantServiceGrpc.cs | 158 + src/V3/Stubs/ProductBiddingCategoryLevel.cs | 199 + src/V3/Stubs/ProductBiddingCategoryStatus.cs | 186 + src/V3/Stubs/ProductChannel.cs | 184 + src/V3/Stubs/ProductChannelExclusivity.cs | 188 + src/V3/Stubs/ProductCondition.cs | 189 + src/V3/Stubs/ProductCustomAttributeIndex.cs | 199 + src/V3/Stubs/ProductGroupView.cs | 194 + src/V3/Stubs/ProductGroupViewService.cs | 195 + src/V3/Stubs/ProductGroupViewServiceClient.cs | 561 + src/V3/Stubs/ProductGroupViewServiceGrpc.cs | 158 + src/V3/Stubs/ProductTypeLevel.cs | 198 + .../PromotionExtensionDiscountModifier.cs | 183 + src/V3/Stubs/PromotionExtensionOccasion.cs | 341 + src/V3/Stubs/PromotionPlaceholderField.cs | 248 + src/V3/Stubs/ProximityRadiusUnits.cs | 185 + src/V3/Stubs/QualityScoreBucket.cs | 189 + src/V3/Stubs/QueryError.cs | 440 + src/V3/Stubs/QuotaError.cs | 190 + src/V3/Stubs/RangeError.cs | 184 + src/V3/Stubs/ReachPlanAdLength.cs | 190 + src/V3/Stubs/ReachPlanAgeRange.cs | 293 + src/V3/Stubs/ReachPlanError.cs | 177 + src/V3/Stubs/ReachPlanNetwork.cs | 191 + src/V3/Stubs/ReachPlanService.cs | 4054 +++++++ src/V3/Stubs/ReachPlanServiceClient.cs | 980 ++ src/V3/Stubs/ReachPlanServiceGrpc.cs | 375 + src/V3/Stubs/RealEstatePlaceholderField.cs | 274 + src/V3/Stubs/RealTimeBiddingSetting.cs | 194 + src/V3/Stubs/Recommendation.cs | 4191 ++++++++ src/V3/Stubs/RecommendationError.cs | 245 + src/V3/Stubs/RecommendationService.cs | 3129 ++++++ src/V3/Stubs/RecommendationServiceClient.cs | 1201 +++ src/V3/Stubs/RecommendationServiceGrpc.cs | 290 + src/V3/Stubs/RecommendationType.cs | 246 + src/V3/Stubs/RegionCodeError.cs | 181 + src/V3/Stubs/RemarketingAction.cs | 302 + src/V3/Stubs/RemarketingActionService.cs | 999 ++ .../Stubs/RemarketingActionServiceClient.cs | 887 ++ src/V3/Stubs/RemarketingActionServiceGrpc.cs | 224 + src/V3/Stubs/RequestError.cs | 286 + src/V3/Stubs/ResourceAccessDeniedError.cs | 182 + .../Stubs/ResourceCountLimitExceededError.cs | 241 + src/V3/Stubs/ResourceNames.cs | 9134 ++++++++++++++++ src/V3/Stubs/SearchEngineResultsPageType.cs | 191 + src/V3/Stubs/SearchTermMatchType.cs | 198 + src/V3/Stubs/SearchTermTargetingStatus.cs | 196 + src/V3/Stubs/SearchTermView.cs | 309 + src/V3/Stubs/SearchTermViewService.cs | 195 + src/V3/Stubs/SearchTermViewServiceClient.cs | 561 + src/V3/Stubs/SearchTermViewServiceGrpc.cs | 158 + src/V3/Stubs/Segments.cs | 3258 ++++++ src/V3/Stubs/ServedAssetFieldType.cs | 201 + src/V3/Stubs/SettingError.cs | 238 + src/V3/Stubs/SharedCriterion.cs | 597 ++ src/V3/Stubs/SharedCriterionError.cs | 182 + src/V3/Stubs/SharedCriterionService.cs | 952 ++ src/V3/Stubs/SharedCriterionServiceClient.cs | 887 ++ src/V3/Stubs/SharedCriterionServiceGrpc.cs | 224 + src/V3/Stubs/SharedSet.cs | 420 + src/V3/Stubs/SharedSetError.cs | 195 + src/V3/Stubs/SharedSetService.cs | 1032 ++ src/V3/Stubs/SharedSetServiceClient.cs | 887 ++ src/V3/Stubs/SharedSetServiceGrpc.cs | 224 + src/V3/Stubs/SharedSetStatus.cs | 185 + src/V3/Stubs/SharedSetType.cs | 185 + src/V3/Stubs/ShoppingPerformanceView.cs | 199 + .../Stubs/ShoppingPerformanceViewService.cs | 198 + .../ShoppingPerformanceViewServiceClient.cs | 561 + .../ShoppingPerformanceViewServiceGrpc.cs | 158 + src/V3/Stubs/Simulation.cs | 2226 ++++ src/V3/Stubs/SimulationModificationMethod.cs | 190 + src/V3/Stubs/SimulationType.cs | 193 + src/V3/Stubs/SitelinkPlaceholderField.cs | 211 + src/V3/Stubs/SizeLimitError.cs | 186 + src/V3/Stubs/Slot.cs | 206 + src/V3/Stubs/SpendingLimitType.cs | 182 + src/V3/Stubs/StringFormatError.cs | 185 + src/V3/Stubs/StringLengthError.cs | 190 + .../StructuredSnippetPlaceholderField.cs | 191 + src/V3/Stubs/SummaryRowSetting.cs | 191 + src/V3/Stubs/SystemManagedEntitySource.cs | 182 + src/V3/Stubs/TagSnippet.cs | 303 + .../Stubs/TargetCpaOptInRecommendationGoal.cs | 196 + src/V3/Stubs/TargetImpressionShareLocation.cs | 193 + src/V3/Stubs/TargetingDimension.cs | 217 + src/V3/Stubs/TargetingSetting.cs | 602 ++ src/V3/Stubs/TextLabel.cs | 234 + src/V3/Stubs/TimeType.cs | 185 + src/V3/Stubs/TimeZoneError.cs | 181 + src/V3/Stubs/TopicConstant.cs | 301 + src/V3/Stubs/TopicConstantService.cs | 194 + src/V3/Stubs/TopicConstantServiceClient.cs | 561 + src/V3/Stubs/TopicConstantServiceGrpc.cs | 158 + src/V3/Stubs/TopicView.cs | 193 + src/V3/Stubs/TopicViewService.cs | 194 + src/V3/Stubs/TopicViewServiceClient.cs | 561 + src/V3/Stubs/TopicViewServiceGrpc.cs | 158 + src/V3/Stubs/TrackingCodePageFormat.cs | 187 + src/V3/Stubs/TrackingCodeType.cs | 199 + src/V3/Stubs/TravelPlaceholderField.cs | 289 + ...onversionsResponsePartialFailureSupport.cs | 46 + ...onversionsResponsePartialFailureSupport.cs | 46 + ...djustmentsResponsePartialFailureSupport.cs | 46 + src/V3/Stubs/UrlCollection.cs | 280 + src/V3/Stubs/UrlFieldError.cs | 439 + src/V3/Stubs/UserInterest.cs | 410 + src/V3/Stubs/UserInterestService.cs | 195 + src/V3/Stubs/UserInterestServiceClient.cs | 561 + src/V3/Stubs/UserInterestServiceGrpc.cs | 158 + src/V3/Stubs/UserInterestTaxonomyType.cs | 199 + src/V3/Stubs/UserList.cs | 1100 ++ src/V3/Stubs/UserListAccessStatus.cs | 185 + src/V3/Stubs/UserListClosingReason.cs | 182 + src/V3/Stubs/UserListCombinedRuleOperator.cs | 186 + src/V3/Stubs/UserListCrmDataSourceType.cs | 191 + src/V3/Stubs/UserListDateRuleItemOperator.cs | 194 + src/V3/Stubs/UserListError.cs | 308 + src/V3/Stubs/UserListLogicalRuleOperator.cs | 190 + src/V3/Stubs/UserListMembershipStatus.cs | 187 + .../Stubs/UserListNumberRuleItemOperator.cs | 204 + src/V3/Stubs/UserListPrepopulationStatus.cs | 190 + src/V3/Stubs/UserListRuleType.cs | 185 + src/V3/Stubs/UserListService.cs | 1031 ++ src/V3/Stubs/UserListServiceClient.cs | 887 ++ src/V3/Stubs/UserListServiceGrpc.cs | 224 + src/V3/Stubs/UserListSizeRange.cs | 253 + .../Stubs/UserListStringRuleItemOperator.cs | 212 + src/V3/Stubs/UserListType.cs | 203 + src/V3/Stubs/UserLists.cs | 3313 ++++++ src/V3/Stubs/UserLocationView.cs | 277 + src/V3/Stubs/UserLocationViewService.cs | 195 + src/V3/Stubs/UserLocationViewServiceClient.cs | 561 + src/V3/Stubs/UserLocationViewServiceGrpc.cs | 158 + src/V3/Stubs/Value.cs | 351 + src/V3/Stubs/VanityPharmaDisplayUrlMode.cs | 186 + src/V3/Stubs/VanityPharmaText.cs | 241 + src/V3/Stubs/Video.cs | 346 + src/V3/Stubs/VideoService.cs | 193 + src/V3/Stubs/VideoServiceClient.cs | 561 + src/V3/Stubs/VideoServiceGrpc.cs | 158 + src/V3/Stubs/WebpageConditionOperand.cs | 199 + src/V3/Stubs/WebpageConditionOperator.cs | 186 + src/V3/Stubs/YoutubeVideoRegistrationError.cs | 191 + tests/Config/GoogleAdsConfigTests.cs | 152 +- tests/Examples/ExampleTestsBase.cs | 6 +- .../AdvancedOperations/AddAppCampaignTest.cs | 47 + .../AddSmartDisplayAdTest.cs | 7 +- .../BasicOperations/AddAdGroupsTest.cs | 7 +- .../BasicOperations/AddCampaignsTest.cs | 7 +- .../BasicOperations/AddExpandedTextAdsTest.cs | 7 +- .../BasicOperations/AddKeywordsTest.cs | 7 +- .../AddResponsiveSearchAdTest.cs | 7 +- .../BasicOperations/GetAdGroupsTest.cs | 7 +- .../GetArtifactMetadataTest.cs | 7 +- .../BasicOperations/GetCampaignsTest.cs | 7 +- .../BasicOperations/GetExpandedTextAdsTest.cs | 7 +- .../BasicOperations/GetKeywordsTest.cs | 7 +- .../{V2 => V3}/BasicOperations/PauseAdTest.cs | 7 +- .../BasicOperations/RemoveAdGroupTest.cs | 7 +- .../BasicOperations/RemoveAdTest.cs | 7 +- .../BasicOperations/RemoveCampaignTest.cs | 7 +- .../BasicOperations/RemoveKeywordTest.cs | 7 +- .../BasicOperations/UpdateAdGroupTest.cs | 7 +- .../BasicOperations/UpdateCampaignTest.cs | 7 +- .../BasicOperations/UpdateKeywordTest.cs | 7 +- .../UpdateCampaignCriterionBidModifierTest.cs | 67 + .../CampaignManagement/ValidateTextAdTest.cs | 7 +- .../Examples/{V2 => V3}/ExampleTestsUtils.cs | 69 +- ...dGoogleMyBusinessLocationExtensionsTest.cs | 52 + tests/Examples/V3/Extensions/AddPricesTest.cs | 56 + .../{V2 => V3}/Misc/GetAllImageAssetsTest.cs | 7 +- .../Misc/GetAllVideosAndImagesTest.cs | 7 +- .../{V2 => V3}/Misc/UploadImageAssetTest.cs | 7 +- .../{V2 => V3}/Misc/UploadImageTest.cs | 7 +- .../{V2 => V3}/Misc/UploadMediaBundleTest.cs | 7 +- .../V3/ShoppingAds/AddListingScopeTest.cs | 56 + tests/Google.Ads.GoogleAds.Tests.csproj | 18 +- .../StreamingRpcInterceptorTests.cs | 100 + .../Interceptors/UnaryRpcInterceptorTests.cs | 213 + tests/Lib/CachedChannelFactoryTests.cs | 5 + tests/Lib/GoogleAdsClientTests.cs | 21 +- .../Lib/GoogleAdsServiceClientFactoryTests.cs | 5 + tests/Logging/V1/LogEntryTests.cs | 13 +- ...rceptorTests.cs => LoggingHandlerTests.cs} | 255 +- tests/Logging/V2/LogEntryTests.cs | 13 +- ...rceptorTests.cs => LoggingHandlerTests.cs} | 255 +- tests/Logging/V3/LogEntryTests.cs | 216 + tests/Logging/V3/LoggingHandlerTests.cs | 452 + tests/StubIntegrityTestHelper.cs | 10 +- tests/TestStreamReader.cs | 101 + tests/Util/CollectionUtilitiesTest.cs | 76 +- tests/Util/Examples/ExampleRunnerTest.cs | 41 +- tests/Util/Examples/FlagTest.cs | 15 +- tests/Util/Examples/TestExample.cs | 14 +- tests/Util/FieldMasksTest.cs | 92 +- tests/Util/HttpUtilitiesTest.cs | 3 +- tests/Util/MediaUtilitiesTest.cs | 5 +- tests/Util/TraceUtilitiesTest.cs | 13 +- tests/V1/GoogleAdsFailureExtensionsTests.cs | 2 +- .../GeoTargetConstantServiceClientTest.g.cs | 196 - .../KeywordPlanIdeaServiceClientTest.g.cs | 126 - tests/V1/TestUtils.cs | 10 +- tests/V2/GoogleAdsFailureExtensionsTests.cs | 2 +- .../GeoTargetConstantServiceClientTest.g.cs | 196 - .../KeywordPlanIdeaServiceClientTest.g.cs | 126 - tests/V2/TestUtils.cs | 10 +- tests/V3/GoogleAdsFailureExtensionsTests.cs | 223 + ...ccountBudgetProposalServiceClientTest.g.cs | 240 + .../AccountBudgetServiceClientTest.g.cs | 120 + .../AdGroupAdAssetViewServiceClientTest.g.cs | 120 + .../AdGroupAdLabelServiceClientTest.g.cs | 244 + .../Services/AdGroupAdServiceClientTest.g.cs | 244 + .../AdGroupAudienceViewServiceClientTest.g.cs | 120 + .../AdGroupBidModifierServiceClientTest.g.cs | 244 + ...dGroupCriterionLabelServiceClientTest.g.cs | 244 + .../AdGroupCriterionServiceClientTest.g.cs | 244 + ...pCriterionSimulationServiceClientTest.g.cs | 120 + ...roupExtensionSettingServiceClientTest.g.cs | 244 + .../AdGroupFeedServiceClientTest.g.cs | 244 + .../AdGroupLabelServiceClientTest.g.cs | 244 + .../V3/Services/AdGroupServiceClientTest.g.cs | 244 + .../AdGroupSimulationServiceClientTest.g.cs | 120 + .../AdParameterServiceClientTest.g.cs | 244 + .../AdScheduleViewServiceClientTest.g.cs | 120 + tests/V3/Services/AdServiceClientTest.g.cs | 196 + .../AgeRangeViewServiceClientTest.g.cs | 120 + tests/V3/Services/AssetServiceClientTest.g.cs | 196 + .../BiddingStrategyServiceClientTest.g.cs | 244 + .../BillingSetupServiceClientTest.g.cs | 196 + ...CampaignAudienceViewServiceClientTest.g.cs | 120 + .../CampaignBidModifierServiceClientTest.g.cs | 244 + .../CampaignBudgetServiceClientTest.g.cs | 244 + .../CampaignCriterionServiceClientTest.g.cs | 244 + ...nCriterionSimulationServiceClientTest.g.cs | 120 + .../CampaignDraftServiceClientTest.g.cs | 265 + .../CampaignExperimentServiceClientTest.g.cs | 435 + ...aignExtensionSettingServiceClientTest.g.cs | 244 + .../CampaignFeedServiceClientTest.g.cs | 244 + .../CampaignLabelServiceClientTest.g.cs | 244 + .../Services/CampaignServiceClientTest.g.cs | 244 + .../CampaignSharedSetServiceClientTest.g.cs | 244 + .../CarrierConstantServiceClientTest.g.cs | 120 + .../ChangeStatusServiceClientTest.g.cs | 120 + .../Services/ClickViewServiceClientTest.g.cs | 120 + .../ConversionActionServiceClientTest.g.cs | 244 + ...sionAdjustmentUploadServiceClientTest.g.cs | 161 + .../ConversionUploadServiceClientTest.g.cs | 285 + .../CurrencyConstantServiceClientTest.g.cs | 120 + .../CustomInterestServiceClientTest.g.cs | 240 + .../CustomerClientLinkServiceClientTest.g.cs | 196 + .../CustomerClientServiceClientTest.g.cs | 120 + ...omerExtensionSettingServiceClientTest.g.cs | 244 + .../CustomerFeedServiceClientTest.g.cs | 244 + .../CustomerLabelServiceClientTest.g.cs | 244 + .../CustomerManagerLinkServiceClientTest.g.cs | 290 + ...merNegativeCriterionServiceClientTest.g.cs | 244 + .../Services/CustomerServiceClientTest.g.cs | 411 + .../DetailPlacementViewServiceClientTest.g.cs | 120 + .../DisplayKeywordViewServiceClientTest.g.cs | 120 + .../DistanceViewServiceClientTest.g.cs | 120 + .../DomainCategoryServiceClientTest.g.cs | 120 + ...rchAdsSearchTermViewServiceClientTest.g.cs | 120 + ...andedLandingPageViewServiceClientTest.g.cs | 120 + .../ExtensionFeedItemServiceClientTest.g.cs | 244 + .../Services/FeedItemServiceClientTest.g.cs | 244 + .../FeedItemTargetServiceClientTest.g.cs | 196 + .../FeedMappingServiceClientTest.g.cs | 244 + .../FeedPlaceholderViewServiceClientTest.g.cs | 120 + tests/V3/Services/FeedServiceClientTest.g.cs | 244 + .../Services/GenderViewServiceClientTest.g.cs | 120 + .../GeographicViewServiceClientTest.g.cs | 120 + .../GoogleAdsFieldServiceClientTest.g.cs | 120 + .../Services/GoogleAdsServiceClientTest.g.cs | 161 + .../GroupPlacementViewServiceClientTest.g.cs | 120 + .../HotelGroupViewServiceClientTest.g.cs | 120 + ...HotelPerformanceViewServiceClientTest.g.cs | 120 + .../V3/Services/InvoiceServiceClientTest.g.cs | 126 + .../KeywordPlanAdGroupServiceClientTest.g.cs | 244 + .../KeywordPlanCampaignServiceClientTest.g.cs | 244 + .../KeywordPlanKeywordServiceClientTest.g.cs | 244 + ...dPlanNegativeKeywordServiceClientTest.g.cs | 244 + .../KeywordPlanServiceClientTest.g.cs | 384 + .../KeywordViewServiceClientTest.g.cs | 120 + tests/V3/Services/LabelServiceClientTest.g.cs | 244 + .../LandingPageViewServiceClientTest.g.cs | 120 + .../LanguageConstantServiceClientTest.g.cs | 120 + .../LocationViewServiceClientTest.g.cs | 120 + ...ManagedPlacementViewServiceClientTest.g.cs | 120 + .../Services/MediaFileServiceClientTest.g.cs | 244 + .../MerchantCenterLinkServiceClientTest.g.cs | 266 + ...eAppCategoryConstantServiceClientTest.g.cs | 120 + ...MobileDeviceConstantServiceClientTest.g.cs | 120 + .../Services/MutateJobServiceClientTest.g.cs | 325 + ...ystemVersionConstantServiceClientTest.g.cs | 120 + ...rganicSearchTermViewServiceClientTest.g.cs | 120 + .../ParentalStatusViewServiceClientTest.g.cs | 120 + .../PaymentsAccountServiceClientTest.g.cs | 107 + ...dingCategoryConstantServiceClientTest.g.cs | 120 + .../ProductGroupViewServiceClientTest.g.cs | 120 + .../RecommendationServiceClientTest.g.cs | 360 + .../RemarketingActionServiceClientTest.g.cs | 244 + .../SearchTermViewServiceClientTest.g.cs | 120 + .../SharedCriterionServiceClientTest.g.cs | 244 + .../Services/SharedSetServiceClientTest.g.cs | 244 + ...ppingPerformanceViewServiceClientTest.g.cs | 120 + .../TopicConstantServiceClientTest.g.cs | 120 + .../Services/TopicViewServiceClientTest.g.cs | 120 + .../UserInterestServiceClientTest.g.cs | 120 + .../Services/UserListServiceClientTest.g.cs | 244 + .../UserLocationViewServiceClientTest.g.cs | 120 + tests/V3/Services/VideoServiceClientTest.g.cs | 120 + tests/V3/TestUtils.cs | 68 + 1314 files changed, 419659 insertions(+), 8149 deletions(-) create mode 100644 custom_nupkg/.gitignore create mode 100644 examples/AdvancedOperations/AddAppCampaign.cs create mode 100644 examples/CampaignManagement/UpdateCampaignCriterionBidModifier.cs create mode 100644 examples/Extensions/AddGoogleMyBusinessLocationExtensions.cs create mode 100644 examples/Extensions/AddPrices.cs create mode 100644 examples/ShoppingAds/AddListingScope.cs create mode 100644 src/Interceptors/GoogleAdsGrpcInterceptor.cs create mode 100644 src/Interceptors/StreamingRpcInterceptor.cs create mode 100644 src/Interceptors/UnaryRpcInterceptor.cs create mode 100644 src/Lib/GoogleAdsBaseException.cs create mode 100644 src/Lib/MetadataKeyNames.cs create mode 100644 src/Logging/LoggingHandler.cs delete mode 100644 src/Logging/LoggingInterceptor.cs delete mode 100644 src/V1/Stubs/AccountBudgetProposalServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AccountBudgetServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupAdLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupAdServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupAudienceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupBidModifierServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupCriterionLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupCriterionServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupCriterionSimulationServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupExtensionSettingServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupFeedServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdGroupSimulationServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdParameterServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AdScheduleViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AgeRangeViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/AssetServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/BiddingStrategyServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/BillingSetupServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignAudienceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignBidModifierServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignBudgetServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignCriterionServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignCriterionSimulationServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignDraftServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignExperimentServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignExtensionSettingServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignFeedServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CampaignSharedSetServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CarrierConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ChangeStatusServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ClickViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ConversionActionServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ConversionAdjustmentUploadServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ConversionUploadServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomInterestServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomerClientLinkServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomerClientServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomerExtensionSettingServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomerFeedServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomerLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomerManagerLinkServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomerNegativeCriterionServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/CustomerServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/DetailPlacementViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/DisplayKeywordViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/DomainCategoryServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/DynamicSearchAdsSearchTermViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ExpandedLandingPageViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ExtensionFeedItemServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/FeedItemServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/FeedItemTargetServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/FeedMappingServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/FeedPlaceholderViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/FeedServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/GenderViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/GeoTargetConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/GeographicViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/GoogleAdsFieldServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/GoogleAdsServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/GroupPlacementViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/HotelGroupViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/HotelPerformanceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/KeywordPlanAdGroupServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/KeywordPlanCampaignServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/KeywordPlanIdeaServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/KeywordPlanKeywordServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/KeywordPlanNegativeKeywordServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/KeywordPlanServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/KeywordViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/LabelServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/LandingPageViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/LanguageConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/LocationViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ManagedPlacementViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/MediaFileServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/MerchantCenterLinkServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/MobileAppCategoryConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/MobileDeviceConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/MutateJobServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/OperatingSystemVersionConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/PaidOrganicSearchTermViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ParentalStatusViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/PaymentsAccountServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ProductBiddingCategoryConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ProductGroupViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/RecommendationServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/RemarketingActionServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/SearchTermViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/SharedCriterionServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/SharedSetServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/ShoppingPerformanceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/TopicConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/TopicViewServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/UserInterestServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/UserListServiceClientExceptionCustomization.cs delete mode 100644 src/V1/Stubs/VideoServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AccountBudgetProposalServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AccountBudgetServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupAdAssetViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupAdLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupAdServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupAudienceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupBidModifierServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupCriterionLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupCriterionServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupCriterionSimulationServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupExtensionSettingServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupFeedServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdGroupSimulationServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdParameterServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdScheduleViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AdServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AgeRangeViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/AssetServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/BiddingStrategyServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/BillingSetupServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignAudienceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignBidModifierServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignBudgetServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignCriterionServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignCriterionSimulationServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignDraftServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignExperimentServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignExtensionSettingServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignFeedServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CampaignSharedSetServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CarrierConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ChangeStatusServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ClickViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ConversionActionServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ConversionAdjustmentUploadServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ConversionUploadServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomInterestServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomerClientLinkServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomerClientServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomerExtensionSettingServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomerFeedServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomerLabelServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomerManagerLinkServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomerNegativeCriterionServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/CustomerServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/DetailPlacementViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/DisplayKeywordViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/DistanceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/DomainCategoryServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/DynamicSearchAdsSearchTermViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ExpandedLandingPageViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ExtensionFeedItemServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/FeedItemServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/FeedItemTargetServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/FeedMappingServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/FeedPlaceholderViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/FeedServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/GenderViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/GeoTargetConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/GeographicViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/GoogleAdsFieldServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/GoogleAdsServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/GroupPlacementViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/HotelGroupViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/HotelPerformanceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/InvoiceServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/KeywordPlanAdGroupServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/KeywordPlanCampaignServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/KeywordPlanIdeaServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/KeywordPlanKeywordServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/KeywordPlanNegativeKeywordServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/KeywordPlanServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/KeywordViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/LabelServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/LandingPageViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/LanguageConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/LocationViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ManagedPlacementViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/MediaFileServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/MerchantCenterLinkServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/MobileAppCategoryConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/MobileDeviceConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/MutateJobServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/OperatingSystemVersionConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/PaidOrganicSearchTermViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ParentalStatusViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/PaymentsAccountServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ProductBiddingCategoryConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ProductGroupViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ReachPlanServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/RecommendationServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/RemarketingActionServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/SearchTermViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/SharedCriterionServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/SharedSetServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/ShoppingPerformanceViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/TopicConstantServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/TopicViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/UserInterestServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/UserListServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/UserLocationViewServiceClientExceptionCustomization.cs delete mode 100644 src/V2/Stubs/VideoServiceClientExceptionCustomization.cs create mode 100644 src/V3/GoogleAdsException.cs create mode 100644 src/V3/GoogleAdsFailureExtensions.cs create mode 100644 src/V3/ResourceNames.cs create mode 100644 src/V3/ServiceExtensions.cs create mode 100644 src/V3/ServiceHelperMethods.cs create mode 100644 src/V3/Services.V3.cs create mode 100644 src/V3/Stubs/AccessInvitationError.cs create mode 100644 src/V3/Stubs/AccessReason.cs create mode 100644 src/V3/Stubs/AccessRole.cs create mode 100644 src/V3/Stubs/AccountBudget.cs create mode 100644 src/V3/Stubs/AccountBudgetProposal.cs create mode 100644 src/V3/Stubs/AccountBudgetProposalError.cs create mode 100644 src/V3/Stubs/AccountBudgetProposalService.cs create mode 100644 src/V3/Stubs/AccountBudgetProposalServiceClient.cs create mode 100644 src/V3/Stubs/AccountBudgetProposalServiceGrpc.cs create mode 100644 src/V3/Stubs/AccountBudgetProposalStatus.cs create mode 100644 src/V3/Stubs/AccountBudgetProposalType.cs create mode 100644 src/V3/Stubs/AccountBudgetService.cs create mode 100644 src/V3/Stubs/AccountBudgetServiceClient.cs create mode 100644 src/V3/Stubs/AccountBudgetServiceGrpc.cs create mode 100644 src/V3/Stubs/AccountBudgetStatus.cs create mode 100644 src/V3/Stubs/Ad.cs create mode 100644 src/V3/Stubs/AdAsset.cs create mode 100644 src/V3/Stubs/AdCustomizerError.cs create mode 100644 src/V3/Stubs/AdCustomizerPlaceholderField.cs create mode 100644 src/V3/Stubs/AdError.cs create mode 100644 src/V3/Stubs/AdGroup.cs create mode 100644 src/V3/Stubs/AdGroupAd.cs create mode 100644 src/V3/Stubs/AdGroupAdAssetView.cs create mode 100644 src/V3/Stubs/AdGroupAdAssetViewService.cs create mode 100644 src/V3/Stubs/AdGroupAdAssetViewServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupAdAssetViewServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupAdError.cs create mode 100644 src/V3/Stubs/AdGroupAdLabel.cs create mode 100644 src/V3/Stubs/AdGroupAdLabelService.cs create mode 100644 src/V3/Stubs/AdGroupAdLabelServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupAdLabelServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupAdRotationMode.cs create mode 100644 src/V3/Stubs/AdGroupAdService.cs create mode 100644 src/V3/Stubs/AdGroupAdServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupAdServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupAdStatus.cs create mode 100644 src/V3/Stubs/AdGroupAudienceView.cs create mode 100644 src/V3/Stubs/AdGroupAudienceViewService.cs create mode 100644 src/V3/Stubs/AdGroupAudienceViewServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupAudienceViewServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupBidModifier.cs create mode 100644 src/V3/Stubs/AdGroupBidModifierError.cs create mode 100644 src/V3/Stubs/AdGroupBidModifierService.cs create mode 100644 src/V3/Stubs/AdGroupBidModifierServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupBidModifierServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupCriterion.cs create mode 100644 src/V3/Stubs/AdGroupCriterionApprovalStatus.cs create mode 100644 src/V3/Stubs/AdGroupCriterionError.cs create mode 100644 src/V3/Stubs/AdGroupCriterionLabel.cs create mode 100644 src/V3/Stubs/AdGroupCriterionLabelService.cs create mode 100644 src/V3/Stubs/AdGroupCriterionLabelServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupCriterionLabelServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupCriterionService.cs create mode 100644 src/V3/Stubs/AdGroupCriterionServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupCriterionServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupCriterionSimulation.cs create mode 100644 src/V3/Stubs/AdGroupCriterionSimulationService.cs create mode 100644 src/V3/Stubs/AdGroupCriterionSimulationServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupCriterionSimulationServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupCriterionStatus.cs create mode 100644 src/V3/Stubs/AdGroupError.cs create mode 100644 src/V3/Stubs/AdGroupExtensionSetting.cs create mode 100644 src/V3/Stubs/AdGroupExtensionSettingService.cs create mode 100644 src/V3/Stubs/AdGroupExtensionSettingServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupExtensionSettingServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupFeed.cs create mode 100644 src/V3/Stubs/AdGroupFeedError.cs create mode 100644 src/V3/Stubs/AdGroupFeedService.cs create mode 100644 src/V3/Stubs/AdGroupFeedServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupFeedServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupLabel.cs create mode 100644 src/V3/Stubs/AdGroupLabelService.cs create mode 100644 src/V3/Stubs/AdGroupLabelServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupLabelServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupService.cs create mode 100644 src/V3/Stubs/AdGroupServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupSimulation.cs create mode 100644 src/V3/Stubs/AdGroupSimulationService.cs create mode 100644 src/V3/Stubs/AdGroupSimulationServiceClient.cs create mode 100644 src/V3/Stubs/AdGroupSimulationServiceGrpc.cs create mode 100644 src/V3/Stubs/AdGroupStatus.cs create mode 100644 src/V3/Stubs/AdGroupType.cs create mode 100644 src/V3/Stubs/AdNetworkType.cs create mode 100644 src/V3/Stubs/AdParameter.cs create mode 100644 src/V3/Stubs/AdParameterError.cs create mode 100644 src/V3/Stubs/AdParameterService.cs create mode 100644 src/V3/Stubs/AdParameterServiceClient.cs create mode 100644 src/V3/Stubs/AdParameterServiceGrpc.cs create mode 100644 src/V3/Stubs/AdScheduleView.cs create mode 100644 src/V3/Stubs/AdScheduleViewService.cs create mode 100644 src/V3/Stubs/AdScheduleViewServiceClient.cs create mode 100644 src/V3/Stubs/AdScheduleViewServiceGrpc.cs create mode 100644 src/V3/Stubs/AdService.cs create mode 100644 src/V3/Stubs/AdServiceClient.cs create mode 100644 src/V3/Stubs/AdServiceGrpc.cs create mode 100644 src/V3/Stubs/AdServingOptimizationStatus.cs create mode 100644 src/V3/Stubs/AdSharingError.cs create mode 100644 src/V3/Stubs/AdStrength.cs create mode 100644 src/V3/Stubs/AdType.cs create mode 100644 src/V3/Stubs/AdTypeInfos.cs create mode 100644 src/V3/Stubs/AdvertisingChannelSubType.cs create mode 100644 src/V3/Stubs/AdvertisingChannelType.cs create mode 100644 src/V3/Stubs/AdxError.cs create mode 100644 src/V3/Stubs/AffiliateLocationFeedRelationshipType.cs create mode 100644 src/V3/Stubs/AffiliateLocationPlaceholderField.cs create mode 100644 src/V3/Stubs/AgeRangeType.cs create mode 100644 src/V3/Stubs/AgeRangeView.cs create mode 100644 src/V3/Stubs/AgeRangeViewService.cs create mode 100644 src/V3/Stubs/AgeRangeViewServiceClient.cs create mode 100644 src/V3/Stubs/AgeRangeViewServiceGrpc.cs create mode 100644 src/V3/Stubs/AppCampaignAppStore.cs create mode 100644 src/V3/Stubs/AppCampaignBiddingStrategyGoalType.cs create mode 100644 src/V3/Stubs/AppPaymentModelType.cs create mode 100644 src/V3/Stubs/AppPlaceholderField.cs create mode 100644 src/V3/Stubs/AppStore.cs create mode 100644 src/V3/Stubs/AppUrlOperatingSystemType.cs create mode 100644 src/V3/Stubs/ApplyRecommendationResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/Asset.cs create mode 100644 src/V3/Stubs/AssetError.cs create mode 100644 src/V3/Stubs/AssetFieldType.cs create mode 100644 src/V3/Stubs/AssetPerformanceLabel.cs create mode 100644 src/V3/Stubs/AssetService.cs create mode 100644 src/V3/Stubs/AssetServiceClient.cs create mode 100644 src/V3/Stubs/AssetServiceGrpc.cs create mode 100644 src/V3/Stubs/AssetType.cs create mode 100644 src/V3/Stubs/AssetTypes.cs create mode 100644 src/V3/Stubs/AttributionModel.cs create mode 100644 src/V3/Stubs/AuthenticationError.cs create mode 100644 src/V3/Stubs/AuthorizationError.cs create mode 100644 src/V3/Stubs/BidModifierSource.cs create mode 100644 src/V3/Stubs/Bidding.cs create mode 100644 src/V3/Stubs/BiddingError.cs create mode 100644 src/V3/Stubs/BiddingSource.cs create mode 100644 src/V3/Stubs/BiddingStrategy.cs create mode 100644 src/V3/Stubs/BiddingStrategyError.cs create mode 100644 src/V3/Stubs/BiddingStrategyService.cs create mode 100644 src/V3/Stubs/BiddingStrategyServiceClient.cs create mode 100644 src/V3/Stubs/BiddingStrategyServiceGrpc.cs create mode 100644 src/V3/Stubs/BiddingStrategyStatus.cs create mode 100644 src/V3/Stubs/BiddingStrategyType.cs create mode 100644 src/V3/Stubs/BillingSetup.cs create mode 100644 src/V3/Stubs/BillingSetupError.cs create mode 100644 src/V3/Stubs/BillingSetupService.cs create mode 100644 src/V3/Stubs/BillingSetupServiceClient.cs create mode 100644 src/V3/Stubs/BillingSetupServiceGrpc.cs create mode 100644 src/V3/Stubs/BillingSetupStatus.cs create mode 100644 src/V3/Stubs/BrandSafetySuitability.cs create mode 100644 src/V3/Stubs/BudgetDeliveryMethod.cs create mode 100644 src/V3/Stubs/BudgetPeriod.cs create mode 100644 src/V3/Stubs/BudgetStatus.cs create mode 100644 src/V3/Stubs/BudgetType.cs create mode 100644 src/V3/Stubs/CallConversionReportingState.cs create mode 100644 src/V3/Stubs/CallPlaceholderField.cs create mode 100644 src/V3/Stubs/CalloutPlaceholderField.cs create mode 100644 src/V3/Stubs/Campaign.cs create mode 100644 src/V3/Stubs/CampaignAudienceView.cs create mode 100644 src/V3/Stubs/CampaignAudienceViewService.cs create mode 100644 src/V3/Stubs/CampaignAudienceViewServiceClient.cs create mode 100644 src/V3/Stubs/CampaignAudienceViewServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignBidModifier.cs create mode 100644 src/V3/Stubs/CampaignBidModifierService.cs create mode 100644 src/V3/Stubs/CampaignBidModifierServiceClient.cs create mode 100644 src/V3/Stubs/CampaignBidModifierServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignBudget.cs create mode 100644 src/V3/Stubs/CampaignBudgetError.cs create mode 100644 src/V3/Stubs/CampaignBudgetService.cs create mode 100644 src/V3/Stubs/CampaignBudgetServiceClient.cs create mode 100644 src/V3/Stubs/CampaignBudgetServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignCriterion.cs create mode 100644 src/V3/Stubs/CampaignCriterionError.cs create mode 100644 src/V3/Stubs/CampaignCriterionService.cs create mode 100644 src/V3/Stubs/CampaignCriterionServiceClient.cs create mode 100644 src/V3/Stubs/CampaignCriterionServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignCriterionSimulation.cs create mode 100644 src/V3/Stubs/CampaignCriterionSimulationService.cs create mode 100644 src/V3/Stubs/CampaignCriterionSimulationServiceClient.cs create mode 100644 src/V3/Stubs/CampaignCriterionSimulationServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignCriterionStatus.cs create mode 100644 src/V3/Stubs/CampaignDraft.cs create mode 100644 src/V3/Stubs/CampaignDraftError.cs create mode 100644 src/V3/Stubs/CampaignDraftService.cs create mode 100644 src/V3/Stubs/CampaignDraftServiceClient.cs create mode 100644 src/V3/Stubs/CampaignDraftServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignDraftStatus.cs create mode 100644 src/V3/Stubs/CampaignError.cs create mode 100644 src/V3/Stubs/CampaignExperiment.cs create mode 100644 src/V3/Stubs/CampaignExperimentError.cs create mode 100644 src/V3/Stubs/CampaignExperimentService.cs create mode 100644 src/V3/Stubs/CampaignExperimentServiceClient.cs create mode 100644 src/V3/Stubs/CampaignExperimentServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignExperimentStatus.cs create mode 100644 src/V3/Stubs/CampaignExperimentTrafficSplitType.cs create mode 100644 src/V3/Stubs/CampaignExperimentType.cs create mode 100644 src/V3/Stubs/CampaignExtensionSetting.cs create mode 100644 src/V3/Stubs/CampaignExtensionSettingService.cs create mode 100644 src/V3/Stubs/CampaignExtensionSettingServiceClient.cs create mode 100644 src/V3/Stubs/CampaignExtensionSettingServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignFeed.cs create mode 100644 src/V3/Stubs/CampaignFeedError.cs create mode 100644 src/V3/Stubs/CampaignFeedService.cs create mode 100644 src/V3/Stubs/CampaignFeedServiceClient.cs create mode 100644 src/V3/Stubs/CampaignFeedServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignLabel.cs create mode 100644 src/V3/Stubs/CampaignLabelService.cs create mode 100644 src/V3/Stubs/CampaignLabelServiceClient.cs create mode 100644 src/V3/Stubs/CampaignLabelServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignService.cs create mode 100644 src/V3/Stubs/CampaignServiceClient.cs create mode 100644 src/V3/Stubs/CampaignServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignServingStatus.cs create mode 100644 src/V3/Stubs/CampaignSharedSet.cs create mode 100644 src/V3/Stubs/CampaignSharedSetError.cs create mode 100644 src/V3/Stubs/CampaignSharedSetService.cs create mode 100644 src/V3/Stubs/CampaignSharedSetServiceClient.cs create mode 100644 src/V3/Stubs/CampaignSharedSetServiceGrpc.cs create mode 100644 src/V3/Stubs/CampaignSharedSetStatus.cs create mode 100644 src/V3/Stubs/CampaignStatus.cs create mode 100644 src/V3/Stubs/CarrierConstant.cs create mode 100644 src/V3/Stubs/CarrierConstantService.cs create mode 100644 src/V3/Stubs/CarrierConstantServiceClient.cs create mode 100644 src/V3/Stubs/CarrierConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/ChangeStatus.cs create mode 100644 src/V3/Stubs/ChangeStatusError.cs create mode 100644 src/V3/Stubs/ChangeStatusOperation.cs create mode 100644 src/V3/Stubs/ChangeStatusResourceType.cs create mode 100644 src/V3/Stubs/ChangeStatusService.cs create mode 100644 src/V3/Stubs/ChangeStatusServiceClient.cs create mode 100644 src/V3/Stubs/ChangeStatusServiceGrpc.cs create mode 100644 src/V3/Stubs/ClickLocation.cs create mode 100644 src/V3/Stubs/ClickType.cs create mode 100644 src/V3/Stubs/ClickView.cs create mode 100644 src/V3/Stubs/ClickViewService.cs create mode 100644 src/V3/Stubs/ClickViewServiceClient.cs create mode 100644 src/V3/Stubs/ClickViewServiceGrpc.cs create mode 100644 src/V3/Stubs/CollectionSizeError.cs create mode 100644 src/V3/Stubs/ContentLabelType.cs create mode 100644 src/V3/Stubs/ContextError.cs create mode 100644 src/V3/Stubs/ConversionAction.cs create mode 100644 src/V3/Stubs/ConversionActionCategory.cs create mode 100644 src/V3/Stubs/ConversionActionCountingType.cs create mode 100644 src/V3/Stubs/ConversionActionError.cs create mode 100644 src/V3/Stubs/ConversionActionService.cs create mode 100644 src/V3/Stubs/ConversionActionServiceClient.cs create mode 100644 src/V3/Stubs/ConversionActionServiceGrpc.cs create mode 100644 src/V3/Stubs/ConversionActionStatus.cs create mode 100644 src/V3/Stubs/ConversionActionType.cs create mode 100644 src/V3/Stubs/ConversionAdjustmentType.cs create mode 100644 src/V3/Stubs/ConversionAdjustmentUploadError.cs create mode 100644 src/V3/Stubs/ConversionAdjustmentUploadService.cs create mode 100644 src/V3/Stubs/ConversionAdjustmentUploadServiceClient.cs create mode 100644 src/V3/Stubs/ConversionAdjustmentUploadServiceGrpc.cs create mode 100644 src/V3/Stubs/ConversionAttributionEventType.cs create mode 100644 src/V3/Stubs/ConversionLagBucket.cs create mode 100644 src/V3/Stubs/ConversionOrAdjustmentLagBucket.cs create mode 100644 src/V3/Stubs/ConversionUploadError.cs create mode 100644 src/V3/Stubs/ConversionUploadService.cs create mode 100644 src/V3/Stubs/ConversionUploadServiceClient.cs create mode 100644 src/V3/Stubs/ConversionUploadServiceGrpc.cs create mode 100644 src/V3/Stubs/CountryCodeError.cs create mode 100644 src/V3/Stubs/Criteria.cs create mode 100644 src/V3/Stubs/CriterionCategoryAvailability.cs create mode 100644 src/V3/Stubs/CriterionCategoryChannelAvailabilityMode.cs create mode 100644 src/V3/Stubs/CriterionCategoryLocaleAvailabilityMode.cs create mode 100644 src/V3/Stubs/CriterionError.cs create mode 100644 src/V3/Stubs/CriterionSystemServingStatus.cs create mode 100644 src/V3/Stubs/CriterionType.cs create mode 100644 src/V3/Stubs/CurrencyCodeError.cs create mode 100644 src/V3/Stubs/CurrencyConstant.cs create mode 100644 src/V3/Stubs/CurrencyConstantService.cs create mode 100644 src/V3/Stubs/CurrencyConstantServiceClient.cs create mode 100644 src/V3/Stubs/CurrencyConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomInterest.cs create mode 100644 src/V3/Stubs/CustomInterestError.cs create mode 100644 src/V3/Stubs/CustomInterestMemberType.cs create mode 100644 src/V3/Stubs/CustomInterestService.cs create mode 100644 src/V3/Stubs/CustomInterestServiceClient.cs create mode 100644 src/V3/Stubs/CustomInterestServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomInterestStatus.cs create mode 100644 src/V3/Stubs/CustomInterestType.cs create mode 100644 src/V3/Stubs/CustomParameter.cs create mode 100644 src/V3/Stubs/CustomPlaceholderField.cs create mode 100644 src/V3/Stubs/Customer.cs create mode 100644 src/V3/Stubs/CustomerClient.cs create mode 100644 src/V3/Stubs/CustomerClientLink.cs create mode 100644 src/V3/Stubs/CustomerClientLinkError.cs create mode 100644 src/V3/Stubs/CustomerClientLinkService.cs create mode 100644 src/V3/Stubs/CustomerClientLinkServiceClient.cs create mode 100644 src/V3/Stubs/CustomerClientLinkServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomerClientService.cs create mode 100644 src/V3/Stubs/CustomerClientServiceClient.cs create mode 100644 src/V3/Stubs/CustomerClientServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomerError.cs create mode 100644 src/V3/Stubs/CustomerExtensionSetting.cs create mode 100644 src/V3/Stubs/CustomerExtensionSettingService.cs create mode 100644 src/V3/Stubs/CustomerExtensionSettingServiceClient.cs create mode 100644 src/V3/Stubs/CustomerExtensionSettingServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomerFeed.cs create mode 100644 src/V3/Stubs/CustomerFeedError.cs create mode 100644 src/V3/Stubs/CustomerFeedService.cs create mode 100644 src/V3/Stubs/CustomerFeedServiceClient.cs create mode 100644 src/V3/Stubs/CustomerFeedServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomerLabel.cs create mode 100644 src/V3/Stubs/CustomerLabelService.cs create mode 100644 src/V3/Stubs/CustomerLabelServiceClient.cs create mode 100644 src/V3/Stubs/CustomerLabelServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomerManagerLink.cs create mode 100644 src/V3/Stubs/CustomerManagerLinkError.cs create mode 100644 src/V3/Stubs/CustomerManagerLinkService.cs create mode 100644 src/V3/Stubs/CustomerManagerLinkServiceClient.cs create mode 100644 src/V3/Stubs/CustomerManagerLinkServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomerMatchUploadKeyType.cs create mode 100644 src/V3/Stubs/CustomerNegativeCriterion.cs create mode 100644 src/V3/Stubs/CustomerNegativeCriterionService.cs create mode 100644 src/V3/Stubs/CustomerNegativeCriterionServiceClient.cs create mode 100644 src/V3/Stubs/CustomerNegativeCriterionServiceGrpc.cs create mode 100644 src/V3/Stubs/CustomerPayPerConversionEligibilityFailureReason.cs create mode 100644 src/V3/Stubs/CustomerService.cs create mode 100644 src/V3/Stubs/CustomerServiceClient.cs create mode 100644 src/V3/Stubs/CustomerServiceGrpc.cs create mode 100644 src/V3/Stubs/DataDrivenModelStatus.cs create mode 100644 src/V3/Stubs/DatabaseError.cs create mode 100644 src/V3/Stubs/DateError.cs create mode 100644 src/V3/Stubs/DateRangeError.cs create mode 100644 src/V3/Stubs/Dates.cs create mode 100644 src/V3/Stubs/DayOfWeek.cs create mode 100644 src/V3/Stubs/DetailPlacementView.cs create mode 100644 src/V3/Stubs/DetailPlacementViewService.cs create mode 100644 src/V3/Stubs/DetailPlacementViewServiceClient.cs create mode 100644 src/V3/Stubs/DetailPlacementViewServiceGrpc.cs create mode 100644 src/V3/Stubs/Device.cs create mode 100644 src/V3/Stubs/DismissRecommendationResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/DisplayAdFormatSetting.cs create mode 100644 src/V3/Stubs/DisplayKeywordView.cs create mode 100644 src/V3/Stubs/DisplayKeywordViewService.cs create mode 100644 src/V3/Stubs/DisplayKeywordViewServiceClient.cs create mode 100644 src/V3/Stubs/DisplayKeywordViewServiceGrpc.cs create mode 100644 src/V3/Stubs/DisplayUploadProductType.cs create mode 100644 src/V3/Stubs/DistanceBucket.cs create mode 100644 src/V3/Stubs/DistanceView.cs create mode 100644 src/V3/Stubs/DistanceViewService.cs create mode 100644 src/V3/Stubs/DistanceViewServiceClient.cs create mode 100644 src/V3/Stubs/DistanceViewServiceGrpc.cs create mode 100644 src/V3/Stubs/DistinctError.cs create mode 100644 src/V3/Stubs/DomainCategory.cs create mode 100644 src/V3/Stubs/DomainCategoryService.cs create mode 100644 src/V3/Stubs/DomainCategoryServiceClient.cs create mode 100644 src/V3/Stubs/DomainCategoryServiceGrpc.cs create mode 100644 src/V3/Stubs/DsaPageFeedCriterionField.cs create mode 100644 src/V3/Stubs/DynamicSearchAdsSearchTermView.cs create mode 100644 src/V3/Stubs/DynamicSearchAdsSearchTermViewService.cs create mode 100644 src/V3/Stubs/DynamicSearchAdsSearchTermViewServiceClient.cs create mode 100644 src/V3/Stubs/DynamicSearchAdsSearchTermViewServiceGrpc.cs create mode 100644 src/V3/Stubs/EducationPlaceholderField.cs create mode 100644 src/V3/Stubs/EnumError.cs create mode 100644 src/V3/Stubs/Errors.cs create mode 100644 src/V3/Stubs/ExpandedLandingPageView.cs create mode 100644 src/V3/Stubs/ExpandedLandingPageViewService.cs create mode 100644 src/V3/Stubs/ExpandedLandingPageViewServiceClient.cs create mode 100644 src/V3/Stubs/ExpandedLandingPageViewServiceGrpc.cs create mode 100644 src/V3/Stubs/ExplorerAutoOptimizerSetting.cs create mode 100644 src/V3/Stubs/ExtensionFeedItem.cs create mode 100644 src/V3/Stubs/ExtensionFeedItemError.cs create mode 100644 src/V3/Stubs/ExtensionFeedItemService.cs create mode 100644 src/V3/Stubs/ExtensionFeedItemServiceClient.cs create mode 100644 src/V3/Stubs/ExtensionFeedItemServiceGrpc.cs create mode 100644 src/V3/Stubs/ExtensionSettingDevice.cs create mode 100644 src/V3/Stubs/ExtensionSettingError.cs create mode 100644 src/V3/Stubs/ExtensionType.cs create mode 100644 src/V3/Stubs/Extensions.cs create mode 100644 src/V3/Stubs/ExternalConversionSource.cs create mode 100644 src/V3/Stubs/Feed.cs create mode 100644 src/V3/Stubs/FeedAttributeReferenceError.cs create mode 100644 src/V3/Stubs/FeedAttributeType.cs create mode 100644 src/V3/Stubs/FeedCommon.cs create mode 100644 src/V3/Stubs/FeedError.cs create mode 100644 src/V3/Stubs/FeedItem.cs create mode 100644 src/V3/Stubs/FeedItemError.cs create mode 100644 src/V3/Stubs/FeedItemQualityApprovalStatus.cs create mode 100644 src/V3/Stubs/FeedItemQualityDisapprovalReason.cs create mode 100644 src/V3/Stubs/FeedItemService.cs create mode 100644 src/V3/Stubs/FeedItemServiceClient.cs create mode 100644 src/V3/Stubs/FeedItemServiceGrpc.cs create mode 100644 src/V3/Stubs/FeedItemStatus.cs create mode 100644 src/V3/Stubs/FeedItemTarget.cs create mode 100644 src/V3/Stubs/FeedItemTargetDevice.cs create mode 100644 src/V3/Stubs/FeedItemTargetError.cs create mode 100644 src/V3/Stubs/FeedItemTargetService.cs create mode 100644 src/V3/Stubs/FeedItemTargetServiceClient.cs create mode 100644 src/V3/Stubs/FeedItemTargetServiceGrpc.cs create mode 100644 src/V3/Stubs/FeedItemTargetStatus.cs create mode 100644 src/V3/Stubs/FeedItemTargetType.cs create mode 100644 src/V3/Stubs/FeedItemValidationError.cs create mode 100644 src/V3/Stubs/FeedItemValidationStatus.cs create mode 100644 src/V3/Stubs/FeedLinkStatus.cs create mode 100644 src/V3/Stubs/FeedMapping.cs create mode 100644 src/V3/Stubs/FeedMappingCriterionType.cs create mode 100644 src/V3/Stubs/FeedMappingError.cs create mode 100644 src/V3/Stubs/FeedMappingService.cs create mode 100644 src/V3/Stubs/FeedMappingServiceClient.cs create mode 100644 src/V3/Stubs/FeedMappingServiceGrpc.cs create mode 100644 src/V3/Stubs/FeedMappingStatus.cs create mode 100644 src/V3/Stubs/FeedOrigin.cs create mode 100644 src/V3/Stubs/FeedPlaceholderView.cs create mode 100644 src/V3/Stubs/FeedPlaceholderViewService.cs create mode 100644 src/V3/Stubs/FeedPlaceholderViewServiceClient.cs create mode 100644 src/V3/Stubs/FeedPlaceholderViewServiceGrpc.cs create mode 100644 src/V3/Stubs/FeedService.cs create mode 100644 src/V3/Stubs/FeedServiceClient.cs create mode 100644 src/V3/Stubs/FeedServiceGrpc.cs create mode 100644 src/V3/Stubs/FeedStatus.cs create mode 100644 src/V3/Stubs/FieldError.cs create mode 100644 src/V3/Stubs/FieldMaskError.cs create mode 100644 src/V3/Stubs/FinalAppUrl.cs create mode 100644 src/V3/Stubs/FlightPlaceholderField.cs create mode 100644 src/V3/Stubs/FrequencyCap.cs create mode 100644 src/V3/Stubs/FrequencyCapEventType.cs create mode 100644 src/V3/Stubs/FrequencyCapLevel.cs create mode 100644 src/V3/Stubs/FrequencyCapTimeUnit.cs create mode 100644 src/V3/Stubs/FunctionError.cs create mode 100644 src/V3/Stubs/FunctionParsingError.cs create mode 100644 src/V3/Stubs/GenderType.cs create mode 100644 src/V3/Stubs/GenderView.cs create mode 100644 src/V3/Stubs/GenderViewService.cs create mode 100644 src/V3/Stubs/GenderViewServiceClient.cs create mode 100644 src/V3/Stubs/GenderViewServiceGrpc.cs create mode 100644 src/V3/Stubs/GeoTargetConstant.cs create mode 100644 src/V3/Stubs/GeoTargetConstantService.cs create mode 100644 src/V3/Stubs/GeoTargetConstantServiceClient.cs create mode 100644 src/V3/Stubs/GeoTargetConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/GeoTargetConstantStatus.cs create mode 100644 src/V3/Stubs/GeoTargetConstantSuggestionError.cs create mode 100644 src/V3/Stubs/GeoTargetingRestriction.cs create mode 100644 src/V3/Stubs/GeoTargetingType.cs create mode 100644 src/V3/Stubs/GeographicView.cs create mode 100644 src/V3/Stubs/GeographicViewService.cs create mode 100644 src/V3/Stubs/GeographicViewServiceClient.cs create mode 100644 src/V3/Stubs/GeographicViewServiceGrpc.cs create mode 100644 src/V3/Stubs/GoogleAdsField.cs create mode 100644 src/V3/Stubs/GoogleAdsFieldCategory.cs create mode 100644 src/V3/Stubs/GoogleAdsFieldDataType.cs create mode 100644 src/V3/Stubs/GoogleAdsFieldService.cs create mode 100644 src/V3/Stubs/GoogleAdsFieldServiceClient.cs create mode 100644 src/V3/Stubs/GoogleAdsFieldServiceGrpc.cs create mode 100644 src/V3/Stubs/GoogleAdsService.cs create mode 100644 src/V3/Stubs/GoogleAdsServiceClient.cs create mode 100644 src/V3/Stubs/GoogleAdsServiceGrpc.cs create mode 100644 src/V3/Stubs/GroupPlacementView.cs create mode 100644 src/V3/Stubs/GroupPlacementViewService.cs create mode 100644 src/V3/Stubs/GroupPlacementViewServiceClient.cs create mode 100644 src/V3/Stubs/GroupPlacementViewServiceGrpc.cs create mode 100644 src/V3/Stubs/HeaderError.cs create mode 100644 src/V3/Stubs/HotelDateSelectionType.cs create mode 100644 src/V3/Stubs/HotelGroupView.cs create mode 100644 src/V3/Stubs/HotelGroupViewService.cs create mode 100644 src/V3/Stubs/HotelGroupViewServiceClient.cs create mode 100644 src/V3/Stubs/HotelGroupViewServiceGrpc.cs create mode 100644 src/V3/Stubs/HotelPerformanceView.cs create mode 100644 src/V3/Stubs/HotelPerformanceViewService.cs create mode 100644 src/V3/Stubs/HotelPerformanceViewServiceClient.cs create mode 100644 src/V3/Stubs/HotelPerformanceViewServiceGrpc.cs create mode 100644 src/V3/Stubs/HotelPlaceholderField.cs create mode 100644 src/V3/Stubs/HotelPriceBucket.cs create mode 100644 src/V3/Stubs/HotelRateType.cs create mode 100644 src/V3/Stubs/IdError.cs create mode 100644 src/V3/Stubs/ImageError.cs create mode 100644 src/V3/Stubs/IncomeRangeType.cs create mode 100644 src/V3/Stubs/InteractionEventType.cs create mode 100644 src/V3/Stubs/InteractionType.cs create mode 100644 src/V3/Stubs/InternalError.cs create mode 100644 src/V3/Stubs/Invoice.cs create mode 100644 src/V3/Stubs/InvoiceError.cs create mode 100644 src/V3/Stubs/InvoiceService.cs create mode 100644 src/V3/Stubs/InvoiceServiceClient.cs create mode 100644 src/V3/Stubs/InvoiceServiceGrpc.cs create mode 100644 src/V3/Stubs/InvoiceType.cs create mode 100644 src/V3/Stubs/JobPlaceholderField.cs create mode 100644 src/V3/Stubs/KeywordMatchType.cs create mode 100644 src/V3/Stubs/KeywordPlan.cs create mode 100644 src/V3/Stubs/KeywordPlanAdGroup.cs create mode 100644 src/V3/Stubs/KeywordPlanAdGroupError.cs create mode 100644 src/V3/Stubs/KeywordPlanAdGroupService.cs create mode 100644 src/V3/Stubs/KeywordPlanAdGroupServiceClient.cs create mode 100644 src/V3/Stubs/KeywordPlanAdGroupServiceGrpc.cs create mode 100644 src/V3/Stubs/KeywordPlanCampaign.cs create mode 100644 src/V3/Stubs/KeywordPlanCampaignError.cs create mode 100644 src/V3/Stubs/KeywordPlanCampaignService.cs create mode 100644 src/V3/Stubs/KeywordPlanCampaignServiceClient.cs create mode 100644 src/V3/Stubs/KeywordPlanCampaignServiceGrpc.cs create mode 100644 src/V3/Stubs/KeywordPlanCommon.cs create mode 100644 src/V3/Stubs/KeywordPlanCompetitionLevel.cs create mode 100644 src/V3/Stubs/KeywordPlanError.cs create mode 100644 src/V3/Stubs/KeywordPlanForecastInterval.cs create mode 100644 src/V3/Stubs/KeywordPlanIdeaError.cs create mode 100644 src/V3/Stubs/KeywordPlanIdeaService.cs create mode 100644 src/V3/Stubs/KeywordPlanIdeaServiceClient.cs create mode 100644 src/V3/Stubs/KeywordPlanIdeaServiceGrpc.cs create mode 100644 src/V3/Stubs/KeywordPlanKeyword.cs create mode 100644 src/V3/Stubs/KeywordPlanKeywordError.cs create mode 100644 src/V3/Stubs/KeywordPlanKeywordService.cs create mode 100644 src/V3/Stubs/KeywordPlanKeywordServiceClient.cs create mode 100644 src/V3/Stubs/KeywordPlanKeywordServiceGrpc.cs create mode 100644 src/V3/Stubs/KeywordPlanNegativeKeyword.cs create mode 100644 src/V3/Stubs/KeywordPlanNegativeKeywordError.cs create mode 100644 src/V3/Stubs/KeywordPlanNegativeKeywordService.cs create mode 100644 src/V3/Stubs/KeywordPlanNegativeKeywordServiceClient.cs create mode 100644 src/V3/Stubs/KeywordPlanNegativeKeywordServiceGrpc.cs create mode 100644 src/V3/Stubs/KeywordPlanNetwork.cs create mode 100644 src/V3/Stubs/KeywordPlanService.cs create mode 100644 src/V3/Stubs/KeywordPlanServiceClient.cs create mode 100644 src/V3/Stubs/KeywordPlanServiceGrpc.cs create mode 100644 src/V3/Stubs/KeywordView.cs create mode 100644 src/V3/Stubs/KeywordViewService.cs create mode 100644 src/V3/Stubs/KeywordViewServiceClient.cs create mode 100644 src/V3/Stubs/KeywordViewServiceGrpc.cs create mode 100644 src/V3/Stubs/Label.cs create mode 100644 src/V3/Stubs/LabelError.cs create mode 100644 src/V3/Stubs/LabelService.cs create mode 100644 src/V3/Stubs/LabelServiceClient.cs create mode 100644 src/V3/Stubs/LabelServiceGrpc.cs create mode 100644 src/V3/Stubs/LabelStatus.cs create mode 100644 src/V3/Stubs/LandingPageView.cs create mode 100644 src/V3/Stubs/LandingPageViewService.cs create mode 100644 src/V3/Stubs/LandingPageViewServiceClient.cs create mode 100644 src/V3/Stubs/LandingPageViewServiceGrpc.cs create mode 100644 src/V3/Stubs/LanguageCodeError.cs create mode 100644 src/V3/Stubs/LanguageConstant.cs create mode 100644 src/V3/Stubs/LanguageConstantService.cs create mode 100644 src/V3/Stubs/LanguageConstantServiceClient.cs create mode 100644 src/V3/Stubs/LanguageConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/LegacyAppInstallAdAppStore.cs create mode 100644 src/V3/Stubs/ListOperationError.cs create mode 100644 src/V3/Stubs/ListingGroupType.cs create mode 100644 src/V3/Stubs/LocalPlaceholderField.cs create mode 100644 src/V3/Stubs/LocationExtensionTargetingCriterionField.cs create mode 100644 src/V3/Stubs/LocationGroupRadiusUnits.cs create mode 100644 src/V3/Stubs/LocationPlaceholderField.cs create mode 100644 src/V3/Stubs/LocationView.cs create mode 100644 src/V3/Stubs/LocationViewService.cs create mode 100644 src/V3/Stubs/LocationViewServiceClient.cs create mode 100644 src/V3/Stubs/LocationViewServiceGrpc.cs create mode 100644 src/V3/Stubs/ManagedPlacementView.cs create mode 100644 src/V3/Stubs/ManagedPlacementViewService.cs create mode 100644 src/V3/Stubs/ManagedPlacementViewServiceClient.cs create mode 100644 src/V3/Stubs/ManagedPlacementViewServiceGrpc.cs create mode 100644 src/V3/Stubs/ManagerLinkError.cs create mode 100644 src/V3/Stubs/ManagerLinkStatus.cs create mode 100644 src/V3/Stubs/MatchingFunction.cs create mode 100644 src/V3/Stubs/MatchingFunctionContextType.cs create mode 100644 src/V3/Stubs/MatchingFunctionOperator.cs create mode 100644 src/V3/Stubs/MediaBundleError.cs create mode 100644 src/V3/Stubs/MediaFile.cs create mode 100644 src/V3/Stubs/MediaFileError.cs create mode 100644 src/V3/Stubs/MediaFileService.cs create mode 100644 src/V3/Stubs/MediaFileServiceClient.cs create mode 100644 src/V3/Stubs/MediaFileServiceGrpc.cs create mode 100644 src/V3/Stubs/MediaType.cs create mode 100644 src/V3/Stubs/MediaUploadError.cs create mode 100644 src/V3/Stubs/MerchantCenterLink.cs create mode 100644 src/V3/Stubs/MerchantCenterLinkService.cs create mode 100644 src/V3/Stubs/MerchantCenterLinkServiceClient.cs create mode 100644 src/V3/Stubs/MerchantCenterLinkServiceGrpc.cs create mode 100644 src/V3/Stubs/MerchantCenterLinkStatus.cs create mode 100644 src/V3/Stubs/MessagePlaceholderField.cs create mode 100644 src/V3/Stubs/Metrics.cs create mode 100644 src/V3/Stubs/MimeType.cs create mode 100644 src/V3/Stubs/MinuteOfHour.cs create mode 100644 src/V3/Stubs/MobileAppCategoryConstant.cs create mode 100644 src/V3/Stubs/MobileAppCategoryConstantService.cs create mode 100644 src/V3/Stubs/MobileAppCategoryConstantServiceClient.cs create mode 100644 src/V3/Stubs/MobileAppCategoryConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/MobileDeviceConstant.cs create mode 100644 src/V3/Stubs/MobileDeviceConstantService.cs create mode 100644 src/V3/Stubs/MobileDeviceConstantServiceClient.cs create mode 100644 src/V3/Stubs/MobileDeviceConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/MobileDeviceType.cs create mode 100644 src/V3/Stubs/MonthOfYear.cs create mode 100644 src/V3/Stubs/MultiplierError.cs create mode 100644 src/V3/Stubs/MutateAdGroupAdLabelsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdGroupAdsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdGroupBidModifiersResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdGroupCriteriaResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdGroupCriterionLabelsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdGroupExtensionSettingsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdGroupFeedsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdGroupLabelsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdGroupsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateAdParametersResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateBiddingStrategiesResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignBidModifiersResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignBudgetsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignCriteriaResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignDraftsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignExperimentsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignExtensionSettingsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignFeedsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignLabelsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignSharedSetsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCampaignsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateConversionActionsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCustomerExtensionSettingsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCustomerFeedsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCustomerLabelsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateCustomerNegativeCriteriaResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateError.cs create mode 100644 src/V3/Stubs/MutateFeedItemsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateFeedMappingsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateFeedsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateGoogleAdsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateJob.cs create mode 100644 src/V3/Stubs/MutateJobError.cs create mode 100644 src/V3/Stubs/MutateJobService.cs create mode 100644 src/V3/Stubs/MutateJobServiceClient.cs create mode 100644 src/V3/Stubs/MutateJobServiceGrpc.cs create mode 100644 src/V3/Stubs/MutateJobStatus.cs create mode 100644 src/V3/Stubs/MutateKeywordPlanAdGroupsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateKeywordPlanCampaignsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateKeywordPlanKeywordsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateKeywordPlanNegativeKeywordsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateKeywordPlansResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateLabelsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateMediaFilesResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateRemarketingActionsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateSharedCriteriaResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateSharedSetsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/MutateUserListsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/NegativeGeoTargetType.cs create mode 100644 src/V3/Stubs/NewResourceCreationError.cs create mode 100644 src/V3/Stubs/NotEmptyError.cs create mode 100644 src/V3/Stubs/NotWhitelistedError.cs create mode 100644 src/V3/Stubs/NullError.cs create mode 100644 src/V3/Stubs/OperatingSystemVersionConstant.cs create mode 100644 src/V3/Stubs/OperatingSystemVersionConstantService.cs create mode 100644 src/V3/Stubs/OperatingSystemVersionConstantServiceClient.cs create mode 100644 src/V3/Stubs/OperatingSystemVersionConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/OperatingSystemVersionOperatorType.cs create mode 100644 src/V3/Stubs/OperationAccessDeniedError.cs create mode 100644 src/V3/Stubs/OperatorError.cs create mode 100644 src/V3/Stubs/PageOnePromotedStrategyGoal.cs create mode 100644 src/V3/Stubs/PaidOrganicSearchTermView.cs create mode 100644 src/V3/Stubs/PaidOrganicSearchTermViewService.cs create mode 100644 src/V3/Stubs/PaidOrganicSearchTermViewServiceClient.cs create mode 100644 src/V3/Stubs/PaidOrganicSearchTermViewServiceGrpc.cs create mode 100644 src/V3/Stubs/ParentalStatusType.cs create mode 100644 src/V3/Stubs/ParentalStatusView.cs create mode 100644 src/V3/Stubs/ParentalStatusViewService.cs create mode 100644 src/V3/Stubs/ParentalStatusViewServiceClient.cs create mode 100644 src/V3/Stubs/ParentalStatusViewServiceGrpc.cs create mode 100644 src/V3/Stubs/PartialFailureError.cs create mode 100644 src/V3/Stubs/PaymentMode.cs create mode 100644 src/V3/Stubs/PaymentsAccount.cs create mode 100644 src/V3/Stubs/PaymentsAccountError.cs create mode 100644 src/V3/Stubs/PaymentsAccountService.cs create mode 100644 src/V3/Stubs/PaymentsAccountServiceClient.cs create mode 100644 src/V3/Stubs/PaymentsAccountServiceGrpc.cs create mode 100644 src/V3/Stubs/PlaceholderType.cs create mode 100644 src/V3/Stubs/PlacementType.cs create mode 100644 src/V3/Stubs/Policy.cs create mode 100644 src/V3/Stubs/PolicyApprovalStatus.cs create mode 100644 src/V3/Stubs/PolicyFindingError.cs create mode 100644 src/V3/Stubs/PolicyReviewStatus.cs create mode 100644 src/V3/Stubs/PolicyTopicEntryType.cs create mode 100644 src/V3/Stubs/PolicyTopicEvidenceDestinationMismatchUrlType.cs create mode 100644 src/V3/Stubs/PolicyTopicEvidenceDestinationNotWorkingDevice.cs create mode 100644 src/V3/Stubs/PolicyTopicEvidenceDestinationNotWorkingDnsErrorType.cs create mode 100644 src/V3/Stubs/PolicyValidationParameterError.cs create mode 100644 src/V3/Stubs/PolicyViolationError.cs create mode 100644 src/V3/Stubs/PositiveGeoTargetType.cs create mode 100644 src/V3/Stubs/PreferredContentType.cs create mode 100644 src/V3/Stubs/PriceExtensionPriceQualifier.cs create mode 100644 src/V3/Stubs/PriceExtensionPriceUnit.cs create mode 100644 src/V3/Stubs/PriceExtensionType.cs create mode 100644 src/V3/Stubs/PricePlaceholderField.cs create mode 100644 src/V3/Stubs/ProductBiddingCategoryConstant.cs create mode 100644 src/V3/Stubs/ProductBiddingCategoryConstantService.cs create mode 100644 src/V3/Stubs/ProductBiddingCategoryConstantServiceClient.cs create mode 100644 src/V3/Stubs/ProductBiddingCategoryConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/ProductBiddingCategoryLevel.cs create mode 100644 src/V3/Stubs/ProductBiddingCategoryStatus.cs create mode 100644 src/V3/Stubs/ProductChannel.cs create mode 100644 src/V3/Stubs/ProductChannelExclusivity.cs create mode 100644 src/V3/Stubs/ProductCondition.cs create mode 100644 src/V3/Stubs/ProductCustomAttributeIndex.cs create mode 100644 src/V3/Stubs/ProductGroupView.cs create mode 100644 src/V3/Stubs/ProductGroupViewService.cs create mode 100644 src/V3/Stubs/ProductGroupViewServiceClient.cs create mode 100644 src/V3/Stubs/ProductGroupViewServiceGrpc.cs create mode 100644 src/V3/Stubs/ProductTypeLevel.cs create mode 100644 src/V3/Stubs/PromotionExtensionDiscountModifier.cs create mode 100644 src/V3/Stubs/PromotionExtensionOccasion.cs create mode 100644 src/V3/Stubs/PromotionPlaceholderField.cs create mode 100644 src/V3/Stubs/ProximityRadiusUnits.cs create mode 100644 src/V3/Stubs/QualityScoreBucket.cs create mode 100644 src/V3/Stubs/QueryError.cs create mode 100644 src/V3/Stubs/QuotaError.cs create mode 100644 src/V3/Stubs/RangeError.cs create mode 100644 src/V3/Stubs/ReachPlanAdLength.cs create mode 100644 src/V3/Stubs/ReachPlanAgeRange.cs create mode 100644 src/V3/Stubs/ReachPlanError.cs create mode 100644 src/V3/Stubs/ReachPlanNetwork.cs create mode 100644 src/V3/Stubs/ReachPlanService.cs create mode 100644 src/V3/Stubs/ReachPlanServiceClient.cs create mode 100644 src/V3/Stubs/ReachPlanServiceGrpc.cs create mode 100644 src/V3/Stubs/RealEstatePlaceholderField.cs create mode 100644 src/V3/Stubs/RealTimeBiddingSetting.cs create mode 100644 src/V3/Stubs/Recommendation.cs create mode 100644 src/V3/Stubs/RecommendationError.cs create mode 100644 src/V3/Stubs/RecommendationService.cs create mode 100644 src/V3/Stubs/RecommendationServiceClient.cs create mode 100644 src/V3/Stubs/RecommendationServiceGrpc.cs create mode 100644 src/V3/Stubs/RecommendationType.cs create mode 100644 src/V3/Stubs/RegionCodeError.cs create mode 100644 src/V3/Stubs/RemarketingAction.cs create mode 100644 src/V3/Stubs/RemarketingActionService.cs create mode 100644 src/V3/Stubs/RemarketingActionServiceClient.cs create mode 100644 src/V3/Stubs/RemarketingActionServiceGrpc.cs create mode 100644 src/V3/Stubs/RequestError.cs create mode 100644 src/V3/Stubs/ResourceAccessDeniedError.cs create mode 100644 src/V3/Stubs/ResourceCountLimitExceededError.cs create mode 100644 src/V3/Stubs/ResourceNames.cs create mode 100644 src/V3/Stubs/SearchEngineResultsPageType.cs create mode 100644 src/V3/Stubs/SearchTermMatchType.cs create mode 100644 src/V3/Stubs/SearchTermTargetingStatus.cs create mode 100644 src/V3/Stubs/SearchTermView.cs create mode 100644 src/V3/Stubs/SearchTermViewService.cs create mode 100644 src/V3/Stubs/SearchTermViewServiceClient.cs create mode 100644 src/V3/Stubs/SearchTermViewServiceGrpc.cs create mode 100644 src/V3/Stubs/Segments.cs create mode 100644 src/V3/Stubs/ServedAssetFieldType.cs create mode 100644 src/V3/Stubs/SettingError.cs create mode 100644 src/V3/Stubs/SharedCriterion.cs create mode 100644 src/V3/Stubs/SharedCriterionError.cs create mode 100644 src/V3/Stubs/SharedCriterionService.cs create mode 100644 src/V3/Stubs/SharedCriterionServiceClient.cs create mode 100644 src/V3/Stubs/SharedCriterionServiceGrpc.cs create mode 100644 src/V3/Stubs/SharedSet.cs create mode 100644 src/V3/Stubs/SharedSetError.cs create mode 100644 src/V3/Stubs/SharedSetService.cs create mode 100644 src/V3/Stubs/SharedSetServiceClient.cs create mode 100644 src/V3/Stubs/SharedSetServiceGrpc.cs create mode 100644 src/V3/Stubs/SharedSetStatus.cs create mode 100644 src/V3/Stubs/SharedSetType.cs create mode 100644 src/V3/Stubs/ShoppingPerformanceView.cs create mode 100644 src/V3/Stubs/ShoppingPerformanceViewService.cs create mode 100644 src/V3/Stubs/ShoppingPerformanceViewServiceClient.cs create mode 100644 src/V3/Stubs/ShoppingPerformanceViewServiceGrpc.cs create mode 100644 src/V3/Stubs/Simulation.cs create mode 100644 src/V3/Stubs/SimulationModificationMethod.cs create mode 100644 src/V3/Stubs/SimulationType.cs create mode 100644 src/V3/Stubs/SitelinkPlaceholderField.cs create mode 100644 src/V3/Stubs/SizeLimitError.cs create mode 100644 src/V3/Stubs/Slot.cs create mode 100644 src/V3/Stubs/SpendingLimitType.cs create mode 100644 src/V3/Stubs/StringFormatError.cs create mode 100644 src/V3/Stubs/StringLengthError.cs create mode 100644 src/V3/Stubs/StructuredSnippetPlaceholderField.cs create mode 100644 src/V3/Stubs/SummaryRowSetting.cs create mode 100644 src/V3/Stubs/SystemManagedEntitySource.cs create mode 100644 src/V3/Stubs/TagSnippet.cs create mode 100644 src/V3/Stubs/TargetCpaOptInRecommendationGoal.cs create mode 100644 src/V3/Stubs/TargetImpressionShareLocation.cs create mode 100644 src/V3/Stubs/TargetingDimension.cs create mode 100644 src/V3/Stubs/TargetingSetting.cs create mode 100644 src/V3/Stubs/TextLabel.cs create mode 100644 src/V3/Stubs/TimeType.cs create mode 100644 src/V3/Stubs/TimeZoneError.cs create mode 100644 src/V3/Stubs/TopicConstant.cs create mode 100644 src/V3/Stubs/TopicConstantService.cs create mode 100644 src/V3/Stubs/TopicConstantServiceClient.cs create mode 100644 src/V3/Stubs/TopicConstantServiceGrpc.cs create mode 100644 src/V3/Stubs/TopicView.cs create mode 100644 src/V3/Stubs/TopicViewService.cs create mode 100644 src/V3/Stubs/TopicViewServiceClient.cs create mode 100644 src/V3/Stubs/TopicViewServiceGrpc.cs create mode 100644 src/V3/Stubs/TrackingCodePageFormat.cs create mode 100644 src/V3/Stubs/TrackingCodeType.cs create mode 100644 src/V3/Stubs/TravelPlaceholderField.cs create mode 100644 src/V3/Stubs/UploadCallConversionsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/UploadClickConversionsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/UploadConversionAdjustmentsResponsePartialFailureSupport.cs create mode 100644 src/V3/Stubs/UrlCollection.cs create mode 100644 src/V3/Stubs/UrlFieldError.cs create mode 100644 src/V3/Stubs/UserInterest.cs create mode 100644 src/V3/Stubs/UserInterestService.cs create mode 100644 src/V3/Stubs/UserInterestServiceClient.cs create mode 100644 src/V3/Stubs/UserInterestServiceGrpc.cs create mode 100644 src/V3/Stubs/UserInterestTaxonomyType.cs create mode 100644 src/V3/Stubs/UserList.cs create mode 100644 src/V3/Stubs/UserListAccessStatus.cs create mode 100644 src/V3/Stubs/UserListClosingReason.cs create mode 100644 src/V3/Stubs/UserListCombinedRuleOperator.cs create mode 100644 src/V3/Stubs/UserListCrmDataSourceType.cs create mode 100644 src/V3/Stubs/UserListDateRuleItemOperator.cs create mode 100644 src/V3/Stubs/UserListError.cs create mode 100644 src/V3/Stubs/UserListLogicalRuleOperator.cs create mode 100644 src/V3/Stubs/UserListMembershipStatus.cs create mode 100644 src/V3/Stubs/UserListNumberRuleItemOperator.cs create mode 100644 src/V3/Stubs/UserListPrepopulationStatus.cs create mode 100644 src/V3/Stubs/UserListRuleType.cs create mode 100644 src/V3/Stubs/UserListService.cs create mode 100644 src/V3/Stubs/UserListServiceClient.cs create mode 100644 src/V3/Stubs/UserListServiceGrpc.cs create mode 100644 src/V3/Stubs/UserListSizeRange.cs create mode 100644 src/V3/Stubs/UserListStringRuleItemOperator.cs create mode 100644 src/V3/Stubs/UserListType.cs create mode 100644 src/V3/Stubs/UserLists.cs create mode 100644 src/V3/Stubs/UserLocationView.cs create mode 100644 src/V3/Stubs/UserLocationViewService.cs create mode 100644 src/V3/Stubs/UserLocationViewServiceClient.cs create mode 100644 src/V3/Stubs/UserLocationViewServiceGrpc.cs create mode 100644 src/V3/Stubs/Value.cs create mode 100644 src/V3/Stubs/VanityPharmaDisplayUrlMode.cs create mode 100644 src/V3/Stubs/VanityPharmaText.cs create mode 100644 src/V3/Stubs/Video.cs create mode 100644 src/V3/Stubs/VideoService.cs create mode 100644 src/V3/Stubs/VideoServiceClient.cs create mode 100644 src/V3/Stubs/VideoServiceGrpc.cs create mode 100644 src/V3/Stubs/WebpageConditionOperand.cs create mode 100644 src/V3/Stubs/WebpageConditionOperator.cs create mode 100644 src/V3/Stubs/YoutubeVideoRegistrationError.cs create mode 100644 tests/Examples/V3/AdvancedOperations/AddAppCampaignTest.cs rename tests/Examples/{V2 => V3}/AdvancedOperations/AddSmartDisplayAdTest.cs (86%) rename tests/Examples/{V2 => V3}/BasicOperations/AddAdGroupsTest.cs (90%) rename tests/Examples/{V2 => V3}/BasicOperations/AddCampaignsTest.cs (86%) rename tests/Examples/{V2 => V3}/BasicOperations/AddExpandedTextAdsTest.cs (90%) rename tests/Examples/{V2 => V3}/BasicOperations/AddKeywordsTest.cs (91%) rename tests/Examples/{V2 => V3}/BasicOperations/AddResponsiveSearchAdTest.cs (90%) rename tests/Examples/{V2 => V3}/BasicOperations/GetAdGroupsTest.cs (92%) rename tests/Examples/{V2 => V3}/BasicOperations/GetArtifactMetadataTest.cs (86%) rename tests/Examples/{V2 => V3}/BasicOperations/GetCampaignsTest.cs (89%) rename tests/Examples/{V2 => V3}/BasicOperations/GetExpandedTextAdsTest.cs (92%) rename tests/Examples/{V2 => V3}/BasicOperations/GetKeywordsTest.cs (91%) rename tests/Examples/{V2 => V3}/BasicOperations/PauseAdTest.cs (92%) rename tests/Examples/{V2 => V3}/BasicOperations/RemoveAdGroupTest.cs (90%) rename tests/Examples/{V2 => V3}/BasicOperations/RemoveAdTest.cs (92%) rename tests/Examples/{V2 => V3}/BasicOperations/RemoveCampaignTest.cs (89%) rename tests/Examples/{V2 => V3}/BasicOperations/RemoveKeywordTest.cs (91%) rename tests/Examples/{V2 => V3}/BasicOperations/UpdateAdGroupTest.cs (91%) rename tests/Examples/{V2 => V3}/BasicOperations/UpdateCampaignTest.cs (89%) rename tests/Examples/{V2 => V3}/BasicOperations/UpdateKeywordTest.cs (91%) create mode 100644 tests/Examples/V3/CampaignManagement/UpdateCampaignCriterionBidModifierTest.cs rename tests/Examples/{V2 => V3}/CampaignManagement/ValidateTextAdTest.cs (90%) rename tests/Examples/{V2 => V3}/ExampleTestsUtils.cs (82%) create mode 100644 tests/Examples/V3/Extensions/AddGoogleMyBusinessLocationExtensionsTest.cs create mode 100644 tests/Examples/V3/Extensions/AddPricesTest.cs rename tests/Examples/{V2 => V3}/Misc/GetAllImageAssetsTest.cs (86%) rename tests/Examples/{V2 => V3}/Misc/GetAllVideosAndImagesTest.cs (86%) rename tests/Examples/{V2 => V3}/Misc/UploadImageAssetTest.cs (86%) rename tests/Examples/{V2 => V3}/Misc/UploadImageTest.cs (86%) rename tests/Examples/{V2 => V3}/Misc/UploadMediaBundleTest.cs (86%) create mode 100644 tests/Examples/V3/ShoppingAds/AddListingScopeTest.cs create mode 100644 tests/Interceptors/StreamingRpcInterceptorTests.cs create mode 100644 tests/Interceptors/UnaryRpcInterceptorTests.cs rename tests/Logging/V1/{LoggingInterceptorTests.cs => LoggingHandlerTests.cs} (53%) rename tests/Logging/V2/{LoggingInterceptorTests.cs => LoggingHandlerTests.cs} (53%) create mode 100644 tests/Logging/V3/LogEntryTests.cs create mode 100644 tests/Logging/V3/LoggingHandlerTests.cs create mode 100644 tests/TestStreamReader.cs delete mode 100644 tests/V1/Services/GeoTargetConstantServiceClientTest.g.cs delete mode 100644 tests/V1/Services/KeywordPlanIdeaServiceClientTest.g.cs delete mode 100644 tests/V2/Services/GeoTargetConstantServiceClientTest.g.cs delete mode 100644 tests/V2/Services/KeywordPlanIdeaServiceClientTest.g.cs create mode 100644 tests/V3/GoogleAdsFailureExtensionsTests.cs create mode 100644 tests/V3/Services/AccountBudgetProposalServiceClientTest.g.cs create mode 100644 tests/V3/Services/AccountBudgetServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupAdAssetViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupAdLabelServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupAdServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupAudienceViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupBidModifierServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupCriterionLabelServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupCriterionServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupCriterionSimulationServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupExtensionSettingServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupFeedServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupLabelServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdGroupSimulationServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdParameterServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdScheduleViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/AdServiceClientTest.g.cs create mode 100644 tests/V3/Services/AgeRangeViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/AssetServiceClientTest.g.cs create mode 100644 tests/V3/Services/BiddingStrategyServiceClientTest.g.cs create mode 100644 tests/V3/Services/BillingSetupServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignAudienceViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignBidModifierServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignBudgetServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignCriterionServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignCriterionSimulationServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignDraftServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignExperimentServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignExtensionSettingServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignFeedServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignLabelServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignServiceClientTest.g.cs create mode 100644 tests/V3/Services/CampaignSharedSetServiceClientTest.g.cs create mode 100644 tests/V3/Services/CarrierConstantServiceClientTest.g.cs create mode 100644 tests/V3/Services/ChangeStatusServiceClientTest.g.cs create mode 100644 tests/V3/Services/ClickViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/ConversionActionServiceClientTest.g.cs create mode 100644 tests/V3/Services/ConversionAdjustmentUploadServiceClientTest.g.cs create mode 100644 tests/V3/Services/ConversionUploadServiceClientTest.g.cs create mode 100644 tests/V3/Services/CurrencyConstantServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomInterestServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomerClientLinkServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomerClientServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomerExtensionSettingServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomerFeedServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomerLabelServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomerManagerLinkServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomerNegativeCriterionServiceClientTest.g.cs create mode 100644 tests/V3/Services/CustomerServiceClientTest.g.cs create mode 100644 tests/V3/Services/DetailPlacementViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/DisplayKeywordViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/DistanceViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/DomainCategoryServiceClientTest.g.cs create mode 100644 tests/V3/Services/DynamicSearchAdsSearchTermViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/ExpandedLandingPageViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/ExtensionFeedItemServiceClientTest.g.cs create mode 100644 tests/V3/Services/FeedItemServiceClientTest.g.cs create mode 100644 tests/V3/Services/FeedItemTargetServiceClientTest.g.cs create mode 100644 tests/V3/Services/FeedMappingServiceClientTest.g.cs create mode 100644 tests/V3/Services/FeedPlaceholderViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/FeedServiceClientTest.g.cs create mode 100644 tests/V3/Services/GenderViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/GeographicViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/GoogleAdsFieldServiceClientTest.g.cs create mode 100644 tests/V3/Services/GoogleAdsServiceClientTest.g.cs create mode 100644 tests/V3/Services/GroupPlacementViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/HotelGroupViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/HotelPerformanceViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/InvoiceServiceClientTest.g.cs create mode 100644 tests/V3/Services/KeywordPlanAdGroupServiceClientTest.g.cs create mode 100644 tests/V3/Services/KeywordPlanCampaignServiceClientTest.g.cs create mode 100644 tests/V3/Services/KeywordPlanKeywordServiceClientTest.g.cs create mode 100644 tests/V3/Services/KeywordPlanNegativeKeywordServiceClientTest.g.cs create mode 100644 tests/V3/Services/KeywordPlanServiceClientTest.g.cs create mode 100644 tests/V3/Services/KeywordViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/LabelServiceClientTest.g.cs create mode 100644 tests/V3/Services/LandingPageViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/LanguageConstantServiceClientTest.g.cs create mode 100644 tests/V3/Services/LocationViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/ManagedPlacementViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/MediaFileServiceClientTest.g.cs create mode 100644 tests/V3/Services/MerchantCenterLinkServiceClientTest.g.cs create mode 100644 tests/V3/Services/MobileAppCategoryConstantServiceClientTest.g.cs create mode 100644 tests/V3/Services/MobileDeviceConstantServiceClientTest.g.cs create mode 100644 tests/V3/Services/MutateJobServiceClientTest.g.cs create mode 100644 tests/V3/Services/OperatingSystemVersionConstantServiceClientTest.g.cs create mode 100644 tests/V3/Services/PaidOrganicSearchTermViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/ParentalStatusViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/PaymentsAccountServiceClientTest.g.cs create mode 100644 tests/V3/Services/ProductBiddingCategoryConstantServiceClientTest.g.cs create mode 100644 tests/V3/Services/ProductGroupViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/RecommendationServiceClientTest.g.cs create mode 100644 tests/V3/Services/RemarketingActionServiceClientTest.g.cs create mode 100644 tests/V3/Services/SearchTermViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/SharedCriterionServiceClientTest.g.cs create mode 100644 tests/V3/Services/SharedSetServiceClientTest.g.cs create mode 100644 tests/V3/Services/ShoppingPerformanceViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/TopicConstantServiceClientTest.g.cs create mode 100644 tests/V3/Services/TopicViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/UserInterestServiceClientTest.g.cs create mode 100644 tests/V3/Services/UserListServiceClientTest.g.cs create mode 100644 tests/V3/Services/UserLocationViewServiceClientTest.g.cs create mode 100644 tests/V3/Services/VideoServiceClientTest.g.cs create mode 100644 tests/V3/TestUtils.cs diff --git a/ChangeLog b/ChangeLog index 932b8876a..15dc10cca 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,26 @@ +2.8.0 +===== + +- Added support for v3 of Google Ads API. +- Upgraded all code examples and tests to use v3. +- Fixed AddShoppingProductListingGroupTree example to work with v3. +- Made changes to logging and exception handling framework to support streaming methods. +- The generated stubs no longer use the ExceptionCustomization feature of gax libraries, since the +exception handling logic have moved to grpc interceptors. These stub classes have been removed from +the distribution. +- Convert GetCampaigns and GetKeywordStats examples to use server streaming. + See https://developers.google.com/google-ads/api/docs/reporting/streaming to learn more about + server streaming. +- Add an empty `custom_nupkg` folder in the repo to help with testing dependent packages that are + custom-built from GitHub sources. +- Fixed the visibility of several test classes and methods. +- Added new code examples: + - AddPrices + - AddGoogleMyBusinessLocationExtensions + - AddAppCampaign + - UpdateCampaignCriterionBidModifier +- Refactored all the grpc metadata keynames into a standalone class. + 2.7.0 ===== @@ -5,7 +28,7 @@ - AdvancedOperations\AddAdCustomerizer.cs - AdvancedOperations\AddSmartDisplayAd.cs - BasicOperations\AddResponsiveSearchAd.cs - - BasicOperations\AddAdGroup.cs renamed to BasicOperations\AddAdGroups.cs + - BasicOperations\AddAdGroup.cs renamed to BasicOperations\AddAdGroups.cs - CampaignManagement\AddCampaignLabels.cs - CampaignManagement\GetCampaignsByLabel.cs - CampaignManagement\SetAdParameters.cs @@ -57,7 +80,7 @@ should build and run against the csproj instead. ===== - Optimize for a check on section name if it is empty in the GoogleAdsConfig class. - Add a specialized ConfigSetting class named StringConfigSetting for string - settings, so its parsing can be bypassed. Switch all string-based setting parsing to this type in + settings, so its parsing can be bypassed. Switch all string-based setting parsing to this type in the GoogleAdsConfig class. - Expose the Dictionary constructor in the base class at GoogleAdsConfig level. - Improve how DEFAULT_TIMEOUT is represented in GoogleAdsConfig class. diff --git a/custom_nupkg/.gitignore b/custom_nupkg/.gitignore new file mode 100644 index 000000000..f955a5385 --- /dev/null +++ b/custom_nupkg/.gitignore @@ -0,0 +1,2 @@ +# Custom dependent nuget packages which were locally built to validate a fix. +*.nupkg diff --git a/examples/AccountManagement/CreateCustomer.cs b/examples/AccountManagement/CreateCustomer.cs index f895d8ed3..3a06902c4 100644 --- a/examples/AccountManagement/CreateCustomer.cs +++ b/examples/AccountManagement/CreateCustomer.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates how to create a new customer under a given manager account. @@ -64,7 +64,7 @@ public override string Description public void Run(GoogleAdsClient client, long managerCustomerId) { // Get the CustomerService. - CustomerServiceClient customerService = client.GetService(Services.V2.CustomerService); + CustomerServiceClient customerService = client.GetService(Services.V3.CustomerService); Customer customer = new Customer() { diff --git a/examples/AccountManagement/GetAccountChanges.cs b/examples/AccountManagement/GetAccountChanges.cs index a2ce7d057..279e2bb27 100644 --- a/examples/AccountManagement/GetAccountChanges.cs +++ b/examples/AccountManagement/GetAccountChanges.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; -using static Google.Ads.GoogleAds.V2.Enums.ChangeStatusResourceTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeEnum.Types; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets the changes in an account during the last 7 days. @@ -68,7 +68,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); string searchQuery = "SELECT change_status.resource_name, " + "change_status.last_change_date_time, change_status.resource_type, " + diff --git a/examples/AccountManagement/GetAccountInformation.cs b/examples/AccountManagement/GetAccountInformation.cs index dcc181a55..a2e0ff16c 100644 --- a/examples/AccountManagement/GetAccountInformation.cs +++ b/examples/AccountManagement/GetAccountInformation.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example lists basic information about an advertising account, like the name, @@ -63,7 +63,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId) { // Get the CustomerService. - CustomerServiceClient customerService = client.GetService(Services.V2.CustomerService); + CustomerServiceClient customerService = client.GetService(Services.V3.CustomerService); try { diff --git a/examples/AccountManagement/LinkManagerToClient.cs b/examples/AccountManagement/LinkManagerToClient.cs index 143b299cf..544799b14 100644 --- a/examples/AccountManagement/LinkManagerToClient.cs +++ b/examples/AccountManagement/LinkManagerToClient.cs @@ -14,15 +14,15 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.ManagerLinkStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example demonstrates how to link an existing Google Ads manager customer @@ -109,7 +109,7 @@ private string CreateInvitation(GoogleAdsClient client, long managerCustomerId, { // Get the CustomerClientLinkService. CustomerClientLinkServiceClient customerClientLinkService = - client.GetService(Services.V2.CustomerClientLinkService); + client.GetService(Services.V3.CustomerClientLinkService); // Create a client with the manager customer ID as login customer ID. client.Config.LoginCustomerId = managerCustomerId.ToString(); @@ -160,7 +160,7 @@ private string GetManagerLinkResourceName(GoogleAdsClient client, long managerCu { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); // Create a client with the manager customer ID as login customer ID. client.Config.LoginCustomerId = managerCustomerId.ToString(); @@ -196,7 +196,7 @@ private void AcceptInvitation(GoogleAdsClient client, long clientCustomerId, { // Get the CustomerManagerLinkService. CustomerManagerLinkServiceClient customerManagerLinkService = - client.GetService(Services.V2.CustomerManagerLinkService); + client.GetService(Services.V3.CustomerManagerLinkService); // Create a client with the manager customer ID as login customer ID. client.Config.LoginCustomerId = clientCustomerId.ToString(); diff --git a/examples/AccountManagement/ListAccessibleCustomers.cs b/examples/AccountManagement/ListAccessibleCustomers.cs index 296f06f2c..2acc24ac1 100644 --- a/examples/AccountManagement/ListAccessibleCustomers.cs +++ b/examples/AccountManagement/ListAccessibleCustomers.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example lists the resource names for the customers that the authenticating user @@ -64,7 +64,7 @@ public override string Description public void Run(GoogleAdsClient client) { // Get the CustomerService. - CustomerServiceClient customerService = client.GetService(Services.V2.CustomerService); + CustomerServiceClient customerService = client.GetService(Services.V3.CustomerService); try { diff --git a/examples/AdvancedOperations/AddAdCustomizer.cs b/examples/AdvancedOperations/AddAdCustomizer.cs index 12e99382b..027096600 100644 --- a/examples/AdvancedOperations/AddAdCustomizer.cs +++ b/examples/AdvancedOperations/AddAdCustomizer.cs @@ -13,19 +13,19 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.AdCustomizerPlaceholderFieldEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.FeedAttributeTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.PlaceholderTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdCustomizerPlaceholderFieldEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds an ad customizer feed and associates it with the customer. @@ -80,7 +80,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId1, long a { // Get the AdGroupBidModifierService. AdGroupBidModifierServiceClient adGroupBidModifierService = - client.GetService(Services.V2.AdGroupBidModifierService); + client.GetService(Services.V3.AdGroupBidModifierService); string feedName = "Ad Customizer example feed " + ExampleUtilities.GetRandomString(); @@ -121,7 +121,7 @@ private string CreateAdCustomizerFeed(GoogleAdsClient client, long customerId, string feedName) { // Get the FeedServiceClient. - FeedServiceClient feedService = client.GetService(Services.V2.FeedService); + FeedServiceClient feedService = client.GetService(Services.V3.FeedService); // Creates three feed attributes: a name, a price and a date. The attribute names // are arbitrary choices and will be used as placeholders in the ad text fields. @@ -175,7 +175,7 @@ private Dictionary GetFeedAttributes(GoogleAdsClient clie { // Get the GoogleAdsServiceClient. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); string query = $"SELECT feed.attributes, feed.name FROM feed WHERE " + $"feed.resource_name = '{feedResourceName}'"; @@ -213,11 +213,11 @@ private void CreateAdCustomizerMapping(GoogleAdsClient client, long customerId, { // Get the FeedMappingService. FeedMappingServiceClient feedMappingService = - client.GetService(Services.V2.FeedMappingService); + client.GetService(Services.V3.FeedMappingService); // Map the feed attributes to ad customizer placeholder fields. // For a full list of ad customizer placeholder fields, see - // https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v2.enums#google.ads.googleads.v2.enums.AdCustomizerPlaceholderFieldEnum.AdCustomizerPlaceholderField + // https://developers.google.com/google-ads/api/reference/rpc/Google.Ads.GoogleAds.V3.enums#Google.Ads.GoogleAds.V3.enums.AdCustomizerPlaceholderFieldEnum.AdCustomizerPlaceholderField AttributeFieldMapping nameFieldMapping = new AttributeFieldMapping() { FeedAttributeId = feedAttributes["Name"].Id, @@ -268,7 +268,7 @@ private List CreateFeedItems(GoogleAdsClient client, long customerId, { // Get the FeedItemServiceClient. FeedItemServiceClient feedItemService = - client.GetService(Services.V2.FeedItemService); + client.GetService(Services.V3.FeedItemService); List feedItemOperations = new List(); @@ -353,7 +353,7 @@ private void CreateFeedItemTargets(GoogleAdsClient client, { // Get the FeedItemTargetServiceClient. FeedItemTargetServiceClient feedItemTargetService = - client.GetService(Services.V2.FeedItemTargetService); + client.GetService(Services.V3.FeedItemTargetService); // Bind each feed item to a specific ad group to make sure it will only be used to // customize ads inside that ad group; using the feed item elsewhere will result @@ -396,7 +396,7 @@ private void CreateAdsWithCustomizations(GoogleAdsClient client, long customerId { // Get the AdGroupAdServiceClient. AdGroupAdServiceClient adGroupAdService = - client.GetService(Services.V2.AdGroupAdService); + client.GetService(Services.V3.AdGroupAdService); // Creates an expanded text ad using the feed attribute names as placeholders. diff --git a/examples/AdvancedOperations/AddAdGroupBidModifier.cs b/examples/AdvancedOperations/AddAdGroupBidModifier.cs index 8e6702f22..cb398152a 100644 --- a/examples/AdvancedOperations/AddAdGroupBidModifier.cs +++ b/examples/AdvancedOperations/AddAdGroupBidModifier.cs @@ -13,15 +13,15 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.DeviceEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example demonstrates how to add an ad group bid modifier for mobile devices. @@ -76,7 +76,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, { // Get the AdGroupBidModifierService. AdGroupBidModifierServiceClient adGroupBidModifierService = - client.GetService(Services.V2.AdGroupBidModifierService); + client.GetService(Services.V3.AdGroupBidModifierService); // Creates an ad group bid modifier for mobile devices with the specified ad group // ID and bid modifier value. diff --git a/examples/AdvancedOperations/AddAppCampaign.cs b/examples/AdvancedOperations/AddAppCampaign.cs new file mode 100644 index 000000000..798f91e75 --- /dev/null +++ b/examples/AdvancedOperations/AddAppCampaign.cs @@ -0,0 +1,418 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; + +using System; +using System.Collections.Generic; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 +{ + /// + /// This code example adds a new App Campaign. + /// + public class AddAppCampaign : ExampleBase + { + /// + /// Main method, to run this code example as a standalone application. + /// + /// The command line arguments. + public static void Main(string[] args) + { + AddAppCampaign codeExample = new AddAppCampaign(); + Console.WriteLine(codeExample.Description); + + // The Google Ads customer ID for which the call is made. + long customerId = long.Parse("INSERT_CUSTOMER_ID_HERE"); + + codeExample.Run(new GoogleAdsClient(), customerId); + } + + /// + /// Returns a description about the code example. + /// + public override string Description + { + get + { + return "This code example adds a new App Campaign."; + } + } + + /// + /// Runs the code example. + /// + /// The Google Ads client. + /// The Google Ads customer ID for which the call is made. + public void Run(GoogleAdsClient client, long customerId) + { + try + { + // Creates a budget for the campaign. + string budgetResourceName = CreateBudget(client, customerId); + + // Creates the campaign. + string campaignResourceName = CreateCampaign(client, customerId, budgetResourceName); + + // Sets campaign targeting. + SetCampaignTargetingCriteria(client, customerId, campaignResourceName); + + // Creates an ad group. + string adGroupResourceName = CreateAdGroup(client, customerId, campaignResourceName); + + // Creates an App ad. + CreateAppAd(client, customerId, adGroupResourceName); + } + catch (GoogleAdsException e) + { + Console.WriteLine("Failure:"); + Console.WriteLine($"Message: {e.Message}"); + Console.WriteLine($"Failure: {e.Failure}"); + Console.WriteLine($"Request ID: {e.RequestId}"); + } + } + + /// + /// Creates the budget for the campaign. + /// + /// The Google Ads client. + /// The Google Ads customer ID for which the call is made. + /// The resource name of the newly created campaign budget. + private string CreateBudget(GoogleAdsClient client, long customerId) + { + // Get the BudgetService. + CampaignBudgetServiceClient budgetService = client.GetService( + Services.V3.CampaignBudgetService); + + // Creates a campaign budget. + CampaignBudget budget = new CampaignBudget() + { + Name = "Interplanetary Cruise Budget #" + ExampleUtilities.GetRandomString(), + DeliveryMethod = BudgetDeliveryMethod.Standard, + AmountMicros = 50_000_000, + // An App campaign cannot use a shared campaign budget. + // explicitly_shared must be set to false. + ExplicitlyShared = false + }; + + // Create the operation. + CampaignBudgetOperation budgetOperation = new CampaignBudgetOperation() + { + Create = budget + }; + + // Create the campaign budget. + MutateCampaignBudgetsResponse response = budgetService.MutateCampaignBudgets( + customerId.ToString(), new CampaignBudgetOperation[] { budgetOperation }); + + string budgetResourceName = response.Results[0].ResourceName; + Console.WriteLine($"Created campaign budget with resource name " + + $"'{budgetResourceName}'."); + + return budgetResourceName; + } + + /// + /// Creates an App campaign under the given customer ID. + /// + /// The Google Ads client. + /// The Google Ads customer ID for which the call is made. + /// The budget resource name. + /// Resource name of the newly created campaign. + private string CreateCampaign(GoogleAdsClient client, long customerId, + string budgetResourceName) + { + // Get the CampaignService. + CampaignServiceClient campaignService = client.GetService(Services.V3.CampaignService); + + // Create the campaign. + Campaign campaign = new Campaign() + { + Name = "Interplanetary Cruise #" + ExampleUtilities.GetRandomString(), + CampaignBudget = budgetResourceName, + + // Recommendation: Set the campaign to PAUSED when creating it to prevent + // the ads from immediately serving. Set to ENABLED once you've added + // targeting and the ads are ready to serve + Status = CampaignStatus.Paused, + + // All App campaigns have an advertising_channel_type of + // MULTI_CHANNEL to reflect the fact that ads from these campaigns are + // eligible to appear on multiple channels. + AdvertisingChannelType = AdvertisingChannelType.MultiChannel, + AdvertisingChannelSubType = AdvertisingChannelSubType.AppCampaign, + + // Sets the target CPA to $1 / app install. + // + // campaign_bidding_strategy is a 'oneof' message so setting target_cpa + // is mutually exclusive with other bidding strategies such as + // manual_cpc, commission, maximize_conversions, etc. + // See https://developers.google.com/google-ads/api/reference/rpc + // under current version / resources / Campaign. + TargetCpa = new TargetCpa() + { + TargetCpaMicros = 1000000 + }, + + // Sets the App campaign settings. + AppCampaignSetting = new AppCampaignSetting() + { + AppId = "com.google.android.apps.adwords", + AppStore = AppCampaignAppStore.GoogleAppStore, + // Optional: Optimize this campaign for getting new users for your app. + BiddingStrategyGoalType = + AppCampaignBiddingStrategyGoalType.OptimizeInstallsTargetInstallCost + }, + + // Optional: Set the start date. + StartDate = DateTime.Now.AddDays(1).ToString("yyyyMMdd"), + + // Optional: Set the end date. + EndDate = DateTime.Now.AddYears(1).ToString("yyyyMMdd"), + }; + + // Creates a campaign operation. + CampaignOperation operation = new CampaignOperation() + { + Create = campaign + }; + + // Add the campaigns. + MutateCampaignsResponse response = campaignService.MutateCampaigns( + customerId.ToString(), new CampaignOperation[] { operation }); + + // Display the results. + string campaignResourceName = response.Results[0].ResourceName; + Console.WriteLine($"Created App campaign with resource name '{campaignResourceName}'."); + + return campaignResourceName; + } + + /// + /// Sets campaign targeting criteria for a given campaign. Both location and language + /// targeting are illustrated. + /// + /// The Google Ads client. + /// The Google Ads customer ID for which the call is made. + /// The resource name of the campaign to apply + /// targeting to. + private void SetCampaignTargetingCriteria(GoogleAdsClient client, long customerId, + string campaignResourceName) + { + // Get the CampaignCriterionService. + CampaignCriterionServiceClient campaignCriterionService = client.GetService( + Services.V3.CampaignCriterionService); + + List operations = new List(); + + // Creates the location campaign criteria. + // Besides using location_id, you can also search by location names from + // GeoTargetConstantService.suggestGeoTargetConstants() and directly + // apply GeoTargetConstant.resource_name here. An example can be found + // in GetGeoTargetConstantByNames.cs. + int[] locationIds = new int[] + { + 21137, // California + 2484 // Mexico + }; + + foreach (int locationId in locationIds) + { + // Creates a campaign criterion. + CampaignCriterion campaignCriterion = new CampaignCriterion() + { + Campaign = campaignResourceName, + Type = CriterionType.Location, + Location = new LocationInfo() + { + GeoTargetConstant = ResourceNames.GeoTargetConstant(locationId) + } + }; + + // Creates a campaign criterion operation. + CampaignCriterionOperation operation = new CampaignCriterionOperation() + { + Create = campaignCriterion + }; + + operations.Add(operation); + } + + // Creates the language campaign criteria. + int[] languageIds = new int[] + { + 1000, // English + 1003 // Spanish + }; + + foreach (int languageId in languageIds) + { + // Creates a campaign criterion. + CampaignCriterion campaignCriterion = new CampaignCriterion() + { + Campaign = campaignResourceName, + Type = CriterionType.Language, + Language = new LanguageInfo() + { + LanguageConstant = ResourceNames.LanguageConstant(languageId) + } + }; + + // Creates a campaign criterion operation. + CampaignCriterionOperation operation = new CampaignCriterionOperation() + { + Create = campaignCriterion + }; + + operations.Add(operation); + } + + // Submits the criteria operations and prints their information. + MutateCampaignCriteriaResponse response = + campaignCriterionService.MutateCampaignCriteria(customerId.ToString(), operations); + Console.WriteLine($"Created {response.Results.Count} campaign criteria with " + + $"resource names:"); + + foreach (MutateCampaignCriterionResult result in response.Results) + { + Console.WriteLine(result.ResourceName); + } + } + + /// + /// Creates an ad group for a given campaign + /// + /// The Google Ads client. + /// The Google Ads customer ID for which the call is made. + /// Resource name of the campaign to add the ad group + /// to. + /// The resource name of the newly created ad group. + private string CreateAdGroup(GoogleAdsClient client, long customerId, + string campaignResourceName) + { + // Get the AdGroupService. + AdGroupServiceClient adGroupService = client.GetService(Services.V3.AdGroupService); + + // Creates an ad group. + // Note that the ad group type must not be set. + // Since the advertising_channel_sub_type is APP_CAMPAIGN, + // 1. you cannot override bid settings at the ad group level. + // 2. you cannot add ad group criteria. + AdGroup adGroup = new AdGroup() + { + Name = $"Earth to Mars Cruises #{ExampleUtilities.GetRandomString()}", + Status = AdGroupStatus.Enabled, + Campaign = campaignResourceName + }; + + // Creates an ad group operation. + // Create the operation. + AdGroupOperation operation = new AdGroupOperation() + { + Create = adGroup + }; + + // Submits the ad group operation to add the ad group and prints the results. + MutateAdGroupsResponse response = + adGroupService.MutateAdGroups(customerId.ToString(), new[] { operation }); + + // Prints and returns the ad group resource name. + string adGroupResourceName = response.Results[0].ResourceName; + Console.WriteLine($"Created an ad group with resource name '{adGroupResourceName}'."); + return adGroupResourceName; + } + + /// + /// Creates an App ad for a given ad group. + /// + /// The Google Ads client. + /// The Google Ads customer ID for which the call is made. + /// The resource name of the ad group to add the App + /// ad to. + private void CreateAppAd(GoogleAdsClient client, long customerId, + string adGroupResourceName) + { + // Get the AdGroupAdService. + AdGroupAdServiceClient adGroupAdService = client.GetService( + Services.V3.AdGroupAdService); + + // Creates an ad group ad. + AdGroupAd adGroupAd = new AdGroupAd + { + AdGroup = adGroupResourceName, + Status = AdGroupAdStatus.Enabled, + Ad = new Ad + { + AppAd = new AppAdInfo + { + Headlines = { + new AdTextAsset() + { + Text = "A cool puzzle game" + }, + new AdTextAsset() + { + Text = "Remove connected blocks" + }, + }, + Descriptions = { + new AdTextAsset() + { + Text = "3 difficulty levels" + }, + new AdTextAsset() + { + Text = "4 colorful fun skins" + } + }, + // Optional: You can set up to 20 image assets for your campaign. + //Images = + //{ + // new AdImageAsset() + // { + // Asset = ResourceNames.Asset(customerId, assetId) + // } + //} + } + } + }; + + // Create the operation. + AdGroupAdOperation operation = new AdGroupAdOperation + { + Create = adGroupAd + }; + + // Submits the ad group ad operation to add the ad group ad and prints the results. + MutateAdGroupAdsResponse response = + adGroupAdService.MutateAdGroupAds(customerId.ToString(), new[] { operation }); + Console.WriteLine($"Created an ad group ad with ad with resource name " + + $"'{response.Results[0].ResourceName}'."); + } + } +} diff --git a/examples/AdvancedOperations/AddDynamicPageFeed.cs b/examples/AdvancedOperations/AddDynamicPageFeed.cs index 4096f1298..2e119283c 100644 --- a/examples/AdvancedOperations/AddDynamicPageFeed.cs +++ b/examples/AdvancedOperations/AddDynamicPageFeed.cs @@ -14,21 +14,21 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.DsaPageFeedCriterionFieldEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.FeedAttributeTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.FeedMappingCriterionTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.WebpageConditionOperandEnum.Types; -using static Google.Ads.GoogleAds.V2.Resources.Campaign.Types; +using static Google.Ads.GoogleAds.V3.Enums.DsaPageFeedCriterionFieldEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.FeedMappingCriterionTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperandEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a page feed to specify precisely which URLs to use with your @@ -120,7 +120,7 @@ public void Run(GoogleAdsClient client, long customerId, long campaignId, long a private string CreateFeed(GoogleAdsClient client, long customerId) { // Get the FeedService. - FeedServiceClient feedService = client.GetService(Services.V2.FeedService); + FeedServiceClient feedService = client.GetService(Services.V3.FeedService); // Create a URL attribute. FeedAttribute urlAttribute = new FeedAttribute() @@ -174,7 +174,7 @@ private Dictionary GetFeed( { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Construct the query. String query = $"SELECT feed.attributes FROM feed WHERE feed.resource_name" + @@ -231,7 +231,7 @@ Dictionary feedAttributes { // Get the FeedMappingService. FeedMappingServiceClient feedMappingService = client.GetService( - Services.V2.FeedMappingService); + Services.V3.FeedMappingService); FeedMapping feedMapping = new FeedMapping() { @@ -289,7 +289,7 @@ private void CreateFeedItems(GoogleAdsClient client, long customerId, { // Get the FeedItemService. FeedItemServiceClient feedItemService = client.GetService( - Services.V2.FeedItemService); + Services.V3.FeedItemService); List urls = new List { @@ -353,7 +353,7 @@ private void UpdateCampaignDsaSetting(GoogleAdsClient client, long customerId, { // Get the CampaignService. CampaignServiceClient campaignService = client.GetService( - Services.V2.CampaignService); + Services.V3.CampaignService); DynamicSearchAdsSetting dsaSetting = GetDsaSetting(client, customerId, campaignId); dsaSetting.Feeds.Add(feedResourceName); @@ -396,7 +396,7 @@ private DynamicSearchAdsSetting GetDsaSetting(GoogleAdsClient client, long custo { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Creates the query. // You must request all DSA fields in order to update the DSA settings in the @@ -440,7 +440,7 @@ private void AddDsaTarget(GoogleAdsClient client, long customerId, long adGroupI { // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = client.GetService( - Services.V2.AdGroupCriterionService); + Services.V3.AdGroupCriterionService); // Create the webpage condition info. WebpageConditionInfo webpageConditionInfo = new WebpageConditionInfo() diff --git a/examples/AdvancedOperations/AddDynamicSearchAds.cs b/examples/AdvancedOperations/AddDynamicSearchAds.cs index 6d1207568..c7bb6bd69 100644 --- a/examples/AdvancedOperations/AddDynamicSearchAds.cs +++ b/examples/AdvancedOperations/AddDynamicSearchAds.cs @@ -13,24 +13,24 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupCriterionStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.WebpageConditionOperandEnum.Types; -using static Google.Ads.GoogleAds.V2.Resources.Campaign.Types; - -namespace Google.Ads.GoogleAds.Examples.V2 +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperandEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds dynamic search ads to a given ad group. To list @@ -104,7 +104,7 @@ private static string AddCampaignBudget(GoogleAdsClient client, long customerId) { // Get the CampaignBudgetService. CampaignBudgetServiceClient campaignBudgetService = - client.GetService(Services.V2.CampaignBudgetService); + client.GetService(Services.V3.CampaignBudgetService); // Create the budget. CampaignBudget campaignBudget = new CampaignBudget() @@ -142,7 +142,7 @@ private static string AddCampaign(GoogleAdsClient client, long customerId, string budgetResourceName) { // Get the CampaignService. - CampaignServiceClient campaignService = client.GetService(Services.V2.CampaignService); + CampaignServiceClient campaignService = client.GetService(Services.V3.CampaignService); // Create the campaign. Campaign campaign = new Campaign() @@ -190,7 +190,7 @@ private static string AddAdGroup(GoogleAdsClient client, long customerId, string campaignResourceName) { // Get the AdGroupService. - AdGroupServiceClient adGroupService = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient adGroupService = client.GetService(Services.V3.AdGroupService); // Create the ad group. AdGroup adGroup = new AdGroup() @@ -230,7 +230,7 @@ private static void AddExpandedDSA(GoogleAdsClient client, long customerId, { // Get the AdGroupAdService. AdGroupAdServiceClient adGroupAdService = - client.GetService(Services.V2.AdGroupAdService); + client.GetService(Services.V3.AdGroupAdService); // Create an ad group ad. AdGroupAd adGroupAd = new AdGroupAd() @@ -273,7 +273,7 @@ private static void AddWebPageCriteria(GoogleAdsClient client, long customerId, { // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = - client.GetService(Services.V2.AdGroupCriterionService); + client.GetService(Services.V3.AdGroupCriterionService); // Create the criterion. AdGroupCriterion adGroupCriterion = new AdGroupCriterion() diff --git a/examples/AdvancedOperations/AddExpandedTextAdWithUpgradedUrls.cs b/examples/AdvancedOperations/AddExpandedTextAdWithUpgradedUrls.cs index cdb8c969f..7f8e5fc77 100644 --- a/examples/AdvancedOperations/AddExpandedTextAdWithUpgradedUrls.cs +++ b/examples/AdvancedOperations/AddExpandedTextAdWithUpgradedUrls.cs @@ -13,16 +13,16 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds expanded text ads to a given ad group. To list @@ -70,7 +70,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long adGroupId) { // Get the AdGroupAdService. - AdGroupAdServiceClient service = client.GetService(Services.V2.AdGroupAdService); + AdGroupAdServiceClient service = client.GetService(Services.V3.AdGroupAdService); // Create the expanded text ad. AdGroupAd ad = new AdGroupAd diff --git a/examples/AdvancedOperations/AddGmailAd.cs b/examples/AdvancedOperations/AddGmailAd.cs index 6cb02dcdb..dc6d7a601 100644 --- a/examples/AdvancedOperations/AddGmailAd.cs +++ b/examples/AdvancedOperations/AddGmailAd.cs @@ -14,19 +14,19 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Protobuf; using System; using System.Collections.Generic; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.DeviceEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.MediaTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.MimeTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MediaTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a Gmail ad to a given ad group. The ad group's campaign needs to @@ -99,7 +99,7 @@ private Dictionary AddMediaFiles(GoogleAdsClient client, long cu { // Get the MediaFileService. MediaFileServiceClient mediaFileService = - client.GetService(Services.V2.MediaFileService); + client.GetService(Services.V3.MediaFileService); // Creates a bytes array from the logo image data. byte[] logoImageData = MediaUtilities.GetAssetDataFromUrl( @@ -174,7 +174,7 @@ private void AddAd(GoogleAdsClient client, long customerId, long adGroupId, { // Get the AdGroupAdService. AdGroupAdServiceClient adGroupAdService = - client.GetService(Services.V2.AdGroupAdService); + client.GetService(Services.V3.AdGroupAdService); // Creates the Gmail ad info. GmailAdInfo gmailAdInfo = new GmailAdInfo() diff --git a/examples/AdvancedOperations/AddSmartDisplayAd.cs b/examples/AdvancedOperations/AddSmartDisplayAd.cs index 239e62137..e23db56dc 100644 --- a/examples/AdvancedOperations/AddSmartDisplayAd.cs +++ b/examples/AdvancedOperations/AddSmartDisplayAd.cs @@ -14,23 +14,23 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Enums; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Enums; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Protobuf; using System; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelSubTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AssetTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.MimeTypeEnum.Types; - -namespace Google.Ads.GoogleAds.Examples.V2 +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AssetTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// @@ -116,7 +116,7 @@ private static string CreateBudget(GoogleAdsClient client, long customerId) { // Get the BudgetService. CampaignBudgetServiceClient budgetService = client.GetService( - Services.V2.CampaignBudgetService); + Services.V3.CampaignBudgetService); // Create the campaign budget. CampaignBudget budget = new CampaignBudget() @@ -155,7 +155,7 @@ private string CreateSmartDisplayCampaign(GoogleAdsClient client, long customerI string budgetResourceName) { // Get the CampaignService. - CampaignServiceClient campaignService = client.GetService(Services.V2.CampaignService); + CampaignServiceClient campaignService = client.GetService(Services.V3.CampaignService); // Create the campaign. Campaign campaign = new Campaign() @@ -212,7 +212,7 @@ private string CreateAdGroup(GoogleAdsClient client, long customerId, string campaignResourceName) { // Get the AdGroupService. - AdGroupServiceClient adGroupService = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient adGroupService = client.GetService(Services.V3.AdGroupService); // Create the ad group. AdGroup adGroup = new AdGroup() @@ -254,7 +254,7 @@ private static string UploadImageAsset(GoogleAdsClient client, long customerId, { // Get the AssetServiceClient. AssetServiceClient assetService = - client.GetService(Services.V2.AssetService); + client.GetService(Services.V3.AssetService); // Creates an image content. byte[] imageContent = MediaUtilities.GetAssetDataFromUrl(imageUrl, client.Config); @@ -320,7 +320,7 @@ private static string CreateResponsiveDisplayAd(GoogleAdsClient client, long cus { // Get the AdGroupAdServiceClient. AdGroupAdServiceClient adGroupAdService = - client.GetService(Services.V2.AdGroupAdService); + client.GetService(Services.V3.AdGroupAdService); // Creates a responsive display ad info. ResponsiveDisplayAdInfo responsiveDisplayAdInfo = new ResponsiveDisplayAdInfo() diff --git a/examples/AdvancedOperations/CreateAndAttachSharedKeywordSet.cs b/examples/AdvancedOperations/CreateAndAttachSharedKeywordSet.cs index bff3b76db..3ab52c66a 100644 --- a/examples/AdvancedOperations/CreateAndAttachSharedKeywordSet.cs +++ b/examples/AdvancedOperations/CreateAndAttachSharedKeywordSet.cs @@ -13,16 +13,16 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -using static Google.Ads.GoogleAds.V2.Enums.KeywordMatchTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.SharedSetTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.SharedSetTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example creates a shared list of negative broad match keywords. It then @@ -71,11 +71,11 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long campaignId) { SharedSetServiceClient sharedSetService = client.GetService( - Services.V2.SharedSetService); + Services.V3.SharedSetService); SharedCriterionServiceClient sharedCriterionService = - client.GetService(Services.V2.SharedCriterionService); + client.GetService(Services.V3.SharedCriterionService); CampaignSharedSetServiceClient campaignSharedSetService = - client.GetService(Services.V2.CampaignSharedSetService); + client.GetService(Services.V3.CampaignSharedSetService); try { diff --git a/examples/AdvancedOperations/FindAndRemoveCriteriaFromSharedSet.cs b/examples/AdvancedOperations/FindAndRemoveCriteriaFromSharedSet.cs index 6ab50c323..228f933f5 100644 --- a/examples/AdvancedOperations/FindAndRemoveCriteriaFromSharedSet.cs +++ b/examples/AdvancedOperations/FindAndRemoveCriteriaFromSharedSet.cs @@ -13,15 +13,15 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; using System.Collections.Generic; -using static Google.Ads.GoogleAds.V2.Enums.CriterionTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example demonstrates how to find shared sets, shared set criteria, and @@ -72,10 +72,10 @@ public void Run(GoogleAdsClient client, long customerId, long campaignId) try { SharedCriterionServiceClient sharedCriterionService = client.GetService( - Services.V2.SharedCriterionService); + Services.V3.SharedCriterionService); GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); List sharedSetIds = new List(); List criterionResources = new List(); diff --git a/examples/AdvancedOperations/GetAdGroupBidModifiers.cs b/examples/AdvancedOperations/GetAdGroupBidModifiers.cs index a1424bd7c..a37ef1b7e 100644 --- a/examples/AdvancedOperations/GetAdGroupBidModifiers.cs +++ b/examples/AdvancedOperations/GetAdGroupBidModifiers.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets ad group bid modifiers. @@ -71,7 +71,7 @@ public void Run(GoogleAdsClient client, long customerId, long? adGroupId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); string searchQuery = "SELECT ad_group.id, ad_group_bid_modifier.criterion_id, " diff --git a/examples/AdvancedOperations/UsePortfolioBiddingStrategy.cs b/examples/AdvancedOperations/UsePortfolioBiddingStrategy.cs index 14fab8d7f..f652ff466 100644 --- a/examples/AdvancedOperations/UsePortfolioBiddingStrategy.cs +++ b/examples/AdvancedOperations/UsePortfolioBiddingStrategy.cs @@ -13,19 +13,19 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Enums; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Enums; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Resources.Campaign.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a portfolio bidding strategy and uses it to construct a campaign. @@ -123,7 +123,7 @@ private string CreatePortfolioBiddingStrategy(GoogleAdsClient client, { // Get the BiddingStrategyService. BiddingStrategyServiceClient biddingStrategyService = client.GetService( - Services.V2.BiddingStrategyService); + Services.V3.BiddingStrategyService); // Create a portfolio bidding strategy. BiddingStrategy biddingStrategy = new BiddingStrategy() @@ -165,7 +165,7 @@ private string CreateSharedBudget(GoogleAdsClient client, long customerId, strin { // Get the CampaignBudgetService. CampaignBudgetServiceClient campaignBudgetService = - client.GetService(Services.V2.CampaignBudgetService); + client.GetService(Services.V3.CampaignBudgetService); // Create a shared budget. CampaignBudget budget = new CampaignBudget() @@ -202,7 +202,7 @@ private string CreateCampaignWithBiddingStrategy(GoogleAdsClient client, string campaignBudgetResourceName) { // Get the CampaignService. - CampaignServiceClient campaignService = client.GetService(Services.V2.CampaignService); + CampaignServiceClient campaignService = client.GetService(Services.V3.CampaignService); // Create the campaign. Campaign campaign = new Campaign() diff --git a/examples/Authentication/AuthenticateInWebApplication/AuthenticateInWebApplication.csproj b/examples/Authentication/AuthenticateInWebApplication/AuthenticateInWebApplication.csproj index 7310698e2..90f6532ea 100644 --- a/examples/Authentication/AuthenticateInWebApplication/AuthenticateInWebApplication.csproj +++ b/examples/Authentication/AuthenticateInWebApplication/AuthenticateInWebApplication.csproj @@ -50,8 +50,8 @@ {C691BD4D-683D-425B-8BC7-52F161475C7C} Google.Ads.GoogleAds - - ..\..\..\packages\Google.Ads.GoogleAds.2.7.0\lib\net452\Google.Ads.GoogleAds.dll + + ..\..\..\packages\Google.Ads.GoogleAds.2.8.0\lib\net452\Google.Ads.GoogleAds.dll diff --git a/examples/Authentication/AuthenticateInWebApplication/Default.aspx.cs b/examples/Authentication/AuthenticateInWebApplication/Default.aspx.cs index 94665d2af..989799fd3 100644 --- a/examples/Authentication/AuthenticateInWebApplication/Default.aspx.cs +++ b/examples/Authentication/AuthenticateInWebApplication/Default.aspx.cs @@ -13,7 +13,7 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; using System.Web.UI; @@ -82,7 +82,7 @@ protected void btnGetCampaigns_Click(object sender, EventArgs e) string customerId = txtCustomerId.Text; // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create a request that will retrieve all campaigns using pages of the specified // page size. diff --git a/examples/Authentication/AuthenticateInWebApplication/Web.config b/examples/Authentication/AuthenticateInWebApplication/Web.config index c3aaa05dc..a89b67d02 100644 --- a/examples/Authentication/AuthenticateInWebApplication/Web.config +++ b/examples/Authentication/AuthenticateInWebApplication/Web.config @@ -1,85 +1,43 @@  - + - + - - + + - + - - + + - - - - + + + + - + - - + + - - - + + + - - + + - - + + - - + + @@ -99,27 +57,27 @@ - + - + - + - + - + - + @@ -131,15 +89,15 @@ - + - + - + @@ -157,6 +115,10 @@ + + + + diff --git a/examples/Authentication/AuthenticateInWebApplication/packages.config b/examples/Authentication/AuthenticateInWebApplication/packages.config index efc95a115..02a1c1f60 100644 --- a/examples/Authentication/AuthenticateInWebApplication/packages.config +++ b/examples/Authentication/AuthenticateInWebApplication/packages.config @@ -1,6 +1,6 @@  - + diff --git a/examples/BasicOperations/AddAdGroups.cs b/examples/BasicOperations/AddAdGroups.cs index a7108397e..c08570654 100644 --- a/examples/BasicOperations/AddAdGroups.cs +++ b/examples/BasicOperations/AddAdGroups.cs @@ -13,15 +13,15 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Enums; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Enums; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates how to create ad groups. To create campaigns, run @@ -73,7 +73,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long campaignId) { // Get the AdGroupService. - AdGroupServiceClient adGroupService = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient adGroupService = client.GetService(Services.V3.AdGroupService); List operations = new List(); diff --git a/examples/BasicOperations/AddCampaigns.cs b/examples/BasicOperations/AddCampaigns.cs index 7426e4b25..644e56478 100644 --- a/examples/BasicOperations/AddCampaigns.cs +++ b/examples/BasicOperations/AddCampaigns.cs @@ -13,19 +13,19 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Resources.Campaign.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds campaigns. @@ -72,7 +72,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId) { // Get the CampaignService. - CampaignServiceClient campaignService = client.GetService(Services.V2.CampaignService); + CampaignServiceClient campaignService = client.GetService(Services.V3.CampaignService); // Create a budget to be used for the campaign. string budget = CreateBudget(client, customerId); @@ -154,7 +154,7 @@ private static string CreateBudget(GoogleAdsClient client, long customerId) { // Get the BudgetService. CampaignBudgetServiceClient budgetService = client.GetService( - Services.V2.CampaignBudgetService); + Services.V3.CampaignBudgetService); // Create the campaign budget. CampaignBudget budget = new CampaignBudget() diff --git a/examples/BasicOperations/AddExpandedTextAds.cs b/examples/BasicOperations/AddExpandedTextAds.cs index 4a366ea50..16e0f4f11 100644 --- a/examples/BasicOperations/AddExpandedTextAds.cs +++ b/examples/BasicOperations/AddExpandedTextAds.cs @@ -13,17 +13,17 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds expanded text ads to a given ad group. To list @@ -77,7 +77,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId) { // Get the AdGroupAdService. AdGroupAdServiceClient adGroupAdService = client.GetService( - Services.V2.AdGroupAdService); + Services.V3.AdGroupAdService); List operations = new List(); for (int i = 0; i < NUMBER_OF_ADS; i++) diff --git a/examples/BasicOperations/AddKeywords.cs b/examples/BasicOperations/AddKeywords.cs index 3bf26e317..32dd345b4 100644 --- a/examples/BasicOperations/AddKeywords.cs +++ b/examples/BasicOperations/AddKeywords.cs @@ -13,17 +13,17 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupCriterionStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.KeywordMatchTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example demonstrates how to add keyword into an ad group. @@ -74,7 +74,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, string { // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = - client.GetService(Services.V2.AdGroupCriterionService); + client.GetService(Services.V3.AdGroupCriterionService); // Create a keyword. AdGroupCriterion criterion = new AdGroupCriterion() diff --git a/examples/BasicOperations/AddResponsiveSearchAd.cs b/examples/BasicOperations/AddResponsiveSearchAd.cs index bfcfb1151..131d7589c 100644 --- a/examples/BasicOperations/AddResponsiveSearchAd.cs +++ b/examples/BasicOperations/AddResponsiveSearchAd.cs @@ -13,16 +13,16 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Enums; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Enums; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.ServedAssetFieldTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ServedAssetFieldTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a responsive search ad to a given ad group. To get ad groups, @@ -70,7 +70,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId) { // Get the AdGroupAdService. AdGroupAdServiceClient adGroupAdService = - client.GetService(Services.V2.AdGroupAdService); + client.GetService(Services.V3.AdGroupAdService); // Create the ad. Ad ad = new Ad() diff --git a/examples/BasicOperations/GetAdGroups.cs b/examples/BasicOperations/GetAdGroups.cs index 26bf069d0..a227690d0 100644 --- a/examples/BasicOperations/GetAdGroups.cs +++ b/examples/BasicOperations/GetAdGroups.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This example gets ad groups. @@ -68,7 +68,7 @@ public void Run(GoogleAdsClient client, long customerId, long? campaignId) { // Get the AdGroupService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign.id, ad_group.id, ad_group.name FROM ad_group"; diff --git a/examples/BasicOperations/GetArtifactMetadata.cs b/examples/BasicOperations/GetArtifactMetadata.cs index cdfd5e244..55cda717d 100644 --- a/examples/BasicOperations/GetArtifactMetadata.cs +++ b/examples/BasicOperations/GetArtifactMetadata.cs @@ -13,16 +13,16 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; using System.Collections.Generic; using System.Linq; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets the metadata, such as whether the artifact is selectable, filterable @@ -76,7 +76,7 @@ public void Run(GoogleAdsClient client, long customerId, string artifactName) { // Get the GoogleAdsFieldService. GoogleAdsFieldServiceClient googleAdsFieldService = client.GetService( - Services.V2.GoogleAdsFieldService); + Services.V3.GoogleAdsFieldService); // Create the query. string searchQuery = $"SELECT name, category, selectable, filterable, sortable, " + diff --git a/examples/BasicOperations/GetCampaigns.cs b/examples/BasicOperations/GetCampaigns.cs index bda1ed377..166852c7e 100644 --- a/examples/BasicOperations/GetCampaigns.cs +++ b/examples/BasicOperations/GetCampaigns.cs @@ -13,23 +13,21 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; +using System.Threading; +using System.Threading.Tasks; +using static Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceClient; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets all campaigns. To add campaigns, run AddCampaigns.cs. /// public class GetCampaigns : ExampleBase { - /// - /// The page size to be used by default. - /// - private const int PAGE_SIZE = 1_000; - /// /// Main method, to run this code example as a standalone application. /// @@ -67,44 +65,29 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); - // Create a request that will retrieve all campaigns using pages of the specified - // page size. - SearchGoogleAdsRequest request = new SearchGoogleAdsRequest() - { - PageSize = PAGE_SIZE, - Query = @"SELECT + // Create a query that will retrieve all campaigns. + string query = @"SELECT campaign.id, campaign.name, campaign.network_settings.target_content_network FROM campaign - ORDER BY campaign.id", - CustomerId = customerId.ToString() - }; + ORDER BY campaign.id"; try { - // Issue the search request. - PagedEnumerable searchPagedResponse = - googleAdsService.Search(request); - - foreach (SearchGoogleAdsResponse response in searchPagedResponse.AsRawResponses()) - { - Console.WriteLine(response.FieldMask.Paths); - foreach (GoogleAdsRow googleAdsRow in response.Results) + // Issue a search request. + googleAdsService.SearchStream(customerId.ToString(), query, + delegate (SearchGoogleAdsStreamResponse resp) { - Console.WriteLine("Campaign with ID {0} and name '{1}' was found.", - googleAdsRow.Campaign.Id, googleAdsRow.Campaign.Name); + foreach (GoogleAdsRow googleAdsRow in resp.Results) + { + Console.WriteLine("Campaign with ID {0} and name '{1}' was found.", + googleAdsRow.Campaign.Id, googleAdsRow.Campaign.Name); + } } - } - // Iterate over all rows in all pages and prints the requested field values for the - // campaign in each row. - foreach (GoogleAdsRow googleAdsRow in searchPagedResponse) - { - Console.WriteLine("Campaign with ID {0} and name '{1}' was found.", - googleAdsRow.Campaign.Id, googleAdsRow.Campaign.Name); - } + ); } catch (GoogleAdsException e) { diff --git a/examples/BasicOperations/GetExpandedTextAds.cs b/examples/BasicOperations/GetExpandedTextAds.cs index 4fd5f3bed..a8613ab3f 100644 --- a/examples/BasicOperations/GetExpandedTextAds.cs +++ b/examples/BasicOperations/GetExpandedTextAds.cs @@ -13,15 +13,15 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets expanded text ads. @@ -73,7 +73,7 @@ public void Run(GoogleAdsClient client, long customerId, long? adGroupId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); string searchQuery = $@"SELECT diff --git a/examples/BasicOperations/GetKeywords.cs b/examples/BasicOperations/GetKeywords.cs index 878516ec2..0d2e63d09 100644 --- a/examples/BasicOperations/GetKeywords.cs +++ b/examples/BasicOperations/GetKeywords.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates getting keywords. @@ -61,7 +61,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); try { PagedEnumerable result = diff --git a/examples/BasicOperations/PauseAd.cs b/examples/BasicOperations/PauseAd.cs index 207353626..165c16b92 100644 --- a/examples/BasicOperations/PauseAd.cs +++ b/examples/BasicOperations/PauseAd.cs @@ -14,15 +14,15 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example pauses a given ad. To list all ads, run GetExpandedTextAds.cs. @@ -73,7 +73,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, long ad { // Get the AdGroupAdService. AdGroupAdServiceClient adGroupAdService = client.GetService( - Services.V2.AdGroupAdService); + Services.V3.AdGroupAdService); // Create the ad group ad. AdGroupAd adGroupAd = new AdGroupAd diff --git a/examples/BasicOperations/RemoveAd.cs b/examples/BasicOperations/RemoveAd.cs index c628bfd36..0194787dd 100644 --- a/examples/BasicOperations/RemoveAd.cs +++ b/examples/BasicOperations/RemoveAd.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example removes an ad. To list ads, run GetExpandedTextAds.cs. @@ -67,7 +67,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long adGroupId, long adId) { // Get the AdGroupAdService. - AdGroupAdServiceClient service = client.GetService(Services.V2.AdGroupAdService); + AdGroupAdServiceClient service = client.GetService(Services.V3.AdGroupAdService); // Create a new operation. AdGroupAdOperation operation = new AdGroupAdOperation diff --git a/examples/BasicOperations/RemoveAdGroup.cs b/examples/BasicOperations/RemoveAdGroup.cs index 6e9dd1bd1..4cb62b685 100644 --- a/examples/BasicOperations/RemoveAdGroup.cs +++ b/examples/BasicOperations/RemoveAdGroup.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example deletes an ad group. To get ad groups, run GetAdGroups.cs. @@ -64,7 +64,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long adGroupId) { // Get the AdGroupService. - AdGroupServiceClient service = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient service = client.GetService(Services.V3.AdGroupService); // Construct an operation that will remove the ad group with the specified // resource name. diff --git a/examples/BasicOperations/RemoveCampaign.cs b/examples/BasicOperations/RemoveCampaign.cs index 8a5aa4dbc..e763088cb 100644 --- a/examples/BasicOperations/RemoveCampaign.cs +++ b/examples/BasicOperations/RemoveCampaign.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example removes a campaign. To get campaigns, run GetCampaigns.cs. @@ -64,7 +64,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long campaignId) { // Get the CampaignService. - CampaignServiceClient campaignService = client.GetService(Services.V2.CampaignService); + CampaignServiceClient campaignService = client.GetService(Services.V3.CampaignService); // Create the operation, and set the Remove field to the resource name of the // campaign to be removed. diff --git a/examples/BasicOperations/RemoveKeyword.cs b/examples/BasicOperations/RemoveKeyword.cs index 0785acc0a..0cf034888 100644 --- a/examples/BasicOperations/RemoveKeyword.cs +++ b/examples/BasicOperations/RemoveKeyword.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example removes a keyword. To get keywords, run GetKeywords.cs. @@ -69,7 +69,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, long ke { // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = client.GetService( - Services.V2.AdGroupCriterionService); + Services.V3.AdGroupCriterionService); // Create the operation. AdGroupCriterionOperation operation = new AdGroupCriterionOperation(); diff --git a/examples/BasicOperations/UpdateAdGroup.cs b/examples/BasicOperations/UpdateAdGroup.cs index 373964b94..28be57212 100644 --- a/examples/BasicOperations/UpdateAdGroup.cs +++ b/examples/BasicOperations/UpdateAdGroup.cs @@ -14,13 +14,13 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Enums; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Enums; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates how to update an ad group, setting its status to 'PAUSED', @@ -78,7 +78,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long adGroupId, long? bidMicroAmount) { - AdGroupServiceClient adGroupService = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient adGroupService = client.GetService(Services.V3.AdGroupService); // Create an ad group with the specified ID. AdGroup adGroup = new AdGroup(); diff --git a/examples/BasicOperations/UpdateCampaign.cs b/examples/BasicOperations/UpdateCampaign.cs index cda7bc8db..632b3d0f6 100644 --- a/examples/BasicOperations/UpdateCampaign.cs +++ b/examples/BasicOperations/UpdateCampaign.cs @@ -14,15 +14,15 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Resources.Campaign.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example updates a campaign. To get campaigns, run GetCampaigns.cs. @@ -69,7 +69,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long campaignId) { // Get the CampaignService. - CampaignServiceClient campaignService = client.GetService(Services.V2.CampaignService); + CampaignServiceClient campaignService = client.GetService(Services.V3.CampaignService); // Update campaign by setting its status to paused, and "Search network" to false. Campaign campaignToUpdate = new Campaign() diff --git a/examples/BasicOperations/UpdateKeyword.cs b/examples/BasicOperations/UpdateKeyword.cs index 020f9efb0..64cab113c 100644 --- a/examples/BasicOperations/UpdateKeyword.cs +++ b/examples/BasicOperations/UpdateKeyword.cs @@ -14,15 +14,15 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupCriterionStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates udating a keyword. @@ -70,7 +70,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, long ke { // Get the CampaignCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = - client.GetService(Services.V2.AdGroupCriterionService); + client.GetService(Services.V3.AdGroupCriterionService); // Create the keyword for update. AdGroupCriterion keyword = new AdGroupCriterion() diff --git a/examples/Billing/AddAccountBudgetProposal.cs b/examples/Billing/AddAccountBudgetProposal.cs index 6f02f7371..034d51e9d 100644 --- a/examples/Billing/AddAccountBudgetProposal.cs +++ b/examples/Billing/AddAccountBudgetProposal.cs @@ -13,15 +13,15 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; -using static Google.Ads.GoogleAds.V2.Enums.AccountBudgetProposalTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.TimeTypeEnum.Types; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; +using static Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example creates an account budget proposal using the 'CREATE' operation. To get @@ -75,7 +75,7 @@ public void Run(GoogleAdsClient client, long customerId, long billingSetupId) { // Get the AccountBudgetProposalServiceClient. AccountBudgetProposalServiceClient proposalService = - client.GetService(Services.V2.AccountBudgetProposalService); + client.GetService(Services.V3.AccountBudgetProposalService); // Create an AccountBudgetProposal. // The proposal will be reviewed offline by Google Ads, and if approved will diff --git a/examples/Billing/GetAccountBudgetProposals.cs b/examples/Billing/GetAccountBudgetProposals.cs index 199589f98..18d28bf9e 100644 --- a/examples/Billing/GetAccountBudgetProposals.cs +++ b/examples/Billing/GetAccountBudgetProposals.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets all account budget proposals. To add an account budget proposal, run @@ -67,7 +67,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsServiceClient. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Construct a GAQL query which will retrieve AccountBudgetProposals. String searchQuery = diff --git a/examples/Billing/GetAccountBudgets.cs b/examples/Billing/GetAccountBudgets.cs index a6e5e16ba..8680f48a4 100644 --- a/examples/Billing/GetAccountBudgets.cs +++ b/examples/Billing/GetAccountBudgets.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This example retrieves all account budgets for a Google Ads customer. @@ -65,7 +65,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsServiceClient. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Construct a GAQL query which will retrieve AccountBudgetProposals. String searchQuery = diff --git a/examples/Billing/GetBillingSetup.cs b/examples/Billing/GetBillingSetup.cs index c500fed28..ff631cc7e 100644 --- a/examples/Billing/GetBillingSetup.cs +++ b/examples/Billing/GetBillingSetup.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets all BillingSetup objects available for the specified customer ID. @@ -66,7 +66,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsServiceClient. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Define a GAQL query to retrieve all billing setup information. string searchQuery = @" diff --git a/examples/Billing/RemoveBillingSetup.cs b/examples/Billing/RemoveBillingSetup.cs index 6cc214673..c31b34be6 100644 --- a/examples/Billing/RemoveBillingSetup.cs +++ b/examples/Billing/RemoveBillingSetup.cs @@ -13,11 +13,11 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example removes a billing setup, specified by ID. To get available billing setup, @@ -70,7 +70,7 @@ public void Run(GoogleAdsClient client, long customerId, long billingSetupId) { // Get the BillingSetupServiceClient. BillingSetupServiceClient billingSetupService = client.GetService( - Services.V2.BillingSetupService); + Services.V3.BillingSetupService); // Create the billing setup resource. String billingSetupResource = ResourceNames.BillingSetup(customerId, billingSetupId); diff --git a/examples/CampaignManagement/AddCampaignBidModifier.cs b/examples/CampaignManagement/AddCampaignBidModifier.cs index 0ccb819df..173c71849 100644 --- a/examples/CampaignManagement/AddCampaignBidModifier.cs +++ b/examples/CampaignManagement/AddCampaignBidModifier.cs @@ -13,15 +13,15 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.InteractionTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.InteractionTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example demonstrates how to add a campaign-level bid modifier for call @@ -75,7 +75,7 @@ public void Run(GoogleAdsClient client, long customerId, long campaignId, { // Get the CampaignBidModifierService. CampaignBidModifierServiceClient campaignBidModifierService = - client.GetService(Services.V2.CampaignBidModifierService); + client.GetService(Services.V3.CampaignBidModifierService); String campaignResourceName = ResourceNames.Campaign(customerId, campaignId); diff --git a/examples/CampaignManagement/AddCampaignDraft.cs b/examples/CampaignManagement/AddCampaignDraft.cs index d576bf509..b0cf0ed0f 100644 --- a/examples/CampaignManagement/AddCampaignDraft.cs +++ b/examples/CampaignManagement/AddCampaignDraft.cs @@ -13,15 +13,15 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Linq; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a campaign draft for a campaign. Make sure you specify a @@ -95,7 +95,7 @@ private static string CreateCampaignDraft(GoogleAdsClient client, long customerI { // Get the CampaignDraftService. CampaignDraftServiceClient campaignDraftService = - client.GetService(Services.V2.CampaignDraftService); + client.GetService(Services.V3.CampaignDraftService); CampaignDraft campaignDraft = new CampaignDraft() { @@ -128,7 +128,7 @@ private static string FetchDraftCampaign(GoogleAdsClient client, long customerId { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); // Once the draft is created, you can modify the draft campaign as if it were // a real campaign. For example, you may add criteria, adjust bids, or even @@ -159,7 +159,7 @@ private static void AddLanguageCriteria(GoogleAdsClient client, long customerId, { // Get the CampaignCriterionService. CampaignCriterionServiceClient campaignCriterionService = - client.GetService(Services.V2.CampaignCriterionService); + client.GetService(Services.V3.CampaignCriterionService); // Add a language criterion. CampaignCriterionOperation criterionOperation = new CampaignCriterionOperation() diff --git a/examples/CampaignManagement/AddCampaignLabels.cs b/examples/CampaignManagement/AddCampaignLabels.cs index d2b98044d..71f10aedf 100644 --- a/examples/CampaignManagement/AddCampaignLabels.cs +++ b/examples/CampaignManagement/AddCampaignLabels.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a campaign label to a list of campaigns. @@ -73,7 +73,7 @@ public void Run(GoogleAdsClient client, long customerId, long[] campaignIds, lon { // Get the CampaignLabelServiceClient. CampaignLabelServiceClient campaignLabelService = - client.GetService(Services.V2.CampaignLabelService); + client.GetService(Services.V3.CampaignLabelService); // Gets the resource name of the label to be added across all given campaigns. string labelResourceName = ResourceNames.Label(customerId, labelId); diff --git a/examples/CampaignManagement/CreateCampaignExperiment.cs b/examples/CampaignManagement/CreateCampaignExperiment.cs index 4d508c61d..79ce7e4cd 100644 --- a/examples/CampaignManagement/CreateCampaignExperiment.cs +++ b/examples/CampaignManagement/CreateCampaignExperiment.cs @@ -13,16 +13,16 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.LongRunning; using Google.Protobuf.WellKnownTypes; using System; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.CampaignExperimentTrafficSplitTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a campaign draft for a campaign. Make sure you specify a @@ -101,7 +101,7 @@ private static Operation { // Get the CampaignExperimentService. CampaignExperimentServiceClient campaignExperimentService = - client.GetService(Services.V2.CampaignExperimentService); + client.GetService(Services.V3.CampaignExperimentService); CampaignExperiment experiment = new CampaignExperiment() { @@ -134,7 +134,7 @@ private static void DisplayExperimentDetails(GoogleAdsClient client, long custom { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); // Once the draft is created, you can modify the draft campaign as if it were // a real campaign. For example, you may add criteria, adjust bids, or even diff --git a/examples/CampaignManagement/GetAllDisapprovedAds.cs b/examples/CampaignManagement/GetAllDisapprovedAds.cs index c15a06d76..398f792ce 100644 --- a/examples/CampaignManagement/GetAllDisapprovedAds.cs +++ b/examples/CampaignManagement/GetAllDisapprovedAds.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -using static Google.Ads.GoogleAds.V2.Enums.PolicyApprovalStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example retrieves all the disapproved ads in a given campaign. @@ -78,7 +78,7 @@ public void Run(GoogleAdsClient client, long customerId, long campaignId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); String searchQuery = $@"SELECT diff --git a/examples/CampaignManagement/GetCampaignsByLabel.cs b/examples/CampaignManagement/GetCampaignsByLabel.cs index dd1fab05d..0012e4deb 100644 --- a/examples/CampaignManagement/GetCampaignsByLabel.cs +++ b/examples/CampaignManagement/GetCampaignsByLabel.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets all campaigns with a specific label. @@ -64,7 +64,7 @@ public void Run(GoogleAdsClient client, long customerId, long labelId) { // Get the GoogleAdsServiceClient. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); // Creates a request that will retrieve all campaign labels with the specified // labelId using pages of the specified page size. diff --git a/examples/CampaignManagement/SetAdParameters.cs b/examples/CampaignManagement/SetAdParameters.cs index 6077a3c31..1306060a6 100644 --- a/examples/CampaignManagement/SetAdParameters.cs +++ b/examples/CampaignManagement/SetAdParameters.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example sets ad parameters for a keyword. To get ad group criteria, @@ -72,7 +72,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, long ke { // Get the AdParameterServiceClient. AdParameterServiceClient adParameterService = - client.GetService(Services.V2.AdParameterService); + client.GetService(Services.V3.AdParameterService); // Creates ad parameters. // There can be a maximum of two AdParameters per ad group criterion. diff --git a/examples/CampaignManagement/UpdateCampaignCriterionBidModifier.cs b/examples/CampaignManagement/UpdateCampaignCriterionBidModifier.cs new file mode 100644 index 000000000..982b2fb8d --- /dev/null +++ b/examples/CampaignManagement/UpdateCampaignCriterionBidModifier.cs @@ -0,0 +1,119 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; +using Google.Ads.GoogleAds.Util; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; +using System; +using static Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 +{ + /// + /// This code example updates a campaign criterion with a new bid modifier. + /// + public class UpdateCampaignCriterionBidModifier : ExampleBase + { + /// + /// Main method, to run this code example as a standalone application. + /// + /// The command line arguments. + public static void Main(string[] args) + { + UpdateCampaignCriterionBidModifier codeExample = new UpdateCampaignCriterionBidModifier(); + Console.WriteLine(codeExample.Description); + + // The Google Ads customer ID for which the call is made. + long customerId = long.Parse("INSERT_CUSTOMER_ID_HERE"); + + // ID of the campaign that contains the criterion. + long campaignId = long.Parse("INSERT_CAMPAIGN_ID_HERE"); + + // ID of the criterion for which bid modifier is updated. + long criterionId = long.Parse("INSERT_CRITERION_ID_HERE"); + + // The new value of the bid modifier to update. + float bidModifier = float.Parse("INSERT_BID_MODIFIER_HERE"); + + codeExample.Run(new GoogleAdsClient(), customerId, campaignId, criterionId, bidModifier); + } + + /// + /// Returns a description about the code example. + /// + public override string Description + { + get + { + return "This code example updates a campaign criterion with a new bid modifier."; + } + } + + /// + /// Runs the code example. + /// + /// The Google Ads client. + /// The Google Ads customer ID for which the call is made. + /// ID of the campaign that contains the criterion. + /// ID of the criterion for which bid modifier is updated. + /// The new value of the bid modifier to update. + public void Run(GoogleAdsClient client, long customerId, long campaignId, long criterionId, + float? bidModifier) + { + // Get the CampaignCriterionServiceClient . + CampaignCriterionServiceClient campaignCriterionService = + client.GetService(Services.V3.CampaignCriterionService); + + string criterionResourceName = ResourceNames.CampaignCriteria(customerId, + campaignId, criterionId); + + // Construct a campaign bid modifier. + CampaignCriterion campaignCriterion = new CampaignCriterion() + { + ResourceName = criterionResourceName, + BidModifier = (bidModifier != null)? bidModifier.Value : 1.5f, + }; + + // Construct an operation to create the campaign criterion. + CampaignCriterionOperation op = new CampaignCriterionOperation() + { + Update = campaignCriterion, + UpdateMask = FieldMasks.AllSetFieldsOf(campaignCriterion) + }; + + // Send the operation in a mutate request. + try + { + MutateCampaignCriteriaResponse response = + campaignCriterionService.MutateCampaignCriteria(customerId.ToString(), + new CampaignCriterionOperation[] { op }); + foreach (MutateCampaignCriterionResult result in response.Results) + { + Console.WriteLine($"Campaign criterion with resource name" + + $" '{result.ResourceName}' was modified."); + } + } + catch (GoogleAdsException e) + { + Console.WriteLine("Failure:"); + Console.WriteLine($"Message: {e.Message}"); + Console.WriteLine($"Failure: {e.Failure}"); + Console.WriteLine($"Request ID: {e.RequestId}"); + } + } + } +} diff --git a/examples/CampaignManagement/ValidateTextAd.cs b/examples/CampaignManagement/ValidateTextAd.cs index 1b1ec480a..f186defb0 100644 --- a/examples/CampaignManagement/ValidateTextAd.cs +++ b/examples/CampaignManagement/ValidateTextAd.cs @@ -13,18 +13,18 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Errors.PolicyFindingErrorEnum.Types; -using static Google.Ads.GoogleAds.V2.Errors.PolicyViolationErrorEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Errors.PolicyFindingErrorEnum.Types; +using static Google.Ads.GoogleAds.V3.Errors.PolicyViolationErrorEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example shows how to use the validateOnly header to validate @@ -74,7 +74,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId) { // Get the AdGroupAdService. AdGroupAdServiceClient adGroupAdService = client.GetService( - Services.V2.AdGroupAdService); + Services.V3.AdGroupAdService); // Create the ad group ad object. AdGroupAd adGroupAd = new AdGroupAd diff --git a/examples/ErrorHandling/HandlePartialFailures.cs b/examples/ErrorHandling/HandlePartialFailures.cs index 76ce505eb..7b68633e3 100644 --- a/examples/ErrorHandling/HandlePartialFailures.cs +++ b/examples/ErrorHandling/HandlePartialFailures.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; using System.Linq; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example demonstrates how to handle partial failures. @@ -165,7 +165,7 @@ private static MutateAdGroupsResponse CreateAdGroups(GoogleAdsClient client, long customerId, long campaignId) { // Get the AdGroupServiceClient. - AdGroupServiceClient adGroupService = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient adGroupService = client.GetService(Services.V3.AdGroupService); string validAdGroupName = "Valid AdGroup: " + ExampleUtilities.GetRandomString(); diff --git a/examples/ErrorHandling/HandleRateExceededError.cs b/examples/ErrorHandling/HandleRateExceededError.cs index b157aafb1..951753342 100644 --- a/examples/ErrorHandling/HandleRateExceededError.cs +++ b/examples/ErrorHandling/HandleRateExceededError.cs @@ -13,20 +13,20 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; using System.Linq; using System.Threading; using System.Threading.Tasks; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupCriterionStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.KeywordMatchTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Errors.QuotaErrorEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Errors.QuotaErrorEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example demonstrates how to handle RateExceededError in an application. @@ -118,7 +118,7 @@ await Task.Run(() => { // Get the AdGroupCriterionServiceClient. AdGroupCriterionServiceClient adGroupCriterionService = - client.GetService(Services.V2.AdGroupCriterionService); + client.GetService(Services.V3.AdGroupCriterionService); List operations = new List(); diff --git a/examples/Extensions/AddGoogleMyBusinessLocationExtensions.cs b/examples/Extensions/AddGoogleMyBusinessLocationExtensions.cs new file mode 100644 index 000000000..db3e8162b --- /dev/null +++ b/examples/Extensions/AddGoogleMyBusinessLocationExtensions.cs @@ -0,0 +1,467 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; +using Google.Api.Gax; +using Grpc.Core; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading; +using static Google.Ads.GoogleAds.V3.Common.Operand.Types; +using static Google.Ads.GoogleAds.V3.Enums.FeedOriginEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MatchingFunctionOperatorEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Feed.Types; +using static Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 +{ + /// + /// This code example adds a feed that syncs feed items from a Google My Business (GMB) account + /// and associates the feed with a customer. + /// + public class AddGoogleMyBusinessLocationExtensions : ExampleBase + { + // The required scope for setting the OAuth info. + private const string GOOGLE_ADS_SCOPE = "https://www.googleapis.com/auth/adwords"; + + // The maximum number of attempts to make to retrieve the FeedMappings before throwing an + // exception. + private const int MAX_FEEDMAPPING_RETRIEVAL_ATTEMPTS = 10; + + /// + /// Main method, to run this code example as a standalone application. + /// + /// The command line arguments. + public static void Main(string[] args) + { + AddGoogleMyBusinessLocationExtensions codeExample = + new AddGoogleMyBusinessLocationExtensions(); + Console.WriteLine(codeExample.Description); + + GoogleAdsClient client = new GoogleAdsClient(); + + // The customer ID for which the call is made. + int customerId = int.Parse("INSERT_CUSTOMER_ID_HERE"); + + // The email address of either an owner or a manager of the GMB account. + string gmbEmailAddress = "INSERT_GMB_EMAIL_ADDRESS_HERE"; + + // If the gmbEmailAddress above is the same user you used to generate + // your Google Ads API refresh token, leave the assignment below unchanged. + // Otherwise, to obtain an access token for your GMB account, run the + // AuthenticateInStandaloneApplication code example while logged in as the same + // user as gmbEmailAddress. Copy and paste the AccessToken value into the + // assignment below and delete the line after it. + + // string gmbAccessToken = "INSERT_GMB_ACCESS_TOKEN_HERE"; + string gmbAccessToken = client.Config.OAuth2AccessToken; + + // If the gmbEmailAddress above is for a GMB manager instead of the GMB + // account owner, then set businessAccountIdentifier to the Google+ Page ID of + // a location for which the manager has access. This information is available + // through the Google My Business API. See + // https://developers.google.com/my-business/reference/rest/v4/accounts.locations#locationkey + // for details. + string businessAccountId = null; + + codeExample.Run(new GoogleAdsClient(), customerId, gmbEmailAddress, + businessAccountId, gmbAccessToken); + } + + /// + /// Returns a description about the code example. + /// + public override string Description + { + get + { + return "This code example adds a feed that syncs feed items from a " + + "Google My Business (GMB) account and associates the feed with a customer."; + } + } + + /// + /// Runs the code example. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// The Google My Business login email address. + /// The Google My Business account + /// identifier. + /// The OAuth2 access token for The Google My Business + /// account. + public void Run(GoogleAdsClient client, long customerId, string gmbEmailAddress, + string businessAccountId, string gmbAccessToken) + { + try + { + if (string.IsNullOrEmpty(gmbAccessToken)) + { + gmbAccessToken = client.Config.OAuth2AccessToken; + } + string gmbFeedResourceName = CreateGMBFeed(client, customerId, gmbEmailAddress, + businessAccountId, gmbAccessToken); + // After the completion of the Feed ADD operation above the added feed will not be + // available for usage in a CustomerFeed until the FeedMappings are created. + // We will wait with an exponential back-off policy until the feedmappings have + // been created. + WaitForGMBFeedToBeReady(client, customerId, gmbFeedResourceName); + CreateCustomerFeed(client, customerId, gmbFeedResourceName); + } + catch (GoogleAdsException e) + { + Console.WriteLine("Failure:"); + Console.WriteLine($"Message: {e.Message}"); + Console.WriteLine($"Failure: {e.Failure}"); + Console.WriteLine($"Request ID: {e.RequestId}"); + } + } + + /// + /// Creates the Google My Business feed. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// The Google My Business login email address. + /// The Google My Business account ID. + /// The OAuth2 access token for The Google My Business + /// account. + /// ID of the newly created Google My Business feed. + private static string CreateGMBFeed(GoogleAdsClient client, long customerId, + string gmbEmailAddress, string businessAccountId, string gmbAccessToken) + { + // Optional: Delete all existing location extension feeds. This is an optional step, + // and is required for this code example to run correctly more than once. + // 1. Google Ads only allows one location extension feed per email address. + // 2. A Google Ads account cannot have a location extension feed and an affiliate + // location extension feed at the same time. + DeleteLocationExtensionFeeds(client, customerId); + + // Get the FeedServiceClient. + FeedServiceClient feedService = client.GetService(Services.V3.FeedService); + + // Creates a feed that will sync to the Google My Business account specified by + // gmbEmailAddress. Do not add FeedAttributes to this object as Google Ads will add + // them automatically because this will be a system generated feed. + Feed gmbFeed = new Feed() + { + Name = "Google My Business feed #" + ExampleUtilities.GetRandomString(), + + PlacesLocationFeedData = new PlacesLocationFeedData() + { + EmailAddress = gmbEmailAddress, + // If the EmailAddress is for a GMB manager instead of the GMB + // account owner, then set BusinessAccountId to the Google+ Page ID of + // a location for which the manager has access. This information is available + // through the Google My Business API. See + // https://developers.google.com/my-business/reference/rest/v4/accounts.locations#locationkey + // for details. + BusinessAccountId = string.IsNullOrEmpty(businessAccountId) ? + null : businessAccountId, + // Used to filter Google My Business listings by labels. If entries exist in + // label_filters, only listings that have at least one of the labels set are + // candidates to be synchronized into FeedItems. If no entries exist in + // label_filters, then all listings are candidates for syncing. + LabelFilters = { "Stores in New York" }, + // Sets the authentication info to be able to connect Google Ads to the GMB + // account. + OauthInfo = new OAuthInfo() + { + HttpMethod = "GET", + HttpRequestUrl = GOOGLE_ADS_SCOPE, + HttpAuthorizationHeader = $"Bearer {gmbAccessToken}" + }, + }, + // Since this feed's feed items will be managed by Google, + // you must set its origin to GOOGLE. + Origin = FeedOrigin.Google + }; + + FeedOperation operation = new FeedOperation() + { + Create = gmbFeed + }; + + // Adds the feed. + MutateFeedsResponse response = + feedService.MutateFeeds(customerId.ToString(), new[] { operation }); + + // Displays the results. + string gmbFeedResourceName = response.Results[0].ResourceName; + Console.WriteLine($"GMB feed created with resource name: {gmbFeedResourceName}."); + return gmbFeedResourceName; + } + + /// + /// Deletes the old location extension feeds. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + private static void DeleteLocationExtensionFeeds(GoogleAdsClient client, long customerId) + { + // To delete a location extension feed, you need to + // 1. Delete the CustomerFeed so that the location extensions from the feed stop + // serving. + // 2. Delete the feed so that Google Ads will no longer sync from the GMB account. + CustomerFeed[] oldCustomerFeeds = GetLocationExtensionCustomerFeeds(client, customerId); + if (oldCustomerFeeds.Length != 0) + { + DeleteCustomerFeeds(client, customerId, oldCustomerFeeds); + } + Feed[] feeds = GetLocationExtensionFeeds(client, customerId); + + if (feeds.Length != 0) + { + RemoveFeeds(client, customerId, feeds); + } + } + + /// + /// Gets the location extension feeds. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// The list of location extension feeds. + private static Feed[] GetLocationExtensionFeeds(GoogleAdsClient client, long customerId) + { + List feeds = new List(); + GoogleAdsServiceClient googleAdsService = client.GetService( + Services.V3.GoogleAdsService); + + // Create the query. + string query = $"SELECT feed.resource_name, feed.status, " + + $"feed.places_location_feed_data.email_address, " + + $"feed.affiliate_location_feed_data.chain_ids " + + $" from feed where feed.status = ENABLED"; + + PagedEnumerable result = + googleAdsService.Search(customerId.ToString(), query); + + foreach (GoogleAdsRow row in result) + { + // A location extension feed can be identified by checking whether the + // PlacesLocationFeedData field is set (Location extensions feeds) or + // AffiliateLocationFeedData field is set (Affiliate location extension feeds) + Feed feed = row.Feed; + if (feed.PlacesLocationFeedData != null || feed.AffiliateLocationFeedData != null) + { + feeds.Add(feed); + } + } + return feeds.ToArray(); + } + + /// + /// Removes the feeds. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// The list of feeds to remove. + private static void RemoveFeeds(GoogleAdsClient client, long customerId, Feed[] feeds) + { + List operations = new List(); + foreach (Feed feed in feeds) + { + FeedOperation operation = new FeedOperation() + { + Remove = feed.ResourceName, + }; + operations.Add(operation); + } + FeedServiceClient feedService = client.GetService( + Services.V3.FeedService); + + feedService.MutateFeeds(customerId.ToString(), operations.ToArray()); + } + + private static CustomerFeed[] GetLocationExtensionCustomerFeeds(GoogleAdsClient client, + long customerId) + { + List customerFeeds = new List(); + GoogleAdsServiceClient googleAdsService = client.GetService( + Services.V3.GoogleAdsService); + + // Create the query. A location extension customer feed can be identified by filtering + // for placeholder_types=LOCATION (location extension feeds) or + // placeholder_types =AFFILIATE_LOCATION (affiliate location extension feeds) + string query = $"SELECT customer_feed.resource_name, customer_feed.feed, " + + $"customer_feed.status, customer_feed.matching_function.function_string from " + + $"customer_feed " + + $"WHERE customer_feed.placeholder_types CONTAINS " + + $"ANY(LOCATION, AFFILIATE_LOCATION) and customer_feed.status=ENABLED"; + + PagedEnumerable result = + googleAdsService.Search(customerId.ToString(), query); + + foreach (GoogleAdsRow row in result) + { + customerFeeds.Add(row.CustomerFeed); + } + return customerFeeds.ToArray(); + } + + /// + /// Deletes the customer feeds. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// The customer feeds to delete. + private static void DeleteCustomerFeeds(GoogleAdsClient client, long customerId, + CustomerFeed[] customerFeeds) + { + List operations = new List(); + foreach (CustomerFeed customerFeed in customerFeeds) + { + CustomerFeedOperation operation = new CustomerFeedOperation() + { + Remove = customerFeed.ResourceName, + }; + operations.Add(operation); + } + + CustomerFeedServiceClient feedService = client.GetService( + Services.V3.CustomerFeedService); + + feedService.MutateCustomerFeeds(customerId.ToString(), operations.ToArray()); + } + + /// + /// Gets the Google My Business feed mapping. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// The GMB feed resource name. + /// The newly created feed mapping. + private static FeedMapping GetGMBFeedMapping(GoogleAdsClient client, long customerId, + string gmbFeedResourceName) + { + // Get the GoogleAdsService. + GoogleAdsServiceClient googleAdsService = client.GetService( + Services.V3.GoogleAdsService); + + // Create the query. + string query = $"SELECT feed_mapping.resource_name, feed_mapping.status FROM " + + $"feed_mapping WHERE feed_mapping.feed = '{gmbFeedResourceName}' and " + + $"feed_mapping.status = ENABLED and feed_mapping.placeholder_type = LOCATION" + + $" LIMIT 1"; + + // Issue a search request. + PagedEnumerable result = + googleAdsService.Search(customerId.ToString(), query); + + // Display the results. + GoogleAdsRow googleAdsRow = result.FirstOrDefault(); + return (googleAdsRow == null) ? null : googleAdsRow.FeedMapping; + } + + /// + /// Waits for GMB feed to be ready. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// Name of the GMB feed resource. + private static void WaitForGMBFeedToBeReady(GoogleAdsClient client, long customerId, + string gmbFeedResourceName) + { + int numAttempts = 0; + int sleepSeconds = 0; + + while (numAttempts < MAX_FEEDMAPPING_RETRIEVAL_ATTEMPTS) + { + // Once you create a feed, Google's servers will setup the feed by creating feed + // attributes and feedmapping. Once the feedmapping is created, it is ready to be + // used for creating customer feed. + // This process is asynchronous, so we wait until the feed mapping is created, + // peforming exponential backoff. + FeedMapping feedMapping = GetGMBFeedMapping(client, + customerId, gmbFeedResourceName); + + if (feedMapping == null) + { + numAttempts++; + sleepSeconds = (int) (5 * Math.Pow(2, numAttempts)); + Console.WriteLine($"Checked: #{numAttempts} time(s). GMB feed is not ready " + + $"yet. Waiting {sleepSeconds} seconds before trying again."); + Thread.Sleep(sleepSeconds * 1000); + } + else + { + Console.WriteLine($"GMB Feed {gmbFeedResourceName} is now ready."); + return; + } + } + throw new RpcException(new Status(StatusCode.DeadlineExceeded, + $"GMB Feed is not ready after {MAX_FEEDMAPPING_RETRIEVAL_ATTEMPTS}" + + $" retries.")); + } + + /// + /// Creates the customer feed. + /// + /// The client. + /// The customer identifier. + /// Name of the GMB feed resource. + private static void CreateCustomerFeed(GoogleAdsClient client, long customerId, + string gmbFeedResourceName) + { + // Get the CustomerFeedService. + CustomerFeedServiceClient customerFeedService = client.GetService( + Services.V3.CustomerFeedService); + + // Adds a CustomerFeed that associates the feed with this customer for + // the LOCATION placeholder type. + CustomerFeed customerFeed = new CustomerFeed() + { + Feed = gmbFeedResourceName, + PlaceholderTypes = { PlaceholderType.Location }, + MatchingFunction = new MatchingFunction() + { + LeftOperands = + { + new Operand() + { + ConstantOperand = new ConstantOperand() + { + BooleanValue = true + } + } + }, + // Specify the function string as IDENTITY(true) to mark this feed as enabled. + FunctionString = "IDENTITY(true)", + Operator = MatchingFunctionOperator.Identity + }, + }; + + CustomerFeedOperation operation = new CustomerFeedOperation() + { + Create = customerFeed + }; + + MutateCustomerFeedsResponse customerFeedsResponse = + customerFeedService.MutateCustomerFeeds( + customerId.ToString(), new[] { operation }); + + // Displays the result. + string addedCustomerFeed = customerFeedsResponse.Results[0].ResourceName; + Console.WriteLine($"Customer feed created with resource name: {addedCustomerFeed}."); + return; + } + } +} diff --git a/examples/Extensions/AddPrices.cs b/examples/Extensions/AddPrices.cs new file mode 100644 index 000000000..344b93860 --- /dev/null +++ b/examples/Extensions/AddPrices.cs @@ -0,0 +1,270 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Enums; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; + +using System; + +using static Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MinuteOfHourEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceQualifierEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceUnitEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PriceExtensionTypeEnum.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 +{ + /// + /// This code example adds a price extension and associates it with an account. Campaign + /// targeting is also set using the specified campaign ID. To get campaigns, run + /// GetCampaigns.cs. + /// + public class AddPrices : ExampleBase + { + /// + /// Main method, to run this code example as a standalone application. + /// + /// The command line arguments. + public static void Main(string[] args) + { + AddPrices codeExample = new AddPrices(); + Console.WriteLine(codeExample.Description); + + // The customer ID for which the call is made. + int customerId = int.Parse("INSERT_CUSTOMER_ID_HERE"); + + // ID of the campaign to which price extensions are added. + long campaignId = long.Parse("INSERT_CAMPAIGN_ID_HERE"); + + codeExample.Run(new GoogleAdsClient(), customerId, campaignId); + } + + /// + /// Returns a description about the code example. + /// + public override string Description + { + get + { + return "This code example adds a price extension and associates it with an " + + "account. Campaign targeting is also set using the specified campaign ID. " + + "To get campaigns, run GetCampaigns.cs."; + } + } + + /// + /// Runs the code example. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// ID of the campaign to targeting are added. + public void Run(GoogleAdsClient client, long customerId, long campaignId) + { + // Get the CustomerExtensionSettingServiceClient. + CustomerExtensionSettingServiceClient customerExtensionSettingService = + client.GetService(Services.V3.CustomerExtensionSettingService); + + try + { + // Creates an extension feed item as price. + string extensionFeedItemResourceName = + CreateExtensionFeedItem(client, customerId, campaignId); + + // Creates a customer extension setting using the previously created extension + // feed item. This associates the price extension to your account. + CustomerExtensionSetting customerExtensionSetting = + new CustomerExtensionSetting() + { + ExtensionType = ExtensionType.Price, + ExtensionFeedItems = { extensionFeedItemResourceName } + }; + + // Creates an operation to add the extension setting. + CustomerExtensionSettingOperation operation = + new CustomerExtensionSettingOperation() + { + Create = customerExtensionSetting + }; + + // Issues a mutate request to add the customer extension setting + // and prints its information. + MutateCustomerExtensionSettingsResponse response = + customerExtensionSettingService.MutateCustomerExtensionSettings( + customerId.ToString(), new[] { operation }); + + foreach (MutateCustomerExtensionSettingResult result in response.Results) + { + Console.WriteLine("Created customer extension setting with resource name: " + + result.ResourceName); + } + } + catch (GoogleAdsException e) + { + Console.WriteLine("Failure:"); + Console.WriteLine($"Message: {e.Message}"); + Console.WriteLine($"Failure: {e.Failure}"); + Console.WriteLine($"Request ID: {e.RequestId}"); + } + } + + /// + /// Creates an extension feed item for price extension. + /// + /// The Google Ads client. + /// The customer ID for which the call is made. + /// ID of the campaign to target. + /// the resource name of the newly created extension feed item. + private string CreateExtensionFeedItem(GoogleAdsClient client, long customerId, + long campaignId) + { + // Get the ExtensionFeedItemServiceClient. + ExtensionFeedItemServiceClient extensionFeedItemService = + client.GetService(Services.V3.ExtensionFeedItemService); + + // Creates the price extension feed item. + PriceFeedItem priceFeedItem = new PriceFeedItem() + { + Type = PriceExtensionType.Services, + // Optional: sets a qualifier text to show with the price extension. + PriceQualifier = PriceExtensionPriceQualifier.From, + TrackingUrlTemplate = "http://tracker.example.com/?u={lpurl}", + LanguageCode = "en", + // To create a price extension, at least three price offerings are needed. + PriceOfferings = + { + CreatePriceOffer( + "Scrubs", + "Body Scrub, Salt Scrub", + 60000000, // 60 USD + "USD", + PriceExtensionPriceUnit.PerHour, + "http://www.example.com/scrubs", + "http://m.example.com/scrubs"), + CreatePriceOffer( + "Hair Cuts", + "Once a month", + 75000000, // 75 USD + "USD", + PriceExtensionPriceUnit.PerMonth, + "http://www.example.com/haircuts", + "http://m.example.com/haircuts"), + CreatePriceOffer( + "Skin Care Package", + "Four times a month", + 250000000, // 250 USD + "USD", + PriceExtensionPriceUnit.PerMonth, + "http://www.example.com/skincarepackage", + null) + } + }; + + // Creates an extension feed item from the price feed item. + ExtensionFeedItem extensionFeedItem = new ExtensionFeedItem() + { + ExtensionType = ExtensionType.Price, + PriceFeedItem = priceFeedItem, + TargetedCampaign = ResourceNames.Campaign(customerId, campaignId), + AdSchedules = + { + CreateAdScheduleInfo(DayOfWeekEnum.Types.DayOfWeek.Sunday, 10, + MinuteOfHour.Zero, 18, MinuteOfHour.Zero), + CreateAdScheduleInfo(DayOfWeekEnum.Types.DayOfWeek.Saturday, 10, + MinuteOfHour.Zero, 22, MinuteOfHour.Zero) + } + }; + + // Creates an operation to add the feed item. + ExtensionFeedItemOperation operation = new ExtensionFeedItemOperation() + { + Create = extensionFeedItem + }; + + // Issues a mutate request to add the extension feed item and prints its information. + MutateExtensionFeedItemsResponse response = + extensionFeedItemService.MutateExtensionFeedItems(customerId.ToString(), + new[] { operation }); + string resourceName = response.Results[0].ResourceName; + Console.WriteLine($"Created extension feed item with resource name: {resourceName}."); + return resourceName; + } + + /// + /// Creates a new price offer with the specified parameters. + /// + /// The headline for the price extension. + /// The detailed description line that may show on the price + /// extension. + /// The price to display, measured in micros + /// (e.g. 1_000_000 micros = 1 USD). + /// The currency code representing the unit of currency. + /// Optionally set a unit describing the quantity obtained for the + /// price. + /// The final URL to which a click on the price extension drives + /// traffic. + /// The final URL to which mobile clicks on the price + /// extension drives traffic. + /// + private PriceOffer CreatePriceOffer(string header, string description, int priceInMicros, + string currencyCode, PriceExtensionPriceUnit unit, string finalUrl, + string finalMobileUrl) + { + PriceOffer priceOffer = new PriceOffer() + { + Header = header, + Description = description, + FinalUrls = { finalUrl }, + Price = new Money() + { + AmountMicros = priceInMicros, + CurrencyCode = currencyCode + }, + Unit = unit + }; + + // Optional: Sets the final mobile URLs. + if (!string.IsNullOrEmpty(finalMobileUrl)) + { + priceOffer.FinalMobileUrls.Add(finalMobileUrl); + } + return priceOffer; + } + + /// + /// Creates a new AdScheduleInfo with the specified attributes. + /// + /// Day of the week of the AdScheduleInfo. + /// The starting hour of the AdScheduleInfo. + /// The starting minute of the AdScheduleInfo. + /// The ending hour of the AdScheduleInfo. + /// The ending minute of the AdScheduleInfo. + /// The ad schedule info. + private static AdScheduleInfo CreateAdScheduleInfo(DayOfWeekEnum.Types.DayOfWeek day, + int startHour, MinuteOfHour startMinute, int endHour, MinuteOfHour endMinute) + { + return new AdScheduleInfo() + { + DayOfWeek = day, + StartHour = startHour, + StartMinute = startMinute, + EndHour = endHour, + EndMinute = endMinute + }; + } + } +} diff --git a/examples/Extensions/AddSitelinks.cs b/examples/Extensions/AddSitelinks.cs index fc8fb962a..202ddc208 100644 --- a/examples/Extensions/AddSitelinks.cs +++ b/examples/Extensions/AddSitelinks.cs @@ -14,21 +14,21 @@ using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Enums; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Enums; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -using static Google.Ads.GoogleAds.V2.Enums.ExtensionTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.FeedItemTargetDeviceEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.KeywordMatchTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.MinuteOfHourEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MinuteOfHourEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds sitelinks to a campaign. To create a campaign, run AddCampaigns.cs. @@ -75,7 +75,7 @@ public void Run(GoogleAdsClient client, long customerId, long campaignId) { // Get the CampaignExtensionSettingServiceClient. CampaignExtensionSettingServiceClient campaignExtensionSettingService = - client.GetService(Services.V2.CampaignExtensionSettingService); + client.GetService(Services.V3.CampaignExtensionSettingService); string campaignResourceName = ResourceNames.Campaign(customerId, campaignId); @@ -127,7 +127,7 @@ private static List CreateExtensionFeedItems(GoogleAdsClient client, { // Get the ExtensionFeedItemServiceClient. ExtensionFeedItemServiceClient extensionFeedItemService = - client.GetService(Services.V2.ExtensionFeedItemService); + client.GetService(Services.V3.ExtensionFeedItemService); SitelinkFeedItem sitelinkFeedItem1 = CreateSitelinkFeedItem( "Store Hours", "http://www.example.com/storehours"); diff --git a/examples/Extensions/UpdateFeedItemAttributeValue.cs b/examples/Extensions/UpdateFeedItemAttributeValue.cs index 4f4346d6f..b171377b1 100644 --- a/examples/Extensions/UpdateFeedItemAttributeValue.cs +++ b/examples/Extensions/UpdateFeedItemAttributeValue.cs @@ -14,16 +14,16 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.FlightPlaceholderFieldEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example updates a FeedItemAttributeValue in a flights feed. To create a flights @@ -120,7 +120,7 @@ private void UpdateFeedItem(GoogleAdsClient client, long customerId, long feedId { // Get the FeedItemServiceClient. FeedItemServiceClient feedItemService = - client.GetService(Services.V2.FeedItemService); + client.GetService(Services.V3.FeedItemService); // Gets the feed resource name. string feedResourceName = ResourceNames.Feed(customerId, feedId); @@ -190,7 +190,7 @@ public Dictionary GetFeed( { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Constructs the query. string query = $"SELECT feed.attributes FROM feed WHERE feed.resource_name = " + @@ -238,7 +238,7 @@ public Dictionary GetFeed( feedAttributes[FlightPlaceholderField.FinalUrls] = feedAttribute; break; // The full list of FlightPlaceholderFields can be found here - // https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v2.enums#flightplaceholderfieldenum. + // https://developers.google.com/google-ads/api/reference/rpc/Google.Ads.GoogleAds.V3.enums#flightplaceholderfieldenum. default: throw new Exception("Invalid attribute name."); } @@ -259,7 +259,7 @@ private FeedItem GetFeedItem(GoogleAdsClient client, long customerId, { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Constructs the query. string query = "SELECT feed_item.attribute_values FROM feed_item WHERE " + diff --git a/examples/HotelAds/AddHotelAd.cs b/examples/HotelAds/AddHotelAd.cs index 58650c749..0e8c17df8 100644 --- a/examples/HotelAds/AddHotelAd.cs +++ b/examples/HotelAds/AddHotelAd.cs @@ -13,21 +13,21 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Resources.Campaign.Types; - -namespace Google.Ads.GoogleAds.Examples.V2 +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example creates a hotel campaign, a hotel ad group and hotel ad group ad. @@ -134,7 +134,7 @@ private static string AddCampaignBudget(GoogleAdsClient client, long customerId) { // Get the CampaignBudgetService. CampaignBudgetServiceClient service = client.GetService( - Services.V2.CampaignBudgetService); + Services.V3.CampaignBudgetService); // Create a campaign budget. CampaignBudget budget = new CampaignBudget() @@ -173,7 +173,7 @@ private static string AddHotelCampaign(GoogleAdsClient client, long customerId, string budgetResourceName, long hotelCenterAccountId, long cpcBidCeilingMicroAmount) { // Get the CampaignService. - CampaignServiceClient service = client.GetService(Services.V2.CampaignService); + CampaignServiceClient service = client.GetService(Services.V3.CampaignService); // Create a campaign. Campaign campaign = new Campaign() @@ -236,7 +236,7 @@ private static string AddHotelAdGroup(GoogleAdsClient client, long customerId, string campaignResourceName) { // Get the AdGroupService. - AdGroupServiceClient service = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient service = client.GetService(Services.V3.AdGroupService); // Create an ad group. AdGroup adGroup = new AdGroup() @@ -277,7 +277,7 @@ private static void AddHotelAdGroupAd(GoogleAdsClient client, long customerId, string adGroupResourceName) { // Get the AdGroupAdService. - AdGroupAdServiceClient service = client.GetService(Services.V2.AdGroupAdService); + AdGroupAdServiceClient service = client.GetService(Services.V3.AdGroupAdService); // Create a new ad group ad and sets the hotel ad to it. AdGroupAd adGroupAd = new AdGroupAd() diff --git a/examples/HotelAds/AddHotelAdGroupBidModifiers.cs b/examples/HotelAds/AddHotelAdGroupBidModifiers.cs index 186b4ab36..7337d8cb0 100644 --- a/examples/HotelAds/AddHotelAdGroupBidModifiers.cs +++ b/examples/HotelAds/AddHotelAdGroupBidModifiers.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using DayOfWeek = Google.Ads.GoogleAds.V2.Enums.DayOfWeekEnum.Types.DayOfWeek; +using DayOfWeek = Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Types.DayOfWeek; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example shows how to add ad group bid modifiers to a hotel ad group based on @@ -68,7 +68,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId) { // Get the AdGroupBidModifierService. AdGroupBidModifierServiceClient service = client.GetService( - Services.V2.AdGroupBidModifierService); + Services.V3.AdGroupBidModifierService); // Constructs the ad group resource name to use for each bid modifier. string adGroupResourceName = ResourceNames.AdGroup(customerId, adGroupId); diff --git a/examples/Migration/CampaignManagement/CreateCompleteCampaignAdWordsApiOnly.cs b/examples/Migration/CampaignManagement/CreateCompleteCampaignAdWordsApiOnly.cs index 1174ce232..002d13331 100644 --- a/examples/Migration/CampaignManagement/CreateCompleteCampaignAdWordsApiOnly.cs +++ b/examples/Migration/CampaignManagement/CreateCompleteCampaignAdWordsApiOnly.cs @@ -19,7 +19,7 @@ using aw = global::Google.Api.Ads.AdWords.v201809; -namespace Google.Ads.GoogleAds.Examples.V2.Migration.CampaignManagement +namespace Google.Ads.GoogleAds.Examples.V3.Migration.CampaignManagement { /// /// This code example is the first in a series of code examples that shows how to create diff --git a/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase1.cs b/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase1.cs index c15bf96a2..3a5e93162 100644 --- a/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase1.cs +++ b/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase1.cs @@ -21,11 +21,11 @@ using System.Web; using aw = global::Google.Api.Ads.AdWords.v201809; -using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; -using gagvr = Google.Ads.GoogleAds.V2.Resources; -using gagvs = Google.Ads.GoogleAds.V2.Services; +using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gagvs = Google.Ads.GoogleAds.V3.Services; -namespace Google.Ads.GoogleAds.Examples.V2.Migration.CampaignManagement +namespace Google.Ads.GoogleAds.Examples.V3.Migration.CampaignManagement { /// /// This code example is the second in a series of code examples that shows how to create @@ -101,7 +101,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the CampaignBudgetService. gagvs::CampaignBudgetServiceClient budgetService = client.GetService( - Services.V2.CampaignBudgetService); + Services.V3.CampaignBudgetService); // Create the campaign budget. gagvr::CampaignBudget budget = new gagvr::CampaignBudget() @@ -146,7 +146,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign_budget.id, campaign_budget.name, " + diff --git a/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase2.cs b/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase2.cs index dbee03c8b..b5dbc3825 100644 --- a/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase2.cs +++ b/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase2.cs @@ -21,17 +21,17 @@ using System.Web; using aw = global::Google.Api.Ads.AdWords.v201809; -using gag__AdvertisingChannelType = Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType; -using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; -using gag__CampaignStatus = Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types.CampaignStatus; -using gag__NetworkSettings = Google.Ads.GoogleAds.V2.Resources.Campaign.Types.NetworkSettings; +using gag__AdvertisingChannelType = Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType; +using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; +using gag__CampaignStatus = Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types.CampaignStatus; +using gag__NetworkSettings = Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings; -using gagvc = Google.Ads.GoogleAds.V2.Common; -using gagver = Google.Ads.GoogleAds.V2.Errors; -using gagvr = Google.Ads.GoogleAds.V2.Resources; -using gagvs = Google.Ads.GoogleAds.V2.Services; +using gagvc = Google.Ads.GoogleAds.V3.Common; +using gagver = Google.Ads.GoogleAds.V3.Errors; +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gagvs = Google.Ads.GoogleAds.V3.Services; -namespace Google.Ads.GoogleAds.Examples.V2.Migration.CampaignManagement +namespace Google.Ads.GoogleAds.Examples.V3.Migration.CampaignManagement { /// /// This code example is the third in a series of code examples that shows how to create @@ -106,7 +106,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the CampaignBudgetService. gagvs::CampaignBudgetServiceClient budgetService = client.GetService( - Services.V2.CampaignBudgetService); + Services.V3.CampaignBudgetService); // Create the campaign budget. gagvr::CampaignBudget budget = new gagvr::CampaignBudget() @@ -151,7 +151,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign_budget.id, campaign_budget.name, " + @@ -178,7 +178,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the CampaignService. gagvs::CampaignServiceClient campaignService = client.GetService( - Services.V2.CampaignService); + Services.V3.CampaignService); // Create a budget to be used for the campaign. string budgetResource = gagver::ResourceNames.CampaignBudget(customerId, budgetId); @@ -244,7 +244,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign.id, campaign.name, " + diff --git a/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase3.cs b/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase3.cs index 945fc68f4..bde2755d7 100644 --- a/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase3.cs +++ b/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase3.cs @@ -21,19 +21,19 @@ using System.Web; using aw = global::Google.Api.Ads.AdWords.v201809; -using gag__AdGroupAdRotationMode = Google.Ads.GoogleAds.V2.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode; -using gag__AdGroupStatus = Google.Ads.GoogleAds.V2.Enums.AdGroupStatusEnum.Types.AdGroupStatus; -using gag__AdvertisingChannelType = Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType; -using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; -using gag__CampaignStatus = Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types.CampaignStatus; -using gag__NetworkSettings = Google.Ads.GoogleAds.V2.Resources.Campaign.Types.NetworkSettings; - -using gagvc = Google.Ads.GoogleAds.V2.Common; -using gagver = Google.Ads.GoogleAds.V2.Errors; -using gagvr = Google.Ads.GoogleAds.V2.Resources; -using gagvs = Google.Ads.GoogleAds.V2.Services; - -namespace Google.Ads.GoogleAds.Examples.V2.Migration.CampaignManagement +using gag__AdGroupAdRotationMode = Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode; +using gag__AdGroupStatus = Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types.AdGroupStatus; +using gag__AdvertisingChannelType = Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType; +using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; +using gag__CampaignStatus = Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types.CampaignStatus; +using gag__NetworkSettings = Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings; + +using gagvc = Google.Ads.GoogleAds.V3.Common; +using gagver = Google.Ads.GoogleAds.V3.Errors; +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gagvs = Google.Ads.GoogleAds.V3.Services; + +namespace Google.Ads.GoogleAds.Examples.V3.Migration.CampaignManagement { /// /// This code example is the fourth in a series of code examples that shows how to create @@ -108,7 +108,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the CampaignBudgetService. gagvs::CampaignBudgetServiceClient budgetService = client.GetService( - Services.V2.CampaignBudgetService); + Services.V3.CampaignBudgetService); // Create the campaign budget. gagvr::CampaignBudget budget = new gagvr::CampaignBudget() @@ -153,7 +153,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign_budget.id, campaign_budget.name, " + @@ -180,7 +180,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the CampaignService. gagvs::CampaignServiceClient campaignService = client.GetService( - Services.V2.CampaignService); + Services.V3.CampaignService); // Create a budget to be used for the campaign. string budgetResource = gagver::ResourceNames.CampaignBudget(customerId, budgetId); @@ -246,7 +246,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign.id, campaign.name, " + @@ -273,7 +273,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the AdGroupService. gagvs::AdGroupServiceClient adGroupService = client.GetService( - Services.V2.AdGroupService); + Services.V3.AdGroupService); // Create the ad group. gagvr::AdGroup adGroup = new gagvr::AdGroup() @@ -323,7 +323,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT ad_group.id, ad_group.name, " + diff --git a/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase4.cs b/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase4.cs index b796e1c87..73eeb05fe 100644 --- a/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase4.cs +++ b/examples/Migration/CampaignManagement/CreateCompleteCampaignBothApisPhase4.cs @@ -21,20 +21,20 @@ using System.Web; using aw = global::Google.Api.Ads.AdWords.v201809; -using gag__AdGroupAdRotationMode = Google.Ads.GoogleAds.V2.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode; -using gag__AdGroupAdStatus = Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types.AdGroupAdStatus; -using gag__AdGroupStatus = Google.Ads.GoogleAds.V2.Enums.AdGroupStatusEnum.Types.AdGroupStatus; -using gag__AdvertisingChannelType = Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType; -using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; -using gag__CampaignStatus = Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types.CampaignStatus; -using gag__NetworkSettings = Google.Ads.GoogleAds.V2.Resources.Campaign.Types.NetworkSettings; - -using gagvc = Google.Ads.GoogleAds.V2.Common; -using gagver = Google.Ads.GoogleAds.V2.Errors; -using gagvr = Google.Ads.GoogleAds.V2.Resources; -using gagvs = Google.Ads.GoogleAds.V2.Services; - -namespace Google.Ads.GoogleAds.Examples.V2.Migration.CampaignManagement +using gag__AdGroupAdRotationMode = Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode; +using gag__AdGroupAdStatus = Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types.AdGroupAdStatus; +using gag__AdGroupStatus = Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types.AdGroupStatus; +using gag__AdvertisingChannelType = Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType; +using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; +using gag__CampaignStatus = Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types.CampaignStatus; +using gag__NetworkSettings = Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings; + +using gagvc = Google.Ads.GoogleAds.V3.Common; +using gagver = Google.Ads.GoogleAds.V3.Errors; +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gagvs = Google.Ads.GoogleAds.V3.Services; + +namespace Google.Ads.GoogleAds.Examples.V3.Migration.CampaignManagement { /// /// This code example is the fifth in a series of code examples that shows how to create @@ -109,7 +109,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the CampaignBudgetService. gagvs::CampaignBudgetServiceClient budgetService = client.GetService( - Services.V2.CampaignBudgetService); + Services.V3.CampaignBudgetService); // Create the campaign budget. gagvr::CampaignBudget budget = new gagvr::CampaignBudget() @@ -154,7 +154,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign_budget.id, campaign_budget.name, " + @@ -181,7 +181,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the CampaignService. gagvs::CampaignServiceClient campaignService = client.GetService( - Services.V2.CampaignService); + Services.V3.CampaignService); // Create a budget to be used for the campaign. string budgetResource = gagver::ResourceNames.CampaignBudget(customerId, budgetId); @@ -247,7 +247,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign.id, campaign.name, " + @@ -274,7 +274,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the AdGroupService. gagvs::AdGroupServiceClient adGroupService = client.GetService( - Services.V2.AdGroupService); + Services.V3.AdGroupService); // Create the ad group. gagvr::AdGroup adGroup = new gagvr::AdGroup() @@ -324,7 +324,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT ad_group.id, ad_group.name, " + @@ -351,7 +351,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the AdGroupAdService. gagvs::AdGroupAdServiceClient adGroupAdService = client.GetService( - Services.V2.AdGroupAdService); + Services.V3.AdGroupAdService); List operations = new List(); for (int i = 0; i < NUMBER_OF_ADS; i++) @@ -419,7 +419,7 @@ public void Run(AdWordsUser user, GoogleAdsClient client) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = diff --git a/examples/Migration/CampaignManagement/CreateCompleteCampaignGoogleAdsApiOnly.cs b/examples/Migration/CampaignManagement/CreateCompleteCampaignGoogleAdsApiOnly.cs index 9490c864a..babcace2a 100644 --- a/examples/Migration/CampaignManagement/CreateCompleteCampaignGoogleAdsApiOnly.cs +++ b/examples/Migration/CampaignManagement/CreateCompleteCampaignGoogleAdsApiOnly.cs @@ -18,22 +18,22 @@ using System.Collections.Generic; using System.Linq; -using gag__AdGroupAdRotationMode = Google.Ads.GoogleAds.V2.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode; -using gag__AdGroupAdStatus = Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types.AdGroupAdStatus; -using gag__AdGroupCriterionStatus = Google.Ads.GoogleAds.V2.Enums.AdGroupCriterionStatusEnum.Types.AdGroupCriterionStatus; -using gag__AdGroupStatus = Google.Ads.GoogleAds.V2.Enums.AdGroupStatusEnum.Types.AdGroupStatus; -using gag__AdvertisingChannelType = Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType; -using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; -using gag__CampaignStatus = Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types.CampaignStatus; -using gag__KeywordMatchType = Google.Ads.GoogleAds.V2.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType; -using gag__NetworkSettings = Google.Ads.GoogleAds.V2.Resources.Campaign.Types.NetworkSettings; - -using gagvc = Google.Ads.GoogleAds.V2.Common; -using gagver = Google.Ads.GoogleAds.V2.Errors; -using gagvr = Google.Ads.GoogleAds.V2.Resources; -using gagvs = Google.Ads.GoogleAds.V2.Services; - -namespace Google.Ads.GoogleAds.Examples.V2.Migration.CampaignManagement +using gag__AdGroupAdRotationMode = Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode; +using gag__AdGroupAdStatus = Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types.AdGroupAdStatus; +using gag__AdGroupCriterionStatus = Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types.AdGroupCriterionStatus; +using gag__AdGroupStatus = Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types.AdGroupStatus; +using gag__AdvertisingChannelType = Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType; +using gag__BudgetDeliveryMethod = Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod; +using gag__CampaignStatus = Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types.CampaignStatus; +using gag__KeywordMatchType = Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType; +using gag__NetworkSettings = Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings; + +using gagvc = Google.Ads.GoogleAds.V3.Common; +using gagver = Google.Ads.GoogleAds.V3.Errors; +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gagvs = Google.Ads.GoogleAds.V3.Services; + +namespace Google.Ads.GoogleAds.Examples.V3.Migration.CampaignManagement { /// /// This code example is the last in a series of code examples that shows how to create @@ -103,7 +103,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the CampaignBudgetService. gagvs::CampaignBudgetServiceClient budgetService = client.GetService( - Services.V2.CampaignBudgetService); + Services.V3.CampaignBudgetService); // Create the campaign budget. gagvr::CampaignBudget budget = new gagvr::CampaignBudget() @@ -148,7 +148,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign_budget.id, campaign_budget.name, " + @@ -175,7 +175,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the CampaignService. gagvs::CampaignServiceClient campaignService = client.GetService( - Services.V2.CampaignService); + Services.V3.CampaignService); // Create a budget to be used for the campaign. string budgetResource = gagver::ResourceNames.CampaignBudget(customerId, budgetId); @@ -241,7 +241,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT campaign.id, campaign.name, " + @@ -268,7 +268,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the AdGroupService. gagvs::AdGroupServiceClient adGroupService = client.GetService( - Services.V2.AdGroupService); + Services.V3.AdGroupService); // Create the ad group. gagvr::AdGroup adGroup = new gagvr::AdGroup() @@ -318,7 +318,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = "SELECT ad_group.id, ad_group.name, " + @@ -345,7 +345,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the AdGroupAdService. gagvs::AdGroupAdServiceClient adGroupAdService = client.GetService( - Services.V2.AdGroupAdService); + Services.V3.AdGroupAdService); List operations = new List(); for (int i = 0; i < NUMBER_OF_ADS; i++) @@ -413,7 +413,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the search query. string searchQuery = @@ -452,7 +452,7 @@ ad_group_ad.resource_name IN (" + { // Get the AdGroupCriterionService. gagvs::AdGroupCriterionServiceClient adGroupCriterionService = - client.GetService(Services.V2.AdGroupCriterionService); + client.GetService(Services.V3.AdGroupCriterionService); List operations = new List(); @@ -517,7 +517,7 @@ ad_group_ad.resource_name IN (" + { // Get the GoogleAdsService. gagvs::GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); string searchQuery = $@"SELECT diff --git a/examples/Misc/GetAllImageAssets.cs b/examples/Misc/GetAllImageAssets.cs index 66cdd6d16..5ffc416e8 100644 --- a/examples/Misc/GetAllImageAssets.cs +++ b/examples/Misc/GetAllImageAssets.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets all image assets. @@ -62,7 +62,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsServiceClient. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); // Creates the search query. string searchQuery = "SELECT asset.name, asset.image_asset.file_size, " + diff --git a/examples/Misc/GetAllVideosAndImages.cs b/examples/Misc/GetAllVideosAndImages.cs index 7e20ec742..5540a127b 100644 --- a/examples/Misc/GetAllVideosAndImages.cs +++ b/examples/Misc/GetAllVideosAndImages.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets all video and image files. @@ -61,7 +61,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsServiceClient. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); // Creates a request that will retrieve all video and image files. SearchGoogleAdsRequest request = new SearchGoogleAdsRequest() diff --git a/examples/Misc/UploadImage.cs b/examples/Misc/UploadImage.cs index b7ea8f838..92ac4fa83 100644 --- a/examples/Misc/UploadImage.cs +++ b/examples/Misc/UploadImage.cs @@ -14,14 +14,14 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Protobuf; using System; -using static Google.Ads.GoogleAds.V2.Enums.MediaTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MediaTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example uploads an image. @@ -63,7 +63,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the MediaFileServiceClient. MediaFileServiceClient mediaFileService = - client.GetService(Services.V2.MediaFileService); + client.GetService(Services.V3.MediaFileService); const string URL = "https://goo.gl/3b9Wfh"; diff --git a/examples/Misc/UploadImageAsset.cs b/examples/Misc/UploadImageAsset.cs index 824dcb486..0aad2302f 100644 --- a/examples/Misc/UploadImageAsset.cs +++ b/examples/Misc/UploadImageAsset.cs @@ -14,17 +14,17 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Protobuf; using System; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.AssetTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.MimeTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AssetTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example uploads an image asset. To get image assets, run GetAllImageAssets.cs. @@ -72,7 +72,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the AssetServiceClient. AssetServiceClient assetService = - client.GetService(Services.V2.AssetService); + client.GetService(Services.V3.AssetService); // Creates an image content. byte[] imageContent = MediaUtilities.GetAssetDataFromUrl(IMAGE_URL, client.Config); diff --git a/examples/Misc/UploadMediaBundle.cs b/examples/Misc/UploadMediaBundle.cs index c8843165c..6614f1aec 100644 --- a/examples/Misc/UploadMediaBundle.cs +++ b/examples/Misc/UploadMediaBundle.cs @@ -14,15 +14,15 @@ using Google.Ads.GoogleAds.Lib; using Google.Ads.GoogleAds.Util; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Protobuf; using System; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.MediaTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.MediaTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example uploads an HTML5 zip file as a media bundle. @@ -68,7 +68,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId) { // Get the MediaFileServiceClient. - MediaFileServiceClient mediaFileService = client.GetService(Services.V2.MediaFileService); + MediaFileServiceClient mediaFileService = client.GetService(Services.V3.MediaFileService); // Creates an HTML5 zip file media bundle content. byte[] bundleContent = MediaUtilities.GetAssetDataFromUrl(BUNDLE_URL, client.Config); diff --git a/examples/Planning/AddKeywordPlan.cs b/examples/Planning/AddKeywordPlan.cs index feb8edcb3..a157b1113 100644 --- a/examples/Planning/AddKeywordPlan.cs +++ b/examples/Planning/AddKeywordPlan.cs @@ -13,17 +13,17 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -using static Google.Ads.GoogleAds.V2.Enums.KeywordMatchTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.KeywordPlanForecastIntervalEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.KeywordPlanNetworkEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordPlanForecastIntervalEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example creates a keyword plan, which can be reused for retrieving forecast @@ -94,7 +94,7 @@ private string CreateKeywordPlan(GoogleAdsClient client, long customerId) { // Get the KeywordPlanService. KeywordPlanServiceClient serviceClient = client.GetService( - Services.V2.KeywordPlanService); + Services.V3.KeywordPlanService); // Create a keyword plan for next quarter forecast. KeywordPlan keywordPlan = new KeywordPlan() @@ -133,7 +133,7 @@ private string CreateKeywordPlanCampaign(GoogleAdsClient client, long customerId { // Get the KeywordPlanCampaignService. KeywordPlanCampaignServiceClient serviceClient = client.GetService( - Services.V2.KeywordPlanCampaignService); + Services.V3.KeywordPlanCampaignService); // Create a keyword plan campaign. KeywordPlanCampaign campaign = new KeywordPlanCampaign() @@ -184,7 +184,7 @@ private string CreateKeywordPlanAdGroup(GoogleAdsClient client, long customerId, { // Get the KeywordPlanAdGroupService. KeywordPlanAdGroupServiceClient serviceClient = client.GetService( - Services.V2.KeywordPlanAdGroupService); + Services.V3.KeywordPlanAdGroupService); // Create the keyword plan ad group. KeywordPlanAdGroup adGroup = new KeywordPlanAdGroup() @@ -222,7 +222,7 @@ private static void CreateKeywordPlanKeywords(GoogleAdsClient client, long custo { // Get the KeywordPlanKeywordService. KeywordPlanKeywordServiceClient serviceClient = client.GetService( - Services.V2.KeywordPlanKeywordService); + Services.V3.KeywordPlanKeywordService); // Create the keywords for keyword plan. KeywordPlanKeyword keywordPlanKeyword1 = new KeywordPlanKeyword() @@ -293,7 +293,7 @@ private static void CreateKeywordPlanNegativeKeywords(GoogleAdsClient client, { // Get the KeywordPlanNegativeKeywordService. KeywordPlanNegativeKeywordServiceClient serviceClient = client.GetService( - Services.V2.KeywordPlanNegativeKeywordService); + Services.V3.KeywordPlanNegativeKeywordService); // Create the negative keyword for the keyword plan. KeywordPlanNegativeKeyword keywordPlanNegativeKeyword = new KeywordPlanNegativeKeyword() diff --git a/examples/Planning/ForecastReach.cs b/examples/Planning/ForecastReach.cs index cc3a84b99..ee2bc1d5f 100644 --- a/examples/Planning/ForecastReach.cs +++ b/examples/Planning/ForecastReach.cs @@ -13,18 +13,18 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -using static Google.Ads.GoogleAds.V2.Enums.DeviceEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.GenderTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ReachPlanAdLengthEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ReachPlanAgeRangeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.GenderTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ReachPlanAdLengthEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ReachPlanAgeRangeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This example demonstrates how to interact with the ReachPlanService to find plannable @@ -62,7 +62,7 @@ public override string Description /// /// Runs the code example, showing a typical series of calls to the - /// . + /// . /// /// The Google Ads API client. /// The Google Ads customer ID for which the call is made. @@ -72,7 +72,7 @@ public void Run(GoogleAdsClient client, long customerId) string currencyCode = "USD"; long budgetMicros = 500_000_000_000L; ReachPlanServiceClient reachPlanService = - client.GetService(Services.V2.ReachPlanService); + client.GetService(Services.V3.ReachPlanService); try { @@ -194,7 +194,7 @@ public GenerateReachForecastRequest BuildReachRequest( targeting.Devices.AddRange(devices); // See the docs for defaults and valid ranges: - // https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v2.services#google.ads.googleads.v2.services.GenerateReachForecastRequest + // https://developers.google.com/google-ads/api/reference/rpc/Google.Ads.GoogleAds.V3.services#Google.Ads.GoogleAds.V3.services.GenerateReachForecastRequest GenerateReachForecastRequest request = new GenerateReachForecastRequest() { CustomerId = customerId, @@ -266,7 +266,7 @@ public void ForecastManualMix( // See listPlannableProducts on ReachPlanService to retrieve a list // of valid PlannableProductCode's for a given location: - // https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v2.services#reachplanservice + // https://developers.google.com/google-ads/api/reference/rpc/Google.Ads.GoogleAds.V3.services#reachplanservice productMix.Add(new PlannedProduct() { PlannableProductCode = "TRUEVIEW_IN_STREAM", diff --git a/examples/Planning/GenerateForecastMetrics.cs b/examples/Planning/GenerateForecastMetrics.cs index d1ff47555..e316c0962 100644 --- a/examples/Planning/GenerateForecastMetrics.cs +++ b/examples/Planning/GenerateForecastMetrics.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example generates forecast metrics for a keyword plan. To create a keyword plan, @@ -65,7 +65,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId, long keywordPlanId) { KeywordPlanServiceClient kpServiceClient = - client.GetService(Services.V2.KeywordPlanService); + client.GetService(Services.V3.KeywordPlanService); string keywordPlanResource = ResourceNames.KeywordPlan(customerId, keywordPlanId); try diff --git a/examples/Planning/GenerateKeywordIdeas.cs b/examples/Planning/GenerateKeywordIdeas.cs index 9497ea9f4..4af852cb2 100644 --- a/examples/Planning/GenerateKeywordIdeas.cs +++ b/examples/Planning/GenerateKeywordIdeas.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.KeywordPlanNetworkEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example generates keyword ideas from a list of seed keywords or a seed page URL. @@ -86,7 +86,7 @@ public void Run(GoogleAdsClient client, long customerId, long[] locationIds, long languageId, string[] keywordTexts, string pageUrl) { KeywordPlanIdeaServiceClient keywordPlanIdeaService = - client.GetService(Services.V2.KeywordPlanIdeaService); + client.GetService(Services.V3.KeywordPlanIdeaService); // Make sure that keywords and/or page URL were specified. The request must have // exactly one of urlSeed, keywordSeed, or keywordAndUrlSeed set. diff --git a/examples/Recommendations/ApplyRecommendation.cs b/examples/Recommendations/ApplyRecommendation.cs index f9ff0b119..5dc714b87 100644 --- a/examples/Recommendations/ApplyRecommendation.cs +++ b/examples/Recommendations/ApplyRecommendation.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example applies a given recommendation. To retrieve recommendations for text ads, @@ -66,7 +66,7 @@ public void Run(GoogleAdsClient client, long customerId, long recommendationId) { // Get the RecommendationServiceClient. RecommendationServiceClient service = client.GetService( - Services.V2.RecommendationService); + Services.V3.RecommendationService); ApplyRecommendationOperation operation = new ApplyRecommendationOperation() { diff --git a/examples/Recommendations/DismissRecommendation.cs b/examples/Recommendations/DismissRecommendation.cs index 2f2b57f68..9c54daf6e 100644 --- a/examples/Recommendations/DismissRecommendation.cs +++ b/examples/Recommendations/DismissRecommendation.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Services.DismissRecommendationRequest.Types; -using static Google.Ads.GoogleAds.V2.Services.DismissRecommendationResponse.Types; +using static Google.Ads.GoogleAds.V3.Services.DismissRecommendationRequest.Types; +using static Google.Ads.GoogleAds.V3.Services.DismissRecommendationResponse.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example dismisses a given recommendation. To retrieve recommendations for text @@ -68,7 +68,7 @@ public void Run(GoogleAdsClient client, long customerId, long recommendationId) { // Get the RecommendationServiceClient. RecommendationServiceClient service = client.GetService( - Services.V2.RecommendationService); + Services.V3.RecommendationService); DismissRecommendationOperation operation = new DismissRecommendationOperation() { diff --git a/examples/Recommendations/GetTextAdRecommendations.cs b/examples/Recommendations/GetTextAdRecommendations.cs index 2def8d4ac..b533dbbec 100644 --- a/examples/Recommendations/GetTextAdRecommendations.cs +++ b/examples/Recommendations/GetTextAdRecommendations.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets all TEXT_AD recommendations. @@ -66,7 +66,7 @@ public override string Description public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsServiceClient . - GoogleAdsServiceClient service = client.GetService(Services.V2.GoogleAdsService); + GoogleAdsServiceClient service = client.GetService(Services.V3.GoogleAdsService); string query = @"SELECT diff --git a/examples/Remarketing/AddConversionAction.cs b/examples/Remarketing/AddConversionAction.cs index 9527b1fd3..c4ee76ae0 100644 --- a/examples/Remarketing/AddConversionAction.cs +++ b/examples/Remarketing/AddConversionAction.cs @@ -13,16 +13,16 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.ConversionActionCategoryEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ConversionActionStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ConversionActionTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates adding a conversion action. @@ -65,7 +65,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the ConversionActionService. ConversionActionServiceClient conversionActionService = - client.GetService(Services.V2.ConversionActionService); + client.GetService(Services.V3.ConversionActionService); // Add a conversion action. ConversionAction conversionAction = new ConversionAction() diff --git a/examples/Remarketing/AddFlightsFeed.cs b/examples/Remarketing/AddFlightsFeed.cs index fd0ee209d..203a26ff2 100644 --- a/examples/Remarketing/AddFlightsFeed.cs +++ b/examples/Remarketing/AddFlightsFeed.cs @@ -13,18 +13,18 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.FeedAttributeTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.FlightPlaceholderFieldEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.PlaceholderTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a flights feed, creates the associated feed mapping, and @@ -103,7 +103,7 @@ public void Run(GoogleAdsClient client, long customerId) private string CreateFeed(GoogleAdsClient client, long customerId) { // Get the FeedService. - FeedServiceClient feedService = client.GetService(Services.V2.FeedService); + FeedServiceClient feedService = client.GetService(Services.V3.FeedService); // Creates a Flight Description attribute. FeedAttribute flightDescriptionAttribute = new FeedAttribute() @@ -191,7 +191,7 @@ public Dictionary GetFeed( { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Constructs the query. string query = $"SELECT feed.attributes FROM feed WHERE feed.resource_name = " + @@ -238,7 +238,7 @@ public Dictionary GetFeed( feedAttributes[FlightPlaceholderField.FinalUrls] = feedAttribute; break; // The full list of FlightPlaceholderFields can be found here - // https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v2.enums#flightplaceholderfieldenum. + // https://developers.google.com/google-ads/api/reference/rpc/Google.Ads.GoogleAds.V3.enums#flightplaceholderfieldenum. default: throw new Exception("Invalid attribute name."); } @@ -260,7 +260,7 @@ private void CreateFeedMapping(GoogleAdsClient client, long customerId, { // Get the FeedMappingServiceClient. FeedMappingServiceClient feedMappingService = client.GetService( - Services.V2.FeedMappingService); + Services.V3.FeedMappingService); // Maps the FeedAttributeIds to the fieldId constants. AttributeFieldMapping flightDescriptionMapping = new AttributeFieldMapping() @@ -340,7 +340,7 @@ private void CreateFeedItem(GoogleAdsClient client, long customerId, { // Get the FeedItemServiceClient. FeedItemServiceClient feedItemService = client.GetService( - Services.V2.FeedItemService); + Services.V3.FeedItemService); // Creates the flight description feed attribute value. FeedItemAttributeValue flightDescription = new FeedItemAttributeValue() diff --git a/examples/Remarketing/AddRealEstateFeed.cs b/examples/Remarketing/AddRealEstateFeed.cs index b4a20c91e..1dcd5e909 100644 --- a/examples/Remarketing/AddRealEstateFeed.cs +++ b/examples/Remarketing/AddRealEstateFeed.cs @@ -13,18 +13,18 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.FeedAttributeTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.RealEstatePlaceholderFieldEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.PlaceholderTypeEnum.Types; -using Google.Ads.GoogleAds.V2.Errors; +using static Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.RealEstatePlaceholderFieldEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types; +using Google.Ads.GoogleAds.V3.Errors; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a real estate feed, creates the feed mapping, and adds items to @@ -103,7 +103,7 @@ public void Run(GoogleAdsClient client, long customerId) private string CreateFeed(GoogleAdsClient client, long customerId) { // Get the FeedService. - FeedServiceClient feedService = client.GetService(Services.V2.FeedService); + FeedServiceClient feedService = client.GetService(Services.V3.FeedService); // Creates a Listing ID attribute. FeedAttribute listingIdAttribute = new FeedAttribute() @@ -191,7 +191,7 @@ public Dictionary GetFeed( { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Constructs the query. string query = $"SELECT feed.attributes FROM feed WHERE feed.resource_name = " + @@ -239,7 +239,7 @@ public Dictionary GetFeed( feedAttributes[RealEstatePlaceholderField.ContextualKeywords] = feedAttribute; break; // The full list of RealEstatePlaceholderField can be found here - // https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v2.enums#RealEstatePlaceholderFieldenum. + // https://developers.google.com/google-ads/api/reference/rpc/Google.Ads.GoogleAds.V3.enums#RealEstatePlaceholderFieldenum. default: throw new Exception("Invalid attribute name."); } @@ -261,7 +261,7 @@ private void CreateFeedMapping(GoogleAdsClient client, long customerId, { // Get the FeedMappingServiceClient. FeedMappingServiceClient feedMappingService = client.GetService( - Services.V2.FeedMappingService); + Services.V3.FeedMappingService); // Maps the FeedAttributeIds to the placeholder values. The FeedAttributeId is the // ID of the FeedAttribute created in the CreatedFeed method. This can be thought of @@ -269,7 +269,7 @@ private void CreateFeedMapping(GoogleAdsClient client, long customerId, // the type of column this is in the context of a real estate feed (e.g. // a LISTING_ID or LISTING_NAME). The FeedMapping associates the feed column by ID to // this type and controls how the feed attributes are presented in dynamic content. - // See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v2.enums#google.ads.googleads.v2.enums.RealEstatePlaceholderFieldEnum.RealEstatePlaceholderField + // See https://developers.google.com/google-ads/api/reference/rpc/Google.Ads.GoogleAds.V3.enums#Google.Ads.GoogleAds.V3.enums.RealEstatePlaceholderFieldEnum.RealEstatePlaceholderField // for the full list of placeholder values. AttributeFieldMapping listingIdMapping = new AttributeFieldMapping() @@ -349,7 +349,7 @@ private void CreateFeedItem(GoogleAdsClient client, long customerId, { // Get the FeedItemServiceClient. FeedItemServiceClient feedItemService = client.GetService( - Services.V2.FeedItemService); + Services.V3.FeedItemService); // Creates the listing ID feed attribute value. FeedItemAttributeValue listingId = new FeedItemAttributeValue() diff --git a/examples/Remarketing/AddRemarketingAction.cs b/examples/Remarketing/AddRemarketingAction.cs index bd5c11e86..561fc87a7 100644 --- a/examples/Remarketing/AddRemarketingAction.cs +++ b/examples/Remarketing/AddRemarketingAction.cs @@ -14,15 +14,15 @@ using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Linq; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds a new remarketing action to the customer and then retrieves its @@ -67,11 +67,11 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the RemarketingActionService. RemarketingActionServiceClient remarketingActionService = - client.GetService(Services.V2.RemarketingActionService); + client.GetService(Services.V3.RemarketingActionService); // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); try { diff --git a/examples/Remarketing/UploadConversionAdjustment.cs b/examples/Remarketing/UploadConversionAdjustment.cs index ba839d68f..1ac159ced 100644 --- a/examples/Remarketing/UploadConversionAdjustment.cs +++ b/examples/Remarketing/UploadConversionAdjustment.cs @@ -13,13 +13,13 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.ConversionAdjustmentTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example imports conversion adjustments for conversions that already exist. @@ -95,7 +95,7 @@ public void Run(GoogleAdsClient client, long customerId, long conversionActionId { // Get the ConversionAdjustmentUploadService. ConversionAdjustmentUploadServiceClient conversionAdjustmentUploadService = - client.GetService(Services.V2.ConversionAdjustmentUploadService); + client.GetService(Services.V3.ConversionAdjustmentUploadService); // Associate conversion adjustments with the existing conversion action. // The GCLID should have been uploaded before with a conversion. diff --git a/examples/Remarketing/UploadOfflineConversion.cs b/examples/Remarketing/UploadOfflineConversion.cs index e81526bbe..42c512841 100644 --- a/examples/Remarketing/UploadOfflineConversion.cs +++ b/examples/Remarketing/UploadOfflineConversion.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example imports offline conversion values for specific clicks to your account. @@ -86,7 +86,7 @@ public void Run(GoogleAdsClient client, long customerId, long conversionActionId { // Get the ConversionActionService. ConversionUploadServiceClient conversionUploadService = - client.GetService(Services.V2.ConversionUploadService); + client.GetService(Services.V3.ConversionUploadService); // Creates a click conversion by specifying currency as USD. ClickConversion clickConversion = new ClickConversion() diff --git a/examples/Reporting/GetHotelAdsPerformance.cs b/examples/Reporting/GetHotelAdsPerformance.cs index 09b9d21d7..2b7a73ad5 100644 --- a/examples/Reporting/GetHotelAdsPerformance.cs +++ b/examples/Reporting/GetHotelAdsPerformance.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example gets Hotel-ads performance statistics for the 50 Hotel ad groups with @@ -62,7 +62,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Creates a query that retrieves hotel-ads statistics for each campaign and ad group. // Returned statistics will be segmented by the check-in day of week and length of diff --git a/examples/Reporting/GetKeywordStats.cs b/examples/Reporting/GetKeywordStats.cs index 0b24ade15..bb87f4417 100644 --- a/examples/Reporting/GetKeywordStats.cs +++ b/examples/Reporting/GetKeywordStats.cs @@ -13,16 +13,18 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; -using Google.Api.Gax; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; +using System.Threading; +using System.Threading.Tasks; +using static Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceClient; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// - /// This code example illustrates getting campaign targeting criteria. + /// This code example illustrates getting keyword stats. /// public class GetKeywordStats : ExampleBase { @@ -61,7 +63,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the query. string query = @@ -84,28 +86,32 @@ WHERE segments.date DURING LAST_7_DAYS AND ad_group_criterion.status IN ('ENABLED','PAUSED') ORDER BY metrics.impressions DESC LIMIT 50"; + try { // Issue a search request. - PagedEnumerable result = - googleAdsService.Search(customerId.ToString(), query); - - // Display the results. - foreach (GoogleAdsRow criterionRow in result) - { - Console.WriteLine( - $"Keyword with text '{criterionRow.AdGroupCriterion.Keyword.Text}', " + - $" match type '{criterionRow.AdGroupCriterion.Keyword.MatchType}' and " + - $"ID {criterionRow.AdGroupCriterion.CriterionId} " + - $"in ad group '{criterionRow.AdGroup.Name}' with " + - $"ID {criterionRow.AdGroup.Id} " + - $"in campaign '{criterionRow.Campaign.Name}' " + - $"with ID {criterionRow.Campaign.Id} " + - $"had {criterionRow.Metrics.Impressions.ToString()} impressions, " + - $"{criterionRow.Metrics.Clicks} clicks, and " + - $"{criterionRow.Metrics.CostMicros} cost (in micros)" + - "during the last 7 days."); - } + googleAdsService.SearchStream(customerId.ToString(), query, + delegate (SearchGoogleAdsStreamResponse resp) + { + // Display the results. + foreach (GoogleAdsRow criterionRow in resp.Results) + { + Console.WriteLine( + $"Keyword with text " + + $"'{criterionRow.AdGroupCriterion.Keyword.Text}', match type " + + $"'{criterionRow.AdGroupCriterion.Keyword.MatchType}' and ID " + + $"{criterionRow.AdGroupCriterion.CriterionId} in ad group " + + $"'{criterionRow.AdGroup.Name}' with ID " + + $"{criterionRow.AdGroup.Id} in campaign " + + $"'{criterionRow.Campaign.Name}' with ID " + + $"{criterionRow.Campaign.Id} had " + + $"{criterionRow.Metrics.Impressions.ToString()} impressions, " + + $"{criterionRow.Metrics.Clicks} clicks, and " + + $"{criterionRow.Metrics.CostMicros} cost (in micros) during the " + + $"last 7 days."); + } + } + ); } catch (GoogleAdsException e) { diff --git a/examples/ShoppingAds/AddListingScope.cs b/examples/ShoppingAds/AddListingScope.cs new file mode 100644 index 000000000..639a576b4 --- /dev/null +++ b/examples/ShoppingAds/AddListingScope.cs @@ -0,0 +1,179 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; +using System; +using static Google.Ads.GoogleAds.V3.Enums.ProductCustomAttributeIndexEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ProductTypeLevelEnum.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 +{ + /// + /// This code example adds a shopping listing scope to a shopping campaign. The example will + /// construct and add a new listing scope which will act as the inventory filter for the + /// campaign. The campaign will only advertise products that match the following requirements: + /// + ///
    + ///
  • Brand is "google"
  • + ///
  • Custom label 0 is "top_selling_products"
  • + ///
  • Product type (level 1) is "electronics"
  • + ///
  • Product type(level 2) is "smartphones"
  • + ///
+ /// + /// Only one listing scope is allowed per campaign. Remove any existing listing scopes before + /// running this code example. + ///
+ public class AddListingScope : ExampleBase + { + /// + /// Main method, to run this code example as a standalone application. + /// + /// The command line arguments. + public static void Main(string[] args) + { + AddListingScope codeExample = new AddListingScope(); + Console.WriteLine(codeExample.Description); + + // The Google Ads customer ID for which the call is made. + long customerId = long.Parse("INSERT_CUSTOMER_ID_HERE"); + + // The campaign to which listing scope is added. + long campaignId = long.Parse("INSERT_CAMPAIGN_ID_HERE"); + + codeExample.Run(new GoogleAdsClient(), customerId, campaignId); + } + + /// + /// Returns a description about the code example. + /// + public override string Description + { + get + { + return "This code example adds a shopping listing scope to a shopping campaign. " + + "The example will construct and add a new listing scope which will act as " + + "the inventory filter for the campaign. The campaign will only advertise " + + "products that match the following requirements: \n" + + " - Brand is 'google \n" + + " - Custom label 0 is 'top_selling_products'\n" + + " - Product type (level 1) is 'electronics'\n" + + " - Product type(level 2) is 'smartphones'\n" + + "Only one listing scope is allowed per campaign. Remove any existing " + + "listing scopes before running this code example."; + } + } + + /// + /// Runs the code example. + /// + /// The Google Ads client. + /// The Google Ads customer ID for which the call is made. + /// The campaign to which listing scope is added. + public void Run(GoogleAdsClient client, long customerId, long campaignId) + { + // Get the CampaignCriterionService. + CampaignCriterionServiceClient campaignCriterionService = + client.GetService(Services.V3.CampaignCriterionService); + + // A listing scope allows you to filter the products that will be included in a given + // campaign. You can specify multiple dimensions with conditions that must be met for + // a product to be included in a campaign. + // A typical ListingScope might only have a few dimensions. This example demonstrates + // a range of different dimensions you could use. + ListingScopeInfo listingScope = new ListingScopeInfo() + { + Dimensions = + { + // Creates a ProductBrand dimension set to "google". + new ListingDimensionInfo() + { + ProductBrand = new ProductBrandInfo() + { + Value = "google" + } + }, + + // Creates a ProductCustomAttribute dimension for INDEX0 set to + // "top_selling_products". + new ListingDimensionInfo() + { + ProductCustomAttribute = new ProductCustomAttributeInfo() + { + Index = ProductCustomAttributeIndex.Index0, + Value = "top_selling_products" + } + }, + + // Creates a ProductType dimension for LEVEL1 set to "electronics". + new ListingDimensionInfo() + { + ProductType = new ProductTypeInfo() + { + Level = ProductTypeLevel.Level1, + Value = "electronics" + } + }, + + // Creates a ProductType dimension for LEVEL2 set to "smartphones". + new ListingDimensionInfo() + { + ProductType = new ProductTypeInfo() + { + Level = ProductTypeLevel.Level2, + Value = "smartphones" + } + }, + } + }; + + string campaignResourceName = ResourceNames.Campaign(customerId, campaignId); + + // Creates a campaign criterion to store the listing scope. + CampaignCriterion campaignCriterion = new CampaignCriterion() + { + Campaign = campaignResourceName, + ListingScope = listingScope + }; + + CampaignCriterionOperation operation = new CampaignCriterionOperation() + { + Create = campaignCriterion + }; + + try + { + // Calls the mutate method to add the campaign criterion. + MutateCampaignCriteriaResponse response = + campaignCriterionService.MutateCampaignCriteria( + customerId.ToString(), new[] { operation }); + Console.WriteLine($"Added {response.Results.Count} campaign criteria:"); + foreach (MutateCampaignCriterionResult result in response.Results) + { + Console.WriteLine(result.ResourceName); + } + } + catch (GoogleAdsException e) + { + Console.WriteLine("Failure:"); + Console.WriteLine($"Message: {e.Message}"); + Console.WriteLine($"Failure: {e.Failure}"); + Console.WriteLine($"Request ID: {e.RequestId}"); + } + } + } +} diff --git a/examples/ShoppingAds/AddShoppingProductAd.cs b/examples/ShoppingAds/AddShoppingProductAd.cs index 0f0644f39..bba58811f 100644 --- a/examples/ShoppingAds/AddShoppingProductAd.cs +++ b/examples/ShoppingAds/AddShoppingProductAd.cs @@ -13,23 +13,23 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupCriterionStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ListingGroupTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Resources.Campaign.Types; - -namespace Google.Ads.GoogleAds.Examples.V2 +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ListingGroupTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example creates a standard shopping campaign, a shopping product ad group and a @@ -145,7 +145,7 @@ private string AddCampaignBudget(GoogleAdsClient client, long customerId) { // Get the CampaignBudgetService. CampaignBudgetServiceClient campaignBudgetService = - client.GetService(Services.V2.CampaignBudgetService); + client.GetService(Services.V3.CampaignBudgetService); CampaignBudget budget = new CampaignBudget() { @@ -183,7 +183,7 @@ private string AddStandardShoppingCampaign(GoogleAdsClient client, long customer { // Get the CampaignService. CampaignServiceClient campaignService = - client.GetService(Services.V2.CampaignService); + client.GetService(Services.V3.CampaignService); // Configures the shopping settings. ShoppingSetting shoppingSetting = new ShoppingSetting() @@ -261,7 +261,7 @@ private string AddProductShoppingAdGroup(GoogleAdsClient client, long customerId string campaignResourceName) { // Get the AdGroupService. - AdGroupServiceClient adGroupService = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient adGroupService = client.GetService(Services.V3.AdGroupService); // Creates an ad group. AdGroup adGroup = new AdGroup() @@ -306,7 +306,7 @@ private string AddProductShoppingAdGroupAd(GoogleAdsClient client, long customer { // Get the AdGroupAdService. AdGroupAdServiceClient adGroupAdService = client.GetService( - Services.V2.AdGroupAdService); + Services.V3.AdGroupAdService); // Creates a new shopping product ad. Ad ad = new Ad() @@ -361,7 +361,7 @@ private string AddDefaultShoppingListingGroup(GoogleAdsClient client, long custo { // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = client.GetService( - Services.V2.AdGroupCriterionService); + Services.V3.AdGroupCriterionService); // Creates a new ad group criterion. This will contain the "default" listing group (All // products). diff --git a/examples/ShoppingAds/AddShoppingProductListingGroupTree.cs b/examples/ShoppingAds/AddShoppingProductListingGroupTree.cs index b9ec2b34d..e0f452414 100644 --- a/examples/ShoppingAds/AddShoppingProductListingGroupTree.cs +++ b/examples/ShoppingAds/AddShoppingProductListingGroupTree.cs @@ -13,18 +13,18 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; using System.Linq; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupCriterionStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ListingGroupTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ProductConditionEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ListingGroupTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ProductConditionEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example shows how to add a shopping listing group tree to a shopping ad group. @@ -106,7 +106,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, { // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = - client.GetService(Services.V2.AdGroupCriterionService); + client.GetService(Services.V3.AdGroupCriterionService); try { @@ -216,7 +216,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, adGroupCriterionResourceNameConditionOther, new ListingDimensionInfo() { - ListingBrand = new ListingBrandInfo() + ProductBrand = new ProductBrandInfo() { Value = "CoolBrand" } @@ -237,7 +237,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, adGroupCriterionResourceNameConditionOther, new ListingDimensionInfo() { - ListingBrand = new ListingBrandInfo() + ProductBrand = new ProductBrandInfo() { Value = "CheapBrand" } @@ -259,7 +259,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId, adGroupCriterionResourceNameConditionOther, new ListingDimensionInfo() { - ListingBrand = new ListingBrandInfo() + ProductBrand = new ProductBrandInfo() }, 50_000L); operations.Add(new AdGroupCriterionOperation() @@ -305,11 +305,11 @@ private void RemoveListingGroupTree(GoogleAdsClient client, long customerId, { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = - client.GetService(Services.V2.AdGroupCriterionService); + client.GetService(Services.V3.AdGroupCriterionService); String searchQuery = "SELECT ad_group_criterion.resource_name FROM " + "ad_group_criterion WHERE ad_group_criterion.type = LISTING_GROUP AND " + diff --git a/examples/ShoppingAds/AddShoppingSmartAd.cs b/examples/ShoppingAds/AddShoppingSmartAd.cs index 3f9430c8b..445637dec 100644 --- a/examples/ShoppingAds/AddShoppingSmartAd.cs +++ b/examples/ShoppingAds/AddShoppingSmartAd.cs @@ -13,24 +13,24 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupAdStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupCriterionStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdGroupTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.BudgetDeliveryMethodEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.CampaignStatusEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ListingGroupTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Resources.Campaign.Types; -using static Google.Ads.GoogleAds.V2.Enums.AdvertisingChannelSubTypeEnum.Types; - -namespace Google.Ads.GoogleAds.Examples.V2 +using static Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ListingGroupTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Resources.Campaign.Types; +using static Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Types; + +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example creates a Smart Shopping campaign, a Smart Shopping ad group, a Smart @@ -148,7 +148,7 @@ private string AddCampaignBudget(GoogleAdsClient client, long customerId) { // Get the CampaignBudgetService. CampaignBudgetServiceClient campaignBudgetService = - client.GetService(Services.V2.CampaignBudgetService); + client.GetService(Services.V3.CampaignBudgetService); CampaignBudget budget = new CampaignBudget() { @@ -188,7 +188,7 @@ private string AddSmartShoppingCampaign(GoogleAdsClient client, long customerId, { // Get the CampaignService. CampaignServiceClient campaignService = - client.GetService(Services.V2.CampaignService); + client.GetService(Services.V3.CampaignService); // Configures the shopping settings. ShoppingSetting shoppingSetting = new ShoppingSetting() @@ -264,7 +264,7 @@ private string AddSmartShoppingAdGroup(GoogleAdsClient client, long customerId, string campaignResourceName) { // Get the AdGroupService. - AdGroupServiceClient adGroupService = client.GetService(Services.V2.AdGroupService); + AdGroupServiceClient adGroupService = client.GetService(Services.V3.AdGroupService); // Creates an ad group. AdGroup adGroup = new AdGroup() @@ -309,7 +309,7 @@ private string AddSmartShoppingAdGroupAd(GoogleAdsClient client, long customerId { // Get the AdGroupAdService. AdGroupAdServiceClient adGroupAdService = client.GetService( - Services.V2.AdGroupAdService); + Services.V3.AdGroupAdService); // Creates a new shopping product ad. Ad ad = new Ad() @@ -364,7 +364,7 @@ private string AddDefaultShoppingListingGroup(GoogleAdsClient client, long custo { // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = client.GetService( - Services.V2.AdGroupCriterionService); + Services.V3.AdGroupCriterionService); // Creates a new ad group criterion. This will contain the "default" listing group (All // products). diff --git a/examples/ShoppingAds/GetProductBiddingCategoryConstant.cs b/examples/ShoppingAds/GetProductBiddingCategoryConstant.cs index f772a4d26..d3b500734 100644 --- a/examples/ShoppingAds/GetProductBiddingCategoryConstant.cs +++ b/examples/ShoppingAds/GetProductBiddingCategoryConstant.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; using System.Collections.Generic; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example fetches the set of valid ProductBiddingCategories. @@ -117,7 +117,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the GoogleAdsServiceClient . GoogleAdsServiceClient googleAdsService = - client.GetService(Services.V2.GoogleAdsService); + client.GetService(Services.V3.GoogleAdsService); // Creates the query. string query = "SELECT product_bidding_category_constant.localized_name, " + diff --git a/examples/Targeting/AddCampaignTargetingCriteria.cs b/examples/Targeting/AddCampaignTargetingCriteria.cs index d3ec51966..feccd5cb0 100644 --- a/examples/Targeting/AddCampaignTargetingCriteria.cs +++ b/examples/Targeting/AddCampaignTargetingCriteria.cs @@ -13,17 +13,17 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.KeywordMatchTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.ProximityRadiusUnitsEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ProximityRadiusUnitsEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates adding campaign targeting criteria. @@ -80,7 +80,7 @@ public void Run(GoogleAdsClient client, long customerId, long campaignId, { // Get the CampaignCriterionService. CampaignCriterionServiceClient campaignCriterionService = - client.GetService(Services.V2.CampaignCriterionService); + client.GetService(Services.V3.CampaignCriterionService); // Set the Campaign Resource Name string campaignResourceName = ResourceNames.Campaign(customerId, campaignId); diff --git a/examples/Targeting/AddCustomerNegativeCriteria.cs b/examples/Targeting/AddCustomerNegativeCriteria.cs index 9f8aa7d2a..e13ec92cb 100644 --- a/examples/Targeting/AddCustomerNegativeCriteria.cs +++ b/examples/Targeting/AddCustomerNegativeCriteria.cs @@ -13,14 +13,14 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.ContentLabelTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds various types of negative criteria as exclusions at the customer @@ -65,7 +65,7 @@ public void Run(GoogleAdsClient client, long customerId) { // Get the CustomerNegativeCriterionServiceClient . CustomerNegativeCriterionServiceClient customerNegativeCriterionService = - client.GetService(Services.V2.CustomerNegativeCriterionService); + client.GetService(Services.V3.CustomerNegativeCriterionService); // Creates a negative customer criterion excluding the content label type of 'TRAGEDY'. CustomerNegativeCriterion tragedyCriterion = new CustomerNegativeCriterion() diff --git a/examples/Targeting/AddDemographicTargetingCriteria.cs b/examples/Targeting/AddDemographicTargetingCriteria.cs index e4bb450e5..6085260f9 100644 --- a/examples/Targeting/AddDemographicTargetingCriteria.cs +++ b/examples/Targeting/AddDemographicTargetingCriteria.cs @@ -14,17 +14,17 @@ using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Common; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Common; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using System; -using static Google.Ads.GoogleAds.V2.Enums.AgeRangeTypeEnum.Types; -using static Google.Ads.GoogleAds.V2.Enums.GenderTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.GenderTypeEnum.Types; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example adds demographic criteria to an ad group. To get ad groups, @@ -73,7 +73,7 @@ public void Run(GoogleAdsClient client, long customerId, long adGroupId) { // Get the AdGroupCriterionService. AdGroupCriterionServiceClient adGroupCriterionService = - client.GetService(Services.V2.AdGroupCriterionService); + client.GetService(Services.V3.AdGroupCriterionService); string adGroupResourceName = ResourceNames.AdGroup(customerId, adGroupId); diff --git a/examples/Targeting/GetCampaignTargetingCriteria.cs b/examples/Targeting/GetCampaignTargetingCriteria.cs index 4f0dacb7b..3f5a2413a 100644 --- a/examples/Targeting/GetCampaignTargetingCriteria.cs +++ b/examples/Targeting/GetCampaignTargetingCriteria.cs @@ -13,16 +13,16 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Resources; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Resources; +using Google.Ads.GoogleAds.V3.Services; using Google.Api.Gax; using System; -using static Google.Ads.GoogleAds.V2.Resources.CampaignCriterion; +using static Google.Ads.GoogleAds.V3.Resources.CampaignCriterion; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates getting campaign targeting criteria. @@ -69,7 +69,7 @@ public void Run(GoogleAdsClient client, long customerId, long campaignId) { // Get the GoogleAdsService. GoogleAdsServiceClient googleAdsService = client.GetService( - Services.V2.GoogleAdsService); + Services.V3.GoogleAdsService); // Create the query. string query = $@"SELECT campaign.id, campaign_criterion.campaign, diff --git a/examples/Targeting/GetGeoTargetConstantsByName.cs b/examples/Targeting/GetGeoTargetConstantsByName.cs index 3b8f393c6..c0ca79921 100644 --- a/examples/Targeting/GetGeoTargetConstantsByName.cs +++ b/examples/Targeting/GetGeoTargetConstantsByName.cs @@ -13,12 +13,12 @@ // limitations under the License. using Google.Ads.GoogleAds.Lib; -using Google.Ads.GoogleAds.V2.Errors; -using Google.Ads.GoogleAds.V2.Services; +using Google.Ads.GoogleAds.V3.Errors; +using Google.Ads.GoogleAds.V3.Services; using System; -namespace Google.Ads.GoogleAds.Examples.V2 +namespace Google.Ads.GoogleAds.Examples.V3 { /// /// This code example illustrates getting GeoTargetConstants by given location names. @@ -58,7 +58,7 @@ public void Run(GoogleAdsClient client) { // Get the GeoTargetConstantServiceClient. GeoTargetConstantServiceClient geoService = - client.GetService(Services.V2.GeoTargetConstantService); + client.GetService(Services.V3.GeoTargetConstantService); // Locale is using ISO 639-1 format. If an invalid locale is given, // 'en' is used by default. diff --git a/src/Config/GoogleAdsConfig.cs b/src/Config/GoogleAdsConfig.cs index 1a26f6793..0397c5884 100644 --- a/src/Config/GoogleAdsConfig.cs +++ b/src/Config/GoogleAdsConfig.cs @@ -16,7 +16,7 @@ using Google.Apis.Auth.OAuth2; using Google.Apis.Auth.OAuth2.Flows; using Google.Apis.Auth.OAuth2.Responses; - +using Google.Apis.Util; using Microsoft.Extensions.Configuration; using Newtonsoft.Json; @@ -25,6 +25,7 @@ using System.Collections.Generic; using System.IO; using System.Net; +using System.Threading.Tasks; namespace Google.Ads.GoogleAds.Config { @@ -58,21 +59,6 @@ public class GoogleAdsConfig : ConfigBase /// private const string DEFAULT_OAUTH_SCOPE = "https://www.googleapis.com/auth/adwords"; - /// - /// The developer token keyname in request metadata. - /// - public const string DEVELOPER_TOKEN_KEYNAME = "developer-token"; - - /// - /// The login customer ID keyname in request metadata. - /// - public const string LOGIN_CUSTOMER_ID_KEYNAME = "login-customer-id"; - - /// - /// The library identifier keyname in request metadata. - /// - internal const string LIBRARY_IDENTIFIER_KEYNAME = "x-goog-api-client"; - /// /// The configuration section name in App.config file. /// @@ -86,24 +72,12 @@ public class GoogleAdsConfig : ConfigBase private StringConfigSetting oAuth2ClientId = new StringConfigSetting("OAuth2ClientId", ""); - /// - /// OAuth2 server URL. - /// - private StringConfigSetting oAuth2ServerUrl = - new StringConfigSetting("OAuth2ServerUrl", DEFAULT_OAUTH2_SERVER); - /// /// OAuth2 client secret. /// private StringConfigSetting oAuth2ClientSecret = new StringConfigSetting( "OAuth2ClientSecret", ""); - /// - /// OAuth2 access token. - /// - private StringConfigSetting oAuth2AccessToken = new StringConfigSetting( - "OAuth2AccessToken", ""); - /// /// OAuth2 refresh token. /// @@ -165,6 +139,24 @@ public class GoogleAdsConfig : ConfigBase private ConfigSetting clientCustomerId = new ConfigSetting("ClientCustomerId", 0); + /// + /// The GMB login email. + /// + /// + /// This setting is only for testing purposes. + /// + private ConfigSetting gmbLoginEmail = + new ConfigSetting("GMBLoginEmail", ""); + + /// + /// Merchant Center ID to be used for Shopping campaigns. + /// + /// + /// This setting is only for testing purposes. + /// + private ConfigSetting merchantCenterAccountId = + new ConfigSetting("MerchantCenterAccountId", ""); + /// /// Web proxy to be used with the services. /// @@ -267,24 +259,17 @@ public string LoginCustomerId set => SetPropertyAndNotify(loginCustomerId, value); } - /// - /// Gets or sets the OAuth2 server URL. - /// - /// This property's setter is primarily used for testing purposes. - /// - public string OAuth2ServerUrl - { - get => oAuth2ServerUrl.Value; - set => SetPropertyAndNotify(oAuth2ServerUrl, value); - } - /// /// Gets or sets the OAuth2 client ID. /// public string OAuth2ClientId { get => oAuth2ClientId.Value; - set => SetPropertyAndNotify(oAuth2ClientId, value); + set + { + SetPropertyAndNotify(oAuth2ClientId, value); + credential = null; + } } /// @@ -293,7 +278,11 @@ public string OAuth2ClientId public string OAuth2ClientSecret { get => oAuth2ClientSecret.Value; - set => SetPropertyAndNotify(oAuth2ClientSecret, value); + set + { + SetPropertyAndNotify(oAuth2ClientSecret, value); + credential = null; + } } /// @@ -301,8 +290,12 @@ public string OAuth2ClientSecret /// public string OAuth2AccessToken { - get => oAuth2AccessToken.Value; - set => SetPropertyAndNotify(oAuth2AccessToken, value); + get + { + Task task = this.Credentials.GetAccessTokenForRequestAsync(); + task.Wait(); + return task.Result; + } } /// @@ -313,7 +306,11 @@ public string OAuth2AccessToken public string OAuth2RefreshToken { get => oAuth2RefreshToken.Value; - set => SetPropertyAndNotify(oAuth2RefreshToken, value); + set + { + SetPropertyAndNotify(oAuth2RefreshToken, value); + credential = null; + } } /// @@ -322,7 +319,11 @@ public string OAuth2RefreshToken public string OAuth2Scope { get => oAuth2Scope.Value; - set => SetPropertyAndNotify(oAuth2Scope, value); + set + { + SetPropertyAndNotify(oAuth2Scope, value); + credential = null; + } } /// @@ -331,7 +332,11 @@ public string OAuth2Scope public OAuth2Flow OAuth2Mode { get => oAuth2Mode.Value; - set => SetPropertyAndNotify(oAuth2Mode, value); + set + { + SetPropertyAndNotify(oAuth2Mode, value); + credential = null; + } } /// @@ -354,6 +359,26 @@ internal long ClientCustomerId set => SetPropertyAndNotify(clientCustomerId, value); } + /// + /// Gets or sets the GMB login email. + /// + /// This setting is only for testing purposes. + internal string GMBLoginEmail + { + get => gmbLoginEmail.Value; + set => SetPropertyAndNotify(gmbLoginEmail, value); + } + + /// + /// Merchant Center ID to be used for Shopping campaigns. + /// + /// This setting is only for testing purposes. + internal string MerchantCenterAccountId + { + get => merchantCenterAccountId.Value; + set => SetPropertyAndNotify(merchantCenterAccountId, value); + } + /// /// Gets or sets the OAuth2 prn email. /// @@ -362,7 +387,11 @@ internal long ClientCustomerId public string OAuth2PrnEmail { get => oAuth2PrnEmail.Value; - set => SetPropertyAndNotify(oAuth2PrnEmail, value); + set + { + SetPropertyAndNotify(oAuth2PrnEmail, value); + credential = null; + } } /// @@ -376,7 +405,11 @@ public string OAuth2PrnEmail public string OAuth2ServiceAccountEmail { get => oAuth2ServiceAccountEmail.Value; - private set => SetPropertyAndNotify(oAuth2ServiceAccountEmail, value); + private set + { + SetPropertyAndNotify(oAuth2ServiceAccountEmail, value); + credential = null; + } } /// @@ -390,7 +423,11 @@ public string OAuth2ServiceAccountEmail public string OAuth2PrivateKey { get => oAuth2PrivateKey.Value; - private set => SetPropertyAndNotify(oAuth2PrivateKey, value); + private set + { + SetPropertyAndNotify(oAuth2PrivateKey, value); + credential = null; + } } /// @@ -452,11 +489,11 @@ protected override void ReadSettings(Dictionary settings) ReadSetting(settings, developerToken); ReadSetting(settings, loginCustomerId); ReadSetting(settings, clientCustomerId); + ReadSetting(settings, gmbLoginEmail); + ReadSetting(settings, merchantCenterAccountId); - ReadSetting(settings, oAuth2ServerUrl); ReadSetting(settings, oAuth2ClientId); ReadSetting(settings, oAuth2ClientSecret); - ReadSetting(settings, oAuth2AccessToken); ReadSetting(settings, oAuth2RefreshToken); ReadSetting(settings, oAuth2Scope); @@ -510,13 +547,22 @@ private void ReadProxySettings(Dictionary settings) } /// - /// Gets or sets the credentials. + /// The credential object that was created from settings. + /// + ICredential credential = null; + + /// + /// Gets the credentials. /// public ICredential Credentials { get { - return CreateCredentials(); + if (credential == null) + { + credential = CreateCredentials(); + } + return credential; } } diff --git a/src/Google.Ads.GoogleAds.csproj b/src/Google.Ads.GoogleAds.csproj index 99a54ff60..949ff2b65 100644 --- a/src/Google.Ads.GoogleAds.csproj +++ b/src/Google.Ads.GoogleAds.csproj @@ -3,7 +3,7 @@ Google Ads API Dotnet Client Library Google.Ads.GoogleAds - 2.7.0 + 2.8.0 This library provides you with functionality to access the Google Ads API. https://github.com/googleads/google-ads-dotnet/blob/master/ChangeLog GoogleAds Google @@ -31,8 +31,8 @@ true true true - 2.7.0.0 - 2.7.0.0 + 2.8.0.0 + 2.8.0.0 latest @@ -73,9 +73,4 @@ NET452 - diff --git a/src/Interceptors/GoogleAdsGrpcInterceptor.cs b/src/Interceptors/GoogleAdsGrpcInterceptor.cs new file mode 100644 index 000000000..536a3137c --- /dev/null +++ b/src/Interceptors/GoogleAdsGrpcInterceptor.cs @@ -0,0 +1,146 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Config; +using Google.Ads.GoogleAds.Logging; +using Grpc.Core; +using Grpc.Core.Interceptors; +using System; +using System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.Interceptors +{ + /// + /// Interceptor for logging requests and responses. + /// + internal class GoogleAdsGrpcInterceptor : Interceptor + { + /// + /// The singleton instance. + /// + private static GoogleAdsGrpcInterceptor instance; + + /// + /// The logging handler. + /// + private LoggingHandler loggingHandler; + + /// + /// The configuration. + /// + private GoogleAdsConfig config; + + /// + /// Initializes a new instance of the class. + /// + /// The configuration. + protected GoogleAdsGrpcInterceptor(GoogleAdsConfig config) : base() + { + this.config = config; + this.loggingHandler = new LoggingHandler(config); + } + + /// + /// Gets an instance of the logging interceptor. + /// + /// The application configuration. + /// An instance of the logging interceptor. + internal static GoogleAdsGrpcInterceptor GetInstance(GoogleAdsConfig config) + { + lock (typeof(GoogleAdsGrpcInterceptor)) + { + if (instance == null) + { + instance = new GoogleAdsGrpcInterceptor(config); + } + } + return instance; + } + + /// + /// Intercepts an asynchronous invocation of a simple remote call. + /// + /// The request message of the invocation. + /// The + /// associated with the current invocation. + /// The callback that continues the invocation process. + /// This can be invoked zero or more times by the interceptor. + /// The interceptor can invoke the continuation passing the given + /// request value and context arguments, or substitute them as it sees fit. + /// + /// An instance of + /// representing an asynchronous unary invocation. + /// The interceptor can simply return the return value of the + /// delegate passed to it intact, or construct its + /// own substitute. + /// + public override AsyncUnaryCall AsyncUnaryCall( + TRequest request, ClientInterceptorContext context, + AsyncUnaryCallContinuation continuationCallback) + { + AsyncUnaryCall call = continuationCallback(request, context); + + Task t = call.ResponseAsync.ContinueWith( + delegate (Task oldTask) + { + loggingHandler.HandleAsyncUnaryLogging(request, context, oldTask, call); + }); + t.Wait(); + + return UnaryRpcInterceptor.Intercept(call); + } + + /// + /// Intercepts an asynchronous invocation of a streaming remote call. + /// + /// + /// + /// The request message of the invocation. + /// The + /// associated with the current invocation. + /// The callback that continues the invocation process. + /// This can be invoked zero or more times by the interceptor. + /// The interceptor can invoke the continuation passing the given + /// request value and context arguments, or substitute them as it sees fit. + /// + /// An instance of + /// representing an asynchronous server-streaming invocation. + /// The interceptor can simply return the return value of the + /// continuation delegate passed to it intact, or construct its + /// own substitute as it sees fit. + /// + public override AsyncServerStreamingCall AsyncServerStreamingCall( + TRequest request, ClientInterceptorContext context, + AsyncServerStreamingCallContinuation continuation) + { + AsyncServerStreamingCall call = continuation(request, context); + StreamingRpcInterceptor responseStream = null; + + responseStream = new StreamingRpcInterceptor(call.ResponseStream, + delegate (TResponse response, AggregateException rpcException) + { + loggingHandler.HandleAsyncServerStreamingLogging(request, response, + context, rpcException, call); + }); + + return new AsyncServerStreamingCall( + responseStream, + call.ResponseHeadersAsync, + call.GetStatus, + call.GetTrailers, + call.Dispose + ); + } + } +} diff --git a/src/Interceptors/StreamingRpcInterceptor.cs b/src/Interceptors/StreamingRpcInterceptor.cs new file mode 100644 index 000000000..28648e9e1 --- /dev/null +++ b/src/Interceptors/StreamingRpcInterceptor.cs @@ -0,0 +1,126 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Grpc.Core; +using System; +using System.Threading; +using System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.Interceptors +{ + /// + /// An class for intecepting streaming + /// requests. + /// + /// The type of the response. + /// + internal class StreamingRpcInterceptor : IAsyncStreamReader + where TResponse : class + { + /// + /// The stream reader that this instance wraps over. + /// + private readonly IAsyncStreamReader innerStreamReader = null; + + /// + /// The callback to be invoked when MoveNext() is called. + /// + private Action onMoveNext = null; + + /// + /// Initializes a new instance of the class. + /// + /// The stream reader to wrap over.. + /// The callback to be invoked when MoveNext() is + /// called. + internal StreamingRpcInterceptor(IAsyncStreamReader streamReader, + Action moveNextCallback) + { + this.innerStreamReader = streamReader; + this.onMoveNext = moveNextCallback; + } + + /// + /// Gets the current item in the stream. + /// + public TResponse Current + { + get + { + return innerStreamReader.Current; + } + } + + /// + /// Moves to the next item in the stream. + /// + /// The cancellation token. + /// A task that can be waited upon to complete this operation. + public async Task MoveNext(CancellationToken cancellationToken) + { + AggregateException aggregateException = null; + Task task = innerStreamReader.MoveNext(cancellationToken); + + try + { + // Wait for the next result to be retrieved. + task.Wait(); + } + catch (AggregateException e) + { + // If an exception is caught, we catch it, for parsing later. + aggregateException = e; + } + finally + { + if (onMoveNext != null) + { + if (task.IsFaulted) + { + // The task has already faulted, so there's no result. Pass the default + // value of TResponse and the caught exception to the callback. + onMoveNext(default, aggregateException); + } + else + { + // There is no exception. Invoke the callback if we haven't reached + // the end of stream. + if (task.Result) + { + onMoveNext(this.Current, null); + } + } + } + } + + if (task.IsFaulted) + { + // Parse the exception thrown by the task and throw it. + throw UnaryRpcInterceptor.ParseTaskException(aggregateException); + } + else + { + // Pass on the result we retrieved. + return await Task.FromResult(task.Result); + } + } + + /// + /// Releases unmanaged and - optionally - managed resources. + /// + public void Dispose() + { + } + } +} diff --git a/src/Interceptors/UnaryRpcInterceptor.cs b/src/Interceptors/UnaryRpcInterceptor.cs new file mode 100644 index 000000000..e1e511396 --- /dev/null +++ b/src/Interceptors/UnaryRpcInterceptor.cs @@ -0,0 +1,213 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; +using Grpc.Core; +using System; +using System.Linq; +using System.Reflection; +using System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.Interceptors +{ + /// + /// This class provides functionality to intercept tasks and callbacks, and performs custom + /// exception handling. + /// + internal class UnaryRpcInterceptor + { + private const string GOOGLE_ADS_EXCEPTION_NAMESPACE_TEMPLATE = + "Google.Ads.GoogleAds.{0}.Errors.GoogleAdsException"; + + /// + /// Intercepts an async unary call adds a custom exception handler. + /// + /// The type of the response. + /// The async unary call to intercept. + /// The async unary call with custom exception handling for + /// . + internal static AsyncUnaryCall Intercept(AsyncUnaryCall call) + { + return new AsyncUnaryCall( + Intercept(call.ResponseAsync), Intercept(call.ResponseHeadersAsync), + Intercept(call.GetStatus), Intercept(call.GetTrailers), Intercept(call.Dispose)); + } + + /// + /// Intercepts a task and adds a custom exception handler. + /// + /// The task result type + /// The task to be intercepted. + /// The intercepted task with custom exception handling for + /// . + /// Thrown if the intercepted + /// can be parsed. + internal static async Task Intercept(Task task) + { + GoogleAdsBaseException parsedException; + try + { + return await task; + } + catch (RpcException e) when ((parsedException = ParseRpcException(e)) != null) + { + throw parsedException; + } + } + + /// + /// Intercepts a function delegate and adds a custom exception handler. + /// + /// The return type of the function delegate. + /// The function delegate to intercept. + /// The intercepted function delegate with custom exception handling for + /// + internal static Func Intercept(Func function) + { + return new Func(delegate () + { + GoogleAdsBaseException parsedException; + try + { + return function(); + } + catch (RpcException e) when ((parsedException = ParseRpcException(e)) != null) + { + throw parsedException; + } + }); + } + + /// + /// Intercepts an action delegate and adds custom exception handling. + /// + /// The action delegate to intercept. + /// The intercepted action delegate, with custom exception handling for + /// + internal static Action Intercept(Action action) + { + return new Action(delegate () + { + GoogleAdsBaseException parsedException; + try + { + action(); + } + catch (RpcException e) when ((parsedException = ParseRpcException(e)) != null) + { + throw parsedException; + } + }); + } + + /// + /// Parses the task exception. + /// + /// The to parse. + /// The parsed if parsing is successful; + /// The underlying if the exception cannot be parsed as a + /// GoogleAdsException. + /// AggregateException is very close to a catch-all exception for + /// Tasks. While all the situations that we know of involves this exception being thrown + /// by an underlying RpcException, theoretically this method may return a + /// null object, if the AggregateException is not caused by an + /// RpcException. That would typically indicate an underlying issue with + /// the code. + internal static RpcException ParseTaskException(AggregateException e) + { + RpcException rpcException = ExtractRpcException(e); + GoogleAdsBaseException googleAdsException = ParseRpcException(rpcException); + return (googleAdsException == null) ? rpcException : googleAdsException; + } + + /// + /// Parses the RPC exception into a . + /// + /// The RPC exception. + /// The parsed exception, or a null if the parsing cannot be done. + internal static GoogleAdsBaseException ParseRpcException(RpcException rpcException) + { + if (rpcException == null) + { + return null; + } + + string apiVersion = GetApiExceptionVersion(rpcException); + if (string.IsNullOrEmpty(apiVersion)) + { + return null; + } + System.Type exceptionType = GetApiExceptionType(apiVersion); + if (exceptionType == null) + { + return null; + } + MethodInfo methodInfo = exceptionType.GetMethod("Create", + BindingFlags.Public | BindingFlags.Static); + if (methodInfo == null) + { + return null; + } + return methodInfo.Invoke(null, new object[] { rpcException }) + as GoogleAdsBaseException; + } + + /// + /// Extracts the RPC exception from an . + /// + /// The aggregate exception. + /// the extracted , or null if an exception + /// cannot be extracted. + internal static RpcException ExtractRpcException(AggregateException aggregateException) + { + return aggregateException?.InnerExceptions?.FirstOrDefault( + delegate (Exception innerException) + { + return (innerException is RpcException); + } + ) as RpcException; + } + + /// + /// Gets the API exception version. + /// + /// The RPC exception. + /// The version string. + private static string GetApiExceptionVersion(RpcException rpcException) + { + foreach (Metadata.Entry entry in rpcException.Trailers) + { + if (entry.Key.EndsWith(".googleadsfailure-bin")) + { + return entry.Key.Replace("google.ads.googleads.", "") + .Replace(".errors.googleadsfailure-bin", "").ToUpper(); + } + } + return null; + } + + /// + /// Gets the type of the API exception. + /// + /// The version. + /// The type of the exception. + private static System.Type GetApiExceptionType(string version) + { + Assembly myAssembly = MethodBase.GetCurrentMethod().DeclaringType.Assembly; + string googleAdsExceptionTypeName = + string.Format(GOOGLE_ADS_EXCEPTION_NAMESPACE_TEMPLATE, version); + return myAssembly.GetType(googleAdsExceptionTypeName); + } + } +} diff --git a/src/Lib/GoogleAdsBaseException.cs b/src/Lib/GoogleAdsBaseException.cs new file mode 100644 index 000000000..15059fb26 --- /dev/null +++ b/src/Lib/GoogleAdsBaseException.cs @@ -0,0 +1,139 @@ +using Google.Protobuf; +using Grpc.Core; +using Newtonsoft.Json; +using Newtonsoft.Json.Linq; +using System.Reflection; + +namespace Google.Ads.GoogleAds.Lib +{ + /// + /// + /// + /// + public abstract class GoogleAdsBaseException : RpcException + { + /// + /// Gets the request ID. + /// + public string RequestId + { + get; + protected set; + } + + /// + /// Initializes a new instance of the class. + /// + /// Resulting status of a call. + /// The exception message. + protected GoogleAdsBaseException(Status status, string message) : base(status, message) + { + } + + /// + /// Initializes a new instance of the class. + /// + /// Resulting status of a call. + /// Response trailing metadata. + protected GoogleAdsBaseException(Status status, Metadata trailers) : base(status, trailers) + { + } + + /// + /// Parses the failure. + /// + /// + /// The data. + /// + protected U ParseFailure(byte[] data) where U : IMessage + { + MessageParser parser = (MessageParser) typeof(U) + .GetProperty("Parser", BindingFlags.Public | BindingFlags.Static) + .GetValue(null); + + return parser.ParseFrom(data); + } + + /// + /// Gets the name of the version from type name. + /// + /// The class type. + /// + internal static string GetFailureKeyFromTypeName(System.Type type) + { + string version = type.FullName + .Replace("Google.Ads.GoogleAds.", "") + .Replace(".Errors.GoogleAdsException", "").ToLower(); + + return string.Format(MetadataKeyNames.FailureKeyTemplate, version); + } + } + + /// + /// + /// + /// + /// + public abstract class GoogleAdsBaseException : GoogleAdsBaseException where T : IMessage + { + /// + /// Gets the Google Ads failure details. + /// + public T Failure + { + get; + } + + /// + /// Initializes a new instance of the class. + /// + /// Resulting status of a call. + /// The exception message. + protected GoogleAdsBaseException(Status status, string message) : base(status, message) + { + } + + /// + /// Initializes a new instance of the class. + /// + /// Resulting status of a call. + /// Response trailing metadata. + protected GoogleAdsBaseException(Status status, Metadata trailers) : base(status, trailers) + { + foreach (Metadata.Entry entry in trailers) + { + if (entry.Key == MetadataKeyNames.RequestId) + { + RequestId = entry.Value; + } + else if (entry.Key.EndsWith(MetadataKeyNames.FailureKeySuffix)) + { + Failure = ParseFailure(entry.ValueBytes); + } + } + } + + /// + /// Returns a that represents this instance. + /// + /// + /// A that represents this instance. + /// + public override string ToString() + { + JObject jsonObject = new JObject( + new JProperty("StatusCode", this.StatusCode), + new JProperty("Details", this.Status.Detail), + new JProperty("RequestId", this.RequestId) + ); + + if (this.Failure != null) + { + jsonObject.Add(new JProperty("Failure", JObject.Parse( + JsonFormatter.ToDiagnosticString(this.Failure)))); + } + + return JsonConvert.SerializeObject(jsonObject, Formatting.Indented); + } + } +} diff --git a/src/Lib/GoogleAdsServiceClientFactory.cs b/src/Lib/GoogleAdsServiceClientFactory.cs index 2de399d29..851edfd7f 100644 --- a/src/Lib/GoogleAdsServiceClientFactory.cs +++ b/src/Lib/GoogleAdsServiceClientFactory.cs @@ -13,7 +13,7 @@ // limitations under the License. using Google.Ads.GoogleAds.Config; -using Google.Ads.GoogleAds.Logging; +using Google.Ads.GoogleAds.Interceptors; using Google.Api.Gax.Grpc; using Grpc.Core; using Grpc.Core.Interceptors; @@ -40,8 +40,8 @@ internal TService GetService( where TService : GoogleAdsServiceClientBase { Channel channel = CreateChannel(config); - CallInvoker callInvoker = channel.Intercept( - LoggingInterceptor.GetInstance(config)); + CallInvoker callInvoker = channel + .Intercept(GoogleAdsGrpcInterceptor.GetInstance(config)); // Build a service context to bind the service, configuration and CallSettings. GoogleAdsServiceContext serviceContext = new GoogleAdsServiceContext(); @@ -135,7 +135,7 @@ private CallSettings CreateCallSettings(GoogleAdsConfig config, private CallSettings UpdateCallSettingsWithConfigParameters(CallSettings callSettings, GoogleAdsConfig config, GoogleAdsServiceContext serviceContext) { - callSettings = callSettings.WithHeader(GoogleAdsConfig.DEVELOPER_TOKEN_KEYNAME, + callSettings = callSettings.WithHeader(MetadataKeyNames.DeveloperToken, config.DeveloperToken) .WithResponseMetadataHandler(delegate (Metadata metadata) { @@ -146,13 +146,13 @@ private CallSettings UpdateCallSettingsWithConfigParameters(CallSettings callSet if (!string.IsNullOrEmpty(config.LoginCustomerId)) { - callSettings = callSettings.WithHeader(GoogleAdsConfig.LOGIN_CUSTOMER_ID_KEYNAME, + callSettings = callSettings.WithHeader(MetadataKeyNames.LoginCustomerId, config.LoginCustomerId); } if (!string.IsNullOrEmpty(config.LibraryIdentifierOverride)) { - callSettings = callSettings.WithHeader(GoogleAdsConfig.LIBRARY_IDENTIFIER_KEYNAME, + callSettings = callSettings.WithHeader(MetadataKeyNames.LibraryIdentifier, config.LibraryIdentifierOverride); } diff --git a/src/Lib/MetadataKeyNames.cs b/src/Lib/MetadataKeyNames.cs new file mode 100644 index 000000000..26272d633 --- /dev/null +++ b/src/Lib/MetadataKeyNames.cs @@ -0,0 +1,53 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +namespace Google.Ads.GoogleAds.Lib +{ + /// + /// Key names to be used in gRPC metadata headers. + /// + internal class MetadataKeyNames + { + /// + /// The developer token keyname in request metadata. + /// + internal const string DeveloperToken = "developer-token"; + + /// + /// The login customer ID keyname in request metadata. + /// + internal const string LoginCustomerId = "login-customer-id"; + + /// + /// The library identifier keyname in request metadata. + /// + internal const string LibraryIdentifier = "x-goog-api-client"; + + /// + /// The metadata key name for request ID. + /// + internal const string RequestId = "request-id"; + + /// + /// The metadata key name suffix for the serialized failure object. + /// + internal const string FailureKeySuffix = "errors.googleadsfailure-bin"; + + /// + /// The metadata key name for the serialized failure object. + /// + internal const string FailureKeyTemplate = "google.ads.googleads.{0}." + + FailureKeySuffix; + } +} diff --git a/src/Logging/LogEntry.cs b/src/Logging/LogEntry.cs index 2b4e95999..55bdcee06 100644 --- a/src/Logging/LogEntry.cs +++ b/src/Logging/LogEntry.cs @@ -16,6 +16,7 @@ using Google.Ads.GoogleAds.Lib; using Grpc.Core; using Newtonsoft.Json; +using System; using System.Collections.Generic; using System.Text; @@ -27,7 +28,7 @@ namespace Google.Ads.GoogleAds.Logging public class LogEntry { private readonly HashSet REQUEST_HEADERS_TO_MASK = - new HashSet() { GoogleAdsConfig.DEVELOPER_TOKEN_KEYNAME }; + new HashSet() { MetadataKeyNames.DeveloperToken }; private readonly HashSet RESPONSE_HEADERS_TO_MASK = new HashSet() { }; @@ -190,7 +191,7 @@ private string DetailedRequestLog builder.Append($"Method Name: {Method}\r\n"); builder.Append($"Host: {Host}\r\n"); - builder.Append("Headers: " + FormatHeaders(RequestHeaders, RESPONSE_HEADERS_TO_MASK)); + builder.Append("Headers: " + FormatHeaders(RequestHeaders, REQUEST_HEADERS_TO_MASK)); builder.Append("\r\n\r\n" + Request.ToString() + "\r\n"); return builder.ToString(); } @@ -247,11 +248,18 @@ private static string FormatHeaders(Metadata metadata, HashSet keysToMas } else { - headers[entry.Key] = entry.Value; + if (entry.IsBinary) + { + headers[entry.Key] = Convert.ToBase64String(entry.ValueBytes); + } + else + { + headers[entry.Key] = entry.Value; + } } } } - return JsonConvert.SerializeObject(headers); + return JsonConvert.SerializeObject(headers, Formatting.Indented); } } } diff --git a/src/Logging/LoggingHandler.cs b/src/Logging/LoggingHandler.cs new file mode 100644 index 000000000..fa2c9003c --- /dev/null +++ b/src/Logging/LoggingHandler.cs @@ -0,0 +1,246 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Config; +using Google.Ads.GoogleAds.Interceptors; +using Google.Ads.GoogleAds.Util; +using Grpc.Core; +using Grpc.Core.Interceptors; +using System; +using System.Reflection; +using System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.Logging +{ + /// + /// Handles logging of requests and responses. + /// + internal class LoggingHandler + { + /// + /// Gets the trace writer. + /// + private ITraceWriter traceWriter; + + /// + /// Gets the configuration. + /// + private GoogleAdsConfig config; + + /// + /// Gets or sets the callback for writing logs. + /// + internal Action WriteLogs + { + get; + set; + } + + /// + /// Initializes a new instance of the class. + /// + /// The configuration. + internal LoggingHandler(GoogleAdsConfig config) + { + this.config = config; + this.traceWriter = new DefaultTraceWriter(); + this.WriteLogs = WriteLogEntry; + } + + /// + /// Handles the logging of asynchronous unary calls. + /// + /// The type of the request. + /// The type of the response. + /// The request. + /// The context. + /// The old task. + /// The call. + internal void HandleAsyncUnaryLogging(TRequest request, + ClientInterceptorContext context, + Task oldTask, AsyncUnaryCall call) + where TRequest : class + where TResponse : class + { + // Generating log entry is expensive, so let's do that only if the log source + // has been configured to do so. + if (TraceUtilities.ShouldGenerateRequestLogs()) + { + LogEntry logEntry = new LogEntry() + { + Host = config.ServerUrl, + Method = context.Method.FullName, + RequestHeaders = context.Options.Headers, + Request = request, + ResponseHeaders = Merge(GetResponseHeader(call.ResponseHeadersAsync), + call.GetTrailers()), + Response = (oldTask.IsFaulted) ? default : oldTask.Result, + Exception = UnaryRpcInterceptor.ParseTaskException(oldTask.Exception), + IsFailure = oldTask.IsFaulted, + CustomerId = GetCustomerId(request), + PartialFailures = (oldTask.IsFaulted) ? "" : + GetPartialFailures(oldTask.Result) + }; + WriteLogs(logEntry); + } + } + + /// + /// Handles the logging of asynchronous server streaming calls. + /// + /// The type of the request. + /// The type of the response. + /// The request. + /// The response. + /// The context. + /// The RPC exception. + /// The call. + internal void HandleAsyncServerStreamingLogging(TRequest request, + TResponse response, ClientInterceptorContext context, + AggregateException rpcException, AsyncServerStreamingCall call) + where TRequest : class + where TResponse : class + { + // Generating log entry is expensive, so let's do that only if the log source + // has been configured to do so. + if (TraceUtilities.ShouldGenerateRequestLogs()) + { + LogEntry logEntry = new LogEntry() + { + Host = config.ServerUrl, + Method = context.Method.FullName, + RequestHeaders = context.Options.Headers, + Request = request, + ResponseHeaders = Merge(GetResponseHeader(call.ResponseHeadersAsync), + TryGetCallTrailers(call)), + Response = response, + Exception = UnaryRpcInterceptor.ParseTaskException(rpcException), + IsFailure = (rpcException != null), + CustomerId = GetCustomerId(request), + PartialFailures = (rpcException != null) ? "" : GetPartialFailures(response) + }; + WriteLogs(logEntry); + } + } + + /// + /// Tries to the get call trailers. + /// + /// The type of the response. + /// The call. + /// The trailing metadata, if the call has completed, an empty metadata if the + /// call is ongoing. + /// There is currently no exposed method in the gRPC stack to check if an API call + /// has completed. + private Metadata TryGetCallTrailers(AsyncServerStreamingCall call) + { + try + { + return call.GetTrailers(); + } + catch (InvalidOperationException) { + return new Metadata(); + } + } + + /// + /// Writes the log entry. + /// + /// The log entry. + private void WriteLogEntry(LogEntry logEntry) + { + traceWriter.WriteDetailedRequestLogs(logEntry); + traceWriter.WriteSummaryRequestLogs(logEntry); + } + + /// + /// Gets the customer ID from the request, if available. + /// + /// The request. + /// The customer ID, or an empty string if customer ID is not found. + private string GetCustomerId(TRequest request) + { + try + { + return request.GetType().GetProperty("CustomerId").GetValue( + request, null).ToString(); + } + catch + { + return ""; + } + } + + /// + /// Gets the partial failures. + /// + /// The response. + /// + private string GetPartialFailures(object response) + { + if (response == null) + { + return ""; + } + PropertyInfo propInfo = response.GetType().GetProperty("PartialFailure"); + if (propInfo == null) + { + return ""; + } + object propValue = propInfo.GetValue(response); + if (propValue == null) + { + return ""; + } + else + { + return propValue.ToString(); + } + } + + /// + /// Gets the response header. + /// + /// The task for retrieving metadata headers. + /// The trailing response metadata headers. + private static Metadata GetResponseHeader(Task task) + { + task.Wait(); + return task.Result; + } + + /// + /// Merges two metadata objects. + /// + /// The first metadata object. + /// The second metadata object. + /// The merged metadata object. + private static Metadata Merge(Metadata first, Metadata second) + { + Metadata merged = new Metadata(); + + foreach (Metadata.Entry entry in first) + { + merged.Add(entry); + } + + foreach (Metadata.Entry entry in second) + { + merged.Add(entry); + } + + return merged; + } + } +} diff --git a/src/Logging/LoggingInterceptor.cs b/src/Logging/LoggingInterceptor.cs deleted file mode 100644 index 3507b7298..000000000 --- a/src/Logging/LoggingInterceptor.cs +++ /dev/null @@ -1,243 +0,0 @@ -// Copyright 2018 Google LLC -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -using Google.Ads.GoogleAds.Config; -using Google.Ads.GoogleAds.Util; -using Grpc.Core; -using Grpc.Core.Interceptors; -using System; -using System.Linq; -using System.Reflection; -using System.Threading.Tasks; - -namespace Google.Ads.GoogleAds.Logging -{ - /// - /// Interceptor for logging requests and responses. - /// - internal class LoggingInterceptor : Interceptor - { - /// - /// The singleton instance. - /// - private static LoggingInterceptor instance; - - /// - /// The callback to be called when a new is available. - /// - protected EventHandler OnLogEventAvailable; - - /// - /// Initializes a new instance of the class. - /// - /// The configuration. - protected LoggingInterceptor(GoogleAdsConfig config) : base() - { - this.Config = config; - this.TraceWriter = new DefaultTraceWriter(); - OnLogEventAvailable += WriteLogEntry; - } - - /// - /// Gets an instance of the logging interceptor. - /// - /// The application configuration. - /// An instance of the logging interceptor. - public static LoggingInterceptor GetInstance(GoogleAdsConfig config) - { - lock (typeof(LoggingInterceptor)) - { - if (instance == null) - { - instance = new LoggingInterceptor(config); - } - } - return instance; - } - - /// - /// Gets the configuration. - /// - protected GoogleAdsConfig Config - { - get; - } - - /// - /// Gets the trace writer. - /// - public ITraceWriter TraceWriter - { - get; - protected set; - } - - /// - /// Intercepts an asynchronous invocation of a simple remote call. - /// - /// The request message of the invocation. - /// The - /// associated with the current invocation. - /// The callback that continues the invocation process. - /// This can be invoked zero or more times by the interceptor. - /// The interceptor can invoke the continuation passing the given - /// request value and context arguments, or substitute them as it sees fit. - /// - /// An instance of - /// representing an asynchronous unary invocation. - /// The interceptor can simply return the return value of the - /// continuation delegate passed to it intact, or construct its - /// own substitute as it sees fit. - /// - public override AsyncUnaryCall AsyncUnaryCall( - TRequest request, ClientInterceptorContext context, - AsyncUnaryCallContinuation continuation) - { - AsyncUnaryCall call = continuation(request, context); - Task t = call.ResponseAsync.ContinueWith( - delegate (Task oldTask) - { - // Generating log entry is expensive, so let's do that only if the log source - // has been configured to do so. - if (TraceUtilities.ShouldGenerateRequestLogs()) - { - LogEntry logEntry = new LogEntry() - { - Host = Config.ServerUrl, - Method = context.Method.FullName, - RequestHeaders = context.Options.Headers, - Request = request, - ResponseHeaders = GetResponseHeader(call), - Response = (oldTask.IsFaulted) ? default(TResponse) : oldTask.Result, - Exception = GetGoogleAdsException(oldTask.Exception), - IsFailure = oldTask.IsFaulted, - CustomerId = GetCustomerId(request), - PartialFailures = (oldTask.IsFaulted) ? "" : - GetPartialFailures(oldTask.Result) - }; - OnLogEventAvailable?.Invoke(this, logEntry); - } - }); - t.Wait(); - return call; - } - - /// - /// Gets the partial failures. - /// - /// The response. - /// - private string GetPartialFailures(object response) - { - if (response == null) - { - return ""; - } - PropertyInfo propInfo = response.GetType().GetProperty("PartialFailure"); - if (propInfo == null) - { - return ""; - } - object propValue = propInfo.GetValue(response); - if (propValue == null) - { - return ""; - } - else - { - return propValue.ToString(); - } - } - - /// - /// Writes the log entry. - /// - /// The sender. - /// The log entry. - private void WriteLogEntry(object sender, LogEntry logEntry) - { - TraceWriter.WriteDetailedRequestLogs(logEntry); - TraceWriter.WriteSummaryRequestLogs(logEntry); - } - - /// - /// Gets the customer ID from the request, if available. - /// - /// The request. - /// The customer ID, or an empty string if customer ID is not found. - private string GetCustomerId(TRequest request) - { - try - { - return request.GetType().GetProperty("CustomerId").GetValue( - request, null).ToString(); - } - catch - { - return ""; - } - } - - /// - /// Gets the response header. - /// - /// The type of the response. - /// The call instance. - /// The trailing response metadata headers. - private static Metadata GetResponseHeader(AsyncUnaryCall call) - where TResponse : class - { - call.ResponseHeadersAsync.Wait(); - return call.ResponseHeadersAsync.Result; - } - - /// - /// Gets the Google Ads exception. - /// - /// The aggregate exception from the task. - /// The deserialized exception, or null if the exception cannot be deserialized. - /// - private static RpcException GetGoogleAdsException(AggregateException e) - { - Assembly myAssembly = MethodBase.GetCurrentMethod().DeclaringType.Assembly; - - RpcException rpcException = e?.InnerExceptions?.FirstOrDefault( - delegate (Exception innerException) - { - return (innerException is RpcException); - } - ) as RpcException; - - if (rpcException == null) - { - return null; - } - - foreach (Metadata.Entry entry in rpcException.Trailers) - { - if (entry.Key.EndsWith(".googleadsfailure-bin")) - { - string version = entry.Key.Replace("google.ads.googleads.", "") - .Replace(".errors.googleadsfailure-bin", "").ToUpper(); - - return (RpcException) myAssembly.GetType( - $"Google.Ads.GoogleAds.{version}.Errors.GoogleAdsException") - .GetMethod("Create", BindingFlags.Public | BindingFlags.Static) - .Invoke(null, new object[] { rpcException }); - } - } - return rpcException; - } - } -} diff --git a/src/Util/Examples/ExampleRunner.cs b/src/Util/Examples/ExampleRunner.cs index f4e353034..a4ae2874f 100644 --- a/src/Util/Examples/ExampleRunner.cs +++ b/src/Util/Examples/ExampleRunner.cs @@ -35,10 +35,11 @@ public class ExampleRunner new SortedDictionary(StringComparer.OrdinalIgnoreCase); /// - /// Finds the code examples. + /// Finds the code examples in a given assembly. /// - /// The assembly. - public void LoadCodeExamples(Assembly assembly) + /// The assembly to search for. + /// List of types to exclude. + public void LoadCodeExamples(Assembly assembly, SystemType[] typesToExclude) { lock (codeExampleMap) { @@ -47,7 +48,7 @@ public void LoadCodeExamples(Assembly assembly) foreach (SystemType type in types) { - if (type.IsSubclassOf(typeof(ExampleBase))) + if (type.IsSubclassOf(typeof(ExampleBase)) && !typesToExclude.Contains(type)) { ExampleBase example = (ExampleBase) Activator.CreateInstance(type); codeExampleMap.Add(example.Name, example); @@ -56,6 +57,12 @@ public void LoadCodeExamples(Assembly assembly) } } + /// + /// Finds the code examples in a given assembly. + /// + /// The assembly to search for. + public void LoadCodeExamples(Assembly assembly) => LoadCodeExamples(assembly, new SystemType[] { }); + /// /// Prints the list of available code examples. /// diff --git a/src/V1/GoogleAdsException.cs b/src/V1/GoogleAdsException.cs index 39e220b9b..18b71fd1b 100644 --- a/src/V1/GoogleAdsException.cs +++ b/src/V1/GoogleAdsException.cs @@ -12,74 +12,32 @@ // See the License for the specific language governing permissions and // limitations under the License. -using Google.Protobuf; +using Google.Ads.GoogleAds.Lib; using Grpc.Core; -using Newtonsoft.Json; -using Newtonsoft.Json.Linq; +using System; +using System.Linq; +using System.Reflection; namespace Google.Ads.GoogleAds.V1.Errors { /// /// Exception thrown in response to an API error from the GoogleAds servers. /// - public sealed class GoogleAdsException : RpcException + public sealed class GoogleAdsException : GoogleAdsBaseException { - /// - /// The gRPC metadata key name for the serialized failure object. - /// - public const string FAILURE_KEY = "google.ads.googleads.v1.errors.googleadsfailure-bin"; - - /// - /// The gRPC metadata key name for request ID. - /// - public const string REQUEST_ID_KEY = "request-id"; - - /// - /// Gets the Google Ads failure details. - /// - public GoogleAdsFailure Failure - { - get; - } - - /// - /// Gets the request ID. - /// - public string RequestId - { - get; - } - /// /// Initializes a new instance of the class. /// /// Resulting status of a call. - /// Response trailing metadata. - private GoogleAdsException(Status status, Metadata trailers) : base(status, trailers) - { - foreach (Metadata.Entry entry in trailers) - { - switch (entry.Key) - { - case FAILURE_KEY: - Failure = GoogleAdsFailure.Parser.ParseFrom(entry.ValueBytes); - break; - - case REQUEST_ID_KEY: - RequestId = entry.Value; - break; - } - } - } + /// The exception message. + private GoogleAdsException(Status status, string message) : base(status, message) { } /// /// Initializes a new instance of the class. /// /// Resulting status of a call. - /// The exception message. - private GoogleAdsException(Status status, string message) : base(status, message) - { - } + /// Response trailing metadata. + private GoogleAdsException(Status status, Metadata trailers) : base(status, trailers) { } /// /// Creates a new instance of the class from an @@ -87,7 +45,7 @@ private GoogleAdsException(Status status, string message) : base(status, message /// /// The original gRPC exception. /// - public static GoogleAdsException Create(RpcException rpcException) + public static GoogleAdsBaseException Create(RpcException rpcException) { return (rpcException.Trailers != null) ? new GoogleAdsException(rpcException.Status, rpcException.Trailers) @@ -95,26 +53,17 @@ public static GoogleAdsException Create(RpcException rpcException) } /// - /// Returns a that represents this instance. + /// Extracts a from an /// - /// - /// A that represents this instance. - /// - public override string ToString() + /// The aggregate exception. + /// An underlying GoogleAdsException if present, or null if one + /// is missing. + public static GoogleAdsException FromTaskException(AggregateException ae) { - JObject jsonObject = new JObject( - new JProperty("StatusCode", this.StatusCode), - new JProperty("Details", this.Status.Detail), - new JProperty("RequestId", this.RequestId) - ); - - if (this.Failure != null) + return ae.Flatten().InnerExceptions.Where((Exception ex) => { - jsonObject.Add(new JProperty("Failure", JObject.Parse( - JsonFormatter.ToDiagnosticString(this.Failure)))); - } - - return JsonConvert.SerializeObject(jsonObject, Formatting.Indented); + return ex is GoogleAdsException; + }).FirstOrDefault() as GoogleAdsException; } } -} +} \ No newline at end of file diff --git a/src/V1/Stubs/AccountBudgetProposalServiceClientExceptionCustomization.cs b/src/V1/Stubs/AccountBudgetProposalServiceClientExceptionCustomization.cs deleted file mode 100644 index 564e3798c..000000000 --- a/src/V1/Stubs/AccountBudgetProposalServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AccountBudgetProposalServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AccountBudgetServiceClientExceptionCustomization.cs b/src/V1/Stubs/AccountBudgetServiceClientExceptionCustomization.cs deleted file mode 100644 index f60c5c72a..000000000 --- a/src/V1/Stubs/AccountBudgetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AccountBudgetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupAdLabelServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupAdLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index cb7239974..000000000 --- a/src/V1/Stubs/AdGroupAdLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupAdLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupAdServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupAdServiceClientExceptionCustomization.cs deleted file mode 100644 index 5a44ce71d..000000000 --- a/src/V1/Stubs/AdGroupAdServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupAdServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupAudienceViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupAudienceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index ceaa18934..000000000 --- a/src/V1/Stubs/AdGroupAudienceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupAudienceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupBidModifierServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupBidModifierServiceClientExceptionCustomization.cs deleted file mode 100644 index e6b323ba1..000000000 --- a/src/V1/Stubs/AdGroupBidModifierServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupBidModifierServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupCriterionLabelServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupCriterionLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index 0b9e9a2be..000000000 --- a/src/V1/Stubs/AdGroupCriterionLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupCriterionLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupCriterionServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupCriterionServiceClientExceptionCustomization.cs deleted file mode 100644 index 075b56c44..000000000 --- a/src/V1/Stubs/AdGroupCriterionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupCriterionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupCriterionSimulationServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupCriterionSimulationServiceClientExceptionCustomization.cs deleted file mode 100644 index 4eeb10c20..000000000 --- a/src/V1/Stubs/AdGroupCriterionSimulationServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupCriterionSimulationServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupExtensionSettingServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupExtensionSettingServiceClientExceptionCustomization.cs deleted file mode 100644 index 47d811fe4..000000000 --- a/src/V1/Stubs/AdGroupExtensionSettingServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupExtensionSettingServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupFeedServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupFeedServiceClientExceptionCustomization.cs deleted file mode 100644 index 92d96bfe1..000000000 --- a/src/V1/Stubs/AdGroupFeedServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupFeedServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupLabelServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index 853299e0c..000000000 --- a/src/V1/Stubs/AdGroupLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupServiceClientExceptionCustomization.cs deleted file mode 100644 index 5c540986b..000000000 --- a/src/V1/Stubs/AdGroupServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdGroupSimulationServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdGroupSimulationServiceClientExceptionCustomization.cs deleted file mode 100644 index f791a3b7b..000000000 --- a/src/V1/Stubs/AdGroupSimulationServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdGroupSimulationServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdParameterServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdParameterServiceClientExceptionCustomization.cs deleted file mode 100644 index e56886465..000000000 --- a/src/V1/Stubs/AdParameterServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdParameterServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AdScheduleViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/AdScheduleViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 8748c29c9..000000000 --- a/src/V1/Stubs/AdScheduleViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AdScheduleViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AgeRangeViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/AgeRangeViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 94796d1f9..000000000 --- a/src/V1/Stubs/AgeRangeViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AgeRangeViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/AssetServiceClientExceptionCustomization.cs b/src/V1/Stubs/AssetServiceClientExceptionCustomization.cs deleted file mode 100644 index 483574896..000000000 --- a/src/V1/Stubs/AssetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class AssetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/BiddingStrategyServiceClientExceptionCustomization.cs b/src/V1/Stubs/BiddingStrategyServiceClientExceptionCustomization.cs deleted file mode 100644 index 37597cc69..000000000 --- a/src/V1/Stubs/BiddingStrategyServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class BiddingStrategyServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/BillingSetupServiceClientExceptionCustomization.cs b/src/V1/Stubs/BillingSetupServiceClientExceptionCustomization.cs deleted file mode 100644 index c2a412bfa..000000000 --- a/src/V1/Stubs/BillingSetupServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class BillingSetupServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignAudienceViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignAudienceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 9b8ceaece..000000000 --- a/src/V1/Stubs/CampaignAudienceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignAudienceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignBidModifierServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignBidModifierServiceClientExceptionCustomization.cs deleted file mode 100644 index 5921c2947..000000000 --- a/src/V1/Stubs/CampaignBidModifierServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignBidModifierServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignBudgetServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignBudgetServiceClientExceptionCustomization.cs deleted file mode 100644 index c5f919499..000000000 --- a/src/V1/Stubs/CampaignBudgetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignBudgetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignCriterionServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignCriterionServiceClientExceptionCustomization.cs deleted file mode 100644 index 53d39a60f..000000000 --- a/src/V1/Stubs/CampaignCriterionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignCriterionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignCriterionSimulationServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignCriterionSimulationServiceClientExceptionCustomization.cs deleted file mode 100644 index 5b3e44953..000000000 --- a/src/V1/Stubs/CampaignCriterionSimulationServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignCriterionSimulationServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignDraftServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignDraftServiceClientExceptionCustomization.cs deleted file mode 100644 index f83e4b4c6..000000000 --- a/src/V1/Stubs/CampaignDraftServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignDraftServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignExperimentServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignExperimentServiceClientExceptionCustomization.cs deleted file mode 100644 index dcb6b4bd2..000000000 --- a/src/V1/Stubs/CampaignExperimentServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignExperimentServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignExtensionSettingServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignExtensionSettingServiceClientExceptionCustomization.cs deleted file mode 100644 index cae61d0b6..000000000 --- a/src/V1/Stubs/CampaignExtensionSettingServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignExtensionSettingServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignFeedServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignFeedServiceClientExceptionCustomization.cs deleted file mode 100644 index a05e4fb4a..000000000 --- a/src/V1/Stubs/CampaignFeedServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignFeedServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignLabelServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index adcfbfd33..000000000 --- a/src/V1/Stubs/CampaignLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignServiceClientExceptionCustomization.cs deleted file mode 100644 index 23b7bf8ad..000000000 --- a/src/V1/Stubs/CampaignServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CampaignSharedSetServiceClientExceptionCustomization.cs b/src/V1/Stubs/CampaignSharedSetServiceClientExceptionCustomization.cs deleted file mode 100644 index ee5971b5f..000000000 --- a/src/V1/Stubs/CampaignSharedSetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CampaignSharedSetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CarrierConstantServiceClientExceptionCustomization.cs b/src/V1/Stubs/CarrierConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 292983990..000000000 --- a/src/V1/Stubs/CarrierConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CarrierConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ChangeStatusServiceClientExceptionCustomization.cs b/src/V1/Stubs/ChangeStatusServiceClientExceptionCustomization.cs deleted file mode 100644 index d4fa266df..000000000 --- a/src/V1/Stubs/ChangeStatusServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ChangeStatusServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ClickViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/ClickViewServiceClientExceptionCustomization.cs deleted file mode 100644 index e90325e1b..000000000 --- a/src/V1/Stubs/ClickViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ClickViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ConversionActionServiceClientExceptionCustomization.cs b/src/V1/Stubs/ConversionActionServiceClientExceptionCustomization.cs deleted file mode 100644 index 55b2635dc..000000000 --- a/src/V1/Stubs/ConversionActionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ConversionActionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ConversionAdjustmentUploadServiceClientExceptionCustomization.cs b/src/V1/Stubs/ConversionAdjustmentUploadServiceClientExceptionCustomization.cs deleted file mode 100644 index 5204f7851..000000000 --- a/src/V1/Stubs/ConversionAdjustmentUploadServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ConversionAdjustmentUploadServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ConversionUploadServiceClientExceptionCustomization.cs b/src/V1/Stubs/ConversionUploadServiceClientExceptionCustomization.cs deleted file mode 100644 index 94ad21bb5..000000000 --- a/src/V1/Stubs/ConversionUploadServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ConversionUploadServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomInterestServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomInterestServiceClientExceptionCustomization.cs deleted file mode 100644 index 1ee1bfe50..000000000 --- a/src/V1/Stubs/CustomInterestServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomInterestServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomerClientLinkServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomerClientLinkServiceClientExceptionCustomization.cs deleted file mode 100644 index 9b7f34e06..000000000 --- a/src/V1/Stubs/CustomerClientLinkServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomerClientLinkServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomerClientServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomerClientServiceClientExceptionCustomization.cs deleted file mode 100644 index 815f367f4..000000000 --- a/src/V1/Stubs/CustomerClientServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomerClientServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomerExtensionSettingServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomerExtensionSettingServiceClientExceptionCustomization.cs deleted file mode 100644 index b94329f15..000000000 --- a/src/V1/Stubs/CustomerExtensionSettingServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomerExtensionSettingServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomerFeedServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomerFeedServiceClientExceptionCustomization.cs deleted file mode 100644 index 22d40f4a6..000000000 --- a/src/V1/Stubs/CustomerFeedServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomerFeedServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomerLabelServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomerLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index ba7fbe54e..000000000 --- a/src/V1/Stubs/CustomerLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomerLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomerManagerLinkServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomerManagerLinkServiceClientExceptionCustomization.cs deleted file mode 100644 index 45039ba21..000000000 --- a/src/V1/Stubs/CustomerManagerLinkServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomerManagerLinkServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomerNegativeCriterionServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomerNegativeCriterionServiceClientExceptionCustomization.cs deleted file mode 100644 index 901f816cc..000000000 --- a/src/V1/Stubs/CustomerNegativeCriterionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomerNegativeCriterionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/CustomerServiceClientExceptionCustomization.cs b/src/V1/Stubs/CustomerServiceClientExceptionCustomization.cs deleted file mode 100644 index 98a5fdb51..000000000 --- a/src/V1/Stubs/CustomerServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class CustomerServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/DetailPlacementViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/DetailPlacementViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 6f42de292..000000000 --- a/src/V1/Stubs/DetailPlacementViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class DetailPlacementViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/DisplayKeywordViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/DisplayKeywordViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 7d02521f6..000000000 --- a/src/V1/Stubs/DisplayKeywordViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class DisplayKeywordViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/DomainCategoryServiceClientExceptionCustomization.cs b/src/V1/Stubs/DomainCategoryServiceClientExceptionCustomization.cs deleted file mode 100644 index 4a85bfc3f..000000000 --- a/src/V1/Stubs/DomainCategoryServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class DomainCategoryServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/DynamicSearchAdsSearchTermViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/DynamicSearchAdsSearchTermViewServiceClientExceptionCustomization.cs deleted file mode 100644 index a4d956bdf..000000000 --- a/src/V1/Stubs/DynamicSearchAdsSearchTermViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class DynamicSearchAdsSearchTermViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ExpandedLandingPageViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/ExpandedLandingPageViewServiceClientExceptionCustomization.cs deleted file mode 100644 index f770de3b9..000000000 --- a/src/V1/Stubs/ExpandedLandingPageViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ExpandedLandingPageViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ExtensionFeedItemServiceClientExceptionCustomization.cs b/src/V1/Stubs/ExtensionFeedItemServiceClientExceptionCustomization.cs deleted file mode 100644 index f718498d1..000000000 --- a/src/V1/Stubs/ExtensionFeedItemServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ExtensionFeedItemServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/FeedItemServiceClientExceptionCustomization.cs b/src/V1/Stubs/FeedItemServiceClientExceptionCustomization.cs deleted file mode 100644 index 157a38541..000000000 --- a/src/V1/Stubs/FeedItemServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class FeedItemServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/FeedItemTargetServiceClientExceptionCustomization.cs b/src/V1/Stubs/FeedItemTargetServiceClientExceptionCustomization.cs deleted file mode 100644 index f51883f2d..000000000 --- a/src/V1/Stubs/FeedItemTargetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class FeedItemTargetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/FeedMappingServiceClientExceptionCustomization.cs b/src/V1/Stubs/FeedMappingServiceClientExceptionCustomization.cs deleted file mode 100644 index fe04be4ef..000000000 --- a/src/V1/Stubs/FeedMappingServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class FeedMappingServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/FeedPlaceholderViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/FeedPlaceholderViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 6c111a7dc..000000000 --- a/src/V1/Stubs/FeedPlaceholderViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class FeedPlaceholderViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/FeedServiceClientExceptionCustomization.cs b/src/V1/Stubs/FeedServiceClientExceptionCustomization.cs deleted file mode 100644 index eb1898099..000000000 --- a/src/V1/Stubs/FeedServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class FeedServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/GenderViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/GenderViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 3c8728424..000000000 --- a/src/V1/Stubs/GenderViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class GenderViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/GeoTargetConstantServiceClientExceptionCustomization.cs b/src/V1/Stubs/GeoTargetConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 0ad71e482..000000000 --- a/src/V1/Stubs/GeoTargetConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class GeoTargetConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/GeographicViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/GeographicViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 6e74c70c1..000000000 --- a/src/V1/Stubs/GeographicViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class GeographicViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/GoogleAdsFieldServiceClientExceptionCustomization.cs b/src/V1/Stubs/GoogleAdsFieldServiceClientExceptionCustomization.cs deleted file mode 100644 index 46af9f706..000000000 --- a/src/V1/Stubs/GoogleAdsFieldServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class GoogleAdsFieldServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/GoogleAdsServiceClientExceptionCustomization.cs b/src/V1/Stubs/GoogleAdsServiceClientExceptionCustomization.cs deleted file mode 100644 index 6be56859f..000000000 --- a/src/V1/Stubs/GoogleAdsServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class GoogleAdsServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/GroupPlacementViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/GroupPlacementViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 78324b795..000000000 --- a/src/V1/Stubs/GroupPlacementViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class GroupPlacementViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/HotelGroupViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/HotelGroupViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 8db4b66e5..000000000 --- a/src/V1/Stubs/HotelGroupViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class HotelGroupViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/HotelPerformanceViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/HotelPerformanceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 0a8dbc5e9..000000000 --- a/src/V1/Stubs/HotelPerformanceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class HotelPerformanceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/KeywordPlanAdGroupServiceClientExceptionCustomization.cs b/src/V1/Stubs/KeywordPlanAdGroupServiceClientExceptionCustomization.cs deleted file mode 100644 index 006a0e6ed..000000000 --- a/src/V1/Stubs/KeywordPlanAdGroupServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class KeywordPlanAdGroupServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/KeywordPlanCampaignServiceClientExceptionCustomization.cs b/src/V1/Stubs/KeywordPlanCampaignServiceClientExceptionCustomization.cs deleted file mode 100644 index 3609f5922..000000000 --- a/src/V1/Stubs/KeywordPlanCampaignServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class KeywordPlanCampaignServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/KeywordPlanIdeaServiceClientExceptionCustomization.cs b/src/V1/Stubs/KeywordPlanIdeaServiceClientExceptionCustomization.cs deleted file mode 100644 index 336bf1ce0..000000000 --- a/src/V1/Stubs/KeywordPlanIdeaServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class KeywordPlanIdeaServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/KeywordPlanKeywordServiceClientExceptionCustomization.cs b/src/V1/Stubs/KeywordPlanKeywordServiceClientExceptionCustomization.cs deleted file mode 100644 index 638e5781a..000000000 --- a/src/V1/Stubs/KeywordPlanKeywordServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class KeywordPlanKeywordServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/KeywordPlanNegativeKeywordServiceClientExceptionCustomization.cs b/src/V1/Stubs/KeywordPlanNegativeKeywordServiceClientExceptionCustomization.cs deleted file mode 100644 index 72cc19f24..000000000 --- a/src/V1/Stubs/KeywordPlanNegativeKeywordServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class KeywordPlanNegativeKeywordServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/KeywordPlanServiceClientExceptionCustomization.cs b/src/V1/Stubs/KeywordPlanServiceClientExceptionCustomization.cs deleted file mode 100644 index 9c209f42b..000000000 --- a/src/V1/Stubs/KeywordPlanServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class KeywordPlanServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/KeywordViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/KeywordViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 2ff0f802a..000000000 --- a/src/V1/Stubs/KeywordViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class KeywordViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/LabelServiceClientExceptionCustomization.cs b/src/V1/Stubs/LabelServiceClientExceptionCustomization.cs deleted file mode 100644 index 0a43c9251..000000000 --- a/src/V1/Stubs/LabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class LabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/LandingPageViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/LandingPageViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 4e13bd124..000000000 --- a/src/V1/Stubs/LandingPageViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class LandingPageViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/LanguageConstantServiceClientExceptionCustomization.cs b/src/V1/Stubs/LanguageConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 754a66b2d..000000000 --- a/src/V1/Stubs/LanguageConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class LanguageConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/LocationViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/LocationViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 0cab5bc76..000000000 --- a/src/V1/Stubs/LocationViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class LocationViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ManagedPlacementViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/ManagedPlacementViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 8eac31b50..000000000 --- a/src/V1/Stubs/ManagedPlacementViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ManagedPlacementViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/MediaFileServiceClientExceptionCustomization.cs b/src/V1/Stubs/MediaFileServiceClientExceptionCustomization.cs deleted file mode 100644 index 5084c77c7..000000000 --- a/src/V1/Stubs/MediaFileServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class MediaFileServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/MerchantCenterLinkServiceClientExceptionCustomization.cs b/src/V1/Stubs/MerchantCenterLinkServiceClientExceptionCustomization.cs deleted file mode 100644 index 642a792ca..000000000 --- a/src/V1/Stubs/MerchantCenterLinkServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class MerchantCenterLinkServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/MobileAppCategoryConstantServiceClientExceptionCustomization.cs b/src/V1/Stubs/MobileAppCategoryConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index a317e2ee5..000000000 --- a/src/V1/Stubs/MobileAppCategoryConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class MobileAppCategoryConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/MobileDeviceConstantServiceClientExceptionCustomization.cs b/src/V1/Stubs/MobileDeviceConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index b51b68688..000000000 --- a/src/V1/Stubs/MobileDeviceConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class MobileDeviceConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/MutateJobServiceClientExceptionCustomization.cs b/src/V1/Stubs/MutateJobServiceClientExceptionCustomization.cs deleted file mode 100644 index 51e46880f..000000000 --- a/src/V1/Stubs/MutateJobServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class MutateJobServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/OperatingSystemVersionConstantServiceClientExceptionCustomization.cs b/src/V1/Stubs/OperatingSystemVersionConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 68f4f8b12..000000000 --- a/src/V1/Stubs/OperatingSystemVersionConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class OperatingSystemVersionConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/PaidOrganicSearchTermViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/PaidOrganicSearchTermViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 1a1b11484..000000000 --- a/src/V1/Stubs/PaidOrganicSearchTermViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class PaidOrganicSearchTermViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ParentalStatusViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/ParentalStatusViewServiceClientExceptionCustomization.cs deleted file mode 100644 index f18fdae5b..000000000 --- a/src/V1/Stubs/ParentalStatusViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ParentalStatusViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/PaymentsAccountServiceClientExceptionCustomization.cs b/src/V1/Stubs/PaymentsAccountServiceClientExceptionCustomization.cs deleted file mode 100644 index 4f1cc99e1..000000000 --- a/src/V1/Stubs/PaymentsAccountServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class PaymentsAccountServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ProductBiddingCategoryConstantServiceClientExceptionCustomization.cs b/src/V1/Stubs/ProductBiddingCategoryConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index a1250b854..000000000 --- a/src/V1/Stubs/ProductBiddingCategoryConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ProductBiddingCategoryConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ProductGroupViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/ProductGroupViewServiceClientExceptionCustomization.cs deleted file mode 100644 index e1977f60f..000000000 --- a/src/V1/Stubs/ProductGroupViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ProductGroupViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/RecommendationServiceClientExceptionCustomization.cs b/src/V1/Stubs/RecommendationServiceClientExceptionCustomization.cs deleted file mode 100644 index d676fa691..000000000 --- a/src/V1/Stubs/RecommendationServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class RecommendationServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/RemarketingActionServiceClientExceptionCustomization.cs b/src/V1/Stubs/RemarketingActionServiceClientExceptionCustomization.cs deleted file mode 100644 index a34de87a9..000000000 --- a/src/V1/Stubs/RemarketingActionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class RemarketingActionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/SearchTermViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/SearchTermViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 497c4f679..000000000 --- a/src/V1/Stubs/SearchTermViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class SearchTermViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/SharedCriterionServiceClientExceptionCustomization.cs b/src/V1/Stubs/SharedCriterionServiceClientExceptionCustomization.cs deleted file mode 100644 index 110a9f54d..000000000 --- a/src/V1/Stubs/SharedCriterionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class SharedCriterionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/SharedSetServiceClientExceptionCustomization.cs b/src/V1/Stubs/SharedSetServiceClientExceptionCustomization.cs deleted file mode 100644 index 15e4c8a7d..000000000 --- a/src/V1/Stubs/SharedSetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class SharedSetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/ShoppingPerformanceViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/ShoppingPerformanceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 2faff842d..000000000 --- a/src/V1/Stubs/ShoppingPerformanceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class ShoppingPerformanceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/TopicConstantServiceClientExceptionCustomization.cs b/src/V1/Stubs/TopicConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index fcc25c2f6..000000000 --- a/src/V1/Stubs/TopicConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class TopicConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/TopicViewServiceClientExceptionCustomization.cs b/src/V1/Stubs/TopicViewServiceClientExceptionCustomization.cs deleted file mode 100644 index a26c3f00b..000000000 --- a/src/V1/Stubs/TopicViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class TopicViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/UserInterestServiceClientExceptionCustomization.cs b/src/V1/Stubs/UserInterestServiceClientExceptionCustomization.cs deleted file mode 100644 index 1cbc7bdb6..000000000 --- a/src/V1/Stubs/UserInterestServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class UserInterestServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/UserListServiceClientExceptionCustomization.cs b/src/V1/Stubs/UserListServiceClientExceptionCustomization.cs deleted file mode 100644 index 435285d4b..000000000 --- a/src/V1/Stubs/UserListServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class UserListServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V1/Stubs/VideoServiceClientExceptionCustomization.cs b/src/V1/Stubs/VideoServiceClientExceptionCustomization.cs deleted file mode 100644 index 47de78aa3..000000000 --- a/src/V1/Stubs/VideoServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V1.Errors; -namespace Google.Ads.GoogleAds.V1.Services -{ - public partial class VideoServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/GoogleAdsException.cs b/src/V2/GoogleAdsException.cs index 68b7e31b7..f4e1ccda0 100644 --- a/src/V2/GoogleAdsException.cs +++ b/src/V2/GoogleAdsException.cs @@ -12,74 +12,32 @@ // See the License for the specific language governing permissions and // limitations under the License. -using Google.Protobuf; +using Google.Ads.GoogleAds.Lib; using Grpc.Core; -using Newtonsoft.Json; -using Newtonsoft.Json.Linq; +using System; +using System.Linq; +using System.Reflection; namespace Google.Ads.GoogleAds.V2.Errors { /// /// Exception thrown in response to an API error from the GoogleAds servers. /// - public sealed class GoogleAdsException : RpcException + public sealed class GoogleAdsException : GoogleAdsBaseException { - /// - /// The gRPC metadata key name for the serialized failure object. - /// - public const string FAILURE_KEY = "google.ads.googleads.v2.errors.googleadsfailure-bin"; - - /// - /// The gRPC metadata key name for request ID. - /// - public const string REQUEST_ID_KEY = "request-id"; - - /// - /// Gets the Google Ads failure details. - /// - public GoogleAdsFailure Failure - { - get; - } - - /// - /// Gets the request ID. - /// - public string RequestId - { - get; - } - /// /// Initializes a new instance of the class. /// /// Resulting status of a call. - /// Response trailing metadata. - private GoogleAdsException(Status status, Metadata trailers) : base(status, trailers) - { - foreach (Metadata.Entry entry in trailers) - { - switch (entry.Key) - { - case FAILURE_KEY: - Failure = GoogleAdsFailure.Parser.ParseFrom(entry.ValueBytes); - break; - - case REQUEST_ID_KEY: - RequestId = entry.Value; - break; - } - } - } + /// The exception message. + private GoogleAdsException(Status status, string message) : base(status, message) { } /// /// Initializes a new instance of the class. /// /// Resulting status of a call. - /// The exception message. - private GoogleAdsException(Status status, string message) : base(status, message) - { - } + /// Response trailing metadata. + private GoogleAdsException(Status status, Metadata trailers) : base(status, trailers) { } /// /// Creates a new instance of the class from an @@ -87,7 +45,7 @@ private GoogleAdsException(Status status, string message) : base(status, message /// /// The original gRPC exception. /// - public static GoogleAdsException Create(RpcException rpcException) + public static GoogleAdsBaseException Create(RpcException rpcException) { return (rpcException.Trailers != null) ? new GoogleAdsException(rpcException.Status, rpcException.Trailers) @@ -95,26 +53,17 @@ public static GoogleAdsException Create(RpcException rpcException) } /// - /// Returns a that represents this instance. + /// Extracts a from an /// - /// - /// A that represents this instance. - /// - public override string ToString() + /// The aggregate exception. + /// An underlying GoogleAdsException if present, or null if one + /// is missing. + public static GoogleAdsException FromTaskException(AggregateException ae) { - JObject jsonObject = new JObject( - new JProperty("StatusCode", this.StatusCode), - new JProperty("Details", this.Status.Detail), - new JProperty("RequestId", this.RequestId) - ); - - if (this.Failure != null) + return ae.Flatten().InnerExceptions.Where((Exception ex) => { - jsonObject.Add(new JProperty("Failure", JObject.Parse( - JsonFormatter.ToDiagnosticString(this.Failure)))); - } - - return JsonConvert.SerializeObject(jsonObject, Formatting.Indented); + return ex is GoogleAdsException; + }).FirstOrDefault() as GoogleAdsException; } } } diff --git a/src/V2/Stubs/AccountBudgetProposalServiceClientExceptionCustomization.cs b/src/V2/Stubs/AccountBudgetProposalServiceClientExceptionCustomization.cs deleted file mode 100644 index 50e6ec328..000000000 --- a/src/V2/Stubs/AccountBudgetProposalServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AccountBudgetProposalServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AccountBudgetServiceClientExceptionCustomization.cs b/src/V2/Stubs/AccountBudgetServiceClientExceptionCustomization.cs deleted file mode 100644 index 348d1d55e..000000000 --- a/src/V2/Stubs/AccountBudgetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AccountBudgetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupAdAssetViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupAdAssetViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 1b38cf126..000000000 --- a/src/V2/Stubs/AdGroupAdAssetViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupAdAssetViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupAdLabelServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupAdLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index d2fcab59f..000000000 --- a/src/V2/Stubs/AdGroupAdLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupAdLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupAdServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupAdServiceClientExceptionCustomization.cs deleted file mode 100644 index ce682d4f1..000000000 --- a/src/V2/Stubs/AdGroupAdServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupAdServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupAudienceViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupAudienceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index dff0b0112..000000000 --- a/src/V2/Stubs/AdGroupAudienceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupAudienceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupBidModifierServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupBidModifierServiceClientExceptionCustomization.cs deleted file mode 100644 index 7e524af39..000000000 --- a/src/V2/Stubs/AdGroupBidModifierServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupBidModifierServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupCriterionLabelServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupCriterionLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index 7b7f4cf99..000000000 --- a/src/V2/Stubs/AdGroupCriterionLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupCriterionLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupCriterionServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupCriterionServiceClientExceptionCustomization.cs deleted file mode 100644 index 155f5d584..000000000 --- a/src/V2/Stubs/AdGroupCriterionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupCriterionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupCriterionSimulationServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupCriterionSimulationServiceClientExceptionCustomization.cs deleted file mode 100644 index c4e11612b..000000000 --- a/src/V2/Stubs/AdGroupCriterionSimulationServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupCriterionSimulationServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupExtensionSettingServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupExtensionSettingServiceClientExceptionCustomization.cs deleted file mode 100644 index 65e291d88..000000000 --- a/src/V2/Stubs/AdGroupExtensionSettingServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupExtensionSettingServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupFeedServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupFeedServiceClientExceptionCustomization.cs deleted file mode 100644 index d957e64b8..000000000 --- a/src/V2/Stubs/AdGroupFeedServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupFeedServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupLabelServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index 1115f83d1..000000000 --- a/src/V2/Stubs/AdGroupLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupServiceClientExceptionCustomization.cs deleted file mode 100644 index ff538d11a..000000000 --- a/src/V2/Stubs/AdGroupServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdGroupSimulationServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdGroupSimulationServiceClientExceptionCustomization.cs deleted file mode 100644 index d391fe05c..000000000 --- a/src/V2/Stubs/AdGroupSimulationServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdGroupSimulationServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdParameterServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdParameterServiceClientExceptionCustomization.cs deleted file mode 100644 index d485e79f7..000000000 --- a/src/V2/Stubs/AdParameterServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdParameterServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdScheduleViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdScheduleViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 787f19147..000000000 --- a/src/V2/Stubs/AdScheduleViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdScheduleViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AdServiceClientExceptionCustomization.cs b/src/V2/Stubs/AdServiceClientExceptionCustomization.cs deleted file mode 100644 index a4798bbe6..000000000 --- a/src/V2/Stubs/AdServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AdServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AgeRangeViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/AgeRangeViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 959b8b163..000000000 --- a/src/V2/Stubs/AgeRangeViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AgeRangeViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/AssetServiceClientExceptionCustomization.cs b/src/V2/Stubs/AssetServiceClientExceptionCustomization.cs deleted file mode 100644 index 9c6bf2b63..000000000 --- a/src/V2/Stubs/AssetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class AssetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/BiddingStrategyServiceClientExceptionCustomization.cs b/src/V2/Stubs/BiddingStrategyServiceClientExceptionCustomization.cs deleted file mode 100644 index fad623b63..000000000 --- a/src/V2/Stubs/BiddingStrategyServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class BiddingStrategyServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/BillingSetupServiceClientExceptionCustomization.cs b/src/V2/Stubs/BillingSetupServiceClientExceptionCustomization.cs deleted file mode 100644 index d4645141e..000000000 --- a/src/V2/Stubs/BillingSetupServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class BillingSetupServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignAudienceViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignAudienceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 4e7259471..000000000 --- a/src/V2/Stubs/CampaignAudienceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignAudienceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignBidModifierServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignBidModifierServiceClientExceptionCustomization.cs deleted file mode 100644 index 85b4cdf0a..000000000 --- a/src/V2/Stubs/CampaignBidModifierServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignBidModifierServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignBudgetServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignBudgetServiceClientExceptionCustomization.cs deleted file mode 100644 index fda7a226f..000000000 --- a/src/V2/Stubs/CampaignBudgetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignBudgetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignCriterionServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignCriterionServiceClientExceptionCustomization.cs deleted file mode 100644 index 6f224930e..000000000 --- a/src/V2/Stubs/CampaignCriterionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignCriterionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignCriterionSimulationServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignCriterionSimulationServiceClientExceptionCustomization.cs deleted file mode 100644 index e8374bed0..000000000 --- a/src/V2/Stubs/CampaignCriterionSimulationServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignCriterionSimulationServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignDraftServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignDraftServiceClientExceptionCustomization.cs deleted file mode 100644 index df606079f..000000000 --- a/src/V2/Stubs/CampaignDraftServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignDraftServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignExperimentServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignExperimentServiceClientExceptionCustomization.cs deleted file mode 100644 index 3c28973eb..000000000 --- a/src/V2/Stubs/CampaignExperimentServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignExperimentServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignExtensionSettingServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignExtensionSettingServiceClientExceptionCustomization.cs deleted file mode 100644 index 1949f9785..000000000 --- a/src/V2/Stubs/CampaignExtensionSettingServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignExtensionSettingServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignFeedServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignFeedServiceClientExceptionCustomization.cs deleted file mode 100644 index bd9780e87..000000000 --- a/src/V2/Stubs/CampaignFeedServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignFeedServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignLabelServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index 312054752..000000000 --- a/src/V2/Stubs/CampaignLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignServiceClientExceptionCustomization.cs deleted file mode 100644 index 9b8993854..000000000 --- a/src/V2/Stubs/CampaignServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CampaignSharedSetServiceClientExceptionCustomization.cs b/src/V2/Stubs/CampaignSharedSetServiceClientExceptionCustomization.cs deleted file mode 100644 index 0ab913451..000000000 --- a/src/V2/Stubs/CampaignSharedSetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CampaignSharedSetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CarrierConstantServiceClientExceptionCustomization.cs b/src/V2/Stubs/CarrierConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 22a46eea9..000000000 --- a/src/V2/Stubs/CarrierConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CarrierConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ChangeStatusServiceClientExceptionCustomization.cs b/src/V2/Stubs/ChangeStatusServiceClientExceptionCustomization.cs deleted file mode 100644 index ca25c66d9..000000000 --- a/src/V2/Stubs/ChangeStatusServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ChangeStatusServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ClickViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/ClickViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 8fb8078bc..000000000 --- a/src/V2/Stubs/ClickViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ClickViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ConversionActionServiceClientExceptionCustomization.cs b/src/V2/Stubs/ConversionActionServiceClientExceptionCustomization.cs deleted file mode 100644 index 5311ec894..000000000 --- a/src/V2/Stubs/ConversionActionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ConversionActionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ConversionAdjustmentUploadServiceClientExceptionCustomization.cs b/src/V2/Stubs/ConversionAdjustmentUploadServiceClientExceptionCustomization.cs deleted file mode 100644 index 6adccc3a7..000000000 --- a/src/V2/Stubs/ConversionAdjustmentUploadServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ConversionAdjustmentUploadServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ConversionUploadServiceClientExceptionCustomization.cs b/src/V2/Stubs/ConversionUploadServiceClientExceptionCustomization.cs deleted file mode 100644 index a74f6b4d9..000000000 --- a/src/V2/Stubs/ConversionUploadServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ConversionUploadServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomInterestServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomInterestServiceClientExceptionCustomization.cs deleted file mode 100644 index 81c12e1be..000000000 --- a/src/V2/Stubs/CustomInterestServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomInterestServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomerClientLinkServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomerClientLinkServiceClientExceptionCustomization.cs deleted file mode 100644 index 89666a5d7..000000000 --- a/src/V2/Stubs/CustomerClientLinkServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomerClientLinkServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomerClientServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomerClientServiceClientExceptionCustomization.cs deleted file mode 100644 index b0d47eda2..000000000 --- a/src/V2/Stubs/CustomerClientServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomerClientServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomerExtensionSettingServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomerExtensionSettingServiceClientExceptionCustomization.cs deleted file mode 100644 index 992d8a415..000000000 --- a/src/V2/Stubs/CustomerExtensionSettingServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomerExtensionSettingServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomerFeedServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomerFeedServiceClientExceptionCustomization.cs deleted file mode 100644 index f817203af..000000000 --- a/src/V2/Stubs/CustomerFeedServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomerFeedServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomerLabelServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomerLabelServiceClientExceptionCustomization.cs deleted file mode 100644 index 95825c13f..000000000 --- a/src/V2/Stubs/CustomerLabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomerLabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomerManagerLinkServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomerManagerLinkServiceClientExceptionCustomization.cs deleted file mode 100644 index 32411abe6..000000000 --- a/src/V2/Stubs/CustomerManagerLinkServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomerManagerLinkServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomerNegativeCriterionServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomerNegativeCriterionServiceClientExceptionCustomization.cs deleted file mode 100644 index 6738157b8..000000000 --- a/src/V2/Stubs/CustomerNegativeCriterionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomerNegativeCriterionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/CustomerServiceClientExceptionCustomization.cs b/src/V2/Stubs/CustomerServiceClientExceptionCustomization.cs deleted file mode 100644 index 54b72fdea..000000000 --- a/src/V2/Stubs/CustomerServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class CustomerServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/DetailPlacementViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/DetailPlacementViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 35fdbb73e..000000000 --- a/src/V2/Stubs/DetailPlacementViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class DetailPlacementViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/DisplayKeywordViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/DisplayKeywordViewServiceClientExceptionCustomization.cs deleted file mode 100644 index a6abef38f..000000000 --- a/src/V2/Stubs/DisplayKeywordViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class DisplayKeywordViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/DistanceViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/DistanceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 915172755..000000000 --- a/src/V2/Stubs/DistanceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class DistanceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/DomainCategoryServiceClientExceptionCustomization.cs b/src/V2/Stubs/DomainCategoryServiceClientExceptionCustomization.cs deleted file mode 100644 index 5e2ad14f7..000000000 --- a/src/V2/Stubs/DomainCategoryServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class DomainCategoryServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/DynamicSearchAdsSearchTermViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/DynamicSearchAdsSearchTermViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 3f68c291b..000000000 --- a/src/V2/Stubs/DynamicSearchAdsSearchTermViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class DynamicSearchAdsSearchTermViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ExpandedLandingPageViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/ExpandedLandingPageViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 648f125b5..000000000 --- a/src/V2/Stubs/ExpandedLandingPageViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ExpandedLandingPageViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ExtensionFeedItemServiceClientExceptionCustomization.cs b/src/V2/Stubs/ExtensionFeedItemServiceClientExceptionCustomization.cs deleted file mode 100644 index 6d3bd1298..000000000 --- a/src/V2/Stubs/ExtensionFeedItemServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ExtensionFeedItemServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/FeedItemServiceClientExceptionCustomization.cs b/src/V2/Stubs/FeedItemServiceClientExceptionCustomization.cs deleted file mode 100644 index f17e2d3e6..000000000 --- a/src/V2/Stubs/FeedItemServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class FeedItemServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/FeedItemTargetServiceClientExceptionCustomization.cs b/src/V2/Stubs/FeedItemTargetServiceClientExceptionCustomization.cs deleted file mode 100644 index 6b846f292..000000000 --- a/src/V2/Stubs/FeedItemTargetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class FeedItemTargetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/FeedMappingServiceClientExceptionCustomization.cs b/src/V2/Stubs/FeedMappingServiceClientExceptionCustomization.cs deleted file mode 100644 index 2643bd504..000000000 --- a/src/V2/Stubs/FeedMappingServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class FeedMappingServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/FeedPlaceholderViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/FeedPlaceholderViewServiceClientExceptionCustomization.cs deleted file mode 100644 index cfb4ab62c..000000000 --- a/src/V2/Stubs/FeedPlaceholderViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class FeedPlaceholderViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/FeedServiceClientExceptionCustomization.cs b/src/V2/Stubs/FeedServiceClientExceptionCustomization.cs deleted file mode 100644 index 47a6fba62..000000000 --- a/src/V2/Stubs/FeedServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class FeedServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/GenderViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/GenderViewServiceClientExceptionCustomization.cs deleted file mode 100644 index d6b46cb13..000000000 --- a/src/V2/Stubs/GenderViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class GenderViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/GeoTargetConstantServiceClientExceptionCustomization.cs b/src/V2/Stubs/GeoTargetConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 6d626a28d..000000000 --- a/src/V2/Stubs/GeoTargetConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class GeoTargetConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/GeographicViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/GeographicViewServiceClientExceptionCustomization.cs deleted file mode 100644 index fa23212f6..000000000 --- a/src/V2/Stubs/GeographicViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class GeographicViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/GoogleAdsFieldServiceClientExceptionCustomization.cs b/src/V2/Stubs/GoogleAdsFieldServiceClientExceptionCustomization.cs deleted file mode 100644 index d5f44a3ad..000000000 --- a/src/V2/Stubs/GoogleAdsFieldServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class GoogleAdsFieldServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/GoogleAdsServiceClientExceptionCustomization.cs b/src/V2/Stubs/GoogleAdsServiceClientExceptionCustomization.cs deleted file mode 100644 index cfaea3836..000000000 --- a/src/V2/Stubs/GoogleAdsServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class GoogleAdsServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/GroupPlacementViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/GroupPlacementViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 7cb801a44..000000000 --- a/src/V2/Stubs/GroupPlacementViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class GroupPlacementViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/HotelGroupViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/HotelGroupViewServiceClientExceptionCustomization.cs deleted file mode 100644 index cd4beac3c..000000000 --- a/src/V2/Stubs/HotelGroupViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class HotelGroupViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/HotelPerformanceViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/HotelPerformanceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index ad9069091..000000000 --- a/src/V2/Stubs/HotelPerformanceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class HotelPerformanceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/InvoiceServiceClientExceptionCustomization.cs b/src/V2/Stubs/InvoiceServiceClientExceptionCustomization.cs deleted file mode 100644 index ddfa299eb..000000000 --- a/src/V2/Stubs/InvoiceServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class InvoiceServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/KeywordPlanAdGroupServiceClientExceptionCustomization.cs b/src/V2/Stubs/KeywordPlanAdGroupServiceClientExceptionCustomization.cs deleted file mode 100644 index da25e6680..000000000 --- a/src/V2/Stubs/KeywordPlanAdGroupServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class KeywordPlanAdGroupServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/KeywordPlanCampaignServiceClientExceptionCustomization.cs b/src/V2/Stubs/KeywordPlanCampaignServiceClientExceptionCustomization.cs deleted file mode 100644 index 35bb3b285..000000000 --- a/src/V2/Stubs/KeywordPlanCampaignServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class KeywordPlanCampaignServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/KeywordPlanIdeaServiceClientExceptionCustomization.cs b/src/V2/Stubs/KeywordPlanIdeaServiceClientExceptionCustomization.cs deleted file mode 100644 index db7e01a1d..000000000 --- a/src/V2/Stubs/KeywordPlanIdeaServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class KeywordPlanIdeaServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/KeywordPlanKeywordServiceClientExceptionCustomization.cs b/src/V2/Stubs/KeywordPlanKeywordServiceClientExceptionCustomization.cs deleted file mode 100644 index 1edad30ef..000000000 --- a/src/V2/Stubs/KeywordPlanKeywordServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class KeywordPlanKeywordServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/KeywordPlanNegativeKeywordServiceClientExceptionCustomization.cs b/src/V2/Stubs/KeywordPlanNegativeKeywordServiceClientExceptionCustomization.cs deleted file mode 100644 index 510d853f1..000000000 --- a/src/V2/Stubs/KeywordPlanNegativeKeywordServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class KeywordPlanNegativeKeywordServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/KeywordPlanServiceClientExceptionCustomization.cs b/src/V2/Stubs/KeywordPlanServiceClientExceptionCustomization.cs deleted file mode 100644 index 95e91a1eb..000000000 --- a/src/V2/Stubs/KeywordPlanServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class KeywordPlanServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/KeywordViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/KeywordViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 2e45b06b1..000000000 --- a/src/V2/Stubs/KeywordViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class KeywordViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/LabelServiceClientExceptionCustomization.cs b/src/V2/Stubs/LabelServiceClientExceptionCustomization.cs deleted file mode 100644 index 6d79eb06c..000000000 --- a/src/V2/Stubs/LabelServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class LabelServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/LandingPageViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/LandingPageViewServiceClientExceptionCustomization.cs deleted file mode 100644 index c0ed631e6..000000000 --- a/src/V2/Stubs/LandingPageViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class LandingPageViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/LanguageConstantServiceClientExceptionCustomization.cs b/src/V2/Stubs/LanguageConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 51d575f3f..000000000 --- a/src/V2/Stubs/LanguageConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class LanguageConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/LocationViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/LocationViewServiceClientExceptionCustomization.cs deleted file mode 100644 index fcc3ae4af..000000000 --- a/src/V2/Stubs/LocationViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class LocationViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ManagedPlacementViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/ManagedPlacementViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 0d4712bc9..000000000 --- a/src/V2/Stubs/ManagedPlacementViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ManagedPlacementViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/MediaFileServiceClientExceptionCustomization.cs b/src/V2/Stubs/MediaFileServiceClientExceptionCustomization.cs deleted file mode 100644 index 1752b1953..000000000 --- a/src/V2/Stubs/MediaFileServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class MediaFileServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/MerchantCenterLinkServiceClientExceptionCustomization.cs b/src/V2/Stubs/MerchantCenterLinkServiceClientExceptionCustomization.cs deleted file mode 100644 index 373f58b67..000000000 --- a/src/V2/Stubs/MerchantCenterLinkServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class MerchantCenterLinkServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/MobileAppCategoryConstantServiceClientExceptionCustomization.cs b/src/V2/Stubs/MobileAppCategoryConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index a017117b4..000000000 --- a/src/V2/Stubs/MobileAppCategoryConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class MobileAppCategoryConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/MobileDeviceConstantServiceClientExceptionCustomization.cs b/src/V2/Stubs/MobileDeviceConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index accdc1514..000000000 --- a/src/V2/Stubs/MobileDeviceConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class MobileDeviceConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/MutateJobServiceClientExceptionCustomization.cs b/src/V2/Stubs/MutateJobServiceClientExceptionCustomization.cs deleted file mode 100644 index 68317ab23..000000000 --- a/src/V2/Stubs/MutateJobServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class MutateJobServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/OperatingSystemVersionConstantServiceClientExceptionCustomization.cs b/src/V2/Stubs/OperatingSystemVersionConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 9211d27cc..000000000 --- a/src/V2/Stubs/OperatingSystemVersionConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class OperatingSystemVersionConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/PaidOrganicSearchTermViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/PaidOrganicSearchTermViewServiceClientExceptionCustomization.cs deleted file mode 100644 index eb36a7f67..000000000 --- a/src/V2/Stubs/PaidOrganicSearchTermViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class PaidOrganicSearchTermViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ParentalStatusViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/ParentalStatusViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 516c85c17..000000000 --- a/src/V2/Stubs/ParentalStatusViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ParentalStatusViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/PaymentsAccountServiceClientExceptionCustomization.cs b/src/V2/Stubs/PaymentsAccountServiceClientExceptionCustomization.cs deleted file mode 100644 index 4a6e988bf..000000000 --- a/src/V2/Stubs/PaymentsAccountServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class PaymentsAccountServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ProductBiddingCategoryConstantServiceClientExceptionCustomization.cs b/src/V2/Stubs/ProductBiddingCategoryConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 630974628..000000000 --- a/src/V2/Stubs/ProductBiddingCategoryConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ProductBiddingCategoryConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ProductGroupViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/ProductGroupViewServiceClientExceptionCustomization.cs deleted file mode 100644 index c78a26655..000000000 --- a/src/V2/Stubs/ProductGroupViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ProductGroupViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ReachPlanServiceClientExceptionCustomization.cs b/src/V2/Stubs/ReachPlanServiceClientExceptionCustomization.cs deleted file mode 100644 index 228608c74..000000000 --- a/src/V2/Stubs/ReachPlanServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ReachPlanServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/RecommendationServiceClientExceptionCustomization.cs b/src/V2/Stubs/RecommendationServiceClientExceptionCustomization.cs deleted file mode 100644 index 53f22fb6c..000000000 --- a/src/V2/Stubs/RecommendationServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class RecommendationServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/RemarketingActionServiceClientExceptionCustomization.cs b/src/V2/Stubs/RemarketingActionServiceClientExceptionCustomization.cs deleted file mode 100644 index b5b333f1c..000000000 --- a/src/V2/Stubs/RemarketingActionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class RemarketingActionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/SearchTermViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/SearchTermViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 872ec9b1a..000000000 --- a/src/V2/Stubs/SearchTermViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class SearchTermViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/SharedCriterionServiceClientExceptionCustomization.cs b/src/V2/Stubs/SharedCriterionServiceClientExceptionCustomization.cs deleted file mode 100644 index 46dbc4752..000000000 --- a/src/V2/Stubs/SharedCriterionServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class SharedCriterionServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/SharedSetServiceClientExceptionCustomization.cs b/src/V2/Stubs/SharedSetServiceClientExceptionCustomization.cs deleted file mode 100644 index d319eec2f..000000000 --- a/src/V2/Stubs/SharedSetServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class SharedSetServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/ShoppingPerformanceViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/ShoppingPerformanceViewServiceClientExceptionCustomization.cs deleted file mode 100644 index dd5c8cd96..000000000 --- a/src/V2/Stubs/ShoppingPerformanceViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class ShoppingPerformanceViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/TopicConstantServiceClientExceptionCustomization.cs b/src/V2/Stubs/TopicConstantServiceClientExceptionCustomization.cs deleted file mode 100644 index 2dfd3a96d..000000000 --- a/src/V2/Stubs/TopicConstantServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class TopicConstantServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/TopicViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/TopicViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 57f5b78e1..000000000 --- a/src/V2/Stubs/TopicViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class TopicViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/UserInterestServiceClientExceptionCustomization.cs b/src/V2/Stubs/UserInterestServiceClientExceptionCustomization.cs deleted file mode 100644 index 57f5016ff..000000000 --- a/src/V2/Stubs/UserInterestServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class UserInterestServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/UserListServiceClientExceptionCustomization.cs b/src/V2/Stubs/UserListServiceClientExceptionCustomization.cs deleted file mode 100644 index a4a5122c1..000000000 --- a/src/V2/Stubs/UserListServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class UserListServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/UserLocationViewServiceClientExceptionCustomization.cs b/src/V2/Stubs/UserLocationViewServiceClientExceptionCustomization.cs deleted file mode 100644 index 6bf8beb48..000000000 --- a/src/V2/Stubs/UserLocationViewServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class UserLocationViewServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V2/Stubs/VideoServiceClientExceptionCustomization.cs b/src/V2/Stubs/VideoServiceClientExceptionCustomization.cs deleted file mode 100644 index 1f96b9572..000000000 --- a/src/V2/Stubs/VideoServiceClientExceptionCustomization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Google LLC. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// Generated code - do not edit -using Google.Api.Gax.Grpc; -using Google.Protobuf; -using Google.Ads.GoogleAds.V2.Errors; -namespace Google.Ads.GoogleAds.V2.Services -{ - public partial class VideoServiceClientImpl - { - // Modify every API call on construction to use GoogleAdsException - partial void Modify_ApiCall(ref ApiCall call) - where TRequest : class, IMessage - where TResponse : class, IMessage => - call = call.WithExceptionCustomizer(GoogleAdsException.Create); - } -} diff --git a/src/V3/GoogleAdsException.cs b/src/V3/GoogleAdsException.cs new file mode 100644 index 000000000..bf10017ba --- /dev/null +++ b/src/V3/GoogleAdsException.cs @@ -0,0 +1,69 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; +using Grpc.Core; +using System; +using System.Linq; +using System.Reflection; + +namespace Google.Ads.GoogleAds.V3.Errors +{ + /// + /// Exception thrown in response to an API error from the GoogleAds servers. + /// + public sealed class GoogleAdsException : GoogleAdsBaseException + { + /// + /// Initializes a new instance of the class. + /// + /// Resulting status of a call. + /// The exception message. + private GoogleAdsException(Status status, string message) : base(status, message) { } + + /// + /// Initializes a new instance of the class. + /// + /// Resulting status of a call. + /// Response trailing metadata. + private GoogleAdsException(Status status, Metadata trailers) : base(status, trailers) { } + + /// + /// Creates a new instance of the class from an + /// . + /// + /// The original gRPC exception. + /// + public static GoogleAdsBaseException Create(RpcException rpcException) + { + return (rpcException.Trailers != null) + ? new GoogleAdsException(rpcException.Status, rpcException.Trailers) + : new GoogleAdsException(rpcException.Status, rpcException.Message); + } + + /// + /// Extracts a from an + /// + /// The aggregate exception. + /// An underlying GoogleAdsException if present, or null if one + /// is missing. + public static GoogleAdsException FromTaskException(AggregateException ae) + { + return ae.Flatten().InnerExceptions.Where((Exception ex) => + { + return ex is GoogleAdsException; + }).FirstOrDefault() as GoogleAdsException; + } + } +} diff --git a/src/V3/GoogleAdsFailureExtensions.cs b/src/V3/GoogleAdsFailureExtensions.cs new file mode 100644 index 000000000..d5b85b727 --- /dev/null +++ b/src/V3/GoogleAdsFailureExtensions.cs @@ -0,0 +1,73 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using System.Collections.Generic; +using System.Linq; + +namespace Google.Ads.GoogleAds.V3.Errors +{ + partial class GoogleAdsFailure + { + /// + /// The operations fieldname. + /// + private const string OPERATIONS_FIELDNAME = "operations"; + + /// + /// Gets the errors for a given operation index. + /// + /// Index of the operation. + /// The list of errors. + public List GetErrorsByOperationIndex(long operationIndex) + { + return this.Errors.ToList().Where(delegate (GoogleAdsError error) + { + if (error.Location == null) + { + return false; + } + return error.Location.FieldPathElements.Any(fpElement => + fpElement.FieldName == OPERATIONS_FIELDNAME && + fpElement.Index.HasValue && + fpElement.Index.Value == operationIndex); + }).ToList(); + } + } + + public partial class GoogleAdsError + { + /// + /// Gets the combined field path. + /// + public string CombinedFieldPath + { + get + { + if (this.Location == null) + { + return ""; + } + List fieldPaths = this.Location.FieldPathElements.Select(fpElement => + { + return (fpElement.Index.HasValue) ? + $"{fpElement.FieldName}[{fpElement.Index}]" : + fpElement.FieldName; + } + ).ToList(); + + return string.Join(".", fieldPaths); + } + } + } +} diff --git a/src/V3/ResourceNames.cs b/src/V3/ResourceNames.cs new file mode 100644 index 000000000..bc4c8b5af --- /dev/null +++ b/src/V3/ResourceNames.cs @@ -0,0 +1,519 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the \"License\"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an \"AS IS\" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using System; +using System.Text; +using static Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types; +using static Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types; + +#pragma warning disable 1591 + +namespace Google.Ads.GoogleAds.V3.Errors +{ + /// + /// Helper class to generate resource names for various entities. + /// + public class ResourceNames + { + public static string AccountBudgetProposal(long customerId, long accountBudgetProposalId) + { + return $"customers/{customerId}/accountBudgetProposals/{accountBudgetProposalId}"; + } + + public static string AdGroup(long customerId, long adGroupId) + { + return $"customers/{customerId}/adGroups/{adGroupId}"; + } + + public static string AdGroupAd(long customerId, long adGroupId, long adId) + { + return $"customers/{customerId}/adGroupAds/{adGroupId}~{adId}"; + } + + public static string AdGroupAdLabel(long customerId, long adGroupId, long adId, long labelId) + { + return $"customers/{customerId}/adGroupAdLabels/{adGroupId}~{adId}~{labelId}"; + } + + public static string AdGroupAudienceView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/adGroupAudienceViews/{adGroupId}~{criterionId}"; + } + + public static string AdGroupBidModifier(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/adGroupBidModifiers/{adGroupId}~{criterionId}"; + } + + public static string AdGroupCriterion(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/adGroupCriteria/{adGroupId}~{criterionId}"; + } + + public static string AdGroupCriterionLabel(long customerId, long adGroupId, long criterionId, long labelId) + { + return $"customers/{customerId}/adGroupCriterionLabels/{adGroupId}~{criterionId}~{labelId}"; + } + + public static string AdGroupExtensionSetting(long customerId, long adGroupId, ExtensionType extensionType) + { + return $"customers/{customerId}/adGroupExtensionSettings/{adGroupId}~{extensionType}"; + } + + public static string AdGroupFeed(long customerId, long adGroupId, long feedId) + { + return $"customers/{customerId}/adGroupFeeds/{adGroupId}~{feedId}"; + } + + public static string AdGroupLabel(long customerId, long adGroupId, long labelId) + { + return $"customers/{customerId}/adGroupLabels/{adGroupId}~{labelId}"; + } + + public static string AdParameter(long customerId, long adGroupId, long criterionId, long parameterIndex) + { + return $"customers/{customerId}/adParameters/{adGroupId}~{criterionId}~{parameterIndex}"; + } + + public static string AdScheduleView(long customerId, long campaignId, long criterionId) + { + return $"customers/{customerId}/adScheduleViews/{campaignId}~{criterionId}"; + } + + public static string AgeRangeView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/ageRangeViews/{adGroupId}~{criterionId}"; + } + + public static string Asset(long customerId, long assetId) + { + return $"customers/{customerId}/assets/{assetId}"; + } + + public static string BiddingStrategy(long customerId, long biddingStrategyId) + { + return $"customers/{customerId}/biddingStrategies/{biddingStrategyId}"; + } + + public static string BillingSetup(long customerId, long billingSetupId) + { + return $"customers/{customerId}/billingSetups/{billingSetupId}"; + } + + public static string Campaign(long customerId, long campaignId) + { + return $"customers/{customerId}/campaigns/{campaignId}"; + } + + public static string CampaignAudienceView(long customerId, long campaignId, long criterionId) + { + return $"customers/{customerId}/campaignAudienceViews/{campaignId}~{criterionId}"; + } + + public static string CampaignBidModifier(long customerId, long campaignId, long criterionId) + { + return $"customers/{customerId}/campaignBidModifiers/{campaignId}~{criterionId}"; + } + + public static string CampaignBudget(long customerId, long budgetId) + { + return $"customers/{customerId}/campaignBudgets/{budgetId}"; + } + + public static string CampaignDraft(long customerId, long baseCampaignId, long draftId) + { + return $"customers/{customerId}/campaignDrafts/{baseCampaignId}~{draftId}"; + } + + public static string CampaignExperiments(long customerId, long campaignExperimentId) + { + return $"customers/{customerId}/campaignExperiments/{campaignExperimentId}"; + } + + public static string CampaignCriteria(long customerId, long campaignId, long criterionId) + { + return $"customers/{customerId}/campaignCriteria/{campaignId}~{criterionId}"; + } + + public static string CampaignExtensionSetting(long customerId, long campaignId, ExtensionType extensionType) + { + return $"customers/{customerId}/campaignExtensionSettings/{campaignId}~{extensionType}"; + } + + public static string CampaignFeed(long customerId, long campaignId, long feedId) + { + return $"customers/{customerId}/campaignFeeds/{campaignId}~{feedId}"; + } + + public static string CampaignLabel(long customerId, long campaignId, long labelId) + { + return $"customers/{customerId}/campaignLabels/{campaignId}~{labelId}"; + } + + public static string CampaignSharedSet(long customerId, long campaignId, long sharedSetId) + { + return $"customers/{customerId}/campaignSharedSets/{campaignId}~{sharedSetId}"; + } + + public static string CarrierConstant(long criterionId) + { + return $"carrierConstants/{criterionId}"; + } + + public static string ChangeStatus(long customerId, long changeStatusId) + { + return $"customers/{customerId}/changeStatus/{changeStatusId}"; + } + + public static string ClickView(long customerId, DateTime date, string gclid) + { + return $"customers/{customerId}/clickViews/{date.ToString("yyyy-MM-dd")}~{gclid}"; + } + + public static string ConversionAction(long customerId, long conversionActionId) + { + return $"customers/{customerId}/conversionActions/{conversionActionId}"; + } + + public static string CurrencyConstant(string currencyCode) + { + return $"currencyConstants/{currencyCode}"; + } + + public static string CustomInterest(long customerId, long customInterestId) + { + return $"customers/{customerId}/customInterests/{customInterestId}"; + } + + public static string Customer(long customerId) + { + return $"customers/{customerId}"; + } + + public static string CustomerClient(long customerId, long clientCustomerId) + { + return $"customers/{customerId}/customerClients/{clientCustomerId}"; + } + + public static string CustomerClientLink(long customerId, long clientCustomerId, long managerLinkId) + { + return $"customers/{customerId}/customerClientLinks/{clientCustomerId}~{managerLinkId}"; + } + + public static string CustomerExtensionSetting(long customerId, ExtensionType extensionType) + { + return $"customers/{customerId}/customerExtensionSettings/{extensionType}"; + } + + public static string CustomerFeed(long customerId, long feedId) + { + return $"customers/{customerId}/customerFeeds/{feedId}"; + } + + public static string CustomerLabel(long customerId, long labelId) + { + return $"customers/{customerId}/customerLabels/{labelId}"; + } + + public static string CustomerManagerLink(long customerId, long managerCustomerId, long managerLinkId) + { + return $"customers/{customerId}/customerManagerLinks/{managerCustomerId}~{managerLinkId}"; + } + + public static string CustomerNegativeCriteria(long customerId, long criterionId) + { + return $"customers/{customerId}/customerNegativeCriteria/{criterionId}"; + } + + public static string DetailPlacementView(long customerId, long adGroupId, string placement) + { + return $"customers/{customerId}/detailPlacementViews/{adGroupId}~{Base64Encode(placement)}"; + } + + private static string Base64Encode(string text) + { + return Convert.ToBase64String(Encoding.UTF8.GetBytes(text)); + } + + public static string DisplayKeywordView(long customerId, long adGroupId, string criterionId) + { + return $"customers/{customerId}/displayKeywordViews/{adGroupId}~{criterionId}"; + } + + public static string DomainCategorie(long customerId, long campaignId, string category, string languageCode) + { + return $"customers/{customerId}/domainCategories/{campaignId}~{Base64Encode(category)}~{languageCode}"; + } + + public static string DynamicSearchAdsSearchTermView(long customerId, long adGroupId, string searchTermFp, string headlineFp, string landingPageFp, string pageUrlFp) + { + return $"customers/{customerId}/dynamicSearchAdsSearchTermViews/{adGroupId}~{searchTermFp}~{headlineFp}~{landingPageFp}~{pageUrlFp}"; + } + + public static string ExtensionFeedItem(long customerId, long feedItemId) + { + return $"customers/{customerId}/extensionFeedItems/{feedItemId}"; + } + + public static string Feed(long customerId, long feedId) + { + return $"customers/{customerId}/feeds/{feedId}"; + } + + public static string FeedItem(long customerId, long feedId, long feedItemId) + { + return $"customers/{customerId}/feedItems/{feedId}~{feedItemId}"; + } + + public static string FeedItemTarget(long customerId, long feedId, long feedItemId, FeedItemTargetType feedItemTargetType, long feedItemTargetId) + { + return $"customers/{customerId}/feedItemTargets/{feedId}~{feedItemId}~{feedItemTargetType}~{feedItemTargetId}"; + } + + public static string FeedMapping(long customerId, long feedId, long feedMappingId) + { + return $"customers/{customerId}/feedMappings/{feedId}~{feedMappingId}"; + } + + public static string FeedPlaceholderView(long customerId, PlaceholderType placeholderType) + { + return $"customers/{customerId}/feedPlaceholderViews/{placeholderType}"; + } + + public static string GenderView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/genderViews/{adGroupId}~{criterionId}"; + } + + public static string GeoTargetConstant(long geoTargetConstantId) + { + return $"geoTargetConstants/{geoTargetConstantId}"; + } + + public static string GeographicView(long customerId, long countryCriterionId, string locationType) + { + return $"customers/{customerId}/geographicViews/{countryCriterionId}~{locationType}"; + } + + public static string GoogleAdsField(string name) + { + return $"googleAdsFields/{name}"; + } + + public static string GroupPlacementView(long customerId, long adGroupId, string placement) + { + return $"customers/{customerId}/groupPlacementViews/{adGroupId}~{Base64Encode(placement)}"; + } + + public static string HotelGroupView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/hotelGroupViews/{adGroupId}~{criterionId}"; + } + + public static string HotelPerformanceView(long customerId) + { + return $"customers/{customerId}/hotelPerformanceView"; + } + + public static string KeywordPlan(long customerId, long kpPlanId) + { + return $"customers/{customerId}/keywordPlans/{kpPlanId}"; + } + + public static string KeywordPlanAdGroup(long customerId, long kpAdGroupId) + { + return $"customers/{customerId}/keywordPlanAdGroups/{kpAdGroupId}"; + } + + public static string KeywordPlanCampaign(long customerId, long kpCampaignId) + { + return $"customers/{customerId}/keywordPlanCampaigns/{kpCampaignId}"; + } + + public static string KeywordPlanKeyword(long customerId, long kpAdGroupKeywordId) + { + return $"customers/{customerId}/keywordPlanKeywords/{kpAdGroupKeywordId}"; + } + + public static string KeywordPlanNegativeKeyword(long customerId, long kpNegativeKeywordId) + { + return $"customers/{customerId}/keywordPlanNegativeKeywords/{kpNegativeKeywordId}"; + } + + public static string KeywordView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/keywordViews/{adGroupId}~{criterionId}"; + } + + public static string Label(long customerId, long labelId) + { + return $"customers/{customerId}/labels/{labelId}"; + } + + public static string LanguageConstant(long criterionId) + { + return $"languageConstants/{criterionId}"; + } + + public static string LocationView(long customerId, long campaignId, long criterionId) + { + return $"customers/{customerId}/locationViews/{campaignId}~{criterionId}"; + } + + public static string ManagedPlacementView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/managedPlacementViews/{adGroupId}~{criterionId}"; + } + + public static string MediaFile(long customerId, long mediaFileId) + { + return $"customers/{customerId}/mediaFiles/{mediaFileId}"; + } + + public static string MerchantCenterLink(long customerId, long merchantCenterId) + { + return $"customers/{customerId}/merchantCenterLinks/{merchantCenterId}"; + } + + public static string MobileAppCategoryConstant(long mobileAppCategoryId) + { + return $"mobileAppCategoryConstants/{mobileAppCategoryId}"; + } + + public static string MobileDeviceConstant(long criterionId) + { + return $"mobileDeviceConstants/{criterionId}"; + } + + public static string MobileDeviceConstant(long customerId, long mutateJobId) + { + return $"customers/{customerId}/mutateJobs/{mutateJobId}"; + } + + public static string OperatingSystemVersionConstant(long criterionId) + { + return $"operatingSystemVersionConstants/{criterionId}"; + } + + public static string ParentalStatusView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/parentalStatusViews/{adGroupId}~{criterionId}"; + } + + public static string PaymentsAccount(long customerId, long paymentsAccountId) + { + return $"customers/{customerId}/paymentsAccounts/{paymentsAccountId}"; + } + + public static string ProductBiddingCategoryConstant(string country_code, long level, long id) + { + return $"productBiddingCategoryConstants/{country_code}~{level}~{id}"; + } + + public static string ProductGroupView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/productGroupViews/{adGroupId}~{criterionId}"; + } + + public static string Recommendation(long customerId, long recommendationId) + { + return $"customers/{customerId}/recommendations/{recommendationId}"; + } + + public static string RemarketingAction(long customerId, long remarketingActionId) + { + return $"customers/{customerId}/remarketingActions/{remarketingActionId}"; + } + + public static string SearchTermView(long customerId, long campaignId, long adGroupId, string searchterm) + { + return $"customers/{customerId}/searchTermViews/{campaignId}~{adGroupId}_{Base64Encode(searchterm)}"; + } + + public static string SharedCriterion(long customerId, long sharedSetId, long criterionId) + { + return $"customers/{customerId}/sharedCriteria/{sharedSetId}~{criterionId}"; + } + + public static string SharedSet(long customerId, long sharedSetId) + { + return $"customers/{customerId}/sharedSets/{sharedSetId}"; + } + + public static string ShoppingPerformanceView(long customerId) + { + return $"customers/{customerId}/shoppingPerformanceView"; + } + + public static string TopicConstant(long topicId) + { + return $"topicConstants/{topicId}"; + } + + public static string TopicView(long customerId, long adGroupId, long criterionId) + { + return $"customers/{customerId}/topicViews/{adGroupId}~{criterionId}"; + } + + public static string UserInterest(long customerId, long userInterestId) + { + return $"customers/{customerId}/userInterests/{userInterestId}"; + } + + public static string UserList(long customerId, long userListId) + { + return $"customers/{customerId}/userLists/{userListId}"; + } + + public static string Video(long customerId, long videoId) + { + return $"customers/{customerId}/videos/{videoId}"; + } + + public static string PaidOrganicSearchTermView(long customerId, long campaignId, long adGroupId, string searchterm) + { + return $"customers/{customerId}/paidOrganicSearchTermViews/{campaignId}~{adGroupId}_{Base64Encode(searchterm)}"; + } + + public static string LandingPageView(long customerId, long campaignId, long adGroupId, string unexpandedFinalUrlFingerprint) + { + return $"customers/{customerId}/landingPageViews/{unexpandedFinalUrlFingerprint}"; + } + + public static string ExpandedLandingPageView(long customerId, long campaignId, long adGroupId, string expandedFinalUrlFingerprint) + { + return $"customers/{customerId}/expandedLandingPageViews/{expandedFinalUrlFingerprint}"; + } + + public static string CampaignCriterionSimulation(long customerId, long campaignId, long criterionId, SimulationType type, SimulationModificationMethod modificationMethod, DateTime startDate, DateTime endDate) + { + return $"customers/{customerId}/campaignCriterionSimulations/{campaignId}~{criterionId}~{type}~{modificationMethod}~{startDate.ToString("yyyy-MM-dd")}~{endDate.ToString("yyyy-MM-dd")}"; + } + + public static string AdGroupSimulation(long customerId, long adGroupId, SimulationType type, SimulationModificationMethod modificationMethod, DateTime startDate, DateTime endDate) + { + return $"customers/{customerId}/adGroupSimulations/{adGroupId}~{type}~{modificationMethod}~{startDate.ToString("yyyy-MM-dd")}~{endDate.ToString("yyyy-MM-dd")}"; + } + + public static string AdGroupCriterionSimulation(long customerId, long adGroupId, long criterionId, SimulationType type, SimulationModificationMethod modificationMethod, DateTime startDate, DateTime endDate) + { + return $"customers/{customerId}/adGroupCriterionSimulations/{adGroupId}~{criterionId}~{type}~{modificationMethod}~{startDate.ToString("yyyy-MM-dd")}~{endDate.ToString("yyyy-MM-dd")}"; + } + } +} + +#pragma warning restore 1591 diff --git a/src/V3/ServiceExtensions.cs b/src/V3/ServiceExtensions.cs new file mode 100644 index 000000000..51a4f2a03 --- /dev/null +++ b/src/V3/ServiceExtensions.cs @@ -0,0 +1,130 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; + +#pragma warning disable CS1591 + +namespace Google.Ads.GoogleAds.V3.Services +{ + public abstract partial class AccountBudgetProposalServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AccountBudgetServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupAdAssetViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupAdLabelServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupAdServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupAudienceViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupBidModifierServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupCriterionLabelServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupCriterionServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupCriterionSimulationServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupExtensionSettingServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupFeedServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupLabelServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdGroupSimulationServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdParameterServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdScheduleViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AdServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AgeRangeViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class AssetServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class BiddingStrategyServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class BillingSetupServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignAudienceViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignBidModifierServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignBudgetServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignCriterionServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignCriterionSimulationServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignDraftServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignExperimentServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignExtensionSettingServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignFeedServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignLabelServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CampaignSharedSetServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CarrierConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ChangeStatusServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ClickViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ConversionActionServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ConversionAdjustmentUploadServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ConversionUploadServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CurrencyConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomerClientLinkServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomerClientServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomerExtensionSettingServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomerFeedServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomerLabelServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomerManagerLinkServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomerNegativeCriterionServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomerServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class CustomInterestServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class DetailPlacementViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class DisplayKeywordViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class DistanceViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class DomainCategoryServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class DynamicSearchAdsSearchTermViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ExpandedLandingPageViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ExtensionFeedItemServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class FeedItemServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class FeedItemTargetServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class FeedMappingServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class FeedPlaceholderViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class FeedServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class GenderViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class GeographicViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class GeoTargetConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class GoogleAdsFieldServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class GoogleAdsServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class GroupPlacementViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class HotelGroupViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class HotelPerformanceViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class InvoiceServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class KeywordPlanAdGroupServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class KeywordPlanCampaignServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class KeywordPlanIdeaServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class KeywordPlanKeywordServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class KeywordPlanNegativeKeywordServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class KeywordPlanServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class KeywordViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class LabelServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class LandingPageViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class LanguageConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class LocationViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ManagedPlacementViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class MediaFileServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class MerchantCenterLinkServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class MobileAppCategoryConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class MobileDeviceConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class MutateJobServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class OperatingSystemVersionConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class PaidOrganicSearchTermViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ParentalStatusViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class PaymentsAccountServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ProductBiddingCategoryConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ProductGroupViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ReachPlanServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class RecommendationServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class RemarketingActionServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class SearchTermViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class SharedCriterionServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class SharedSetServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class ShoppingPerformanceViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class TopicConstantServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class TopicViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class UserInterestServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class UserListServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class UserLocationViewServiceClient : GoogleAdsServiceClientBase {} + public abstract partial class VideoServiceClient : GoogleAdsServiceClientBase {} +} + +#pragma warning restore CS1591 diff --git a/src/V3/ServiceHelperMethods.cs b/src/V3/ServiceHelperMethods.cs new file mode 100644 index 000000000..4ed0e78b7 --- /dev/null +++ b/src/V3/ServiceHelperMethods.cs @@ -0,0 +1,150 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Protobuf.WellKnownTypes; +using System.Linq; +using gaxgrpc = Google.Api.Gax.Grpc; +using gagve = Google.Ads.GoogleAds.V3.Enums; +using scg = System.Collections.Generic; +using stt = System.Threading.Tasks; +using Google.Api.Gax; +using Google.Api.Gax.Grpc; +using static Google.Ads.GoogleAds.V3.Enums.SummaryRowSettingEnum.Types; +using System; +using Google.Ads.GoogleAds.V3.Errors; +using System.Threading.Tasks; +using System.Threading; + +#pragma warning disable CS1591 + +namespace Google.Ads.GoogleAds.V3.Services +{ + public abstract partial class CustomerServiceClient + { + public string[] ListAccessibleCustomers() + { + return ListAccessibleCustomers(new ListAccessibleCustomersRequest() { }) + .ResourceNames.ToArray(); + } + } + + public abstract partial class GeoTargetConstantServiceClient + { + public virtual SuggestGeoTargetConstantsResponse SuggestGeoTargetConstants( + StringValue locale, + StringValue countryCode, + gaxgrpc::CallSettings callSettings = null) => SuggestGeoTargetConstants( + locale.Value, countryCode.Value, callSettings); + + public virtual stt::Task SuggestGeoTargetConstantsAsync( + StringValue locale, + StringValue countryCode, + gaxgrpc::CallSettings callSettings = null) => SuggestGeoTargetConstantsAsync( + locale.Value, countryCode.Value, callSettings); + } + + public abstract partial class GoogleAdsServiceClient + { + public virtual PagedEnumerable Search( + string customerId, + string query, + string pageToken = null, + int? pageSize = null, + CallSettings callSettings = null) => Search( + new SearchGoogleAdsRequest + { + CustomerId = GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Query = GaxPreconditions.CheckNotNullOrEmpty(query, nameof(query)), + PageToken = pageToken ?? "", + PageSize = pageSize ?? 0, + }, + callSettings); + + public virtual Task SearchStreamAsync( + string customerId, + string query, + Action responseCallback, + SummaryRowSetting summaryRowSetting = SummaryRowSetting.NoSummaryRow, + CallSettings callSettings = null) + { + SearchStreamStream searchStream = this.SearchStream( + new SearchGoogleAdsStreamRequest() + { + CustomerId = customerId.ToString(), + Query = query, + SummaryRowSetting = summaryRowSetting, + }); + + // Issue a search request. + Task t = Task.Run(async () => + { + while (await searchStream.ResponseStream.MoveNext(CancellationToken.None)) + { + SearchGoogleAdsStreamResponse resp = searchStream.ResponseStream.Current; + responseCallback(resp); + } + }); + + return t; + } + + public virtual void SearchStream( + string customerId, + string query, + Action responseCallback, + SummaryRowSetting summaryRowSetting = SummaryRowSetting.NoSummaryRow, + CallSettings callSettings = null) + { + try + { + Task t = SearchStreamAsync(customerId, query, responseCallback, summaryRowSetting, + callSettings); + t.Wait(); + } + catch (AggregateException ae) + { + GoogleAdsException gae = GoogleAdsException.FromTaskException(ae); + + if (gae != null) + { + throw gae; + } + throw; + } + } + } + + public abstract partial class KeywordPlanIdeaServiceClient + { + public virtual GenerateKeywordIdeaResponse GenerateKeywordIdeas( + string customerId, + StringValue language, + scg::IEnumerable geoTargetConstants, + gagve::KeywordPlanNetworkEnum.Types.KeywordPlanNetwork keywordPlanNetwork, + gaxgrpc::CallSettings callSettings = null) => GenerateKeywordIdeas( + customerId, language.Value, geoTargetConstants, keywordPlanNetwork, + callSettings); + + public virtual stt::Task GenerateKeywordIdeasAsync( + string customerId, + StringValue language, + scg::IEnumerable geoTargetConstants, + gagve::KeywordPlanNetworkEnum.Types.KeywordPlanNetwork keywordPlanNetwork, + gaxgrpc::CallSettings callSettings = null) => GenerateKeywordIdeasAsync( + customerId, language.Value, geoTargetConstants, keywordPlanNetwork, + callSettings); + } +} + +#pragma warning restore CS1591 diff --git a/src/V3/Services.V3.cs b/src/V3/Services.V3.cs new file mode 100644 index 000000000..112927bbf --- /dev/null +++ b/src/V3/Services.V3.cs @@ -0,0 +1,1334 @@ +// Copyright 2020, Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using Google.Ads.GoogleAds.Lib; +using Google.Ads.GoogleAds.V3.Services; +using Google.Api.Gax.Grpc; +using Grpc.Core; + +namespace Google.Ads.GoogleAds +{ + /// + /// Class to act as a pseudo namespace provider for service creation. + /// + public partial class Services + { + /// + /// Pseudo enum to list the services supported in V3. + /// + public class V3 + { + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AccountBudgetProposalService + /// for details. + /// + public static readonly ServiceTemplate AccountBudgetProposalService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AccountBudgetService + /// for details. + /// + public static readonly ServiceTemplate AccountBudgetService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupAdAssetViewService + /// for details. + /// + public static readonly ServiceTemplate AdGroupAdAssetViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupAdLabelService + /// for details. + /// + public static readonly ServiceTemplate AdGroupAdLabelService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupAdService + /// for details. + /// + public static readonly ServiceTemplate AdGroupAdService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupAudienceViewService + /// for details. + /// + public static readonly ServiceTemplate AdGroupAudienceViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupBidModifierService + /// for details. + /// + public static readonly ServiceTemplate AdGroupBidModifierService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupCriterionLabelService + /// for details. + /// + public static readonly ServiceTemplate AdGroupCriterionLabelService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupCriterionService + /// for details. + /// + public static readonly ServiceTemplate AdGroupCriterionService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupCriterionSimulationService + /// for details. + /// + public static readonly ServiceTemplate AdGroupCriterionSimulationService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupExtensionSettingService + /// for details. + /// + public static readonly ServiceTemplate AdGroupExtensionSettingService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupFeedService + /// for details. + /// + public static readonly ServiceTemplate AdGroupFeedService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupLabelService + /// for details. + /// + public static readonly ServiceTemplate AdGroupLabelService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupService + /// for details. + /// + public static readonly ServiceTemplate AdGroupService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdGroupSimulationService + /// for details. + /// + public static readonly ServiceTemplate AdGroupSimulationService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdParameterService + /// for details. + /// + public static readonly ServiceTemplate AdParameterService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdScheduleViewService + /// for details. + /// + public static readonly ServiceTemplate AdScheduleViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AdService + /// for details. + /// + public static readonly ServiceTemplate AdService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AgeRangeViewService + /// for details. + /// + public static readonly ServiceTemplate AgeRangeViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.AssetService + /// for details. + /// + public static readonly ServiceTemplate AssetService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.BiddingStrategyService + /// for details. + /// + public static readonly ServiceTemplate BiddingStrategyService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.BillingSetupService + /// for details. + /// + public static readonly ServiceTemplate BillingSetupService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignAudienceViewService + /// for details. + /// + public static readonly ServiceTemplate CampaignAudienceViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignBidModifierService + /// for details. + /// + public static readonly ServiceTemplate CampaignBidModifierService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignBudgetService + /// for details. + /// + public static readonly ServiceTemplate CampaignBudgetService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignCriterionService + /// for details. + /// + public static readonly ServiceTemplate CampaignCriterionService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignCriterionSimulationService + /// for details. + /// + public static readonly ServiceTemplate CampaignCriterionSimulationService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignDraftService + /// for details. + /// + public static readonly ServiceTemplate CampaignDraftService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignExperimentService + /// for details. + /// + public static readonly ServiceTemplate CampaignExperimentService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignExtensionSettingService + /// for details. + /// + public static readonly ServiceTemplate CampaignExtensionSettingService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignFeedService + /// for details. + /// + public static readonly ServiceTemplate CampaignFeedService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignLabelService + /// for details. + /// + public static readonly ServiceTemplate CampaignLabelService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignService + /// for details. + /// + public static readonly ServiceTemplate CampaignService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CampaignSharedSetService + /// for details. + /// + public static readonly ServiceTemplate CampaignSharedSetService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CarrierConstantService + /// for details. + /// + public static readonly ServiceTemplate CarrierConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ChangeStatusService + /// for details. + /// + public static readonly ServiceTemplate ChangeStatusService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ClickViewService + /// for details. + /// + public static readonly ServiceTemplate ClickViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ConversionActionService + /// for details. + /// + public static readonly ServiceTemplate ConversionActionService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ConversionAdjustmentUploadService + /// for details. + /// + public static readonly ServiceTemplate ConversionAdjustmentUploadService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ConversionUploadService + /// for details. + /// + public static readonly ServiceTemplate ConversionUploadService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CurrencyConstantService + /// for details. + /// + public static readonly ServiceTemplate CurrencyConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomerClientLinkService + /// for details. + /// + public static readonly ServiceTemplate CustomerClientLinkService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomerClientService + /// for details. + /// + public static readonly ServiceTemplate CustomerClientService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomerExtensionSettingService + /// for details. + /// + public static readonly ServiceTemplate CustomerExtensionSettingService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomerFeedService + /// for details. + /// + public static readonly ServiceTemplate CustomerFeedService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomerLabelService + /// for details. + /// + public static readonly ServiceTemplate CustomerLabelService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomerManagerLinkService + /// for details. + /// + public static readonly ServiceTemplate CustomerManagerLinkService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomerNegativeCriterionService + /// for details. + /// + public static readonly ServiceTemplate CustomerNegativeCriterionService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomerService + /// for details. + /// + public static readonly ServiceTemplate CustomerService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.CustomInterestService + /// for details. + /// + public static readonly ServiceTemplate CustomInterestService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.DetailPlacementViewService + /// for details. + /// + public static readonly ServiceTemplate DetailPlacementViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.DisplayKeywordViewService + /// for details. + /// + public static readonly ServiceTemplate DisplayKeywordViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.DistanceViewService + /// for details. + /// + public static readonly ServiceTemplate DistanceViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.DomainCategoryService + /// for details. + /// + public static readonly ServiceTemplate DomainCategoryService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.DynamicSearchAdsSearchTermViewService + /// for details. + /// + public static readonly ServiceTemplate DynamicSearchAdsSearchTermViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ExpandedLandingPageViewService + /// for details. + /// + public static readonly ServiceTemplate ExpandedLandingPageViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ExtensionFeedItemService + /// for details. + /// + public static readonly ServiceTemplate ExtensionFeedItemService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.FeedItemService + /// for details. + /// + public static readonly ServiceTemplate FeedItemService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.FeedItemTargetService + /// for details. + /// + public static readonly ServiceTemplate FeedItemTargetService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.FeedMappingService + /// for details. + /// + public static readonly ServiceTemplate FeedMappingService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.FeedPlaceholderViewService + /// for details. + /// + public static readonly ServiceTemplate FeedPlaceholderViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.FeedService + /// for details. + /// + public static readonly ServiceTemplate FeedService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.GenderViewService + /// for details. + /// + public static readonly ServiceTemplate GenderViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.GeographicViewService + /// for details. + /// + public static readonly ServiceTemplate GeographicViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.GeoTargetConstantService + /// for details. + /// + public static readonly ServiceTemplate GeoTargetConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.GoogleAdsFieldService + /// for details. + /// + public static readonly ServiceTemplate GoogleAdsFieldService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.GoogleAdsService + /// for details. + /// + public static readonly ServiceTemplate GoogleAdsService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.GroupPlacementViewService + /// for details. + /// + public static readonly ServiceTemplate GroupPlacementViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.HotelGroupViewService + /// for details. + /// + public static readonly ServiceTemplate HotelGroupViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.HotelPerformanceViewService + /// for details. + /// + public static readonly ServiceTemplate HotelPerformanceViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.InvoiceService + /// for details. + /// + public static readonly ServiceTemplate InvoiceService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.KeywordPlanAdGroupService + /// for details. + /// + public static readonly ServiceTemplate KeywordPlanAdGroupService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.KeywordPlanCampaignService + /// for details. + /// + public static readonly ServiceTemplate KeywordPlanCampaignService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.KeywordPlanIdeaService + /// for details. + /// + public static readonly ServiceTemplate KeywordPlanIdeaService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.KeywordPlanKeywordService + /// for details. + /// + public static readonly ServiceTemplate KeywordPlanKeywordService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.KeywordPlanNegativeKeywordService + /// for details. + /// + public static readonly ServiceTemplate KeywordPlanNegativeKeywordService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.KeywordPlanService + /// for details. + /// + public static readonly ServiceTemplate KeywordPlanService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.KeywordViewService + /// for details. + /// + public static readonly ServiceTemplate KeywordViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.LabelService + /// for details. + /// + public static readonly ServiceTemplate LabelService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.LandingPageViewService + /// for details. + /// + public static readonly ServiceTemplate LandingPageViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.LanguageConstantService + /// for details. + /// + public static readonly ServiceTemplate LanguageConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.LocationViewService + /// for details. + /// + public static readonly ServiceTemplate LocationViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ManagedPlacementViewService + /// for details. + /// + public static readonly ServiceTemplate ManagedPlacementViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.MediaFileService + /// for details. + /// + public static readonly ServiceTemplate MediaFileService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.MerchantCenterLinkService + /// for details. + /// + public static readonly ServiceTemplate MerchantCenterLinkService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.MobileAppCategoryConstantService + /// for details. + /// + public static readonly ServiceTemplate MobileAppCategoryConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.MobileDeviceConstantService + /// for details. + /// + public static readonly ServiceTemplate MobileDeviceConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.MutateJobService + /// for details. + /// + public static readonly ServiceTemplate MutateJobService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.OperatingSystemVersionConstantService + /// for details. + /// + public static readonly ServiceTemplate OperatingSystemVersionConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.PaidOrganicSearchTermViewService + /// for details. + /// + public static readonly ServiceTemplate PaidOrganicSearchTermViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ParentalStatusViewService + /// for details. + /// + public static readonly ServiceTemplate ParentalStatusViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.PaymentsAccountService + /// for details. + /// + public static readonly ServiceTemplate PaymentsAccountService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ProductBiddingCategoryConstantService + /// for details. + /// + public static readonly ServiceTemplate ProductBiddingCategoryConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ProductGroupViewService + /// for details. + /// + public static readonly ServiceTemplate ProductGroupViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ReachPlanService + /// for details. + /// + public static readonly ServiceTemplate ReachPlanService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.RecommendationService + /// for details. + /// + public static readonly ServiceTemplate RecommendationService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.RemarketingActionService + /// for details. + /// + public static readonly ServiceTemplate RemarketingActionService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.SearchTermViewService + /// for details. + /// + public static readonly ServiceTemplate SearchTermViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.SharedCriterionService + /// for details. + /// + public static readonly ServiceTemplate SharedCriterionService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.SharedSetService + /// for details. + /// + public static readonly ServiceTemplate SharedSetService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.ShoppingPerformanceViewService + /// for details. + /// + public static readonly ServiceTemplate ShoppingPerformanceViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.TopicConstantService + /// for details. + /// + public static readonly ServiceTemplate TopicConstantService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.TopicViewService + /// for details. + /// + public static readonly ServiceTemplate TopicViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.UserInterestService + /// for details. + /// + public static readonly ServiceTemplate UserInterestService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.UserListService + /// for details. + /// + public static readonly ServiceTemplate UserListService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.UserLocationViewService + /// for details. + /// + public static readonly ServiceTemplate UserLocationViewService = + new ServiceTemplate(Create); + + + /// + /// See https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v3.services#google.ads.googleads.v3.services.VideoService + /// for details. + /// + public static readonly ServiceTemplate VideoService = + new ServiceTemplate(Create); + + /// + /// Creates the specified service. + /// + /// Name of the service. + /// The call invoker. + /// The service settings. + /// An instance of the service. + public static GoogleAdsServiceClientBase Create(string serviceName, CallInvoker callInvoker, ServiceSettingsBase settings) + { + switch (serviceName) + { + + case "AccountBudgetProposalServiceClient": + return AccountBudgetProposalServiceClient.Create(callInvoker, (AccountBudgetProposalServiceSettings) settings); + + + case "AccountBudgetServiceClient": + return AccountBudgetServiceClient.Create(callInvoker, (AccountBudgetServiceSettings) settings); + + + case "AdGroupAdAssetViewServiceClient": + return AdGroupAdAssetViewServiceClient.Create(callInvoker, (AdGroupAdAssetViewServiceSettings) settings); + + + case "AdGroupAdLabelServiceClient": + return AdGroupAdLabelServiceClient.Create(callInvoker, (AdGroupAdLabelServiceSettings) settings); + + + case "AdGroupAdServiceClient": + return AdGroupAdServiceClient.Create(callInvoker, (AdGroupAdServiceSettings) settings); + + + case "AdGroupAudienceViewServiceClient": + return AdGroupAudienceViewServiceClient.Create(callInvoker, (AdGroupAudienceViewServiceSettings) settings); + + + case "AdGroupBidModifierServiceClient": + return AdGroupBidModifierServiceClient.Create(callInvoker, (AdGroupBidModifierServiceSettings) settings); + + + case "AdGroupCriterionLabelServiceClient": + return AdGroupCriterionLabelServiceClient.Create(callInvoker, (AdGroupCriterionLabelServiceSettings) settings); + + + case "AdGroupCriterionServiceClient": + return AdGroupCriterionServiceClient.Create(callInvoker, (AdGroupCriterionServiceSettings) settings); + + + case "AdGroupCriterionSimulationServiceClient": + return AdGroupCriterionSimulationServiceClient.Create(callInvoker, (AdGroupCriterionSimulationServiceSettings) settings); + + + case "AdGroupExtensionSettingServiceClient": + return AdGroupExtensionSettingServiceClient.Create(callInvoker, (AdGroupExtensionSettingServiceSettings) settings); + + + case "AdGroupFeedServiceClient": + return AdGroupFeedServiceClient.Create(callInvoker, (AdGroupFeedServiceSettings) settings); + + + case "AdGroupLabelServiceClient": + return AdGroupLabelServiceClient.Create(callInvoker, (AdGroupLabelServiceSettings) settings); + + + case "AdGroupServiceClient": + return AdGroupServiceClient.Create(callInvoker, (AdGroupServiceSettings) settings); + + + case "AdGroupSimulationServiceClient": + return AdGroupSimulationServiceClient.Create(callInvoker, (AdGroupSimulationServiceSettings) settings); + + + case "AdParameterServiceClient": + return AdParameterServiceClient.Create(callInvoker, (AdParameterServiceSettings) settings); + + + case "AdScheduleViewServiceClient": + return AdScheduleViewServiceClient.Create(callInvoker, (AdScheduleViewServiceSettings) settings); + + + case "AdServiceClient": + return AdServiceClient.Create(callInvoker, (AdServiceSettings) settings); + + + case "AgeRangeViewServiceClient": + return AgeRangeViewServiceClient.Create(callInvoker, (AgeRangeViewServiceSettings) settings); + + + case "AssetServiceClient": + return AssetServiceClient.Create(callInvoker, (AssetServiceSettings) settings); + + + case "BiddingStrategyServiceClient": + return BiddingStrategyServiceClient.Create(callInvoker, (BiddingStrategyServiceSettings) settings); + + + case "BillingSetupServiceClient": + return BillingSetupServiceClient.Create(callInvoker, (BillingSetupServiceSettings) settings); + + + case "CampaignAudienceViewServiceClient": + return CampaignAudienceViewServiceClient.Create(callInvoker, (CampaignAudienceViewServiceSettings) settings); + + + case "CampaignBidModifierServiceClient": + return CampaignBidModifierServiceClient.Create(callInvoker, (CampaignBidModifierServiceSettings) settings); + + + case "CampaignBudgetServiceClient": + return CampaignBudgetServiceClient.Create(callInvoker, (CampaignBudgetServiceSettings) settings); + + + case "CampaignCriterionServiceClient": + return CampaignCriterionServiceClient.Create(callInvoker, (CampaignCriterionServiceSettings) settings); + + + case "CampaignCriterionSimulationServiceClient": + return CampaignCriterionSimulationServiceClient.Create(callInvoker, (CampaignCriterionSimulationServiceSettings) settings); + + + case "CampaignDraftServiceClient": + return CampaignDraftServiceClient.Create(callInvoker, (CampaignDraftServiceSettings) settings); + + + case "CampaignExperimentServiceClient": + return CampaignExperimentServiceClient.Create(callInvoker, (CampaignExperimentServiceSettings) settings); + + + case "CampaignExtensionSettingServiceClient": + return CampaignExtensionSettingServiceClient.Create(callInvoker, (CampaignExtensionSettingServiceSettings) settings); + + + case "CampaignFeedServiceClient": + return CampaignFeedServiceClient.Create(callInvoker, (CampaignFeedServiceSettings) settings); + + + case "CampaignLabelServiceClient": + return CampaignLabelServiceClient.Create(callInvoker, (CampaignLabelServiceSettings) settings); + + + case "CampaignServiceClient": + return CampaignServiceClient.Create(callInvoker, (CampaignServiceSettings) settings); + + + case "CampaignSharedSetServiceClient": + return CampaignSharedSetServiceClient.Create(callInvoker, (CampaignSharedSetServiceSettings) settings); + + + case "CarrierConstantServiceClient": + return CarrierConstantServiceClient.Create(callInvoker, (CarrierConstantServiceSettings) settings); + + + case "ChangeStatusServiceClient": + return ChangeStatusServiceClient.Create(callInvoker, (ChangeStatusServiceSettings) settings); + + + case "ClickViewServiceClient": + return ClickViewServiceClient.Create(callInvoker, (ClickViewServiceSettings) settings); + + + case "ConversionActionServiceClient": + return ConversionActionServiceClient.Create(callInvoker, (ConversionActionServiceSettings) settings); + + + case "ConversionAdjustmentUploadServiceClient": + return ConversionAdjustmentUploadServiceClient.Create(callInvoker, (ConversionAdjustmentUploadServiceSettings) settings); + + + case "ConversionUploadServiceClient": + return ConversionUploadServiceClient.Create(callInvoker, (ConversionUploadServiceSettings) settings); + + + case "CurrencyConstantServiceClient": + return CurrencyConstantServiceClient.Create(callInvoker, (CurrencyConstantServiceSettings) settings); + + + case "CustomerClientLinkServiceClient": + return CustomerClientLinkServiceClient.Create(callInvoker, (CustomerClientLinkServiceSettings) settings); + + + case "CustomerClientServiceClient": + return CustomerClientServiceClient.Create(callInvoker, (CustomerClientServiceSettings) settings); + + + case "CustomerExtensionSettingServiceClient": + return CustomerExtensionSettingServiceClient.Create(callInvoker, (CustomerExtensionSettingServiceSettings) settings); + + + case "CustomerFeedServiceClient": + return CustomerFeedServiceClient.Create(callInvoker, (CustomerFeedServiceSettings) settings); + + + case "CustomerLabelServiceClient": + return CustomerLabelServiceClient.Create(callInvoker, (CustomerLabelServiceSettings) settings); + + + case "CustomerManagerLinkServiceClient": + return CustomerManagerLinkServiceClient.Create(callInvoker, (CustomerManagerLinkServiceSettings) settings); + + + case "CustomerNegativeCriterionServiceClient": + return CustomerNegativeCriterionServiceClient.Create(callInvoker, (CustomerNegativeCriterionServiceSettings) settings); + + + case "CustomerServiceClient": + return CustomerServiceClient.Create(callInvoker, (CustomerServiceSettings) settings); + + + case "CustomInterestServiceClient": + return CustomInterestServiceClient.Create(callInvoker, (CustomInterestServiceSettings) settings); + + + case "DetailPlacementViewServiceClient": + return DetailPlacementViewServiceClient.Create(callInvoker, (DetailPlacementViewServiceSettings) settings); + + + case "DisplayKeywordViewServiceClient": + return DisplayKeywordViewServiceClient.Create(callInvoker, (DisplayKeywordViewServiceSettings) settings); + + + case "DistanceViewServiceClient": + return DistanceViewServiceClient.Create(callInvoker, (DistanceViewServiceSettings) settings); + + + case "DomainCategoryServiceClient": + return DomainCategoryServiceClient.Create(callInvoker, (DomainCategoryServiceSettings) settings); + + + case "DynamicSearchAdsSearchTermViewServiceClient": + return DynamicSearchAdsSearchTermViewServiceClient.Create(callInvoker, (DynamicSearchAdsSearchTermViewServiceSettings) settings); + + + case "ExpandedLandingPageViewServiceClient": + return ExpandedLandingPageViewServiceClient.Create(callInvoker, (ExpandedLandingPageViewServiceSettings) settings); + + + case "ExtensionFeedItemServiceClient": + return ExtensionFeedItemServiceClient.Create(callInvoker, (ExtensionFeedItemServiceSettings) settings); + + + case "FeedItemServiceClient": + return FeedItemServiceClient.Create(callInvoker, (FeedItemServiceSettings) settings); + + + case "FeedItemTargetServiceClient": + return FeedItemTargetServiceClient.Create(callInvoker, (FeedItemTargetServiceSettings) settings); + + + case "FeedMappingServiceClient": + return FeedMappingServiceClient.Create(callInvoker, (FeedMappingServiceSettings) settings); + + + case "FeedPlaceholderViewServiceClient": + return FeedPlaceholderViewServiceClient.Create(callInvoker, (FeedPlaceholderViewServiceSettings) settings); + + + case "FeedServiceClient": + return FeedServiceClient.Create(callInvoker, (FeedServiceSettings) settings); + + + case "GenderViewServiceClient": + return GenderViewServiceClient.Create(callInvoker, (GenderViewServiceSettings) settings); + + + case "GeographicViewServiceClient": + return GeographicViewServiceClient.Create(callInvoker, (GeographicViewServiceSettings) settings); + + + case "GeoTargetConstantServiceClient": + return GeoTargetConstantServiceClient.Create(callInvoker, (GeoTargetConstantServiceSettings) settings); + + + case "GoogleAdsFieldServiceClient": + return GoogleAdsFieldServiceClient.Create(callInvoker, (GoogleAdsFieldServiceSettings) settings); + + + case "GoogleAdsServiceClient": + return GoogleAdsServiceClient.Create(callInvoker, (GoogleAdsServiceSettings) settings); + + + case "GroupPlacementViewServiceClient": + return GroupPlacementViewServiceClient.Create(callInvoker, (GroupPlacementViewServiceSettings) settings); + + + case "HotelGroupViewServiceClient": + return HotelGroupViewServiceClient.Create(callInvoker, (HotelGroupViewServiceSettings) settings); + + + case "HotelPerformanceViewServiceClient": + return HotelPerformanceViewServiceClient.Create(callInvoker, (HotelPerformanceViewServiceSettings) settings); + + + case "InvoiceServiceClient": + return InvoiceServiceClient.Create(callInvoker, (InvoiceServiceSettings) settings); + + + case "KeywordPlanAdGroupServiceClient": + return KeywordPlanAdGroupServiceClient.Create(callInvoker, (KeywordPlanAdGroupServiceSettings) settings); + + + case "KeywordPlanCampaignServiceClient": + return KeywordPlanCampaignServiceClient.Create(callInvoker, (KeywordPlanCampaignServiceSettings) settings); + + + case "KeywordPlanIdeaServiceClient": + return KeywordPlanIdeaServiceClient.Create(callInvoker, (KeywordPlanIdeaServiceSettings) settings); + + + case "KeywordPlanKeywordServiceClient": + return KeywordPlanKeywordServiceClient.Create(callInvoker, (KeywordPlanKeywordServiceSettings) settings); + + + case "KeywordPlanNegativeKeywordServiceClient": + return KeywordPlanNegativeKeywordServiceClient.Create(callInvoker, (KeywordPlanNegativeKeywordServiceSettings) settings); + + + case "KeywordPlanServiceClient": + return KeywordPlanServiceClient.Create(callInvoker, (KeywordPlanServiceSettings) settings); + + + case "KeywordViewServiceClient": + return KeywordViewServiceClient.Create(callInvoker, (KeywordViewServiceSettings) settings); + + + case "LabelServiceClient": + return LabelServiceClient.Create(callInvoker, (LabelServiceSettings) settings); + + + case "LandingPageViewServiceClient": + return LandingPageViewServiceClient.Create(callInvoker, (LandingPageViewServiceSettings) settings); + + + case "LanguageConstantServiceClient": + return LanguageConstantServiceClient.Create(callInvoker, (LanguageConstantServiceSettings) settings); + + + case "LocationViewServiceClient": + return LocationViewServiceClient.Create(callInvoker, (LocationViewServiceSettings) settings); + + + case "ManagedPlacementViewServiceClient": + return ManagedPlacementViewServiceClient.Create(callInvoker, (ManagedPlacementViewServiceSettings) settings); + + + case "MediaFileServiceClient": + return MediaFileServiceClient.Create(callInvoker, (MediaFileServiceSettings) settings); + + + case "MerchantCenterLinkServiceClient": + return MerchantCenterLinkServiceClient.Create(callInvoker, (MerchantCenterLinkServiceSettings) settings); + + + case "MobileAppCategoryConstantServiceClient": + return MobileAppCategoryConstantServiceClient.Create(callInvoker, (MobileAppCategoryConstantServiceSettings) settings); + + + case "MobileDeviceConstantServiceClient": + return MobileDeviceConstantServiceClient.Create(callInvoker, (MobileDeviceConstantServiceSettings) settings); + + + case "MutateJobServiceClient": + return MutateJobServiceClient.Create(callInvoker, (MutateJobServiceSettings) settings); + + + case "OperatingSystemVersionConstantServiceClient": + return OperatingSystemVersionConstantServiceClient.Create(callInvoker, (OperatingSystemVersionConstantServiceSettings) settings); + + + case "PaidOrganicSearchTermViewServiceClient": + return PaidOrganicSearchTermViewServiceClient.Create(callInvoker, (PaidOrganicSearchTermViewServiceSettings) settings); + + + case "ParentalStatusViewServiceClient": + return ParentalStatusViewServiceClient.Create(callInvoker, (ParentalStatusViewServiceSettings) settings); + + + case "PaymentsAccountServiceClient": + return PaymentsAccountServiceClient.Create(callInvoker, (PaymentsAccountServiceSettings) settings); + + + case "ProductBiddingCategoryConstantServiceClient": + return ProductBiddingCategoryConstantServiceClient.Create(callInvoker, (ProductBiddingCategoryConstantServiceSettings) settings); + + + case "ProductGroupViewServiceClient": + return ProductGroupViewServiceClient.Create(callInvoker, (ProductGroupViewServiceSettings) settings); + + + case "ReachPlanServiceClient": + return ReachPlanServiceClient.Create(callInvoker, (ReachPlanServiceSettings) settings); + + + case "RecommendationServiceClient": + return RecommendationServiceClient.Create(callInvoker, (RecommendationServiceSettings) settings); + + + case "RemarketingActionServiceClient": + return RemarketingActionServiceClient.Create(callInvoker, (RemarketingActionServiceSettings) settings); + + + case "SearchTermViewServiceClient": + return SearchTermViewServiceClient.Create(callInvoker, (SearchTermViewServiceSettings) settings); + + + case "SharedCriterionServiceClient": + return SharedCriterionServiceClient.Create(callInvoker, (SharedCriterionServiceSettings) settings); + + + case "SharedSetServiceClient": + return SharedSetServiceClient.Create(callInvoker, (SharedSetServiceSettings) settings); + + + case "ShoppingPerformanceViewServiceClient": + return ShoppingPerformanceViewServiceClient.Create(callInvoker, (ShoppingPerformanceViewServiceSettings) settings); + + + case "TopicConstantServiceClient": + return TopicConstantServiceClient.Create(callInvoker, (TopicConstantServiceSettings) settings); + + + case "TopicViewServiceClient": + return TopicViewServiceClient.Create(callInvoker, (TopicViewServiceSettings) settings); + + + case "UserInterestServiceClient": + return UserInterestServiceClient.Create(callInvoker, (UserInterestServiceSettings) settings); + + + case "UserListServiceClient": + return UserListServiceClient.Create(callInvoker, (UserListServiceSettings) settings); + + + case "UserLocationViewServiceClient": + return UserLocationViewServiceClient.Create(callInvoker, (UserLocationViewServiceSettings) settings); + + + case "VideoServiceClient": + return VideoServiceClient.Create(callInvoker, (VideoServiceSettings) settings); + + + default: + return null; + } + } + } + } +} diff --git a/src/V3/Stubs/AccessInvitationError.cs b/src/V3/Stubs/AccessInvitationError.cs new file mode 100644 index 000000000..f113c6ea5 --- /dev/null +++ b/src/V3/Stubs/AccessInvitationError.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/access_invitation_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/access_invitation_error.proto + public static partial class AccessInvitationErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/access_invitation_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccessInvitationErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWNjZXNzX2ludml0", + "YXRpb25fZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKTAQoZQWNjZXNz", + "SW52aXRhdGlvbkVycm9yRW51bSJ2ChVBY2Nlc3NJbnZpdGF0aW9uRXJyb3IS", + "DwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESGQoVSU5WQUxJRF9FTUFJ", + "TF9BRERSRVNTEAISJAogRU1BSUxfQUREUkVTU19BTFJFQURZX0hBU19BQ0NF", + "U1MQA0L1AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0Ia", + "QWNjZXNzSW52aXRhdGlvbkVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5v", + "cmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9y", + "cztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJv", + "cnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AccessInvitationErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AccessInvitationErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AccessInvitationErrorEnum.Types.AccessInvitationError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible AccessInvitation errors. + /// + public sealed partial class AccessInvitationErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccessInvitationErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AccessInvitationErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessInvitationErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessInvitationErrorEnum(AccessInvitationErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessInvitationErrorEnum Clone() { + return new AccessInvitationErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccessInvitationErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccessInvitationErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccessInvitationErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AccessInvitationErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible AccessInvitation errors. + /// + public enum AccessInvitationError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The email address is invalid for sending an invitation. + /// + [pbr::OriginalName("INVALID_EMAIL_ADDRESS")] InvalidEmailAddress = 2, + /// + /// Email address already has access to this customer. + /// + [pbr::OriginalName("EMAIL_ADDRESS_ALREADY_HAS_ACCESS")] EmailAddressAlreadyHasAccess = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccessReason.cs b/src/V3/Stubs/AccessReason.cs new file mode 100644 index 000000000..32d32b9f9 --- /dev/null +++ b/src/V3/Stubs/AccessReason.cs @@ -0,0 +1,197 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/access_reason.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/access_reason.proto + public static partial class AccessReasonReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/access_reason.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccessReasonReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hY2Nlc3NfcmVhc29u", + "LnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byKFAQoQQWNjZXNzUmVhc29uRW51bSJx", + "CgxBY2Nlc3NSZWFzb24SDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAES", + "CQoFT1dORUQQAhIKCgZTSEFSRUQQAxIMCghMSUNFTlNFRBAEEg4KClNVQlND", + "UklCRUQQBRIOCgpBRkZJTElBVEVEEAZC5gEKIWNvbS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtc0IRQWNjZXNzUmVhc29uUHJvdG9QAVpCZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMu", + "VjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AccessReasonEnum), global::Google.Ads.GoogleAds.V3.Enums.AccessReasonEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AccessReasonEnum.Types.AccessReason) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Indicates the way the resource such as user list is related to a user. + /// + public sealed partial class AccessReasonEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccessReasonEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AccessReasonReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessReasonEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessReasonEnum(AccessReasonEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessReasonEnum Clone() { + return new AccessReasonEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccessReasonEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccessReasonEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccessReasonEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AccessReasonEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible access reasons. + /// + public enum AccessReason { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The resource is owned by the user. + /// + [pbr::OriginalName("OWNED")] Owned = 2, + /// + /// The resource is shared to the user. + /// + [pbr::OriginalName("SHARED")] Shared = 3, + /// + /// The resource is licensed to the user. + /// + [pbr::OriginalName("LICENSED")] Licensed = 4, + /// + /// The user subscribed to the resource. + /// + [pbr::OriginalName("SUBSCRIBED")] Subscribed = 5, + /// + /// The resource is accessible to the user. + /// + [pbr::OriginalName("AFFILIATED")] Affiliated = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccessRole.cs b/src/V3/Stubs/AccessRole.cs new file mode 100644 index 000000000..e73b5c89c --- /dev/null +++ b/src/V3/Stubs/AccessRole.cs @@ -0,0 +1,189 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/access_role.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/access_role.proto + public static partial class AccessRoleReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/access_role.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccessRoleReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hY2Nlc3Nfcm9sZS5w", + "cm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8iZAoOQWNjZXNzUm9sZUVudW0iUgoKQWNj", + "ZXNzUm9sZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIJCgVBRE1J", + "ThACEgwKCFNUQU5EQVJEEAMSDQoJUkVBRF9PTkxZEARC5AEKIWNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IPQWNjZXNzUm9sZVByb3RvUAFa", + "Qmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51", + "bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3Rv", + "Mw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AccessRoleEnum), global::Google.Ads.GoogleAds.V3.Enums.AccessRoleEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AccessRoleEnum.Types.AccessRole) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible access role for user. + /// + public sealed partial class AccessRoleEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccessRoleEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AccessRoleReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessRoleEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessRoleEnum(AccessRoleEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccessRoleEnum Clone() { + return new AccessRoleEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccessRoleEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccessRoleEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccessRoleEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AccessRoleEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible access role of a user. + /// + public enum AccessRole { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Owns its account and can control the addition of other users. + /// + [pbr::OriginalName("ADMIN")] Admin = 2, + /// + /// Can modify campaigns, but can't affect other users. + /// + [pbr::OriginalName("STANDARD")] Standard = 3, + /// + /// Can view campaigns and account changes, but cannot make edits. + /// + [pbr::OriginalName("READ_ONLY")] ReadOnly = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccountBudget.cs b/src/V3/Stubs/AccountBudget.cs new file mode 100644 index 000000000..5d6daf7b7 --- /dev/null +++ b/src/V3/Stubs/AccountBudget.cs @@ -0,0 +1,1740 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/account_budget.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/account_budget.proto + public static partial class AccountBudgetReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/account_budget.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccountBudgetReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWNjb3VudF9i", + "dWRnZXQucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cxpAZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvYWNjb3VudF9idWRn", + "ZXRfcHJvcG9zYWxfdHlwZS5wcm90bxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZW51bXMvYWNjb3VudF9idWRnZXRfc3RhdHVzLnByb3RvGjdnb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9lbnVtcy9zcGVuZGluZ19saW1pdF90eXBlLnBy", + "b3RvGi1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy90aW1lX3R5cGUu", + "cHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2ds", + "ZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVy", + "cy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLYFgoNQWNj", + "b3VudEJ1ZGdldBJFCg1yZXNvdXJjZV9uYW1lGAEgASgJQi7gQQX6QSgKJmdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BY2NvdW50QnVkZ2V0EiwKAmlkGAIg", + "ASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWVCA+BBAxJiCg1iaWxs", + "aW5nX3NldHVwGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVl", + "Qi3gQQP6QScKJWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9CaWxsaW5nU2V0", + "dXASXwoGc3RhdHVzGAQgASgOMkouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuQWNjb3VudEJ1ZGdldFN0YXR1c0VudW0uQWNjb3VudEJ1ZGdldFN0", + "YXR1c0ID4EEDEi8KBG5hbWUYBSABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWVCA+BBAxJDChhwcm9wb3NlZF9zdGFydF9kYXRlX3RpbWUYBiAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxJDChhhcHBy", + "b3ZlZF9zdGFydF9kYXRlX3RpbWUYByABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWVCA+BBAxJCChh0b3RhbF9hZGp1c3RtZW50c19taWNyb3MY", + "EiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEj4KFGFt", + "b3VudF9zZXJ2ZWRfbWljcm9zGBMgASgLMhsuZ29vZ2xlLnByb3RvYnVmLklu", + "dDY0VmFsdWVCA+BBAxJAChVwdXJjaGFzZV9vcmRlcl9udW1iZXIYFCABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxIwCgVub3RlcxgV", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEmwKEHBl", + "bmRpbmdfcHJvcG9zYWwYFiABKAsyTS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5yZXNvdXJjZXMuQWNjb3VudEJ1ZGdldC5QZW5kaW5nQWNjb3VudEJ1ZGdl", + "dFByb3Bvc2FsQgPgQQMSQwoWcHJvcG9zZWRfZW5kX2RhdGVfdGltZRgIIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDSAASWwoWcHJv", + "cG9zZWRfZW5kX3RpbWVfdHlwZRgJIAEoDjI0Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zLlRpbWVUeXBlRW51bS5UaW1lVHlwZUID4EEDSAASQwoW", + "YXBwcm92ZWRfZW5kX2RhdGVfdGltZRgKIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZUID4EEDSAESWwoWYXBwcm92ZWRfZW5kX3RpbWVfdHlw", + "ZRgLIAEoDjI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLlRpbWVU", + "eXBlRW51bS5UaW1lVHlwZUID4EEDSAESSgoecHJvcG9zZWRfc3BlbmRpbmdf", + "bGltaXRfbWljcm9zGAwgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFs", + "dWVCA+BBA0gCEnMKHHByb3Bvc2VkX3NwZW5kaW5nX2xpbWl0X3R5cGUYDSAB", + "KA4yRi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5TcGVuZGluZ0xp", + "bWl0VHlwZUVudW0uU3BlbmRpbmdMaW1pdFR5cGVCA+BBA0gCEkoKHmFwcHJv", + "dmVkX3NwZW5kaW5nX2xpbWl0X21pY3JvcxgOIAEoCzIbLmdvb2dsZS5wcm90", + "b2J1Zi5JbnQ2NFZhbHVlQgPgQQNIAxJzChxhcHByb3ZlZF9zcGVuZGluZ19s", + "aW1pdF90eXBlGA8gASgOMkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMuU3BlbmRpbmdMaW1pdFR5cGVFbnVtLlNwZW5kaW5nTGltaXRUeXBlQgPg", + "QQNIAxJKCh5hZGp1c3RlZF9zcGVuZGluZ19saW1pdF9taWNyb3MYECABKAsy", + "Gy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDSAQScwocYWRqdXN0", + "ZWRfc3BlbmRpbmdfbGltaXRfdHlwZRgRIAEoDjJGLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVudW1zLlNwZW5kaW5nTGltaXRUeXBlRW51bS5TcGVuZGlu", + "Z0xpbWl0VHlwZUID4EEDSAQahgcKHFBlbmRpbmdBY2NvdW50QnVkZ2V0UHJv", + "cG9zYWwSdQoXYWNjb3VudF9idWRnZXRfcHJvcG9zYWwYASABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWVCNuBBA/pBMAouZ29vZ2xlYWRzLmdv", + "b2dsZWFwaXMuY29tL0FjY291bnRCdWRnZXRQcm9wb3NhbBJyCg1wcm9wb3Nh", + "bF90eXBlGAIgASgOMlYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMu", + "QWNjb3VudEJ1ZGdldFByb3Bvc2FsVHlwZUVudW0uQWNjb3VudEJ1ZGdldFBy", + "b3Bvc2FsVHlwZUID4EEDEi8KBG5hbWUYAyABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWVCA+BBAxI6Cg9zdGFydF9kYXRlX3RpbWUYBCABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxJAChVwdXJjaGFz", + "ZV9vcmRlcl9udW1iZXIYCSABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5n", + "VmFsdWVCA+BBAxIwCgVub3RlcxgKIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZUID4EEDEj0KEmNyZWF0aW9uX2RhdGVfdGltZRgLIAEoCzIc", + "Lmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEjoKDWVuZF9kYXRl", + "X3RpbWUYBSABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BB", + "A0gAElIKDWVuZF90aW1lX3R5cGUYBiABKA4yNC5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lbnVtcy5UaW1lVHlwZUVudW0uVGltZVR5cGVCA+BBA0gAEkEK", + "FXNwZW5kaW5nX2xpbWl0X21pY3JvcxgHIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQ2NFZhbHVlQgPgQQNIARJqChNzcGVuZGluZ19saW1pdF90eXBlGAgg", + "ASgOMkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuU3BlbmRpbmdM", + "aW1pdFR5cGVFbnVtLlNwZW5kaW5nTGltaXRUeXBlQgPgQQNIAUIKCghlbmRf", + "dGltZUIQCg5zcGVuZGluZ19saW1pdDph6kFeCiZnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vQWNjb3VudEJ1ZGdldBI0Y3VzdG9tZXJzL3tjdXN0b21lcn0v", + "YWNjb3VudEJ1ZGdldHMve2FjY291bnRfYnVkZ2V0fUITChFwcm9wb3NlZF9l", + "bmRfdGltZUITChFhcHByb3ZlZF9lbmRfdGltZUIZChdwcm9wb3NlZF9zcGVu", + "ZGluZ19saW1pdEIZChdhcHByb3ZlZF9zcGVuZGluZ19saW1pdEIZChdhZGp1", + "c3RlZF9zcGVuZGluZ19saW1pdEL/AQolY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlc0ISQWNjb3VudEJ1ZGdldFByb3RvUAFaSmdvb2ds", + "ZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFk", + "cy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5H", + "b29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJl", + "c291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.TimeTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AccountBudget), global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Parser, new[]{ "ResourceName", "Id", "BillingSetup", "Status", "Name", "ProposedStartDateTime", "ApprovedStartDateTime", "TotalAdjustmentsMicros", "AmountServedMicros", "PurchaseOrderNumber", "Notes", "PendingProposal", "ProposedEndDateTime", "ProposedEndTimeType", "ApprovedEndDateTime", "ApprovedEndTimeType", "ProposedSpendingLimitMicros", "ProposedSpendingLimitType", "ApprovedSpendingLimitMicros", "ApprovedSpendingLimitType", "AdjustedSpendingLimitMicros", "AdjustedSpendingLimitType" }, new[]{ "ProposedEndTime", "ApprovedEndTime", "ProposedSpendingLimit", "ApprovedSpendingLimit", "AdjustedSpendingLimit" }, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Types.PendingAccountBudgetProposal), global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Types.PendingAccountBudgetProposal.Parser, new[]{ "AccountBudgetProposal", "ProposalType", "Name", "StartDateTime", "PurchaseOrderNumber", "Notes", "CreationDateTime", "EndDateTime", "EndTimeType", "SpendingLimitMicros", "SpendingLimitType" }, new[]{ "EndTime", "SpendingLimit" }, null, null)}) + })); + } + #endregion + + } + #region Messages + /// + /// An account-level budget. It contains information about the budget itself, + /// as well as the most recently approved changes to the budget and proposed + /// changes that are pending approval. The proposed changes that are pending + /// approval, if any, are found in 'pending_proposal'. Effective details about + /// the budget are found in fields prefixed 'approved_', 'adjusted_' and those + /// without a prefix. Since some effective details may differ from what the user + /// had originally requested (e.g. spending limit), these differences are + /// juxtaposed via 'proposed_', 'approved_', and possibly 'adjusted_' fields. + /// + /// This resource is mutated using AccountBudgetProposal and cannot be mutated + /// directly. A budget may have at most one pending proposal at any given time. + /// It is read through pending_proposal. + /// + /// Once approved, a budget may be subject to adjustments, such as credit + /// adjustments. Adjustments create differences between the 'approved' and + /// 'adjusted' fields, which would otherwise be identical. + /// + public sealed partial class AccountBudget : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccountBudget()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudget() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudget(AccountBudget other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + BillingSetup = other.BillingSetup; + status_ = other.status_; + Name = other.Name; + ProposedStartDateTime = other.ProposedStartDateTime; + ApprovedStartDateTime = other.ApprovedStartDateTime; + TotalAdjustmentsMicros = other.TotalAdjustmentsMicros; + AmountServedMicros = other.AmountServedMicros; + PurchaseOrderNumber = other.PurchaseOrderNumber; + Notes = other.Notes; + pendingProposal_ = other.pendingProposal_ != null ? other.pendingProposal_.Clone() : null; + switch (other.ProposedEndTimeCase) { + case ProposedEndTimeOneofCase.ProposedEndDateTime: + ProposedEndDateTime = other.ProposedEndDateTime; + break; + case ProposedEndTimeOneofCase.ProposedEndTimeType: + ProposedEndTimeType = other.ProposedEndTimeType; + break; + } + + switch (other.ApprovedEndTimeCase) { + case ApprovedEndTimeOneofCase.ApprovedEndDateTime: + ApprovedEndDateTime = other.ApprovedEndDateTime; + break; + case ApprovedEndTimeOneofCase.ApprovedEndTimeType: + ApprovedEndTimeType = other.ApprovedEndTimeType; + break; + } + + switch (other.ProposedSpendingLimitCase) { + case ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros: + ProposedSpendingLimitMicros = other.ProposedSpendingLimitMicros; + break; + case ProposedSpendingLimitOneofCase.ProposedSpendingLimitType: + ProposedSpendingLimitType = other.ProposedSpendingLimitType; + break; + } + + switch (other.ApprovedSpendingLimitCase) { + case ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros: + ApprovedSpendingLimitMicros = other.ApprovedSpendingLimitMicros; + break; + case ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType: + ApprovedSpendingLimitType = other.ApprovedSpendingLimitType; + break; + } + + switch (other.AdjustedSpendingLimitCase) { + case AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitMicros: + AdjustedSpendingLimitMicros = other.AdjustedSpendingLimitMicros; + break; + case AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitType: + AdjustedSpendingLimitType = other.AdjustedSpendingLimitType; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudget Clone() { + return new AccountBudget(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the account-level budget. + /// AccountBudget resource names have the form: + /// + /// `customers/{customer_id}/accountBudgets/{account_budget_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the account-level budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "billing_setup" field. + public const int BillingSetupFieldNumber = 3; + private static readonly pb::FieldCodec _single_billingSetup_codec = pb::FieldCodec.ForClassWrapper(26); + private string billingSetup_; + /// + /// Output only. The resource name of the billing setup associated with this account-level + /// budget. BillingSetup resource names have the form: + /// + /// `customers/{customer_id}/billingSetups/{billing_setup_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BillingSetup { + get { return billingSetup_; } + set { + billingSetup_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetStatusEnum.Types.AccountBudgetStatus status_ = 0; + /// + /// Output only. The status of this account-level budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetStatusEnum.Types.AccountBudgetStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "name" field. + public const int NameFieldNumber = 5; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(42); + private string name_; + /// + /// Output only. The name of the account-level budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "proposed_start_date_time" field. + public const int ProposedStartDateTimeFieldNumber = 6; + private static readonly pb::FieldCodec _single_proposedStartDateTime_codec = pb::FieldCodec.ForClassWrapper(50); + private string proposedStartDateTime_; + /// + /// Output only. The proposed start time of the account-level budget in + /// yyyy-MM-dd HH:mm:ss format. If a start time type of NOW was proposed, + /// this is the time of request. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProposedStartDateTime { + get { return proposedStartDateTime_; } + set { + proposedStartDateTime_ = value; + } + } + + + /// Field number for the "approved_start_date_time" field. + public const int ApprovedStartDateTimeFieldNumber = 7; + private static readonly pb::FieldCodec _single_approvedStartDateTime_codec = pb::FieldCodec.ForClassWrapper(58); + private string approvedStartDateTime_; + /// + /// Output only. The approved start time of the account-level budget in yyyy-MM-dd HH:mm:ss + /// format. + /// + /// For example, if a new budget is approved after the proposed start time, + /// the approved start time is the time of approval. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ApprovedStartDateTime { + get { return approvedStartDateTime_; } + set { + approvedStartDateTime_ = value; + } + } + + + /// Field number for the "total_adjustments_micros" field. + public const int TotalAdjustmentsMicrosFieldNumber = 18; + private static readonly pb::FieldCodec _single_totalAdjustmentsMicros_codec = pb::FieldCodec.ForStructWrapper(146); + private long? totalAdjustmentsMicros_; + /// + /// Output only. The total adjustments amount. + /// + /// An example of an adjustment is courtesy credits. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TotalAdjustmentsMicros { + get { return totalAdjustmentsMicros_; } + set { + totalAdjustmentsMicros_ = value; + } + } + + + /// Field number for the "amount_served_micros" field. + public const int AmountServedMicrosFieldNumber = 19; + private static readonly pb::FieldCodec _single_amountServedMicros_codec = pb::FieldCodec.ForStructWrapper(154); + private long? amountServedMicros_; + /// + /// Output only. The value of Ads that have been served, in micros. + /// + /// This includes overdelivery costs, in which case a credit might be + /// automatically applied to the budget (see total_adjustments_micros). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AmountServedMicros { + get { return amountServedMicros_; } + set { + amountServedMicros_ = value; + } + } + + + /// Field number for the "purchase_order_number" field. + public const int PurchaseOrderNumberFieldNumber = 20; + private static readonly pb::FieldCodec _single_purchaseOrderNumber_codec = pb::FieldCodec.ForClassWrapper(162); + private string purchaseOrderNumber_; + /// + /// Output only. A purchase order number is a value that helps users reference this budget + /// in their monthly invoices. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PurchaseOrderNumber { + get { return purchaseOrderNumber_; } + set { + purchaseOrderNumber_ = value; + } + } + + + /// Field number for the "notes" field. + public const int NotesFieldNumber = 21; + private static readonly pb::FieldCodec _single_notes_codec = pb::FieldCodec.ForClassWrapper(170); + private string notes_; + /// + /// Output only. Notes associated with the budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Notes { + get { return notes_; } + set { + notes_ = value; + } + } + + + /// Field number for the "pending_proposal" field. + public const int PendingProposalFieldNumber = 22; + private global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Types.PendingAccountBudgetProposal pendingProposal_; + /// + /// Output only. The pending proposal to modify this budget, if applicable. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Types.PendingAccountBudgetProposal PendingProposal { + get { return pendingProposal_; } + set { + pendingProposal_ = value; + } + } + + /// Field number for the "proposed_end_date_time" field. + public const int ProposedEndDateTimeFieldNumber = 8; + private static readonly pb::FieldCodec _oneof_proposedEndDateTime_codec = pb::FieldCodec.ForClassWrapper(66); + /// + /// Output only. The proposed end time in yyyy-MM-dd HH:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProposedEndDateTime { + get { return proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndDateTime ? (string) proposedEndTime_ : (string) null; } + set { + proposedEndTime_ = value; + proposedEndTimeCase_ = value == null ? ProposedEndTimeOneofCase.None : ProposedEndTimeOneofCase.ProposedEndDateTime; + } + } + + /// Field number for the "proposed_end_time_type" field. + public const int ProposedEndTimeTypeFieldNumber = 9; + /// + /// Output only. The proposed end time as a well-defined type, e.g. FOREVER. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType ProposedEndTimeType { + get { return proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndTimeType ? (global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType) proposedEndTime_ : 0; } + set { + proposedEndTime_ = value; + proposedEndTimeCase_ = ProposedEndTimeOneofCase.ProposedEndTimeType; + } + } + + /// Field number for the "approved_end_date_time" field. + public const int ApprovedEndDateTimeFieldNumber = 10; + private static readonly pb::FieldCodec _oneof_approvedEndDateTime_codec = pb::FieldCodec.ForClassWrapper(82); + /// + /// Output only. The approved end time in yyyy-MM-dd HH:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ApprovedEndDateTime { + get { return approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndDateTime ? (string) approvedEndTime_ : (string) null; } + set { + approvedEndTime_ = value; + approvedEndTimeCase_ = value == null ? ApprovedEndTimeOneofCase.None : ApprovedEndTimeOneofCase.ApprovedEndDateTime; + } + } + + /// Field number for the "approved_end_time_type" field. + public const int ApprovedEndTimeTypeFieldNumber = 11; + /// + /// Output only. The approved end time as a well-defined type, e.g. FOREVER. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType ApprovedEndTimeType { + get { return approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndTimeType ? (global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType) approvedEndTime_ : 0; } + set { + approvedEndTime_ = value; + approvedEndTimeCase_ = ApprovedEndTimeOneofCase.ApprovedEndTimeType; + } + } + + /// Field number for the "proposed_spending_limit_micros" field. + public const int ProposedSpendingLimitMicrosFieldNumber = 12; + private static readonly pb::FieldCodec _oneof_proposedSpendingLimitMicros_codec = pb::FieldCodec.ForStructWrapper(98); + /// + /// Output only. The proposed spending limit in micros. One million is equivalent to + /// one unit. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ProposedSpendingLimitMicros { + get { return proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros ? (long?) proposedSpendingLimit_ : (long?) null; } + set { + proposedSpendingLimit_ = value; + proposedSpendingLimitCase_ = value == null ? ProposedSpendingLimitOneofCase.None : ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros; + } + } + + /// Field number for the "proposed_spending_limit_type" field. + public const int ProposedSpendingLimitTypeFieldNumber = 13; + /// + /// Output only. The proposed spending limit as a well-defined type, e.g. INFINITE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType ProposedSpendingLimitType { + get { return proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitType ? (global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType) proposedSpendingLimit_ : 0; } + set { + proposedSpendingLimit_ = value; + proposedSpendingLimitCase_ = ProposedSpendingLimitOneofCase.ProposedSpendingLimitType; + } + } + + /// Field number for the "approved_spending_limit_micros" field. + public const int ApprovedSpendingLimitMicrosFieldNumber = 14; + private static readonly pb::FieldCodec _oneof_approvedSpendingLimitMicros_codec = pb::FieldCodec.ForStructWrapper(114); + /// + /// Output only. The approved spending limit in micros. One million is equivalent to + /// one unit. This will only be populated if the proposed spending limit + /// is finite, and will always be greater than or equal to the + /// proposed spending limit. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ApprovedSpendingLimitMicros { + get { return approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros ? (long?) approvedSpendingLimit_ : (long?) null; } + set { + approvedSpendingLimit_ = value; + approvedSpendingLimitCase_ = value == null ? ApprovedSpendingLimitOneofCase.None : ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros; + } + } + + /// Field number for the "approved_spending_limit_type" field. + public const int ApprovedSpendingLimitTypeFieldNumber = 15; + /// + /// Output only. The approved spending limit as a well-defined type, e.g. INFINITE. This + /// will only be populated if the approved spending limit is INFINITE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType ApprovedSpendingLimitType { + get { return approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType ? (global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType) approvedSpendingLimit_ : 0; } + set { + approvedSpendingLimit_ = value; + approvedSpendingLimitCase_ = ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType; + } + } + + /// Field number for the "adjusted_spending_limit_micros" field. + public const int AdjustedSpendingLimitMicrosFieldNumber = 16; + private static readonly pb::FieldCodec _oneof_adjustedSpendingLimitMicros_codec = pb::FieldCodec.ForStructWrapper(130); + /// + /// Output only. The adjusted spending limit in micros. One million is equivalent to + /// one unit. + /// + /// If the approved spending limit is finite, the adjusted + /// spending limit may vary depending on the types of adjustments applied + /// to this budget, if applicable. + /// + /// The different kinds of adjustments are described here: + /// https://support.google.com/google-ads/answer/1704323 + /// + /// For example, a debit adjustment reduces how much the account is + /// allowed to spend. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AdjustedSpendingLimitMicros { + get { return adjustedSpendingLimitCase_ == AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitMicros ? (long?) adjustedSpendingLimit_ : (long?) null; } + set { + adjustedSpendingLimit_ = value; + adjustedSpendingLimitCase_ = value == null ? AdjustedSpendingLimitOneofCase.None : AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitMicros; + } + } + + /// Field number for the "adjusted_spending_limit_type" field. + public const int AdjustedSpendingLimitTypeFieldNumber = 17; + /// + /// Output only. The adjusted spending limit as a well-defined type, e.g. INFINITE. + /// This will only be populated if the adjusted spending limit is INFINITE, + /// which is guaranteed to be true if the approved spending limit is + /// INFINITE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType AdjustedSpendingLimitType { + get { return adjustedSpendingLimitCase_ == AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitType ? (global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType) adjustedSpendingLimit_ : 0; } + set { + adjustedSpendingLimit_ = value; + adjustedSpendingLimitCase_ = AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitType; + } + } + + private object proposedEndTime_; + /// Enum of possible cases for the "proposed_end_time" oneof. + public enum ProposedEndTimeOneofCase { + None = 0, + ProposedEndDateTime = 8, + ProposedEndTimeType = 9, + } + private ProposedEndTimeOneofCase proposedEndTimeCase_ = ProposedEndTimeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProposedEndTimeOneofCase ProposedEndTimeCase { + get { return proposedEndTimeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearProposedEndTime() { + proposedEndTimeCase_ = ProposedEndTimeOneofCase.None; + proposedEndTime_ = null; + } + + private object approvedEndTime_; + /// Enum of possible cases for the "approved_end_time" oneof. + public enum ApprovedEndTimeOneofCase { + None = 0, + ApprovedEndDateTime = 10, + ApprovedEndTimeType = 11, + } + private ApprovedEndTimeOneofCase approvedEndTimeCase_ = ApprovedEndTimeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ApprovedEndTimeOneofCase ApprovedEndTimeCase { + get { return approvedEndTimeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearApprovedEndTime() { + approvedEndTimeCase_ = ApprovedEndTimeOneofCase.None; + approvedEndTime_ = null; + } + + private object proposedSpendingLimit_; + /// Enum of possible cases for the "proposed_spending_limit" oneof. + public enum ProposedSpendingLimitOneofCase { + None = 0, + ProposedSpendingLimitMicros = 12, + ProposedSpendingLimitType = 13, + } + private ProposedSpendingLimitOneofCase proposedSpendingLimitCase_ = ProposedSpendingLimitOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProposedSpendingLimitOneofCase ProposedSpendingLimitCase { + get { return proposedSpendingLimitCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearProposedSpendingLimit() { + proposedSpendingLimitCase_ = ProposedSpendingLimitOneofCase.None; + proposedSpendingLimit_ = null; + } + + private object approvedSpendingLimit_; + /// Enum of possible cases for the "approved_spending_limit" oneof. + public enum ApprovedSpendingLimitOneofCase { + None = 0, + ApprovedSpendingLimitMicros = 14, + ApprovedSpendingLimitType = 15, + } + private ApprovedSpendingLimitOneofCase approvedSpendingLimitCase_ = ApprovedSpendingLimitOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ApprovedSpendingLimitOneofCase ApprovedSpendingLimitCase { + get { return approvedSpendingLimitCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearApprovedSpendingLimit() { + approvedSpendingLimitCase_ = ApprovedSpendingLimitOneofCase.None; + approvedSpendingLimit_ = null; + } + + private object adjustedSpendingLimit_; + /// Enum of possible cases for the "adjusted_spending_limit" oneof. + public enum AdjustedSpendingLimitOneofCase { + None = 0, + AdjustedSpendingLimitMicros = 16, + AdjustedSpendingLimitType = 17, + } + private AdjustedSpendingLimitOneofCase adjustedSpendingLimitCase_ = AdjustedSpendingLimitOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdjustedSpendingLimitOneofCase AdjustedSpendingLimitCase { + get { return adjustedSpendingLimitCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearAdjustedSpendingLimit() { + adjustedSpendingLimitCase_ = AdjustedSpendingLimitOneofCase.None; + adjustedSpendingLimit_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccountBudget); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccountBudget other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (BillingSetup != other.BillingSetup) return false; + if (Status != other.Status) return false; + if (Name != other.Name) return false; + if (ProposedStartDateTime != other.ProposedStartDateTime) return false; + if (ApprovedStartDateTime != other.ApprovedStartDateTime) return false; + if (TotalAdjustmentsMicros != other.TotalAdjustmentsMicros) return false; + if (AmountServedMicros != other.AmountServedMicros) return false; + if (PurchaseOrderNumber != other.PurchaseOrderNumber) return false; + if (Notes != other.Notes) return false; + if (!object.Equals(PendingProposal, other.PendingProposal)) return false; + if (ProposedEndDateTime != other.ProposedEndDateTime) return false; + if (ProposedEndTimeType != other.ProposedEndTimeType) return false; + if (ApprovedEndDateTime != other.ApprovedEndDateTime) return false; + if (ApprovedEndTimeType != other.ApprovedEndTimeType) return false; + if (ProposedSpendingLimitMicros != other.ProposedSpendingLimitMicros) return false; + if (ProposedSpendingLimitType != other.ProposedSpendingLimitType) return false; + if (ApprovedSpendingLimitMicros != other.ApprovedSpendingLimitMicros) return false; + if (ApprovedSpendingLimitType != other.ApprovedSpendingLimitType) return false; + if (AdjustedSpendingLimitMicros != other.AdjustedSpendingLimitMicros) return false; + if (AdjustedSpendingLimitType != other.AdjustedSpendingLimitType) return false; + if (ProposedEndTimeCase != other.ProposedEndTimeCase) return false; + if (ApprovedEndTimeCase != other.ApprovedEndTimeCase) return false; + if (ProposedSpendingLimitCase != other.ProposedSpendingLimitCase) return false; + if (ApprovedSpendingLimitCase != other.ApprovedSpendingLimitCase) return false; + if (AdjustedSpendingLimitCase != other.AdjustedSpendingLimitCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (billingSetup_ != null) hash ^= BillingSetup.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (proposedStartDateTime_ != null) hash ^= ProposedStartDateTime.GetHashCode(); + if (approvedStartDateTime_ != null) hash ^= ApprovedStartDateTime.GetHashCode(); + if (totalAdjustmentsMicros_ != null) hash ^= TotalAdjustmentsMicros.GetHashCode(); + if (amountServedMicros_ != null) hash ^= AmountServedMicros.GetHashCode(); + if (purchaseOrderNumber_ != null) hash ^= PurchaseOrderNumber.GetHashCode(); + if (notes_ != null) hash ^= Notes.GetHashCode(); + if (pendingProposal_ != null) hash ^= PendingProposal.GetHashCode(); + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndDateTime) hash ^= ProposedEndDateTime.GetHashCode(); + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndTimeType) hash ^= ProposedEndTimeType.GetHashCode(); + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndDateTime) hash ^= ApprovedEndDateTime.GetHashCode(); + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndTimeType) hash ^= ApprovedEndTimeType.GetHashCode(); + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros) hash ^= ProposedSpendingLimitMicros.GetHashCode(); + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitType) hash ^= ProposedSpendingLimitType.GetHashCode(); + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros) hash ^= ApprovedSpendingLimitMicros.GetHashCode(); + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType) hash ^= ApprovedSpendingLimitType.GetHashCode(); + if (adjustedSpendingLimitCase_ == AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitMicros) hash ^= AdjustedSpendingLimitMicros.GetHashCode(); + if (adjustedSpendingLimitCase_ == AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitType) hash ^= AdjustedSpendingLimitType.GetHashCode(); + hash ^= (int) proposedEndTimeCase_; + hash ^= (int) approvedEndTimeCase_; + hash ^= (int) proposedSpendingLimitCase_; + hash ^= (int) approvedSpendingLimitCase_; + hash ^= (int) adjustedSpendingLimitCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (billingSetup_ != null) { + _single_billingSetup_codec.WriteTagAndValue(output, BillingSetup); + } + if (Status != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) Status); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (proposedStartDateTime_ != null) { + _single_proposedStartDateTime_codec.WriteTagAndValue(output, ProposedStartDateTime); + } + if (approvedStartDateTime_ != null) { + _single_approvedStartDateTime_codec.WriteTagAndValue(output, ApprovedStartDateTime); + } + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndDateTime) { + _oneof_proposedEndDateTime_codec.WriteTagAndValue(output, (string) proposedEndTime_); + } + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndTimeType) { + output.WriteRawTag(72); + output.WriteEnum((int) ProposedEndTimeType); + } + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndDateTime) { + _oneof_approvedEndDateTime_codec.WriteTagAndValue(output, (string) approvedEndTime_); + } + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndTimeType) { + output.WriteRawTag(88); + output.WriteEnum((int) ApprovedEndTimeType); + } + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros) { + _oneof_proposedSpendingLimitMicros_codec.WriteTagAndValue(output, (long?) proposedSpendingLimit_); + } + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitType) { + output.WriteRawTag(104); + output.WriteEnum((int) ProposedSpendingLimitType); + } + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros) { + _oneof_approvedSpendingLimitMicros_codec.WriteTagAndValue(output, (long?) approvedSpendingLimit_); + } + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType) { + output.WriteRawTag(120); + output.WriteEnum((int) ApprovedSpendingLimitType); + } + if (adjustedSpendingLimitCase_ == AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitMicros) { + _oneof_adjustedSpendingLimitMicros_codec.WriteTagAndValue(output, (long?) adjustedSpendingLimit_); + } + if (adjustedSpendingLimitCase_ == AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitType) { + output.WriteRawTag(136, 1); + output.WriteEnum((int) AdjustedSpendingLimitType); + } + if (totalAdjustmentsMicros_ != null) { + _single_totalAdjustmentsMicros_codec.WriteTagAndValue(output, TotalAdjustmentsMicros); + } + if (amountServedMicros_ != null) { + _single_amountServedMicros_codec.WriteTagAndValue(output, AmountServedMicros); + } + if (purchaseOrderNumber_ != null) { + _single_purchaseOrderNumber_codec.WriteTagAndValue(output, PurchaseOrderNumber); + } + if (notes_ != null) { + _single_notes_codec.WriteTagAndValue(output, Notes); + } + if (pendingProposal_ != null) { + output.WriteRawTag(178, 1); + output.WriteMessage(PendingProposal); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (billingSetup_ != null) { + size += _single_billingSetup_codec.CalculateSizeWithTag(BillingSetup); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (proposedStartDateTime_ != null) { + size += _single_proposedStartDateTime_codec.CalculateSizeWithTag(ProposedStartDateTime); + } + if (approvedStartDateTime_ != null) { + size += _single_approvedStartDateTime_codec.CalculateSizeWithTag(ApprovedStartDateTime); + } + if (totalAdjustmentsMicros_ != null) { + size += _single_totalAdjustmentsMicros_codec.CalculateSizeWithTag(TotalAdjustmentsMicros); + } + if (amountServedMicros_ != null) { + size += _single_amountServedMicros_codec.CalculateSizeWithTag(AmountServedMicros); + } + if (purchaseOrderNumber_ != null) { + size += _single_purchaseOrderNumber_codec.CalculateSizeWithTag(PurchaseOrderNumber); + } + if (notes_ != null) { + size += _single_notes_codec.CalculateSizeWithTag(Notes); + } + if (pendingProposal_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(PendingProposal); + } + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndDateTime) { + size += _oneof_proposedEndDateTime_codec.CalculateSizeWithTag(ProposedEndDateTime); + } + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndTimeType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ProposedEndTimeType); + } + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndDateTime) { + size += _oneof_approvedEndDateTime_codec.CalculateSizeWithTag(ApprovedEndDateTime); + } + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndTimeType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ApprovedEndTimeType); + } + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros) { + size += _oneof_proposedSpendingLimitMicros_codec.CalculateSizeWithTag(ProposedSpendingLimitMicros); + } + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ProposedSpendingLimitType); + } + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros) { + size += _oneof_approvedSpendingLimitMicros_codec.CalculateSizeWithTag(ApprovedSpendingLimitMicros); + } + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ApprovedSpendingLimitType); + } + if (adjustedSpendingLimitCase_ == AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitMicros) { + size += _oneof_adjustedSpendingLimitMicros_codec.CalculateSizeWithTag(AdjustedSpendingLimitMicros); + } + if (adjustedSpendingLimitCase_ == AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitType) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdjustedSpendingLimitType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccountBudget other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.billingSetup_ != null) { + if (billingSetup_ == null || other.BillingSetup != "") { + BillingSetup = other.BillingSetup; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.proposedStartDateTime_ != null) { + if (proposedStartDateTime_ == null || other.ProposedStartDateTime != "") { + ProposedStartDateTime = other.ProposedStartDateTime; + } + } + if (other.approvedStartDateTime_ != null) { + if (approvedStartDateTime_ == null || other.ApprovedStartDateTime != "") { + ApprovedStartDateTime = other.ApprovedStartDateTime; + } + } + if (other.totalAdjustmentsMicros_ != null) { + if (totalAdjustmentsMicros_ == null || other.TotalAdjustmentsMicros != 0L) { + TotalAdjustmentsMicros = other.TotalAdjustmentsMicros; + } + } + if (other.amountServedMicros_ != null) { + if (amountServedMicros_ == null || other.AmountServedMicros != 0L) { + AmountServedMicros = other.AmountServedMicros; + } + } + if (other.purchaseOrderNumber_ != null) { + if (purchaseOrderNumber_ == null || other.PurchaseOrderNumber != "") { + PurchaseOrderNumber = other.PurchaseOrderNumber; + } + } + if (other.notes_ != null) { + if (notes_ == null || other.Notes != "") { + Notes = other.Notes; + } + } + if (other.pendingProposal_ != null) { + if (pendingProposal_ == null) { + PendingProposal = new global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Types.PendingAccountBudgetProposal(); + } + PendingProposal.MergeFrom(other.PendingProposal); + } + switch (other.ProposedEndTimeCase) { + case ProposedEndTimeOneofCase.ProposedEndDateTime: + ProposedEndDateTime = other.ProposedEndDateTime; + break; + case ProposedEndTimeOneofCase.ProposedEndTimeType: + ProposedEndTimeType = other.ProposedEndTimeType; + break; + } + + switch (other.ApprovedEndTimeCase) { + case ApprovedEndTimeOneofCase.ApprovedEndDateTime: + ApprovedEndDateTime = other.ApprovedEndDateTime; + break; + case ApprovedEndTimeOneofCase.ApprovedEndTimeType: + ApprovedEndTimeType = other.ApprovedEndTimeType; + break; + } + + switch (other.ProposedSpendingLimitCase) { + case ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros: + ProposedSpendingLimitMicros = other.ProposedSpendingLimitMicros; + break; + case ProposedSpendingLimitOneofCase.ProposedSpendingLimitType: + ProposedSpendingLimitType = other.ProposedSpendingLimitType; + break; + } + + switch (other.ApprovedSpendingLimitCase) { + case ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros: + ApprovedSpendingLimitMicros = other.ApprovedSpendingLimitMicros; + break; + case ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType: + ApprovedSpendingLimitType = other.ApprovedSpendingLimitType; + break; + } + + switch (other.AdjustedSpendingLimitCase) { + case AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitMicros: + AdjustedSpendingLimitMicros = other.AdjustedSpendingLimitMicros; + break; + case AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitType: + AdjustedSpendingLimitType = other.AdjustedSpendingLimitType; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 26: { + string value = _single_billingSetup_codec.Read(input); + if (billingSetup_ == null || value != "") { + BillingSetup = value; + } + break; + } + case 32: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetStatusEnum.Types.AccountBudgetStatus) input.ReadEnum(); + break; + } + case 42: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 50: { + string value = _single_proposedStartDateTime_codec.Read(input); + if (proposedStartDateTime_ == null || value != "") { + ProposedStartDateTime = value; + } + break; + } + case 58: { + string value = _single_approvedStartDateTime_codec.Read(input); + if (approvedStartDateTime_ == null || value != "") { + ApprovedStartDateTime = value; + } + break; + } + case 66: { + ProposedEndDateTime = _oneof_proposedEndDateTime_codec.Read(input); + break; + } + case 72: { + proposedEndTime_ = input.ReadEnum(); + proposedEndTimeCase_ = ProposedEndTimeOneofCase.ProposedEndTimeType; + break; + } + case 82: { + ApprovedEndDateTime = _oneof_approvedEndDateTime_codec.Read(input); + break; + } + case 88: { + approvedEndTime_ = input.ReadEnum(); + approvedEndTimeCase_ = ApprovedEndTimeOneofCase.ApprovedEndTimeType; + break; + } + case 98: { + ProposedSpendingLimitMicros = _oneof_proposedSpendingLimitMicros_codec.Read(input); + break; + } + case 104: { + proposedSpendingLimit_ = input.ReadEnum(); + proposedSpendingLimitCase_ = ProposedSpendingLimitOneofCase.ProposedSpendingLimitType; + break; + } + case 114: { + ApprovedSpendingLimitMicros = _oneof_approvedSpendingLimitMicros_codec.Read(input); + break; + } + case 120: { + approvedSpendingLimit_ = input.ReadEnum(); + approvedSpendingLimitCase_ = ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType; + break; + } + case 130: { + AdjustedSpendingLimitMicros = _oneof_adjustedSpendingLimitMicros_codec.Read(input); + break; + } + case 136: { + adjustedSpendingLimit_ = input.ReadEnum(); + adjustedSpendingLimitCase_ = AdjustedSpendingLimitOneofCase.AdjustedSpendingLimitType; + break; + } + case 146: { + long? value = _single_totalAdjustmentsMicros_codec.Read(input); + if (totalAdjustmentsMicros_ == null || value != 0L) { + TotalAdjustmentsMicros = value; + } + break; + } + case 154: { + long? value = _single_amountServedMicros_codec.Read(input); + if (amountServedMicros_ == null || value != 0L) { + AmountServedMicros = value; + } + break; + } + case 162: { + string value = _single_purchaseOrderNumber_codec.Read(input); + if (purchaseOrderNumber_ == null || value != "") { + PurchaseOrderNumber = value; + } + break; + } + case 170: { + string value = _single_notes_codec.Read(input); + if (notes_ == null || value != "") { + Notes = value; + } + break; + } + case 178: { + if (pendingProposal_ == null) { + PendingProposal = new global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Types.PendingAccountBudgetProposal(); + } + input.ReadMessage(PendingProposal); + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the AccountBudget message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// A pending proposal associated with the enclosing account-level budget, + /// if applicable. + /// + public sealed partial class PendingAccountBudgetProposal : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PendingAccountBudgetProposal()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PendingAccountBudgetProposal() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PendingAccountBudgetProposal(PendingAccountBudgetProposal other) : this() { + AccountBudgetProposal = other.AccountBudgetProposal; + proposalType_ = other.proposalType_; + Name = other.Name; + StartDateTime = other.StartDateTime; + PurchaseOrderNumber = other.PurchaseOrderNumber; + Notes = other.Notes; + CreationDateTime = other.CreationDateTime; + switch (other.EndTimeCase) { + case EndTimeOneofCase.EndDateTime: + EndDateTime = other.EndDateTime; + break; + case EndTimeOneofCase.EndTimeType: + EndTimeType = other.EndTimeType; + break; + } + + switch (other.SpendingLimitCase) { + case SpendingLimitOneofCase.SpendingLimitMicros: + SpendingLimitMicros = other.SpendingLimitMicros; + break; + case SpendingLimitOneofCase.SpendingLimitType: + SpendingLimitType = other.SpendingLimitType; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PendingAccountBudgetProposal Clone() { + return new PendingAccountBudgetProposal(this); + } + + /// Field number for the "account_budget_proposal" field. + public const int AccountBudgetProposalFieldNumber = 1; + private static readonly pb::FieldCodec _single_accountBudgetProposal_codec = pb::FieldCodec.ForClassWrapper(10); + private string accountBudgetProposal_; + /// + /// Output only. The resource name of the proposal. + /// AccountBudgetProposal resource names have the form: + /// + /// `customers/{customer_id}/accountBudgetProposals/{account_budget_proposal_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AccountBudgetProposal { + get { return accountBudgetProposal_; } + set { + accountBudgetProposal_ = value; + } + } + + + /// Field number for the "proposal_type" field. + public const int ProposalTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Types.AccountBudgetProposalType proposalType_ = 0; + /// + /// Output only. The type of this proposal, e.g. END to end the budget associated + /// with this proposal. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Types.AccountBudgetProposalType ProposalType { + get { return proposalType_; } + set { + proposalType_ = value; + } + } + + /// Field number for the "name" field. + public const int NameFieldNumber = 3; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(26); + private string name_; + /// + /// Output only. The name to assign to the account-level budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "start_date_time" field. + public const int StartDateTimeFieldNumber = 4; + private static readonly pb::FieldCodec _single_startDateTime_codec = pb::FieldCodec.ForClassWrapper(34); + private string startDateTime_; + /// + /// Output only. The start time in yyyy-MM-dd HH:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDateTime { + get { return startDateTime_; } + set { + startDateTime_ = value; + } + } + + + /// Field number for the "purchase_order_number" field. + public const int PurchaseOrderNumberFieldNumber = 9; + private static readonly pb::FieldCodec _single_purchaseOrderNumber_codec = pb::FieldCodec.ForClassWrapper(74); + private string purchaseOrderNumber_; + /// + /// Output only. A purchase order number is a value that helps users reference this budget + /// in their monthly invoices. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PurchaseOrderNumber { + get { return purchaseOrderNumber_; } + set { + purchaseOrderNumber_ = value; + } + } + + + /// Field number for the "notes" field. + public const int NotesFieldNumber = 10; + private static readonly pb::FieldCodec _single_notes_codec = pb::FieldCodec.ForClassWrapper(82); + private string notes_; + /// + /// Output only. Notes associated with this budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Notes { + get { return notes_; } + set { + notes_ = value; + } + } + + + /// Field number for the "creation_date_time" field. + public const int CreationDateTimeFieldNumber = 11; + private static readonly pb::FieldCodec _single_creationDateTime_codec = pb::FieldCodec.ForClassWrapper(90); + private string creationDateTime_; + /// + /// Output only. The time when this account-level budget proposal was created. + /// Formatted as yyyy-MM-dd HH:mm:ss. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CreationDateTime { + get { return creationDateTime_; } + set { + creationDateTime_ = value; + } + } + + + /// Field number for the "end_date_time" field. + public const int EndDateTimeFieldNumber = 5; + private static readonly pb::FieldCodec _oneof_endDateTime_codec = pb::FieldCodec.ForClassWrapper(42); + /// + /// Output only. The end time in yyyy-MM-dd HH:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDateTime { + get { return endTimeCase_ == EndTimeOneofCase.EndDateTime ? (string) endTime_ : (string) null; } + set { + endTime_ = value; + endTimeCase_ = value == null ? EndTimeOneofCase.None : EndTimeOneofCase.EndDateTime; + } + } + + /// Field number for the "end_time_type" field. + public const int EndTimeTypeFieldNumber = 6; + /// + /// Output only. The end time as a well-defined type, e.g. FOREVER. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType EndTimeType { + get { return endTimeCase_ == EndTimeOneofCase.EndTimeType ? (global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType) endTime_ : 0; } + set { + endTime_ = value; + endTimeCase_ = EndTimeOneofCase.EndTimeType; + } + } + + /// Field number for the "spending_limit_micros" field. + public const int SpendingLimitMicrosFieldNumber = 7; + private static readonly pb::FieldCodec _oneof_spendingLimitMicros_codec = pb::FieldCodec.ForStructWrapper(58); + /// + /// Output only. The spending limit in micros. One million is equivalent to + /// one unit. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? SpendingLimitMicros { + get { return spendingLimitCase_ == SpendingLimitOneofCase.SpendingLimitMicros ? (long?) spendingLimit_ : (long?) null; } + set { + spendingLimit_ = value; + spendingLimitCase_ = value == null ? SpendingLimitOneofCase.None : SpendingLimitOneofCase.SpendingLimitMicros; + } + } + + /// Field number for the "spending_limit_type" field. + public const int SpendingLimitTypeFieldNumber = 8; + /// + /// Output only. The spending limit as a well-defined type, e.g. INFINITE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType SpendingLimitType { + get { return spendingLimitCase_ == SpendingLimitOneofCase.SpendingLimitType ? (global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType) spendingLimit_ : 0; } + set { + spendingLimit_ = value; + spendingLimitCase_ = SpendingLimitOneofCase.SpendingLimitType; + } + } + + private object endTime_; + /// Enum of possible cases for the "end_time" oneof. + public enum EndTimeOneofCase { + None = 0, + EndDateTime = 5, + EndTimeType = 6, + } + private EndTimeOneofCase endTimeCase_ = EndTimeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EndTimeOneofCase EndTimeCase { + get { return endTimeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearEndTime() { + endTimeCase_ = EndTimeOneofCase.None; + endTime_ = null; + } + + private object spendingLimit_; + /// Enum of possible cases for the "spending_limit" oneof. + public enum SpendingLimitOneofCase { + None = 0, + SpendingLimitMicros = 7, + SpendingLimitType = 8, + } + private SpendingLimitOneofCase spendingLimitCase_ = SpendingLimitOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SpendingLimitOneofCase SpendingLimitCase { + get { return spendingLimitCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearSpendingLimit() { + spendingLimitCase_ = SpendingLimitOneofCase.None; + spendingLimit_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PendingAccountBudgetProposal); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PendingAccountBudgetProposal other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (AccountBudgetProposal != other.AccountBudgetProposal) return false; + if (ProposalType != other.ProposalType) return false; + if (Name != other.Name) return false; + if (StartDateTime != other.StartDateTime) return false; + if (PurchaseOrderNumber != other.PurchaseOrderNumber) return false; + if (Notes != other.Notes) return false; + if (CreationDateTime != other.CreationDateTime) return false; + if (EndDateTime != other.EndDateTime) return false; + if (EndTimeType != other.EndTimeType) return false; + if (SpendingLimitMicros != other.SpendingLimitMicros) return false; + if (SpendingLimitType != other.SpendingLimitType) return false; + if (EndTimeCase != other.EndTimeCase) return false; + if (SpendingLimitCase != other.SpendingLimitCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (accountBudgetProposal_ != null) hash ^= AccountBudgetProposal.GetHashCode(); + if (ProposalType != 0) hash ^= ProposalType.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (startDateTime_ != null) hash ^= StartDateTime.GetHashCode(); + if (purchaseOrderNumber_ != null) hash ^= PurchaseOrderNumber.GetHashCode(); + if (notes_ != null) hash ^= Notes.GetHashCode(); + if (creationDateTime_ != null) hash ^= CreationDateTime.GetHashCode(); + if (endTimeCase_ == EndTimeOneofCase.EndDateTime) hash ^= EndDateTime.GetHashCode(); + if (endTimeCase_ == EndTimeOneofCase.EndTimeType) hash ^= EndTimeType.GetHashCode(); + if (spendingLimitCase_ == SpendingLimitOneofCase.SpendingLimitMicros) hash ^= SpendingLimitMicros.GetHashCode(); + if (spendingLimitCase_ == SpendingLimitOneofCase.SpendingLimitType) hash ^= SpendingLimitType.GetHashCode(); + hash ^= (int) endTimeCase_; + hash ^= (int) spendingLimitCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (accountBudgetProposal_ != null) { + _single_accountBudgetProposal_codec.WriteTagAndValue(output, AccountBudgetProposal); + } + if (ProposalType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) ProposalType); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (startDateTime_ != null) { + _single_startDateTime_codec.WriteTagAndValue(output, StartDateTime); + } + if (endTimeCase_ == EndTimeOneofCase.EndDateTime) { + _oneof_endDateTime_codec.WriteTagAndValue(output, (string) endTime_); + } + if (endTimeCase_ == EndTimeOneofCase.EndTimeType) { + output.WriteRawTag(48); + output.WriteEnum((int) EndTimeType); + } + if (spendingLimitCase_ == SpendingLimitOneofCase.SpendingLimitMicros) { + _oneof_spendingLimitMicros_codec.WriteTagAndValue(output, (long?) spendingLimit_); + } + if (spendingLimitCase_ == SpendingLimitOneofCase.SpendingLimitType) { + output.WriteRawTag(64); + output.WriteEnum((int) SpendingLimitType); + } + if (purchaseOrderNumber_ != null) { + _single_purchaseOrderNumber_codec.WriteTagAndValue(output, PurchaseOrderNumber); + } + if (notes_ != null) { + _single_notes_codec.WriteTagAndValue(output, Notes); + } + if (creationDateTime_ != null) { + _single_creationDateTime_codec.WriteTagAndValue(output, CreationDateTime); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (accountBudgetProposal_ != null) { + size += _single_accountBudgetProposal_codec.CalculateSizeWithTag(AccountBudgetProposal); + } + if (ProposalType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ProposalType); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (startDateTime_ != null) { + size += _single_startDateTime_codec.CalculateSizeWithTag(StartDateTime); + } + if (purchaseOrderNumber_ != null) { + size += _single_purchaseOrderNumber_codec.CalculateSizeWithTag(PurchaseOrderNumber); + } + if (notes_ != null) { + size += _single_notes_codec.CalculateSizeWithTag(Notes); + } + if (creationDateTime_ != null) { + size += _single_creationDateTime_codec.CalculateSizeWithTag(CreationDateTime); + } + if (endTimeCase_ == EndTimeOneofCase.EndDateTime) { + size += _oneof_endDateTime_codec.CalculateSizeWithTag(EndDateTime); + } + if (endTimeCase_ == EndTimeOneofCase.EndTimeType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) EndTimeType); + } + if (spendingLimitCase_ == SpendingLimitOneofCase.SpendingLimitMicros) { + size += _oneof_spendingLimitMicros_codec.CalculateSizeWithTag(SpendingLimitMicros); + } + if (spendingLimitCase_ == SpendingLimitOneofCase.SpendingLimitType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) SpendingLimitType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PendingAccountBudgetProposal other) { + if (other == null) { + return; + } + if (other.accountBudgetProposal_ != null) { + if (accountBudgetProposal_ == null || other.AccountBudgetProposal != "") { + AccountBudgetProposal = other.AccountBudgetProposal; + } + } + if (other.ProposalType != 0) { + ProposalType = other.ProposalType; + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.startDateTime_ != null) { + if (startDateTime_ == null || other.StartDateTime != "") { + StartDateTime = other.StartDateTime; + } + } + if (other.purchaseOrderNumber_ != null) { + if (purchaseOrderNumber_ == null || other.PurchaseOrderNumber != "") { + PurchaseOrderNumber = other.PurchaseOrderNumber; + } + } + if (other.notes_ != null) { + if (notes_ == null || other.Notes != "") { + Notes = other.Notes; + } + } + if (other.creationDateTime_ != null) { + if (creationDateTime_ == null || other.CreationDateTime != "") { + CreationDateTime = other.CreationDateTime; + } + } + switch (other.EndTimeCase) { + case EndTimeOneofCase.EndDateTime: + EndDateTime = other.EndDateTime; + break; + case EndTimeOneofCase.EndTimeType: + EndTimeType = other.EndTimeType; + break; + } + + switch (other.SpendingLimitCase) { + case SpendingLimitOneofCase.SpendingLimitMicros: + SpendingLimitMicros = other.SpendingLimitMicros; + break; + case SpendingLimitOneofCase.SpendingLimitType: + SpendingLimitType = other.SpendingLimitType; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_accountBudgetProposal_codec.Read(input); + if (accountBudgetProposal_ == null || value != "") { + AccountBudgetProposal = value; + } + break; + } + case 16: { + ProposalType = (global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Types.AccountBudgetProposalType) input.ReadEnum(); + break; + } + case 26: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 34: { + string value = _single_startDateTime_codec.Read(input); + if (startDateTime_ == null || value != "") { + StartDateTime = value; + } + break; + } + case 42: { + EndDateTime = _oneof_endDateTime_codec.Read(input); + break; + } + case 48: { + endTime_ = input.ReadEnum(); + endTimeCase_ = EndTimeOneofCase.EndTimeType; + break; + } + case 58: { + SpendingLimitMicros = _oneof_spendingLimitMicros_codec.Read(input); + break; + } + case 64: { + spendingLimit_ = input.ReadEnum(); + spendingLimitCase_ = SpendingLimitOneofCase.SpendingLimitType; + break; + } + case 74: { + string value = _single_purchaseOrderNumber_codec.Read(input); + if (purchaseOrderNumber_ == null || value != "") { + PurchaseOrderNumber = value; + } + break; + } + case 82: { + string value = _single_notes_codec.Read(input); + if (notes_ == null || value != "") { + Notes = value; + } + break; + } + case 90: { + string value = _single_creationDateTime_codec.Read(input); + if (creationDateTime_ == null || value != "") { + CreationDateTime = value; + } + break; + } + } + } + } + + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccountBudgetProposal.cs b/src/V3/Stubs/AccountBudgetProposal.cs new file mode 100644 index 000000000..cbe27f465 --- /dev/null +++ b/src/V3/Stubs/AccountBudgetProposal.cs @@ -0,0 +1,1122 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/account_budget_proposal.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/account_budget_proposal.proto + public static partial class AccountBudgetProposalReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/account_budget_proposal.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccountBudgetProposalReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWNjb3VudF9i", + "dWRnZXRfcHJvcG9zYWwucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlcxpCZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvYWNj", + "b3VudF9idWRnZXRfcHJvcG9zYWxfc3RhdHVzLnByb3RvGkBnb29nbGUvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcy9hY2NvdW50X2J1ZGdldF9wcm9wb3NhbF90", + "eXBlLnByb3RvGjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9zcGVu", + "ZGluZ19saW1pdF90eXBlLnByb3RvGi1nb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy90aW1lX3R5cGUucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVo", + "YXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2ds", + "ZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0", + "aW9ucy5wcm90byKlEAoVQWNjb3VudEJ1ZGdldFByb3Bvc2FsEk0KDXJlc291", + "cmNlX25hbWUYASABKAlCNuBBBfpBMAouZ29vZ2xlYWRzLmdvb2dsZWFwaXMu", + "Y29tL0FjY291bnRCdWRnZXRQcm9wb3NhbBIsCgJpZBgOIAEoCzIbLmdvb2ds", + "ZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSYgoNYmlsbGluZ19zZXR1cBgC", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIt4EEF+kEnCiVn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQmlsbGluZ1NldHVwEmQKDmFjY291", + "bnRfYnVkZ2V0GAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVl", + "Qi7gQQX6QSgKJmdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BY2NvdW50QnVk", + "Z2V0EnIKDXByb3Bvc2FsX3R5cGUYBCABKA4yVi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lbnVtcy5BY2NvdW50QnVkZ2V0UHJvcG9zYWxUeXBlRW51bS5B", + "Y2NvdW50QnVkZ2V0UHJvcG9zYWxUeXBlQgPgQQUSbwoGc3RhdHVzGA8gASgO", + "MlouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQWNjb3VudEJ1ZGdl", + "dFByb3Bvc2FsU3RhdHVzRW51bS5BY2NvdW50QnVkZ2V0UHJvcG9zYWxTdGF0", + "dXNCA+BBAxI4Cg1wcm9wb3NlZF9uYW1lGAUgASgLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlQgPgQQUSQwoYYXBwcm92ZWRfc3RhcnRfZGF0ZV90", + "aW1lGBQgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMS", + "SQoecHJvcG9zZWRfcHVyY2hhc2Vfb3JkZXJfbnVtYmVyGAwgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQUSOQoOcHJvcG9zZWRfbm90", + "ZXMYDSABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBBRI9", + "ChJjcmVhdGlvbl9kYXRlX3RpbWUYECABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWVCA+BBAxI9ChJhcHByb3ZhbF9kYXRlX3RpbWUYESABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxJFChhwcm9wb3Nl", + "ZF9zdGFydF9kYXRlX3RpbWUYEiABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWVCA+BBBUgAEl0KGHByb3Bvc2VkX3N0YXJ0X3RpbWVfdHlwZRgH", + "IAEoDjI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLlRpbWVUeXBl", + "RW51bS5UaW1lVHlwZUID4EEFSAASQwoWcHJvcG9zZWRfZW5kX2RhdGVfdGlt", + "ZRgTIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEFSAES", + "WwoWcHJvcG9zZWRfZW5kX3RpbWVfdHlwZRgJIAEoDjI0Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zLlRpbWVUeXBlRW51bS5UaW1lVHlwZUID4EEF", + "SAESQwoWYXBwcm92ZWRfZW5kX2RhdGVfdGltZRgVIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDSAISWwoWYXBwcm92ZWRfZW5kX3Rp", + "bWVfdHlwZRgWIAEoDjI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "LlRpbWVUeXBlRW51bS5UaW1lVHlwZUID4EEDSAISSgoecHJvcG9zZWRfc3Bl", + "bmRpbmdfbGltaXRfbWljcm9zGAogASgLMhsuZ29vZ2xlLnByb3RvYnVmLklu", + "dDY0VmFsdWVCA+BBBUgDEnMKHHByb3Bvc2VkX3NwZW5kaW5nX2xpbWl0X3R5", + "cGUYCyABKA4yRi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5TcGVu", + "ZGluZ0xpbWl0VHlwZUVudW0uU3BlbmRpbmdMaW1pdFR5cGVCA+BBBUgDEkoK", + "HmFwcHJvdmVkX3NwZW5kaW5nX2xpbWl0X21pY3JvcxgXIAEoCzIbLmdvb2ds", + "ZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQNIBBJzChxhcHByb3ZlZF9zcGVu", + "ZGluZ19saW1pdF90eXBlGBggASgOMkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZW51bXMuU3BlbmRpbmdMaW1pdFR5cGVFbnVtLlNwZW5kaW5nTGltaXRU", + "eXBlQgPgQQNIBDp66kF3Ci5nb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWNj", + "b3VudEJ1ZGdldFByb3Bvc2FsEkVjdXN0b21lcnMve2N1c3RvbWVyfS9hY2Nv", + "dW50QnVkZ2V0UHJvcG9zYWxzL3thY2NvdW50X2J1ZGdldF9wcm9wb3NhbH1C", + "FQoTcHJvcG9zZWRfc3RhcnRfdGltZUITChFwcm9wb3NlZF9lbmRfdGltZUIT", + "ChFhcHByb3ZlZF9lbmRfdGltZUIZChdwcm9wb3NlZF9zcGVuZGluZ19saW1p", + "dEIZChdhcHByb3ZlZF9zcGVuZGluZ19saW1pdEKHAgolY29tLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IaQWNjb3VudEJ1ZGdldFByb3Bv", + "c2FsUHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNH", + "QUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.TimeTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal), global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal.Parser, new[]{ "ResourceName", "Id", "BillingSetup", "AccountBudget", "ProposalType", "Status", "ProposedName", "ApprovedStartDateTime", "ProposedPurchaseOrderNumber", "ProposedNotes", "CreationDateTime", "ApprovalDateTime", "ProposedStartDateTime", "ProposedStartTimeType", "ProposedEndDateTime", "ProposedEndTimeType", "ApprovedEndDateTime", "ApprovedEndTimeType", "ProposedSpendingLimitMicros", "ProposedSpendingLimitType", "ApprovedSpendingLimitMicros", "ApprovedSpendingLimitType" }, new[]{ "ProposedStartTime", "ProposedEndTime", "ApprovedEndTime", "ProposedSpendingLimit", "ApprovedSpendingLimit" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An account-level budget proposal. + /// + /// All fields prefixed with 'proposed' may not necessarily be applied directly. + /// For example, proposed spending limits may be adjusted before their + /// application. This is true if the 'proposed' field has an 'approved' + /// counterpart, e.g. spending limits. + /// + /// Please note that the proposal type (proposal_type) changes which fields are + /// required and which must remain empty. + /// + public sealed partial class AccountBudgetProposal : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccountBudgetProposal()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposalReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposal() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposal(AccountBudgetProposal other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + BillingSetup = other.BillingSetup; + AccountBudget = other.AccountBudget; + proposalType_ = other.proposalType_; + status_ = other.status_; + ProposedName = other.ProposedName; + ApprovedStartDateTime = other.ApprovedStartDateTime; + ProposedPurchaseOrderNumber = other.ProposedPurchaseOrderNumber; + ProposedNotes = other.ProposedNotes; + CreationDateTime = other.CreationDateTime; + ApprovalDateTime = other.ApprovalDateTime; + switch (other.ProposedStartTimeCase) { + case ProposedStartTimeOneofCase.ProposedStartDateTime: + ProposedStartDateTime = other.ProposedStartDateTime; + break; + case ProposedStartTimeOneofCase.ProposedStartTimeType: + ProposedStartTimeType = other.ProposedStartTimeType; + break; + } + + switch (other.ProposedEndTimeCase) { + case ProposedEndTimeOneofCase.ProposedEndDateTime: + ProposedEndDateTime = other.ProposedEndDateTime; + break; + case ProposedEndTimeOneofCase.ProposedEndTimeType: + ProposedEndTimeType = other.ProposedEndTimeType; + break; + } + + switch (other.ApprovedEndTimeCase) { + case ApprovedEndTimeOneofCase.ApprovedEndDateTime: + ApprovedEndDateTime = other.ApprovedEndDateTime; + break; + case ApprovedEndTimeOneofCase.ApprovedEndTimeType: + ApprovedEndTimeType = other.ApprovedEndTimeType; + break; + } + + switch (other.ProposedSpendingLimitCase) { + case ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros: + ProposedSpendingLimitMicros = other.ProposedSpendingLimitMicros; + break; + case ProposedSpendingLimitOneofCase.ProposedSpendingLimitType: + ProposedSpendingLimitType = other.ProposedSpendingLimitType; + break; + } + + switch (other.ApprovedSpendingLimitCase) { + case ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros: + ApprovedSpendingLimitMicros = other.ApprovedSpendingLimitMicros; + break; + case ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType: + ApprovedSpendingLimitType = other.ApprovedSpendingLimitType; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposal Clone() { + return new AccountBudgetProposal(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the proposal. + /// AccountBudgetProposal resource names have the form: + /// + /// `customers/{customer_id}/accountBudgetProposals/{account_budget_proposal_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 14; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(114); + private long? id_; + /// + /// Output only. The ID of the proposal. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "billing_setup" field. + public const int BillingSetupFieldNumber = 2; + private static readonly pb::FieldCodec _single_billingSetup_codec = pb::FieldCodec.ForClassWrapper(18); + private string billingSetup_; + /// + /// Immutable. The resource name of the billing setup associated with this proposal. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BillingSetup { + get { return billingSetup_; } + set { + billingSetup_ = value; + } + } + + + /// Field number for the "account_budget" field. + public const int AccountBudgetFieldNumber = 3; + private static readonly pb::FieldCodec _single_accountBudget_codec = pb::FieldCodec.ForClassWrapper(26); + private string accountBudget_; + /// + /// Immutable. The resource name of the account-level budget associated with this + /// proposal. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AccountBudget { + get { return accountBudget_; } + set { + accountBudget_ = value; + } + } + + + /// Field number for the "proposal_type" field. + public const int ProposalTypeFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Types.AccountBudgetProposalType proposalType_ = 0; + /// + /// Immutable. The type of this proposal, e.g. END to end the budget associated with this + /// proposal. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Types.AccountBudgetProposalType ProposalType { + get { return proposalType_; } + set { + proposalType_ = value; + } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 15; + private global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalStatusEnum.Types.AccountBudgetProposalStatus status_ = 0; + /// + /// Output only. The status of this proposal. + /// When a new proposal is created, the status defaults to PENDING. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalStatusEnum.Types.AccountBudgetProposalStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "proposed_name" field. + public const int ProposedNameFieldNumber = 5; + private static readonly pb::FieldCodec _single_proposedName_codec = pb::FieldCodec.ForClassWrapper(42); + private string proposedName_; + /// + /// Immutable. The name to assign to the account-level budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProposedName { + get { return proposedName_; } + set { + proposedName_ = value; + } + } + + + /// Field number for the "approved_start_date_time" field. + public const int ApprovedStartDateTimeFieldNumber = 20; + private static readonly pb::FieldCodec _single_approvedStartDateTime_codec = pb::FieldCodec.ForClassWrapper(162); + private string approvedStartDateTime_; + /// + /// Output only. The approved start date time in yyyy-mm-dd hh:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ApprovedStartDateTime { + get { return approvedStartDateTime_; } + set { + approvedStartDateTime_ = value; + } + } + + + /// Field number for the "proposed_purchase_order_number" field. + public const int ProposedPurchaseOrderNumberFieldNumber = 12; + private static readonly pb::FieldCodec _single_proposedPurchaseOrderNumber_codec = pb::FieldCodec.ForClassWrapper(98); + private string proposedPurchaseOrderNumber_; + /// + /// Immutable. A purchase order number is a value that enables the user to help them + /// reference this budget in their monthly invoices. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProposedPurchaseOrderNumber { + get { return proposedPurchaseOrderNumber_; } + set { + proposedPurchaseOrderNumber_ = value; + } + } + + + /// Field number for the "proposed_notes" field. + public const int ProposedNotesFieldNumber = 13; + private static readonly pb::FieldCodec _single_proposedNotes_codec = pb::FieldCodec.ForClassWrapper(106); + private string proposedNotes_; + /// + /// Immutable. Notes associated with this budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProposedNotes { + get { return proposedNotes_; } + set { + proposedNotes_ = value; + } + } + + + /// Field number for the "creation_date_time" field. + public const int CreationDateTimeFieldNumber = 16; + private static readonly pb::FieldCodec _single_creationDateTime_codec = pb::FieldCodec.ForClassWrapper(130); + private string creationDateTime_; + /// + /// Output only. The date time when this account-level budget proposal was created, which is + /// not the same as its approval date time, if applicable. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CreationDateTime { + get { return creationDateTime_; } + set { + creationDateTime_ = value; + } + } + + + /// Field number for the "approval_date_time" field. + public const int ApprovalDateTimeFieldNumber = 17; + private static readonly pb::FieldCodec _single_approvalDateTime_codec = pb::FieldCodec.ForClassWrapper(138); + private string approvalDateTime_; + /// + /// Output only. The date time when this account-level budget was approved, if applicable. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ApprovalDateTime { + get { return approvalDateTime_; } + set { + approvalDateTime_ = value; + } + } + + + /// Field number for the "proposed_start_date_time" field. + public const int ProposedStartDateTimeFieldNumber = 18; + private static readonly pb::FieldCodec _oneof_proposedStartDateTime_codec = pb::FieldCodec.ForClassWrapper(146); + /// + /// Immutable. The proposed start date time in yyyy-mm-dd hh:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProposedStartDateTime { + get { return proposedStartTimeCase_ == ProposedStartTimeOneofCase.ProposedStartDateTime ? (string) proposedStartTime_ : (string) null; } + set { + proposedStartTime_ = value; + proposedStartTimeCase_ = value == null ? ProposedStartTimeOneofCase.None : ProposedStartTimeOneofCase.ProposedStartDateTime; + } + } + + /// Field number for the "proposed_start_time_type" field. + public const int ProposedStartTimeTypeFieldNumber = 7; + /// + /// Immutable. The proposed start date time as a well-defined type, e.g. NOW. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType ProposedStartTimeType { + get { return proposedStartTimeCase_ == ProposedStartTimeOneofCase.ProposedStartTimeType ? (global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType) proposedStartTime_ : 0; } + set { + proposedStartTime_ = value; + proposedStartTimeCase_ = ProposedStartTimeOneofCase.ProposedStartTimeType; + } + } + + /// Field number for the "proposed_end_date_time" field. + public const int ProposedEndDateTimeFieldNumber = 19; + private static readonly pb::FieldCodec _oneof_proposedEndDateTime_codec = pb::FieldCodec.ForClassWrapper(154); + /// + /// Immutable. The proposed end date time in yyyy-mm-dd hh:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProposedEndDateTime { + get { return proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndDateTime ? (string) proposedEndTime_ : (string) null; } + set { + proposedEndTime_ = value; + proposedEndTimeCase_ = value == null ? ProposedEndTimeOneofCase.None : ProposedEndTimeOneofCase.ProposedEndDateTime; + } + } + + /// Field number for the "proposed_end_time_type" field. + public const int ProposedEndTimeTypeFieldNumber = 9; + /// + /// Immutable. The proposed end date time as a well-defined type, e.g. FOREVER. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType ProposedEndTimeType { + get { return proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndTimeType ? (global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType) proposedEndTime_ : 0; } + set { + proposedEndTime_ = value; + proposedEndTimeCase_ = ProposedEndTimeOneofCase.ProposedEndTimeType; + } + } + + /// Field number for the "approved_end_date_time" field. + public const int ApprovedEndDateTimeFieldNumber = 21; + private static readonly pb::FieldCodec _oneof_approvedEndDateTime_codec = pb::FieldCodec.ForClassWrapper(170); + /// + /// Output only. The approved end date time in yyyy-mm-dd hh:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ApprovedEndDateTime { + get { return approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndDateTime ? (string) approvedEndTime_ : (string) null; } + set { + approvedEndTime_ = value; + approvedEndTimeCase_ = value == null ? ApprovedEndTimeOneofCase.None : ApprovedEndTimeOneofCase.ApprovedEndDateTime; + } + } + + /// Field number for the "approved_end_time_type" field. + public const int ApprovedEndTimeTypeFieldNumber = 22; + /// + /// Output only. The approved end date time as a well-defined type, e.g. FOREVER. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType ApprovedEndTimeType { + get { return approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndTimeType ? (global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType) approvedEndTime_ : 0; } + set { + approvedEndTime_ = value; + approvedEndTimeCase_ = ApprovedEndTimeOneofCase.ApprovedEndTimeType; + } + } + + /// Field number for the "proposed_spending_limit_micros" field. + public const int ProposedSpendingLimitMicrosFieldNumber = 10; + private static readonly pb::FieldCodec _oneof_proposedSpendingLimitMicros_codec = pb::FieldCodec.ForStructWrapper(82); + /// + /// Immutable. The proposed spending limit in micros. One million is equivalent to + /// one unit. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ProposedSpendingLimitMicros { + get { return proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros ? (long?) proposedSpendingLimit_ : (long?) null; } + set { + proposedSpendingLimit_ = value; + proposedSpendingLimitCase_ = value == null ? ProposedSpendingLimitOneofCase.None : ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros; + } + } + + /// Field number for the "proposed_spending_limit_type" field. + public const int ProposedSpendingLimitTypeFieldNumber = 11; + /// + /// Immutable. The proposed spending limit as a well-defined type, e.g. INFINITE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType ProposedSpendingLimitType { + get { return proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitType ? (global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType) proposedSpendingLimit_ : 0; } + set { + proposedSpendingLimit_ = value; + proposedSpendingLimitCase_ = ProposedSpendingLimitOneofCase.ProposedSpendingLimitType; + } + } + + /// Field number for the "approved_spending_limit_micros" field. + public const int ApprovedSpendingLimitMicrosFieldNumber = 23; + private static readonly pb::FieldCodec _oneof_approvedSpendingLimitMicros_codec = pb::FieldCodec.ForStructWrapper(186); + /// + /// Output only. The approved spending limit in micros. One million is equivalent to + /// one unit. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ApprovedSpendingLimitMicros { + get { return approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros ? (long?) approvedSpendingLimit_ : (long?) null; } + set { + approvedSpendingLimit_ = value; + approvedSpendingLimitCase_ = value == null ? ApprovedSpendingLimitOneofCase.None : ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros; + } + } + + /// Field number for the "approved_spending_limit_type" field. + public const int ApprovedSpendingLimitTypeFieldNumber = 24; + /// + /// Output only. The approved spending limit as a well-defined type, e.g. INFINITE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType ApprovedSpendingLimitType { + get { return approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType ? (global::Google.Ads.GoogleAds.V3.Enums.SpendingLimitTypeEnum.Types.SpendingLimitType) approvedSpendingLimit_ : 0; } + set { + approvedSpendingLimit_ = value; + approvedSpendingLimitCase_ = ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType; + } + } + + private object proposedStartTime_; + /// Enum of possible cases for the "proposed_start_time" oneof. + public enum ProposedStartTimeOneofCase { + None = 0, + ProposedStartDateTime = 18, + ProposedStartTimeType = 7, + } + private ProposedStartTimeOneofCase proposedStartTimeCase_ = ProposedStartTimeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProposedStartTimeOneofCase ProposedStartTimeCase { + get { return proposedStartTimeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearProposedStartTime() { + proposedStartTimeCase_ = ProposedStartTimeOneofCase.None; + proposedStartTime_ = null; + } + + private object proposedEndTime_; + /// Enum of possible cases for the "proposed_end_time" oneof. + public enum ProposedEndTimeOneofCase { + None = 0, + ProposedEndDateTime = 19, + ProposedEndTimeType = 9, + } + private ProposedEndTimeOneofCase proposedEndTimeCase_ = ProposedEndTimeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProposedEndTimeOneofCase ProposedEndTimeCase { + get { return proposedEndTimeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearProposedEndTime() { + proposedEndTimeCase_ = ProposedEndTimeOneofCase.None; + proposedEndTime_ = null; + } + + private object approvedEndTime_; + /// Enum of possible cases for the "approved_end_time" oneof. + public enum ApprovedEndTimeOneofCase { + None = 0, + ApprovedEndDateTime = 21, + ApprovedEndTimeType = 22, + } + private ApprovedEndTimeOneofCase approvedEndTimeCase_ = ApprovedEndTimeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ApprovedEndTimeOneofCase ApprovedEndTimeCase { + get { return approvedEndTimeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearApprovedEndTime() { + approvedEndTimeCase_ = ApprovedEndTimeOneofCase.None; + approvedEndTime_ = null; + } + + private object proposedSpendingLimit_; + /// Enum of possible cases for the "proposed_spending_limit" oneof. + public enum ProposedSpendingLimitOneofCase { + None = 0, + ProposedSpendingLimitMicros = 10, + ProposedSpendingLimitType = 11, + } + private ProposedSpendingLimitOneofCase proposedSpendingLimitCase_ = ProposedSpendingLimitOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProposedSpendingLimitOneofCase ProposedSpendingLimitCase { + get { return proposedSpendingLimitCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearProposedSpendingLimit() { + proposedSpendingLimitCase_ = ProposedSpendingLimitOneofCase.None; + proposedSpendingLimit_ = null; + } + + private object approvedSpendingLimit_; + /// Enum of possible cases for the "approved_spending_limit" oneof. + public enum ApprovedSpendingLimitOneofCase { + None = 0, + ApprovedSpendingLimitMicros = 23, + ApprovedSpendingLimitType = 24, + } + private ApprovedSpendingLimitOneofCase approvedSpendingLimitCase_ = ApprovedSpendingLimitOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ApprovedSpendingLimitOneofCase ApprovedSpendingLimitCase { + get { return approvedSpendingLimitCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearApprovedSpendingLimit() { + approvedSpendingLimitCase_ = ApprovedSpendingLimitOneofCase.None; + approvedSpendingLimit_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccountBudgetProposal); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccountBudgetProposal other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (BillingSetup != other.BillingSetup) return false; + if (AccountBudget != other.AccountBudget) return false; + if (ProposalType != other.ProposalType) return false; + if (Status != other.Status) return false; + if (ProposedName != other.ProposedName) return false; + if (ApprovedStartDateTime != other.ApprovedStartDateTime) return false; + if (ProposedPurchaseOrderNumber != other.ProposedPurchaseOrderNumber) return false; + if (ProposedNotes != other.ProposedNotes) return false; + if (CreationDateTime != other.CreationDateTime) return false; + if (ApprovalDateTime != other.ApprovalDateTime) return false; + if (ProposedStartDateTime != other.ProposedStartDateTime) return false; + if (ProposedStartTimeType != other.ProposedStartTimeType) return false; + if (ProposedEndDateTime != other.ProposedEndDateTime) return false; + if (ProposedEndTimeType != other.ProposedEndTimeType) return false; + if (ApprovedEndDateTime != other.ApprovedEndDateTime) return false; + if (ApprovedEndTimeType != other.ApprovedEndTimeType) return false; + if (ProposedSpendingLimitMicros != other.ProposedSpendingLimitMicros) return false; + if (ProposedSpendingLimitType != other.ProposedSpendingLimitType) return false; + if (ApprovedSpendingLimitMicros != other.ApprovedSpendingLimitMicros) return false; + if (ApprovedSpendingLimitType != other.ApprovedSpendingLimitType) return false; + if (ProposedStartTimeCase != other.ProposedStartTimeCase) return false; + if (ProposedEndTimeCase != other.ProposedEndTimeCase) return false; + if (ApprovedEndTimeCase != other.ApprovedEndTimeCase) return false; + if (ProposedSpendingLimitCase != other.ProposedSpendingLimitCase) return false; + if (ApprovedSpendingLimitCase != other.ApprovedSpendingLimitCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (billingSetup_ != null) hash ^= BillingSetup.GetHashCode(); + if (accountBudget_ != null) hash ^= AccountBudget.GetHashCode(); + if (ProposalType != 0) hash ^= ProposalType.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (proposedName_ != null) hash ^= ProposedName.GetHashCode(); + if (approvedStartDateTime_ != null) hash ^= ApprovedStartDateTime.GetHashCode(); + if (proposedPurchaseOrderNumber_ != null) hash ^= ProposedPurchaseOrderNumber.GetHashCode(); + if (proposedNotes_ != null) hash ^= ProposedNotes.GetHashCode(); + if (creationDateTime_ != null) hash ^= CreationDateTime.GetHashCode(); + if (approvalDateTime_ != null) hash ^= ApprovalDateTime.GetHashCode(); + if (proposedStartTimeCase_ == ProposedStartTimeOneofCase.ProposedStartDateTime) hash ^= ProposedStartDateTime.GetHashCode(); + if (proposedStartTimeCase_ == ProposedStartTimeOneofCase.ProposedStartTimeType) hash ^= ProposedStartTimeType.GetHashCode(); + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndDateTime) hash ^= ProposedEndDateTime.GetHashCode(); + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndTimeType) hash ^= ProposedEndTimeType.GetHashCode(); + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndDateTime) hash ^= ApprovedEndDateTime.GetHashCode(); + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndTimeType) hash ^= ApprovedEndTimeType.GetHashCode(); + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros) hash ^= ProposedSpendingLimitMicros.GetHashCode(); + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitType) hash ^= ProposedSpendingLimitType.GetHashCode(); + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros) hash ^= ApprovedSpendingLimitMicros.GetHashCode(); + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType) hash ^= ApprovedSpendingLimitType.GetHashCode(); + hash ^= (int) proposedStartTimeCase_; + hash ^= (int) proposedEndTimeCase_; + hash ^= (int) approvedEndTimeCase_; + hash ^= (int) proposedSpendingLimitCase_; + hash ^= (int) approvedSpendingLimitCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (billingSetup_ != null) { + _single_billingSetup_codec.WriteTagAndValue(output, BillingSetup); + } + if (accountBudget_ != null) { + _single_accountBudget_codec.WriteTagAndValue(output, AccountBudget); + } + if (ProposalType != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) ProposalType); + } + if (proposedName_ != null) { + _single_proposedName_codec.WriteTagAndValue(output, ProposedName); + } + if (proposedStartTimeCase_ == ProposedStartTimeOneofCase.ProposedStartTimeType) { + output.WriteRawTag(56); + output.WriteEnum((int) ProposedStartTimeType); + } + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndTimeType) { + output.WriteRawTag(72); + output.WriteEnum((int) ProposedEndTimeType); + } + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros) { + _oneof_proposedSpendingLimitMicros_codec.WriteTagAndValue(output, (long?) proposedSpendingLimit_); + } + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitType) { + output.WriteRawTag(88); + output.WriteEnum((int) ProposedSpendingLimitType); + } + if (proposedPurchaseOrderNumber_ != null) { + _single_proposedPurchaseOrderNumber_codec.WriteTagAndValue(output, ProposedPurchaseOrderNumber); + } + if (proposedNotes_ != null) { + _single_proposedNotes_codec.WriteTagAndValue(output, ProposedNotes); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (Status != 0) { + output.WriteRawTag(120); + output.WriteEnum((int) Status); + } + if (creationDateTime_ != null) { + _single_creationDateTime_codec.WriteTagAndValue(output, CreationDateTime); + } + if (approvalDateTime_ != null) { + _single_approvalDateTime_codec.WriteTagAndValue(output, ApprovalDateTime); + } + if (proposedStartTimeCase_ == ProposedStartTimeOneofCase.ProposedStartDateTime) { + _oneof_proposedStartDateTime_codec.WriteTagAndValue(output, (string) proposedStartTime_); + } + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndDateTime) { + _oneof_proposedEndDateTime_codec.WriteTagAndValue(output, (string) proposedEndTime_); + } + if (approvedStartDateTime_ != null) { + _single_approvedStartDateTime_codec.WriteTagAndValue(output, ApprovedStartDateTime); + } + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndDateTime) { + _oneof_approvedEndDateTime_codec.WriteTagAndValue(output, (string) approvedEndTime_); + } + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndTimeType) { + output.WriteRawTag(176, 1); + output.WriteEnum((int) ApprovedEndTimeType); + } + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros) { + _oneof_approvedSpendingLimitMicros_codec.WriteTagAndValue(output, (long?) approvedSpendingLimit_); + } + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType) { + output.WriteRawTag(192, 1); + output.WriteEnum((int) ApprovedSpendingLimitType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (billingSetup_ != null) { + size += _single_billingSetup_codec.CalculateSizeWithTag(BillingSetup); + } + if (accountBudget_ != null) { + size += _single_accountBudget_codec.CalculateSizeWithTag(AccountBudget); + } + if (ProposalType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ProposalType); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (proposedName_ != null) { + size += _single_proposedName_codec.CalculateSizeWithTag(ProposedName); + } + if (approvedStartDateTime_ != null) { + size += _single_approvedStartDateTime_codec.CalculateSizeWithTag(ApprovedStartDateTime); + } + if (proposedPurchaseOrderNumber_ != null) { + size += _single_proposedPurchaseOrderNumber_codec.CalculateSizeWithTag(ProposedPurchaseOrderNumber); + } + if (proposedNotes_ != null) { + size += _single_proposedNotes_codec.CalculateSizeWithTag(ProposedNotes); + } + if (creationDateTime_ != null) { + size += _single_creationDateTime_codec.CalculateSizeWithTag(CreationDateTime); + } + if (approvalDateTime_ != null) { + size += _single_approvalDateTime_codec.CalculateSizeWithTag(ApprovalDateTime); + } + if (proposedStartTimeCase_ == ProposedStartTimeOneofCase.ProposedStartDateTime) { + size += _oneof_proposedStartDateTime_codec.CalculateSizeWithTag(ProposedStartDateTime); + } + if (proposedStartTimeCase_ == ProposedStartTimeOneofCase.ProposedStartTimeType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ProposedStartTimeType); + } + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndDateTime) { + size += _oneof_proposedEndDateTime_codec.CalculateSizeWithTag(ProposedEndDateTime); + } + if (proposedEndTimeCase_ == ProposedEndTimeOneofCase.ProposedEndTimeType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ProposedEndTimeType); + } + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndDateTime) { + size += _oneof_approvedEndDateTime_codec.CalculateSizeWithTag(ApprovedEndDateTime); + } + if (approvedEndTimeCase_ == ApprovedEndTimeOneofCase.ApprovedEndTimeType) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ApprovedEndTimeType); + } + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros) { + size += _oneof_proposedSpendingLimitMicros_codec.CalculateSizeWithTag(ProposedSpendingLimitMicros); + } + if (proposedSpendingLimitCase_ == ProposedSpendingLimitOneofCase.ProposedSpendingLimitType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ProposedSpendingLimitType); + } + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros) { + size += _oneof_approvedSpendingLimitMicros_codec.CalculateSizeWithTag(ApprovedSpendingLimitMicros); + } + if (approvedSpendingLimitCase_ == ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ApprovedSpendingLimitType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccountBudgetProposal other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.billingSetup_ != null) { + if (billingSetup_ == null || other.BillingSetup != "") { + BillingSetup = other.BillingSetup; + } + } + if (other.accountBudget_ != null) { + if (accountBudget_ == null || other.AccountBudget != "") { + AccountBudget = other.AccountBudget; + } + } + if (other.ProposalType != 0) { + ProposalType = other.ProposalType; + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.proposedName_ != null) { + if (proposedName_ == null || other.ProposedName != "") { + ProposedName = other.ProposedName; + } + } + if (other.approvedStartDateTime_ != null) { + if (approvedStartDateTime_ == null || other.ApprovedStartDateTime != "") { + ApprovedStartDateTime = other.ApprovedStartDateTime; + } + } + if (other.proposedPurchaseOrderNumber_ != null) { + if (proposedPurchaseOrderNumber_ == null || other.ProposedPurchaseOrderNumber != "") { + ProposedPurchaseOrderNumber = other.ProposedPurchaseOrderNumber; + } + } + if (other.proposedNotes_ != null) { + if (proposedNotes_ == null || other.ProposedNotes != "") { + ProposedNotes = other.ProposedNotes; + } + } + if (other.creationDateTime_ != null) { + if (creationDateTime_ == null || other.CreationDateTime != "") { + CreationDateTime = other.CreationDateTime; + } + } + if (other.approvalDateTime_ != null) { + if (approvalDateTime_ == null || other.ApprovalDateTime != "") { + ApprovalDateTime = other.ApprovalDateTime; + } + } + switch (other.ProposedStartTimeCase) { + case ProposedStartTimeOneofCase.ProposedStartDateTime: + ProposedStartDateTime = other.ProposedStartDateTime; + break; + case ProposedStartTimeOneofCase.ProposedStartTimeType: + ProposedStartTimeType = other.ProposedStartTimeType; + break; + } + + switch (other.ProposedEndTimeCase) { + case ProposedEndTimeOneofCase.ProposedEndDateTime: + ProposedEndDateTime = other.ProposedEndDateTime; + break; + case ProposedEndTimeOneofCase.ProposedEndTimeType: + ProposedEndTimeType = other.ProposedEndTimeType; + break; + } + + switch (other.ApprovedEndTimeCase) { + case ApprovedEndTimeOneofCase.ApprovedEndDateTime: + ApprovedEndDateTime = other.ApprovedEndDateTime; + break; + case ApprovedEndTimeOneofCase.ApprovedEndTimeType: + ApprovedEndTimeType = other.ApprovedEndTimeType; + break; + } + + switch (other.ProposedSpendingLimitCase) { + case ProposedSpendingLimitOneofCase.ProposedSpendingLimitMicros: + ProposedSpendingLimitMicros = other.ProposedSpendingLimitMicros; + break; + case ProposedSpendingLimitOneofCase.ProposedSpendingLimitType: + ProposedSpendingLimitType = other.ProposedSpendingLimitType; + break; + } + + switch (other.ApprovedSpendingLimitCase) { + case ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitMicros: + ApprovedSpendingLimitMicros = other.ApprovedSpendingLimitMicros; + break; + case ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType: + ApprovedSpendingLimitType = other.ApprovedSpendingLimitType; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_billingSetup_codec.Read(input); + if (billingSetup_ == null || value != "") { + BillingSetup = value; + } + break; + } + case 26: { + string value = _single_accountBudget_codec.Read(input); + if (accountBudget_ == null || value != "") { + AccountBudget = value; + } + break; + } + case 32: { + ProposalType = (global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Types.AccountBudgetProposalType) input.ReadEnum(); + break; + } + case 42: { + string value = _single_proposedName_codec.Read(input); + if (proposedName_ == null || value != "") { + ProposedName = value; + } + break; + } + case 56: { + proposedStartTime_ = input.ReadEnum(); + proposedStartTimeCase_ = ProposedStartTimeOneofCase.ProposedStartTimeType; + break; + } + case 72: { + proposedEndTime_ = input.ReadEnum(); + proposedEndTimeCase_ = ProposedEndTimeOneofCase.ProposedEndTimeType; + break; + } + case 82: { + ProposedSpendingLimitMicros = _oneof_proposedSpendingLimitMicros_codec.Read(input); + break; + } + case 88: { + proposedSpendingLimit_ = input.ReadEnum(); + proposedSpendingLimitCase_ = ProposedSpendingLimitOneofCase.ProposedSpendingLimitType; + break; + } + case 98: { + string value = _single_proposedPurchaseOrderNumber_codec.Read(input); + if (proposedPurchaseOrderNumber_ == null || value != "") { + ProposedPurchaseOrderNumber = value; + } + break; + } + case 106: { + string value = _single_proposedNotes_codec.Read(input); + if (proposedNotes_ == null || value != "") { + ProposedNotes = value; + } + break; + } + case 114: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 120: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalStatusEnum.Types.AccountBudgetProposalStatus) input.ReadEnum(); + break; + } + case 130: { + string value = _single_creationDateTime_codec.Read(input); + if (creationDateTime_ == null || value != "") { + CreationDateTime = value; + } + break; + } + case 138: { + string value = _single_approvalDateTime_codec.Read(input); + if (approvalDateTime_ == null || value != "") { + ApprovalDateTime = value; + } + break; + } + case 146: { + ProposedStartDateTime = _oneof_proposedStartDateTime_codec.Read(input); + break; + } + case 154: { + ProposedEndDateTime = _oneof_proposedEndDateTime_codec.Read(input); + break; + } + case 162: { + string value = _single_approvedStartDateTime_codec.Read(input); + if (approvedStartDateTime_ == null || value != "") { + ApprovedStartDateTime = value; + } + break; + } + case 170: { + ApprovedEndDateTime = _oneof_approvedEndDateTime_codec.Read(input); + break; + } + case 176: { + approvedEndTime_ = input.ReadEnum(); + approvedEndTimeCase_ = ApprovedEndTimeOneofCase.ApprovedEndTimeType; + break; + } + case 186: { + ApprovedSpendingLimitMicros = _oneof_approvedSpendingLimitMicros_codec.Read(input); + break; + } + case 192: { + approvedSpendingLimit_ = input.ReadEnum(); + approvedSpendingLimitCase_ = ApprovedSpendingLimitOneofCase.ApprovedSpendingLimitType; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccountBudgetProposalError.cs b/src/V3/Stubs/AccountBudgetProposalError.cs new file mode 100644 index 000000000..fd0ad5a4f --- /dev/null +++ b/src/V3/Stubs/AccountBudgetProposalError.cs @@ -0,0 +1,286 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/account_budget_proposal_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/account_budget_proposal_error.proto + public static partial class AccountBudgetProposalErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/account_budget_proposal_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccountBudgetProposalErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWNjb3VudF9idWRn", + "ZXRfcHJvcG9zYWxfZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVycm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLUBgoe", + "QWNjb3VudEJ1ZGdldFByb3Bvc2FsRXJyb3JFbnVtIrEGChpBY2NvdW50QnVk", + "Z2V0UHJvcG9zYWxFcnJvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04Q", + "ARIaChZGSUVMRF9NQVNLX05PVF9BTExPV0VEEAISEwoPSU1NVVRBQkxFX0ZJ", + "RUxEEAMSGgoWUkVRVUlSRURfRklFTERfTUlTU0lORxAEEiMKH0NBTk5PVF9D", + "QU5DRUxfQVBQUk9WRURfUFJPUE9TQUwQBRIjCh9DQU5OT1RfUkVNT1ZFX1VO", + "QVBQUk9WRURfQlVER0VUEAYSIAocQ0FOTk9UX1JFTU9WRV9SVU5OSU5HX0JV", + "REdFVBAHEiAKHENBTk5PVF9FTkRfVU5BUFBST1ZFRF9CVURHRVQQCBIeChpD", + "QU5OT1RfRU5EX0lOQUNUSVZFX0JVREdFVBAJEhgKFEJVREdFVF9OQU1FX1JF", + "UVVJUkVEEAoSHAoYQ0FOTk9UX1VQREFURV9PTERfQlVER0VUEAsSFgoSQ0FO", + "Tk9UX0VORF9JTl9QQVNUEAwSGgoWQ0FOTk9UX0VYVEVORF9FTkRfVElNRRAN", + "EiIKHlBVUkNIQVNFX09SREVSX05VTUJFUl9SRVFVSVJFRBAOEiIKHlBFTkRJ", + "TkdfVVBEQVRFX1BST1BPU0FMX0VYSVNUUxAPEj0KOU1VTFRJUExFX0JVREdF", + "VFNfTk9UX0FMTE9XRURfRk9SX1VOQVBQUk9WRURfQklMTElOR19TRVRVUBAQ", + "Ei8KK0NBTk5PVF9VUERBVEVfU1RBUlRfVElNRV9GT1JfU1RBUlRFRF9CVURH", + "RVQQERI2CjJTUEVORElOR19MSU1JVF9MT1dFUl9USEFOX0FDQ1JVRURfQ09T", + "VF9OT1RfQUxMT1dFRBASEhMKD1VQREFURV9JU19OT19PUBATEiMKH0VORF9U", + "SU1FX01VU1RfRk9MTE9XX1NUQVJUX1RJTUUQFBI1CjFCVURHRVRfREFURV9S", + "QU5HRV9JTkNPTVBBVElCTEVfV0lUSF9CSUxMSU5HX1NFVFVQEBUSEgoOTk9U", + "X0FVVEhPUklaRUQQFhIZChVJTlZBTElEX0JJTExJTkdfU0VUVVAQF0L6AQoi", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IfQWNjb3VudEJ1", + "ZGdldFByb3Bvc2FsRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9n", + "ZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vy", + "cm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oC", + "Hkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AccountBudgetProposalErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AccountBudgetProposalErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AccountBudgetProposalErrorEnum.Types.AccountBudgetProposalError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible account budget proposal errors. + /// + public sealed partial class AccountBudgetProposalErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccountBudgetProposalErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AccountBudgetProposalErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalErrorEnum(AccountBudgetProposalErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalErrorEnum Clone() { + return new AccountBudgetProposalErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccountBudgetProposalErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccountBudgetProposalErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccountBudgetProposalErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AccountBudgetProposalErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible account budget proposal errors. + /// + public enum AccountBudgetProposalError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The field mask must be empty for create/end/remove proposals. + /// + [pbr::OriginalName("FIELD_MASK_NOT_ALLOWED")] FieldMaskNotAllowed = 2, + /// + /// The field cannot be set because of the proposal type. + /// + [pbr::OriginalName("IMMUTABLE_FIELD")] ImmutableField = 3, + /// + /// The field is required because of the proposal type. + /// + [pbr::OriginalName("REQUIRED_FIELD_MISSING")] RequiredFieldMissing = 4, + /// + /// Proposals that have been approved cannot be cancelled. + /// + [pbr::OriginalName("CANNOT_CANCEL_APPROVED_PROPOSAL")] CannotCancelApprovedProposal = 5, + /// + /// Budgets that haven't been approved cannot be removed. + /// + [pbr::OriginalName("CANNOT_REMOVE_UNAPPROVED_BUDGET")] CannotRemoveUnapprovedBudget = 6, + /// + /// Budgets that are currently running cannot be removed. + /// + [pbr::OriginalName("CANNOT_REMOVE_RUNNING_BUDGET")] CannotRemoveRunningBudget = 7, + /// + /// Budgets that haven't been approved cannot be truncated. + /// + [pbr::OriginalName("CANNOT_END_UNAPPROVED_BUDGET")] CannotEndUnapprovedBudget = 8, + /// + /// Only budgets that are currently running can be truncated. + /// + [pbr::OriginalName("CANNOT_END_INACTIVE_BUDGET")] CannotEndInactiveBudget = 9, + /// + /// All budgets must have names. + /// + [pbr::OriginalName("BUDGET_NAME_REQUIRED")] BudgetNameRequired = 10, + /// + /// Expired budgets cannot be edited after a sufficient amount of time has + /// passed. + /// + [pbr::OriginalName("CANNOT_UPDATE_OLD_BUDGET")] CannotUpdateOldBudget = 11, + /// + /// It is not permissible a propose a new budget that ends in the past. + /// + [pbr::OriginalName("CANNOT_END_IN_PAST")] CannotEndInPast = 12, + /// + /// An expired budget cannot be extended to overlap with the running budget. + /// + [pbr::OriginalName("CANNOT_EXTEND_END_TIME")] CannotExtendEndTime = 13, + /// + /// A purchase order number is required. + /// + [pbr::OriginalName("PURCHASE_ORDER_NUMBER_REQUIRED")] PurchaseOrderNumberRequired = 14, + /// + /// Budgets that have a pending update cannot be updated. + /// + [pbr::OriginalName("PENDING_UPDATE_PROPOSAL_EXISTS")] PendingUpdateProposalExists = 15, + /// + /// Cannot propose more than one budget when the corresponding billing setup + /// hasn't been approved. + /// + [pbr::OriginalName("MULTIPLE_BUDGETS_NOT_ALLOWED_FOR_UNAPPROVED_BILLING_SETUP")] MultipleBudgetsNotAllowedForUnapprovedBillingSetup = 16, + /// + /// Cannot update the start time of a budget that has already started. + /// + [pbr::OriginalName("CANNOT_UPDATE_START_TIME_FOR_STARTED_BUDGET")] CannotUpdateStartTimeForStartedBudget = 17, + /// + /// Cannot update the spending limit of a budget with an amount lower than + /// what has already been spent. + /// + [pbr::OriginalName("SPENDING_LIMIT_LOWER_THAN_ACCRUED_COST_NOT_ALLOWED")] SpendingLimitLowerThanAccruedCostNotAllowed = 18, + /// + /// Cannot propose a budget update without actually changing any fields. + /// + [pbr::OriginalName("UPDATE_IS_NO_OP")] UpdateIsNoOp = 19, + /// + /// The end time must come after the start time. + /// + [pbr::OriginalName("END_TIME_MUST_FOLLOW_START_TIME")] EndTimeMustFollowStartTime = 20, + /// + /// The budget's date range must fall within the date range of its billing + /// setup. + /// + [pbr::OriginalName("BUDGET_DATE_RANGE_INCOMPATIBLE_WITH_BILLING_SETUP")] BudgetDateRangeIncompatibleWithBillingSetup = 21, + /// + /// The user is not authorized to mutate budgets for the given billing setup. + /// + [pbr::OriginalName("NOT_AUTHORIZED")] NotAuthorized = 22, + /// + /// Mutates are not allowed for the given billing setup. + /// + [pbr::OriginalName("INVALID_BILLING_SETUP")] InvalidBillingSetup = 23, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccountBudgetProposalService.cs b/src/V3/Stubs/AccountBudgetProposalService.cs new file mode 100644 index 000000000..d91899e76 --- /dev/null +++ b/src/V3/Stubs/AccountBudgetProposalService.cs @@ -0,0 +1,956 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/account_budget_proposal_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/account_budget_proposal_service.proto + public static partial class AccountBudgetProposalServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/account_budget_proposal_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccountBudgetProposalServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hY2NvdW50X2J1", + "ZGdldF9wcm9wb3NhbF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcxo/Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVz", + "b3VyY2VzL2FjY291bnRfYnVkZ2V0X3Byb3Bvc2FsLnByb3RvGhxnb29nbGUv", + "YXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90", + "bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29vZ2xlL3By", + "b3RvYnVmL2ZpZWxkX21hc2sucHJvdG8iPQofR2V0QWNjb3VudEJ1ZGdldFBy", + "b3Bvc2FsUmVxdWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIirwEK", + "Ik11dGF0ZUFjY291bnRCdWRnZXRQcm9wb3NhbFJlcXVlc3QSGAoLY3VzdG9t", + "ZXJfaWQYASABKAlCA+BBAhJYCglvcGVyYXRpb24YAiABKAsyQC5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5BY2NvdW50QnVkZ2V0UHJvcG9z", + "YWxPcGVyYXRpb25CA+BBAhIVCg12YWxpZGF0ZV9vbmx5GAMgASgIIrwBCh5B", + "Y2NvdW50QnVkZ2V0UHJvcG9zYWxPcGVyYXRpb24SLwoLdXBkYXRlX21hc2sY", + "AyABKAsyGi5nb29nbGUucHJvdG9idWYuRmllbGRNYXNrEkoKBmNyZWF0ZRgC", + "IAEoCzI4Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BY2Nv", + "dW50QnVkZ2V0UHJvcG9zYWxIABIQCgZyZW1vdmUYASABKAlIAEILCglvcGVy", + "YXRpb24iegojTXV0YXRlQWNjb3VudEJ1ZGdldFByb3Bvc2FsUmVzcG9uc2US", + "UwoGcmVzdWx0GAIgASgLMkMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuTXV0YXRlQWNjb3VudEJ1ZGdldFByb3Bvc2FsUmVzdWx0IjoKIU11", + "dGF0ZUFjY291bnRCdWRnZXRQcm9wb3NhbFJlc3VsdBIVCg1yZXNvdXJjZV9u", + "YW1lGAEgASgJMrQEChxBY2NvdW50QnVkZ2V0UHJvcG9zYWxTZXJ2aWNlEukB", + "ChhHZXRBY2NvdW50QnVkZ2V0UHJvcG9zYWwSQS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5HZXRBY2NvdW50QnVkZ2V0UHJvcG9zYWxSZXF1", + "ZXN0GjguZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkFjY291", + "bnRCdWRnZXRQcm9wb3NhbCJQgtPkkwI6EjgvdjMve3Jlc291cmNlX25hbWU9", + "Y3VzdG9tZXJzLyovYWNjb3VudEJ1ZGdldFByb3Bvc2Fscy8qfdpBDXJlc291", + "cmNlX25hbWUSigIKG011dGF0ZUFjY291bnRCdWRnZXRQcm9wb3NhbBJELmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFjY291bnRC", + "dWRnZXRQcm9wb3NhbFJlcXVlc3QaRS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5NdXRhdGVBY2NvdW50QnVkZ2V0UHJvcG9zYWxSZXNwb25z", + "ZSJegtPkkwJAIjsvdjMvY3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfS9hY2Nv", + "dW50QnVkZ2V0UHJvcG9zYWxzOm11dGF0ZToBKtpBFWN1c3RvbWVyX2lkLG9w", + "ZXJhdGlvbhobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQogCCiRjb20u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCIUFjY291bnRCdWRn", + "ZXRQcm9wb3NhbFNlcnZpY2VQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9n", + "ZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXM7", + "c2VydmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2", + "aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29v", + "Z2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposalReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetProposalRequest), global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetProposalRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalRequest.Parser, new[]{ "CustomerId", "Operation", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalOperation), global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalOperation.Parser, new[]{ "UpdateMask", "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResponse.Parser, new[]{ "Result" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResult), global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [AccountBudgetProposalService.GetAccountBudgetProposal][google.ads.googleads.v3.services.AccountBudgetProposalService.GetAccountBudgetProposal]. + /// + public sealed partial class GetAccountBudgetProposalRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAccountBudgetProposalRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAccountBudgetProposalRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAccountBudgetProposalRequest(GetAccountBudgetProposalRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAccountBudgetProposalRequest Clone() { + return new GetAccountBudgetProposalRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the account-level budget proposal to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAccountBudgetProposalRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAccountBudgetProposalRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAccountBudgetProposalRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [AccountBudgetProposalService.MutateAccountBudgetProposal][google.ads.googleads.v3.services.AccountBudgetProposalService.MutateAccountBudgetProposal]. + /// + public sealed partial class MutateAccountBudgetProposalRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAccountBudgetProposalRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalRequest(MutateAccountBudgetProposalRequest other) : this() { + customerId_ = other.customerId_; + operation_ = other.operation_ != null ? other.operation_.Clone() : null; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalRequest Clone() { + return new MutateAccountBudgetProposalRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operation" field. + public const int OperationFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalOperation operation_; + /// + /// Required. The operation to perform on an individual account-level budget proposal. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalOperation Operation { + get { return operation_; } + set { + operation_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 3; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAccountBudgetProposalRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAccountBudgetProposalRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (!object.Equals(Operation, other.Operation)) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (operation_ != null) hash ^= Operation.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (operation_ != null) { + output.WriteRawTag(18); + output.WriteMessage(Operation); + } + if (ValidateOnly != false) { + output.WriteRawTag(24); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (operation_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Operation); + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAccountBudgetProposalRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.operation_ != null) { + if (operation_ == null) { + Operation = new global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalOperation(); + } + Operation.MergeFrom(other.Operation); + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + if (operation_ == null) { + Operation = new global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalOperation(); + } + input.ReadMessage(Operation); + break; + } + case 24: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation to propose the creation of a new account-level budget or + /// edit/end/remove an existing one. + /// + public sealed partial class AccountBudgetProposalOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccountBudgetProposalOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalOperation(AccountBudgetProposalOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalOperation Clone() { + return new AccountBudgetProposalOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 3; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which budget fields are modified. While budgets + /// may be modified, proposals that propose such modifications are final. + /// Therefore, update operations are not supported for proposals. + /// + /// Proposals that modify budgets have the 'update' proposal type. Specifying + /// a mask for any other proposal type is considered an error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 2; + /// + /// Create operation: A new proposal to create a new budget, edit an + /// existing budget, end an actively running budget, or remove an approved + /// budget scheduled to start in the future. + /// No resource name is expected for the new proposal. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 1; + /// + /// Remove operation: A resource name for the removed proposal is expected, + /// in this format: + /// + /// `customers/{customer_id}/accountBudgetProposals/{account_budget_proposal_id}` + /// A request may be cancelled iff it is pending. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 2, + Remove = 1, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccountBudgetProposalOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccountBudgetProposalOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(10); + output.WriteString(Remove); + } + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(18); + output.WriteMessage(Create); + } + if (updateMask_ != null) { + output.WriteRawTag(26); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccountBudgetProposalOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + Remove = input.ReadString(); + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 26: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for account-level budget mutate operations. + /// + public sealed partial class MutateAccountBudgetProposalResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAccountBudgetProposalResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalResponse(MutateAccountBudgetProposalResponse other) : this() { + result_ = other.result_ != null ? other.result_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalResponse Clone() { + return new MutateAccountBudgetProposalResponse(this); + } + + /// Field number for the "result" field. + public const int ResultFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResult result_; + /// + /// The result of the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResult Result { + get { return result_; } + set { + result_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAccountBudgetProposalResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAccountBudgetProposalResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Result, other.Result)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (result_ != null) hash ^= Result.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (result_ != null) { + output.WriteRawTag(18); + output.WriteMessage(Result); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (result_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Result); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAccountBudgetProposalResponse other) { + if (other == null) { + return; + } + if (other.result_ != null) { + if (result_ == null) { + Result = new global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResult(); + } + Result.MergeFrom(other.Result); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + if (result_ == null) { + Result = new global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResult(); + } + input.ReadMessage(Result); + break; + } + } + } + } + + } + + /// + /// The result for the account budget proposal mutate. + /// + public sealed partial class MutateAccountBudgetProposalResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAccountBudgetProposalResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalResult(MutateAccountBudgetProposalResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAccountBudgetProposalResult Clone() { + return new MutateAccountBudgetProposalResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAccountBudgetProposalResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAccountBudgetProposalResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAccountBudgetProposalResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccountBudgetProposalServiceClient.cs b/src/V3/Stubs/AccountBudgetProposalServiceClient.cs new file mode 100644 index 000000000..527b7ede3 --- /dev/null +++ b/src/V3/Stubs/AccountBudgetProposalServiceClient.cs @@ -0,0 +1,874 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AccountBudgetProposalServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AccountBudgetProposalServiceSettings GetDefault() => new AccountBudgetProposalServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AccountBudgetProposalServiceSettings() { } + + private AccountBudgetProposalServiceSettings(AccountBudgetProposalServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAccountBudgetProposalSettings = existing.GetAccountBudgetProposalSettings; + MutateAccountBudgetProposalSettings = existing.MutateAccountBudgetProposalSettings; + OnCopy(existing); + } + + partial void OnCopy(AccountBudgetProposalServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AccountBudgetProposalServiceClient.GetAccountBudgetProposal and AccountBudgetProposalServiceClient.GetAccountBudgetProposalAsync. + /// + /// + /// The default AccountBudgetProposalServiceClient.GetAccountBudgetProposal and + /// AccountBudgetProposalServiceClient.GetAccountBudgetProposalAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAccountBudgetProposalSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AccountBudgetProposalServiceClient.MutateAccountBudgetProposal and AccountBudgetProposalServiceClient.MutateAccountBudgetProposalAsync. + /// + /// + /// The default AccountBudgetProposalServiceClient.MutateAccountBudgetProposal and + /// AccountBudgetProposalServiceClient.MutateAccountBudgetProposalAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAccountBudgetProposalSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AccountBudgetProposalServiceSettings Clone() => new AccountBudgetProposalServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AccountBudgetProposalServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AccountBudgetProposalServiceSettings Settings { get; set; } + + /// + public override AccountBudgetProposalServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AccountBudgetProposalServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AccountBudgetProposalServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AccountBudgetProposalServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AccountBudgetProposalServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AccountBudgetProposalServiceClient.ChannelPool; + } + + /// + /// AccountBudgetProposalService client wrapper, for convenient use. + /// + public abstract partial class AccountBudgetProposalServiceClient + { + /// + /// The default endpoint for the AccountBudgetProposalService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AccountBudgetProposalService scopes. + /// + /// + /// The default AccountBudgetProposalService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AccountBudgetProposalServiceClient client = await AccountBudgetProposalServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AccountBudgetProposalServiceClient.DefaultEndpoint.Host, AccountBudgetProposalServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AccountBudgetProposalServiceClient client = AccountBudgetProposalServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AccountBudgetProposalServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AccountBudgetProposalServiceClient client = AccountBudgetProposalServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AccountBudgetProposalServiceClient.DefaultEndpoint.Host, AccountBudgetProposalServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AccountBudgetProposalServiceClient client = AccountBudgetProposalServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AccountBudgetProposalServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AccountBudgetProposalServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AccountBudgetProposalServiceClient Create(grpccore::Channel channel, AccountBudgetProposalServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AccountBudgetProposalServiceClient Create(grpccore::CallInvoker callInvoker, AccountBudgetProposalServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AccountBudgetProposalService.AccountBudgetProposalServiceClient grpcClient = new AccountBudgetProposalService.AccountBudgetProposalServiceClient(callInvoker); + return new AccountBudgetProposalServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AccountBudgetProposalService client. + /// + public virtual AccountBudgetProposalService.AccountBudgetProposalServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// + /// Required. The resource name of the account-level budget proposal to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAccountBudgetProposalAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAccountBudgetProposalAsync( + new GetAccountBudgetProposalRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// + /// Required. The resource name of the account-level budget proposal to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAccountBudgetProposalAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAccountBudgetProposalAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// + /// Required. The resource name of the account-level budget proposal to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AccountBudgetProposal GetAccountBudgetProposal( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAccountBudgetProposal( + new GetAccountBudgetProposalRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAccountBudgetProposalAsync( + GetAccountBudgetProposalRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAccountBudgetProposalAsync( + GetAccountBudgetProposalRequest request, + st::CancellationToken cancellationToken) => GetAccountBudgetProposalAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AccountBudgetProposal GetAccountBudgetProposal( + GetAccountBudgetProposalRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// Required. The ID of the customer. + /// + /// + /// Required. The operation to perform on an individual account-level budget proposal. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAccountBudgetProposalAsync( + string customerId, + AccountBudgetProposalOperation operation, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAccountBudgetProposalAsync( + new MutateAccountBudgetProposalRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// Required. The ID of the customer. + /// + /// + /// Required. The operation to perform on an individual account-level budget proposal. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAccountBudgetProposalAsync( + string customerId, + AccountBudgetProposalOperation operation, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAccountBudgetProposalAsync( + customerId, + operation, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// Required. The ID of the customer. + /// + /// + /// Required. The operation to perform on an individual account-level budget proposal. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAccountBudgetProposalResponse MutateAccountBudgetProposal( + string customerId, + AccountBudgetProposalOperation operation, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAccountBudgetProposal( + new MutateAccountBudgetProposalRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// Required. The ID of the customer. + /// + /// + /// Required. The operation to perform on an individual account-level budget proposal. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAccountBudgetProposalAsync( + string customerId, + AccountBudgetProposalOperation operation, + gaxgrpc::CallSettings callSettings = null) => MutateAccountBudgetProposalAsync( + new MutateAccountBudgetProposalRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + }, + callSettings); + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// Required. The ID of the customer. + /// + /// + /// Required. The operation to perform on an individual account-level budget proposal. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAccountBudgetProposalAsync( + string customerId, + AccountBudgetProposalOperation operation, + st::CancellationToken cancellationToken) => MutateAccountBudgetProposalAsync( + customerId, + operation, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// Required. The ID of the customer. + /// + /// + /// Required. The operation to perform on an individual account-level budget proposal. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAccountBudgetProposalResponse MutateAccountBudgetProposal( + string customerId, + AccountBudgetProposalOperation operation, + gaxgrpc::CallSettings callSettings = null) => MutateAccountBudgetProposal( + new MutateAccountBudgetProposalRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + }, + callSettings); + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAccountBudgetProposalAsync( + MutateAccountBudgetProposalRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAccountBudgetProposalAsync( + MutateAccountBudgetProposalRequest request, + st::CancellationToken cancellationToken) => MutateAccountBudgetProposalAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAccountBudgetProposalResponse MutateAccountBudgetProposal( + MutateAccountBudgetProposalRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AccountBudgetProposalService client wrapper implementation, for convenient use. + /// + public sealed partial class AccountBudgetProposalServiceClientImpl : AccountBudgetProposalServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAccountBudgetProposal; + private readonly gaxgrpc::ApiCall _callMutateAccountBudgetProposal; + + /// + /// Constructs a client wrapper for the AccountBudgetProposalService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AccountBudgetProposalServiceClientImpl(AccountBudgetProposalService.AccountBudgetProposalServiceClient grpcClient, AccountBudgetProposalServiceSettings settings) + { + GrpcClient = grpcClient; + AccountBudgetProposalServiceSettings effectiveSettings = settings ?? AccountBudgetProposalServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAccountBudgetProposal = clientHelper.BuildApiCall( + GrpcClient.GetAccountBudgetProposalAsync, GrpcClient.GetAccountBudgetProposal, effectiveSettings.GetAccountBudgetProposalSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAccountBudgetProposal = clientHelper.BuildApiCall( + GrpcClient.MutateAccountBudgetProposalAsync, GrpcClient.MutateAccountBudgetProposal, effectiveSettings.MutateAccountBudgetProposalSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAccountBudgetProposal); + Modify_GetAccountBudgetProposalApiCall(ref _callGetAccountBudgetProposal); + Modify_ApiCall(ref _callMutateAccountBudgetProposal); + Modify_MutateAccountBudgetProposalApiCall(ref _callMutateAccountBudgetProposal); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAccountBudgetProposalApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAccountBudgetProposalApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AccountBudgetProposalService.AccountBudgetProposalServiceClient grpcClient, AccountBudgetProposalServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AccountBudgetProposalService client. + /// + public override AccountBudgetProposalService.AccountBudgetProposalServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAccountBudgetProposalRequest(ref GetAccountBudgetProposalRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAccountBudgetProposalRequest(ref MutateAccountBudgetProposalRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAccountBudgetProposalAsync( + GetAccountBudgetProposalRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAccountBudgetProposalRequest(ref request, ref callSettings); + return _callGetAccountBudgetProposal.Async(request, callSettings); + } + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AccountBudgetProposal GetAccountBudgetProposal( + GetAccountBudgetProposalRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAccountBudgetProposalRequest(ref request, ref callSettings); + return _callGetAccountBudgetProposal.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAccountBudgetProposalAsync( + MutateAccountBudgetProposalRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAccountBudgetProposalRequest(ref request, ref callSettings); + return _callMutateAccountBudgetProposal.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAccountBudgetProposalResponse MutateAccountBudgetProposal( + MutateAccountBudgetProposalRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAccountBudgetProposalRequest(ref request, ref callSettings); + return _callMutateAccountBudgetProposal.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AccountBudgetProposalServiceGrpc.cs b/src/V3/Stubs/AccountBudgetProposalServiceGrpc.cs new file mode 100644 index 000000000..fcb3419e7 --- /dev/null +++ b/src/V3/Stubs/AccountBudgetProposalServiceGrpc.cs @@ -0,0 +1,242 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/account_budget_proposal_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// A service for managing account-level budgets via proposals. + /// + /// A proposal is a request to create a new budget or make changes to an + /// existing one. + /// + /// Reads for account-level budgets managed by these proposals will be + /// supported in a future version. Until then, please use the + /// BudgetOrderService from the AdWords API. Learn more at + /// https://developers.google.com/adwords/api/docs/guides/budget-order + /// + /// Mutates: + /// The CREATE operation creates a new proposal. + /// UPDATE operations aren't supported. + /// The REMOVE operation cancels a pending proposal. + /// + public static partial class AccountBudgetProposalService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AccountBudgetProposalService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAccountBudgetProposalRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetProposalRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AccountBudgetProposal = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAccountBudgetProposalRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAccountBudgetProposalResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAccountBudgetProposal = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAccountBudgetProposal", + __Marshaller_google_ads_googleads_v3_services_GetAccountBudgetProposalRequest, + __Marshaller_google_ads_googleads_v3_resources_AccountBudgetProposal); + + static readonly grpc::Method __Method_MutateAccountBudgetProposal = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAccountBudgetProposal", + __Marshaller_google_ads_googleads_v3_services_MutateAccountBudgetProposalRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAccountBudgetProposalResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AccountBudgetProposalServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AccountBudgetProposalService + public abstract partial class AccountBudgetProposalServiceBase + { + /// + /// Returns an account-level budget proposal in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAccountBudgetProposal(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetProposalRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAccountBudgetProposal(global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AccountBudgetProposalService + public partial class AccountBudgetProposalServiceClient : grpc::ClientBase + { + /// Creates a new client for AccountBudgetProposalService + /// The channel to use to make remote calls. + public AccountBudgetProposalServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AccountBudgetProposalService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AccountBudgetProposalServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AccountBudgetProposalServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AccountBudgetProposalServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns an account-level budget proposal in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal GetAccountBudgetProposal(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetProposalRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAccountBudgetProposal(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns an account-level budget proposal in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal GetAccountBudgetProposal(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetProposalRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAccountBudgetProposal, null, options, request); + } + /// + /// Returns an account-level budget proposal in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAccountBudgetProposalAsync(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetProposalRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAccountBudgetProposalAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns an account-level budget proposal in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAccountBudgetProposalAsync(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetProposalRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAccountBudgetProposal, null, options, request); + } + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResponse MutateAccountBudgetProposal(global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAccountBudgetProposal(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalResponse MutateAccountBudgetProposal(global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAccountBudgetProposal, null, options, request); + } + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAccountBudgetProposalAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAccountBudgetProposalAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes account budget proposals. Operation statuses + /// are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAccountBudgetProposalAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAccountBudgetProposalRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAccountBudgetProposal, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AccountBudgetProposalServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AccountBudgetProposalServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AccountBudgetProposalServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAccountBudgetProposal, serviceImpl.GetAccountBudgetProposal) + .AddMethod(__Method_MutateAccountBudgetProposal, serviceImpl.MutateAccountBudgetProposal).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AccountBudgetProposalServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAccountBudgetProposal, serviceImpl.GetAccountBudgetProposal); + serviceBinder.AddMethod(__Method_MutateAccountBudgetProposal, serviceImpl.MutateAccountBudgetProposal); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AccountBudgetProposalStatus.cs b/src/V3/Stubs/AccountBudgetProposalStatus.cs new file mode 100644 index 000000000..7766f7f6f --- /dev/null +++ b/src/V3/Stubs/AccountBudgetProposalStatus.cs @@ -0,0 +1,203 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/account_budget_proposal_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/account_budget_proposal_status.proto + public static partial class AccountBudgetProposalStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/account_budget_proposal_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccountBudgetProposalStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hY2NvdW50X2J1ZGdl", + "dF9wcm9wb3NhbF9zdGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIqoBCh9B", + "Y2NvdW50QnVkZ2V0UHJvcG9zYWxTdGF0dXNFbnVtIoYBChtBY2NvdW50QnVk", + "Z2V0UHJvcG9zYWxTdGF0dXMSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dO", + "EAESCwoHUEVORElORxACEhEKDUFQUFJPVkVEX0hFTEQQAxIMCghBUFBST1ZF", + "RBAEEg0KCUNBTkNFTExFRBAFEgwKCFJFSkVDVEVEEAZC9QEKIWNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IgQWNjb3VudEJ1ZGdldFByb3Bv", + "c2FsU3RhdHVzUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8v", + "Z29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FB", + "qgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRz", + "XEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalStatusEnum.Types.AccountBudgetProposalStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing AccountBudgetProposal statuses. + /// + public sealed partial class AccountBudgetProposalStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccountBudgetProposalStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalStatusEnum(AccountBudgetProposalStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalStatusEnum Clone() { + return new AccountBudgetProposalStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccountBudgetProposalStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccountBudgetProposalStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccountBudgetProposalStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AccountBudgetProposalStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of an AccountBudgetProposal. + /// + public enum AccountBudgetProposalStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The proposal is pending approval. + /// + [pbr::OriginalName("PENDING")] Pending = 2, + /// + /// The proposal has been approved but the corresponding billing setup + /// has not. This can occur for proposals that set up the first budget + /// when signing up for billing or when performing a change of bill-to + /// operation. + /// + [pbr::OriginalName("APPROVED_HELD")] ApprovedHeld = 3, + /// + /// The proposal has been approved. + /// + [pbr::OriginalName("APPROVED")] Approved = 4, + /// + /// The proposal has been cancelled by the user. + /// + [pbr::OriginalName("CANCELLED")] Cancelled = 5, + /// + /// The proposal has been rejected by the user, e.g. by rejecting an + /// acceptance email. + /// + [pbr::OriginalName("REJECTED")] Rejected = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccountBudgetProposalType.cs b/src/V3/Stubs/AccountBudgetProposalType.cs new file mode 100644 index 000000000..99cdedf5f --- /dev/null +++ b/src/V3/Stubs/AccountBudgetProposalType.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/account_budget_proposal_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/account_budget_proposal_type.proto + public static partial class AccountBudgetProposalTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/account_budget_proposal_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccountBudgetProposalTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hY2NvdW50X2J1ZGdl", + "dF9wcm9wb3NhbF90eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKHAQodQWNj", + "b3VudEJ1ZGdldFByb3Bvc2FsVHlwZUVudW0iZgoZQWNjb3VudEJ1ZGdldFBy", + "b3Bvc2FsVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIKCgZD", + "UkVBVEUQAhIKCgZVUERBVEUQAxIHCgNFTkQQBBIKCgZSRU1PVkUQBULzAQoh", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQh5BY2NvdW50QnVk", + "Z2V0UHJvcG9zYWxUeXBlUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2Vu", + "cHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1z", + "ogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29n", + "bGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeEnum.Types.AccountBudgetProposalType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing AccountBudgetProposal types. + /// + public sealed partial class AccountBudgetProposalTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccountBudgetProposalTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetProposalTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalTypeEnum(AccountBudgetProposalTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetProposalTypeEnum Clone() { + return new AccountBudgetProposalTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccountBudgetProposalTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccountBudgetProposalTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccountBudgetProposalTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AccountBudgetProposalTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible types of an AccountBudgetProposal. + /// + public enum AccountBudgetProposalType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Identifies a request to create a new budget. + /// + [pbr::OriginalName("CREATE")] Create = 2, + /// + /// Identifies a request to edit an existing budget. + /// + [pbr::OriginalName("UPDATE")] Update = 3, + /// + /// Identifies a request to end a budget that has already started. + /// + [pbr::OriginalName("END")] End = 4, + /// + /// Identifies a request to remove a budget that hasn't started yet. + /// + [pbr::OriginalName("REMOVE")] Remove = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccountBudgetService.cs b/src/V3/Stubs/AccountBudgetService.cs new file mode 100644 index 000000000..8c31d4d2f --- /dev/null +++ b/src/V3/Stubs/AccountBudgetService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/account_budget_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/account_budget_service.proto + public static partial class AccountBudgetServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/account_budget_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccountBudgetServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hY2NvdW50X2J1", + "ZGdldF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2Fj", + "Y291bnRfYnVkZ2V0LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVs", + "ZF9iZWhhdmlvci5wcm90byI1ChdHZXRBY2NvdW50QnVkZ2V0UmVxdWVzdBIa", + "Cg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIy/wEKFEFjY291bnRCdWRnZXRT", + "ZXJ2aWNlEskBChBHZXRBY2NvdW50QnVkZ2V0EjkuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXMuR2V0QWNjb3VudEJ1ZGdldFJlcXVlc3QaMC5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWNjb3VudEJ1ZGdl", + "dCJIgtPkkwIyEjAvdjMve3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovYWNj", + "b3VudEJ1ZGdldHMvKn3aQQ1yZXNvdXJjZV9uYW1lGhvKQRhnb29nbGVhZHMu", + "Z29vZ2xlYXBpcy5jb21CgAIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlc0IZQWNjb3VudEJ1ZGdldFNlcnZpY2VQcm90b1ABWkhnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYz", + "XFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZp", + "Y2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetRequest), global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [AccountBudgetService.GetAccountBudget][google.ads.googleads.v3.services.AccountBudgetService.GetAccountBudget]. + /// + public sealed partial class GetAccountBudgetRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAccountBudgetRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AccountBudgetServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAccountBudgetRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAccountBudgetRequest(GetAccountBudgetRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAccountBudgetRequest Clone() { + return new GetAccountBudgetRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the account-level budget to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAccountBudgetRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAccountBudgetRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAccountBudgetRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AccountBudgetServiceClient.cs b/src/V3/Stubs/AccountBudgetServiceClient.cs new file mode 100644 index 000000000..3a8c79e9a --- /dev/null +++ b/src/V3/Stubs/AccountBudgetServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AccountBudgetServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AccountBudgetServiceSettings GetDefault() => new AccountBudgetServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AccountBudgetServiceSettings() { } + + private AccountBudgetServiceSettings(AccountBudgetServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAccountBudgetSettings = existing.GetAccountBudgetSettings; + OnCopy(existing); + } + + partial void OnCopy(AccountBudgetServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AccountBudgetServiceClient.GetAccountBudget and AccountBudgetServiceClient.GetAccountBudgetAsync. + /// + /// + /// The default AccountBudgetServiceClient.GetAccountBudget and + /// AccountBudgetServiceClient.GetAccountBudgetAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAccountBudgetSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AccountBudgetServiceSettings Clone() => new AccountBudgetServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AccountBudgetServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AccountBudgetServiceSettings Settings { get; set; } + + /// + public override AccountBudgetServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AccountBudgetServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AccountBudgetServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AccountBudgetServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AccountBudgetServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AccountBudgetServiceClient.ChannelPool; + } + + /// + /// AccountBudgetService client wrapper, for convenient use. + /// + public abstract partial class AccountBudgetServiceClient + { + /// + /// The default endpoint for the AccountBudgetService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AccountBudgetService scopes. + /// + /// + /// The default AccountBudgetService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AccountBudgetServiceClient client = await AccountBudgetServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AccountBudgetServiceClient.DefaultEndpoint.Host, AccountBudgetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AccountBudgetServiceClient client = AccountBudgetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AccountBudgetServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AccountBudgetServiceClient client = AccountBudgetServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AccountBudgetServiceClient.DefaultEndpoint.Host, AccountBudgetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AccountBudgetServiceClient client = AccountBudgetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AccountBudgetServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AccountBudgetServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AccountBudgetServiceClient Create(grpccore::Channel channel, AccountBudgetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AccountBudgetServiceClient Create(grpccore::CallInvoker callInvoker, AccountBudgetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AccountBudgetService.AccountBudgetServiceClient grpcClient = new AccountBudgetService.AccountBudgetServiceClient(callInvoker); + return new AccountBudgetServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AccountBudgetService client. + /// + public virtual AccountBudgetService.AccountBudgetServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns an account-level budget in full detail. + /// + /// + /// Required. The resource name of the account-level budget to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAccountBudgetAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAccountBudgetAsync( + new GetAccountBudgetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns an account-level budget in full detail. + /// + /// + /// Required. The resource name of the account-level budget to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAccountBudgetAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAccountBudgetAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns an account-level budget in full detail. + /// + /// + /// Required. The resource name of the account-level budget to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AccountBudget GetAccountBudget( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAccountBudget( + new GetAccountBudgetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns an account-level budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAccountBudgetAsync( + GetAccountBudgetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns an account-level budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAccountBudgetAsync( + GetAccountBudgetRequest request, + st::CancellationToken cancellationToken) => GetAccountBudgetAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns an account-level budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AccountBudget GetAccountBudget( + GetAccountBudgetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AccountBudgetService client wrapper implementation, for convenient use. + /// + public sealed partial class AccountBudgetServiceClientImpl : AccountBudgetServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAccountBudget; + + /// + /// Constructs a client wrapper for the AccountBudgetService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AccountBudgetServiceClientImpl(AccountBudgetService.AccountBudgetServiceClient grpcClient, AccountBudgetServiceSettings settings) + { + GrpcClient = grpcClient; + AccountBudgetServiceSettings effectiveSettings = settings ?? AccountBudgetServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAccountBudget = clientHelper.BuildApiCall( + GrpcClient.GetAccountBudgetAsync, GrpcClient.GetAccountBudget, effectiveSettings.GetAccountBudgetSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetAccountBudget); + Modify_GetAccountBudgetApiCall(ref _callGetAccountBudget); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAccountBudgetApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AccountBudgetService.AccountBudgetServiceClient grpcClient, AccountBudgetServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AccountBudgetService client. + /// + public override AccountBudgetService.AccountBudgetServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAccountBudgetRequest(ref GetAccountBudgetRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns an account-level budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAccountBudgetAsync( + GetAccountBudgetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAccountBudgetRequest(ref request, ref callSettings); + return _callGetAccountBudget.Async(request, callSettings); + } + + /// + /// Returns an account-level budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AccountBudget GetAccountBudget( + GetAccountBudgetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAccountBudgetRequest(ref request, ref callSettings); + return _callGetAccountBudget.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AccountBudgetServiceGrpc.cs b/src/V3/Stubs/AccountBudgetServiceGrpc.cs new file mode 100644 index 000000000..e1e0b6de7 --- /dev/null +++ b/src/V3/Stubs/AccountBudgetServiceGrpc.cs @@ -0,0 +1,160 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/account_budget_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// A service for fetching an account-level budget. + /// + /// Account-level budgets are mutated by creating proposal resources. + /// + public static partial class AccountBudgetService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AccountBudgetService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAccountBudgetRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AccountBudget = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AccountBudget.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAccountBudget = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAccountBudget", + __Marshaller_google_ads_googleads_v3_services_GetAccountBudgetRequest, + __Marshaller_google_ads_googleads_v3_resources_AccountBudget); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AccountBudgetServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AccountBudgetService + public abstract partial class AccountBudgetServiceBase + { + /// + /// Returns an account-level budget in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAccountBudget(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AccountBudgetService + public partial class AccountBudgetServiceClient : grpc::ClientBase + { + /// Creates a new client for AccountBudgetService + /// The channel to use to make remote calls. + public AccountBudgetServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AccountBudgetService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AccountBudgetServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AccountBudgetServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AccountBudgetServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns an account-level budget in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AccountBudget GetAccountBudget(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAccountBudget(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns an account-level budget in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AccountBudget GetAccountBudget(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAccountBudget, null, options, request); + } + /// + /// Returns an account-level budget in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAccountBudgetAsync(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAccountBudgetAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns an account-level budget in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAccountBudgetAsync(global::Google.Ads.GoogleAds.V3.Services.GetAccountBudgetRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAccountBudget, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AccountBudgetServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AccountBudgetServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AccountBudgetServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAccountBudget, serviceImpl.GetAccountBudget).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AccountBudgetServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAccountBudget, serviceImpl.GetAccountBudget); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AccountBudgetStatus.cs b/src/V3/Stubs/AccountBudgetStatus.cs new file mode 100644 index 000000000..b7e7e16c6 --- /dev/null +++ b/src/V3/Stubs/AccountBudgetStatus.cs @@ -0,0 +1,189 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/account_budget_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/account_budget_status.proto + public static partial class AccountBudgetStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/account_budget_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AccountBudgetStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hY2NvdW50X2J1ZGdl", + "dF9zdGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIngKF0FjY291bnRCdWRn", + "ZXRTdGF0dXNFbnVtIl0KE0FjY291bnRCdWRnZXRTdGF0dXMSDwoLVU5TUEVD", + "SUZJRUQQABILCgdVTktOT1dOEAESCwoHUEVORElORxACEgwKCEFQUFJPVkVE", + "EAMSDQoJQ0FOQ0VMTEVEEARC7QEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtc0IYQWNjb3VudEJ1ZGdldFN0YXR1c1Byb3RvUAFaQmdvb2ds", + "ZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFk", + "cy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFH", + "b29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetStatusEnum.Types.AccountBudgetStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing AccountBudget statuses. + /// + public sealed partial class AccountBudgetStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccountBudgetStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AccountBudgetStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetStatusEnum(AccountBudgetStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetStatusEnum Clone() { + return new AccountBudgetStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccountBudgetStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccountBudgetStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccountBudgetStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AccountBudgetStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of an AccountBudget. + /// + public enum AccountBudgetStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The account budget is pending approval. + /// + [pbr::OriginalName("PENDING")] Pending = 2, + /// + /// The account budget has been approved. + /// + [pbr::OriginalName("APPROVED")] Approved = 3, + /// + /// The account budget has been cancelled by the user. + /// + [pbr::OriginalName("CANCELLED")] Cancelled = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Ad.cs b/src/V3/Stubs/Ad.cs new file mode 100644 index 000000000..2ab2e2225 --- /dev/null +++ b/src/V3/Stubs/Ad.cs @@ -0,0 +1,1484 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad.proto + public static partial class AdReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cipnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWQucHJvdG8S", + "IWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcxoyZ29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvY29tbW9uL2FkX3R5cGVfaW5mb3MucHJvdG8aNWdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9jdXN0b21fcGFyYW1ldGVy", + "LnByb3RvGjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZmluYWxf", + "YXBwX3VybC5wcm90bxozZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9u", + "L3VybF9jb2xsZWN0aW9uLnByb3RvGitnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9hZF90eXBlLnByb3RvGipnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9kZXZpY2UucHJvdG8aQGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL3N5c3RlbV9tYW5hZ2VkX2VudGl0eV9zb3VyY2UucHJvdG8aH2dv", + "b2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVz", + "b3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxoc", + "Z29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLeEwoCQWQSOgoNcmVzb3Vy", + "Y2VfbmFtZRglIAEoCUIj4EEF+kEdChtnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b20vQWQSLAoCaWQYASABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1", + "ZUID4EEDEjAKCmZpbmFsX3VybHMYAiADKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWUSQwoOZmluYWxfYXBwX3VybHMYIyADKAsyKy5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5jb21tb24uRmluYWxBcHBVcmwSNwoRZmluYWxf", + "bW9iaWxlX3VybHMYECADKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFs", + "dWUSOwoVdHJhY2tpbmdfdXJsX3RlbXBsYXRlGAwgASgLMhwuZ29vZ2xlLnBy", + "b3RvYnVmLlN0cmluZ1ZhbHVlEjYKEGZpbmFsX3VybF9zdWZmaXgYJiABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSTgoVdXJsX2N1c3RvbV9w", + "YXJhbWV0ZXJzGAogAygLMi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29t", + "bW9uLkN1c3RvbVBhcmFtZXRlchIxCgtkaXNwbGF5X3VybBgEIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJDCgR0eXBlGAUgASgOMjAuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQWRUeXBlRW51bS5BZFR5cGVC", + "A+BBAxI8ChNhZGRlZF9ieV9nb29nbGVfYWRzGBMgASgLMhouZ29vZ2xlLnBy", + "b3RvYnVmLkJvb2xWYWx1ZUID4EEDEksKEWRldmljZV9wcmVmZXJlbmNlGBQg", + "ASgOMjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuRGV2aWNlRW51", + "bS5EZXZpY2USRgoPdXJsX2NvbGxlY3Rpb25zGBogAygLMi0uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuY29tbW9uLlVybENvbGxlY3Rpb24SLwoEbmFtZRgX", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEFEocBCh5z", + "eXN0ZW1fbWFuYWdlZF9yZXNvdXJjZV9zb3VyY2UYGyABKA4yWi5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtcy5TeXN0ZW1NYW5hZ2VkUmVzb3VyY2VT", + "b3VyY2VFbnVtLlN5c3RlbU1hbmFnZWRSZXNvdXJjZVNvdXJjZUID4EEDEj0K", + "B3RleHRfYWQYBiABKAsyKi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21t", + "b24uVGV4dEFkSW5mb0gAEk4KEGV4cGFuZGVkX3RleHRfYWQYByABKAsyMi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uRXhwYW5kZWRUZXh0QWRJ", + "bmZvSAASRgoMY2FsbF9vbmx5X2FkGA0gASgLMi4uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLkNhbGxPbmx5QWRJbmZvSAASYQoaZXhwYW5kZWRf", + "ZHluYW1pY19zZWFyY2hfYWQYDiABKAsyOy5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5jb21tb24uRXhwYW5kZWREeW5hbWljU2VhcmNoQWRJbmZvSAASPwoI", + "aG90ZWxfYWQYDyABKAsyKy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21t", + "b24uSG90ZWxBZEluZm9IABJQChFzaG9wcGluZ19zbWFydF9hZBgRIAEoCzIz", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5TaG9wcGluZ1NtYXJ0", + "QWRJbmZvSAASVAoTc2hvcHBpbmdfcHJvZHVjdF9hZBgSIAEoCzI1Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5TaG9wcGluZ1Byb2R1Y3RBZElu", + "Zm9IABI/CghnbWFpbF9hZBgVIAEoCzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmNvbW1vbi5HbWFpbEFkSW5mb0gAEj8KCGltYWdlX2FkGBYgASgLMisu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkltYWdlQWRJbmZvSAAS", + "PwoIdmlkZW9fYWQYGCABKAsyKy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5j", + "b21tb24uVmlkZW9BZEluZm9IABJWChRyZXNwb25zaXZlX3NlYXJjaF9hZBgZ", + "IAEoCzI2Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5SZXNwb25z", + "aXZlU2VhcmNoQWRJbmZvSAASZQocbGVnYWN5X3Jlc3BvbnNpdmVfZGlzcGxh", + "eV9hZBgcIAEoCzI9Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5M", + "ZWdhY3lSZXNwb25zaXZlRGlzcGxheUFkSW5mb0gAEjsKBmFwcF9hZBgdIAEo", + "CzIpLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BcHBBZEluZm9I", + "ABJcChVsZWdhY3lfYXBwX2luc3RhbGxfYWQYHiABKAsyNi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5jb21tb24uTGVnYWN5QXBwSW5zdGFsbEFkSW5mb0ID", + "4EEFSAASWAoVcmVzcG9uc2l2ZV9kaXNwbGF5X2FkGB8gASgLMjcuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuY29tbW9uLlJlc3BvbnNpdmVEaXNwbGF5QWRJ", + "bmZvSAASUAoRZGlzcGxheV91cGxvYWRfYWQYISABKAsyMy5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5jb21tb24uRGlzcGxheVVwbG9hZEFkSW5mb0gAElAK", + "EWFwcF9lbmdhZ2VtZW50X2FkGCIgASgLMjMuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuY29tbW9uLkFwcEVuZ2FnZW1lbnRBZEluZm9IABJpCh5zaG9wcGlu", + "Z19jb21wYXJpc29uX2xpc3RpbmdfYWQYJCABKAsyPy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5jb21tb24uU2hvcHBpbmdDb21wYXJpc29uTGlzdGluZ0Fk", + "SW5mb0gAOj/qQTwKG2dvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZBIdY3Vz", + "dG9tZXJzL3tjdXN0b21lcn0vYWRzL3thZH1CCQoHYWRfZGF0YUL0AQolY29t", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IHQWRQcm90b1AB", + "Wkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2ds", + "ZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.CustomParameterReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.FinalAppUrlReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.UrlCollectionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.DeviceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SystemManagedEntitySourceReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Ad), global::Google.Ads.GoogleAds.V3.Resources.Ad.Parser, new[]{ "ResourceName", "Id", "FinalUrls", "FinalAppUrls", "FinalMobileUrls", "TrackingUrlTemplate", "FinalUrlSuffix", "UrlCustomParameters", "DisplayUrl", "Type", "AddedByGoogleAds", "DevicePreference", "UrlCollections", "Name", "SystemManagedResourceSource", "TextAd", "ExpandedTextAd", "CallOnlyAd", "ExpandedDynamicSearchAd", "HotelAd", "ShoppingSmartAd", "ShoppingProductAd", "GmailAd", "ImageAd", "VideoAd", "ResponsiveSearchAd", "LegacyResponsiveDisplayAd", "AppAd", "LegacyAppInstallAd", "ResponsiveDisplayAd", "DisplayUploadAd", "AppEngagementAd", "ShoppingComparisonListingAd" }, new[]{ "AdData" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad. + /// + public sealed partial class Ad : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Ad()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Ad() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Ad(Ad other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + finalUrls_ = other.finalUrls_.Clone(); + finalAppUrls_ = other.finalAppUrls_.Clone(); + finalMobileUrls_ = other.finalMobileUrls_.Clone(); + TrackingUrlTemplate = other.TrackingUrlTemplate; + FinalUrlSuffix = other.FinalUrlSuffix; + urlCustomParameters_ = other.urlCustomParameters_.Clone(); + DisplayUrl = other.DisplayUrl; + type_ = other.type_; + AddedByGoogleAds = other.AddedByGoogleAds; + devicePreference_ = other.devicePreference_; + urlCollections_ = other.urlCollections_.Clone(); + Name = other.Name; + systemManagedResourceSource_ = other.systemManagedResourceSource_; + switch (other.AdDataCase) { + case AdDataOneofCase.TextAd: + TextAd = other.TextAd.Clone(); + break; + case AdDataOneofCase.ExpandedTextAd: + ExpandedTextAd = other.ExpandedTextAd.Clone(); + break; + case AdDataOneofCase.CallOnlyAd: + CallOnlyAd = other.CallOnlyAd.Clone(); + break; + case AdDataOneofCase.ExpandedDynamicSearchAd: + ExpandedDynamicSearchAd = other.ExpandedDynamicSearchAd.Clone(); + break; + case AdDataOneofCase.HotelAd: + HotelAd = other.HotelAd.Clone(); + break; + case AdDataOneofCase.ShoppingSmartAd: + ShoppingSmartAd = other.ShoppingSmartAd.Clone(); + break; + case AdDataOneofCase.ShoppingProductAd: + ShoppingProductAd = other.ShoppingProductAd.Clone(); + break; + case AdDataOneofCase.GmailAd: + GmailAd = other.GmailAd.Clone(); + break; + case AdDataOneofCase.ImageAd: + ImageAd = other.ImageAd.Clone(); + break; + case AdDataOneofCase.VideoAd: + VideoAd = other.VideoAd.Clone(); + break; + case AdDataOneofCase.ResponsiveSearchAd: + ResponsiveSearchAd = other.ResponsiveSearchAd.Clone(); + break; + case AdDataOneofCase.LegacyResponsiveDisplayAd: + LegacyResponsiveDisplayAd = other.LegacyResponsiveDisplayAd.Clone(); + break; + case AdDataOneofCase.AppAd: + AppAd = other.AppAd.Clone(); + break; + case AdDataOneofCase.LegacyAppInstallAd: + LegacyAppInstallAd = other.LegacyAppInstallAd.Clone(); + break; + case AdDataOneofCase.ResponsiveDisplayAd: + ResponsiveDisplayAd = other.ResponsiveDisplayAd.Clone(); + break; + case AdDataOneofCase.DisplayUploadAd: + DisplayUploadAd = other.DisplayUploadAd.Clone(); + break; + case AdDataOneofCase.AppEngagementAd: + AppEngagementAd = other.AppEngagementAd.Clone(); + break; + case AdDataOneofCase.ShoppingComparisonListingAd: + ShoppingComparisonListingAd = other.ShoppingComparisonListingAd.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Ad Clone() { + return new Ad(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 37; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad. + /// Ad resource names have the form: + /// + /// `customers/{customer_id}/ads/{ad_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 1; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(10); + private long? id_; + /// + /// Output only. The ID of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "final_urls" field. + public const int FinalUrlsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_finalUrls_codec + = pb::FieldCodec.ForClassWrapper(18); + private readonly pbc::RepeatedField finalUrls_ = new pbc::RepeatedField(); + /// + /// The list of possible final URLs after all cross-domain redirects for the + /// ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalUrls { + get { return finalUrls_; } + } + + /// Field number for the "final_app_urls" field. + public const int FinalAppUrlsFieldNumber = 35; + private static readonly pb::FieldCodec _repeated_finalAppUrls_codec + = pb::FieldCodec.ForMessage(282, global::Google.Ads.GoogleAds.V3.Common.FinalAppUrl.Parser); + private readonly pbc::RepeatedField finalAppUrls_ = new pbc::RepeatedField(); + /// + /// A list of final app URLs that will be used on mobile if the user has the + /// specific app installed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalAppUrls { + get { return finalAppUrls_; } + } + + /// Field number for the "final_mobile_urls" field. + public const int FinalMobileUrlsFieldNumber = 16; + private static readonly pb::FieldCodec _repeated_finalMobileUrls_codec + = pb::FieldCodec.ForClassWrapper(130); + private readonly pbc::RepeatedField finalMobileUrls_ = new pbc::RepeatedField(); + /// + /// The list of possible final mobile URLs after all cross-domain redirects + /// for the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalMobileUrls { + get { return finalMobileUrls_; } + } + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 12; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(98); + private string trackingUrlTemplate_; + /// + /// The URL template for constructing a tracking URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 38; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(306); + private string finalUrlSuffix_; + /// + /// The suffix to use when constructing a final URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + /// Field number for the "url_custom_parameters" field. + public const int UrlCustomParametersFieldNumber = 10; + private static readonly pb::FieldCodec _repeated_urlCustomParameters_codec + = pb::FieldCodec.ForMessage(82, global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser); + private readonly pbc::RepeatedField urlCustomParameters_ = new pbc::RepeatedField(); + /// + /// The list of mappings that can be used to substitute custom parameter tags + /// in a `tracking_url_template`, `final_urls`, or `mobile_final_urls`. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCustomParameters { + get { return urlCustomParameters_; } + } + + /// Field number for the "display_url" field. + public const int DisplayUrlFieldNumber = 4; + private static readonly pb::FieldCodec _single_displayUrl_codec = pb::FieldCodec.ForClassWrapper(34); + private string displayUrl_; + /// + /// The URL that appears in the ad description for some ad formats. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DisplayUrl { + get { return displayUrl_; } + set { + displayUrl_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.AdTypeEnum.Types.AdType type_ = 0; + /// + /// Output only. The type of ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdTypeEnum.Types.AdType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "added_by_google_ads" field. + public const int AddedByGoogleAdsFieldNumber = 19; + private static readonly pb::FieldCodec _single_addedByGoogleAds_codec = pb::FieldCodec.ForStructWrapper(154); + private bool? addedByGoogleAds_; + /// + /// Output only. Indicates if this ad was automatically added by Google Ads and not by a + /// user. For example, this could happen when ads are automatically created as + /// suggestions for new ads based on knowledge of how existing ads are + /// performing. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? AddedByGoogleAds { + get { return addedByGoogleAds_; } + set { + addedByGoogleAds_ = value; + } + } + + + /// Field number for the "device_preference" field. + public const int DevicePreferenceFieldNumber = 20; + private global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types.Device devicePreference_ = 0; + /// + /// The device preference for the ad. You can only specify a preference for + /// mobile devices. When this preference is set the ad will be preferred over + /// other ads when being displayed on a mobile device. The ad can still be + /// displayed on other device types, e.g. if no other ads are available. + /// If unspecified (no device preference), all devices are targeted. + /// This is only supported by some ad types. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types.Device DevicePreference { + get { return devicePreference_; } + set { + devicePreference_ = value; + } + } + + /// Field number for the "url_collections" field. + public const int UrlCollectionsFieldNumber = 26; + private static readonly pb::FieldCodec _repeated_urlCollections_codec + = pb::FieldCodec.ForMessage(210, global::Google.Ads.GoogleAds.V3.Common.UrlCollection.Parser); + private readonly pbc::RepeatedField urlCollections_ = new pbc::RepeatedField(); + /// + /// Additional URLs for the ad that are tagged with a unique identifier that + /// can be referenced from other fields in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCollections { + get { return urlCollections_; } + } + + /// Field number for the "name" field. + public const int NameFieldNumber = 23; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(186); + private string name_; + /// + /// Immutable. The name of the ad. This is only used to be able to identify the ad. It + /// does not need to be unique and does not affect the served ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "system_managed_resource_source" field. + public const int SystemManagedResourceSourceFieldNumber = 27; + private global::Google.Ads.GoogleAds.V3.Enums.SystemManagedResourceSourceEnum.Types.SystemManagedResourceSource systemManagedResourceSource_ = 0; + /// + /// Output only. If this ad is system managed, then this field will indicate the source. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SystemManagedResourceSourceEnum.Types.SystemManagedResourceSource SystemManagedResourceSource { + get { return systemManagedResourceSource_; } + set { + systemManagedResourceSource_ = value; + } + } + + /// Field number for the "text_ad" field. + public const int TextAdFieldNumber = 6; + /// + /// Details pertaining to a text ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TextAdInfo TextAd { + get { return adDataCase_ == AdDataOneofCase.TextAd ? (global::Google.Ads.GoogleAds.V3.Common.TextAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.TextAd; + } + } + + /// Field number for the "expanded_text_ad" field. + public const int ExpandedTextAdFieldNumber = 7; + /// + /// Details pertaining to an expanded text ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ExpandedTextAdInfo ExpandedTextAd { + get { return adDataCase_ == AdDataOneofCase.ExpandedTextAd ? (global::Google.Ads.GoogleAds.V3.Common.ExpandedTextAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.ExpandedTextAd; + } + } + + /// Field number for the "call_only_ad" field. + public const int CallOnlyAdFieldNumber = 13; + /// + /// Details pertaining to a call-only ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CallOnlyAdInfo CallOnlyAd { + get { return adDataCase_ == AdDataOneofCase.CallOnlyAd ? (global::Google.Ads.GoogleAds.V3.Common.CallOnlyAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.CallOnlyAd; + } + } + + /// Field number for the "expanded_dynamic_search_ad" field. + public const int ExpandedDynamicSearchAdFieldNumber = 14; + /// + /// Details pertaining to an Expanded Dynamic Search Ad. + /// This type of ad has its headline, final URLs, and display URL + /// auto-generated at serving time according to domain name specific + /// information provided by `dynamic_search_ads_setting` linked at the + /// campaign level. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ExpandedDynamicSearchAdInfo ExpandedDynamicSearchAd { + get { return adDataCase_ == AdDataOneofCase.ExpandedDynamicSearchAd ? (global::Google.Ads.GoogleAds.V3.Common.ExpandedDynamicSearchAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.ExpandedDynamicSearchAd; + } + } + + /// Field number for the "hotel_ad" field. + public const int HotelAdFieldNumber = 15; + /// + /// Details pertaining to a hotel ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelAdInfo HotelAd { + get { return adDataCase_ == AdDataOneofCase.HotelAd ? (global::Google.Ads.GoogleAds.V3.Common.HotelAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.HotelAd; + } + } + + /// Field number for the "shopping_smart_ad" field. + public const int ShoppingSmartAdFieldNumber = 17; + /// + /// Details pertaining to a Smart Shopping ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ShoppingSmartAdInfo ShoppingSmartAd { + get { return adDataCase_ == AdDataOneofCase.ShoppingSmartAd ? (global::Google.Ads.GoogleAds.V3.Common.ShoppingSmartAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.ShoppingSmartAd; + } + } + + /// Field number for the "shopping_product_ad" field. + public const int ShoppingProductAdFieldNumber = 18; + /// + /// Details pertaining to a Shopping product ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ShoppingProductAdInfo ShoppingProductAd { + get { return adDataCase_ == AdDataOneofCase.ShoppingProductAd ? (global::Google.Ads.GoogleAds.V3.Common.ShoppingProductAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.ShoppingProductAd; + } + } + + /// Field number for the "gmail_ad" field. + public const int GmailAdFieldNumber = 21; + /// + /// Details pertaining to a Gmail ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.GmailAdInfo GmailAd { + get { return adDataCase_ == AdDataOneofCase.GmailAd ? (global::Google.Ads.GoogleAds.V3.Common.GmailAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.GmailAd; + } + } + + /// Field number for the "image_ad" field. + public const int ImageAdFieldNumber = 22; + /// + /// Details pertaining to an Image ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ImageAdInfo ImageAd { + get { return adDataCase_ == AdDataOneofCase.ImageAd ? (global::Google.Ads.GoogleAds.V3.Common.ImageAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.ImageAd; + } + } + + /// Field number for the "video_ad" field. + public const int VideoAdFieldNumber = 24; + /// + /// Details pertaining to a Video ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.VideoAdInfo VideoAd { + get { return adDataCase_ == AdDataOneofCase.VideoAd ? (global::Google.Ads.GoogleAds.V3.Common.VideoAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.VideoAd; + } + } + + /// Field number for the "responsive_search_ad" field. + public const int ResponsiveSearchAdFieldNumber = 25; + /// + /// Details pertaining to a responsive search ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ResponsiveSearchAdInfo ResponsiveSearchAd { + get { return adDataCase_ == AdDataOneofCase.ResponsiveSearchAd ? (global::Google.Ads.GoogleAds.V3.Common.ResponsiveSearchAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.ResponsiveSearchAd; + } + } + + /// Field number for the "legacy_responsive_display_ad" field. + public const int LegacyResponsiveDisplayAdFieldNumber = 28; + /// + /// Details pertaining to a legacy responsive display ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.LegacyResponsiveDisplayAdInfo LegacyResponsiveDisplayAd { + get { return adDataCase_ == AdDataOneofCase.LegacyResponsiveDisplayAd ? (global::Google.Ads.GoogleAds.V3.Common.LegacyResponsiveDisplayAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.LegacyResponsiveDisplayAd; + } + } + + /// Field number for the "app_ad" field. + public const int AppAdFieldNumber = 29; + /// + /// Details pertaining to an app ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AppAdInfo AppAd { + get { return adDataCase_ == AdDataOneofCase.AppAd ? (global::Google.Ads.GoogleAds.V3.Common.AppAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.AppAd; + } + } + + /// Field number for the "legacy_app_install_ad" field. + public const int LegacyAppInstallAdFieldNumber = 30; + /// + /// Immutable. Details pertaining to a legacy app install ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.LegacyAppInstallAdInfo LegacyAppInstallAd { + get { return adDataCase_ == AdDataOneofCase.LegacyAppInstallAd ? (global::Google.Ads.GoogleAds.V3.Common.LegacyAppInstallAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.LegacyAppInstallAd; + } + } + + /// Field number for the "responsive_display_ad" field. + public const int ResponsiveDisplayAdFieldNumber = 31; + /// + /// Details pertaining to a responsive display ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ResponsiveDisplayAdInfo ResponsiveDisplayAd { + get { return adDataCase_ == AdDataOneofCase.ResponsiveDisplayAd ? (global::Google.Ads.GoogleAds.V3.Common.ResponsiveDisplayAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.ResponsiveDisplayAd; + } + } + + /// Field number for the "display_upload_ad" field. + public const int DisplayUploadAdFieldNumber = 33; + /// + /// Details pertaining to a display upload ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.DisplayUploadAdInfo DisplayUploadAd { + get { return adDataCase_ == AdDataOneofCase.DisplayUploadAd ? (global::Google.Ads.GoogleAds.V3.Common.DisplayUploadAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.DisplayUploadAd; + } + } + + /// Field number for the "app_engagement_ad" field. + public const int AppEngagementAdFieldNumber = 34; + /// + /// Details pertaining to an app engagement ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AppEngagementAdInfo AppEngagementAd { + get { return adDataCase_ == AdDataOneofCase.AppEngagementAd ? (global::Google.Ads.GoogleAds.V3.Common.AppEngagementAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.AppEngagementAd; + } + } + + /// Field number for the "shopping_comparison_listing_ad" field. + public const int ShoppingComparisonListingAdFieldNumber = 36; + /// + /// Details pertaining to a Shopping Comparison Listing ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ShoppingComparisonListingAdInfo ShoppingComparisonListingAd { + get { return adDataCase_ == AdDataOneofCase.ShoppingComparisonListingAd ? (global::Google.Ads.GoogleAds.V3.Common.ShoppingComparisonListingAdInfo) adData_ : null; } + set { + adData_ = value; + adDataCase_ = value == null ? AdDataOneofCase.None : AdDataOneofCase.ShoppingComparisonListingAd; + } + } + + private object adData_; + /// Enum of possible cases for the "ad_data" oneof. + public enum AdDataOneofCase { + None = 0, + TextAd = 6, + ExpandedTextAd = 7, + CallOnlyAd = 13, + ExpandedDynamicSearchAd = 14, + HotelAd = 15, + ShoppingSmartAd = 17, + ShoppingProductAd = 18, + GmailAd = 21, + ImageAd = 22, + VideoAd = 24, + ResponsiveSearchAd = 25, + LegacyResponsiveDisplayAd = 28, + AppAd = 29, + LegacyAppInstallAd = 30, + ResponsiveDisplayAd = 31, + DisplayUploadAd = 33, + AppEngagementAd = 34, + ShoppingComparisonListingAd = 36, + } + private AdDataOneofCase adDataCase_ = AdDataOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdDataOneofCase AdDataCase { + get { return adDataCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearAdData() { + adDataCase_ = AdDataOneofCase.None; + adData_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as Ad); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(Ad other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if(!finalUrls_.Equals(other.finalUrls_)) return false; + if(!finalAppUrls_.Equals(other.finalAppUrls_)) return false; + if(!finalMobileUrls_.Equals(other.finalMobileUrls_)) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + if(!urlCustomParameters_.Equals(other.urlCustomParameters_)) return false; + if (DisplayUrl != other.DisplayUrl) return false; + if (Type != other.Type) return false; + if (AddedByGoogleAds != other.AddedByGoogleAds) return false; + if (DevicePreference != other.DevicePreference) return false; + if(!urlCollections_.Equals(other.urlCollections_)) return false; + if (Name != other.Name) return false; + if (SystemManagedResourceSource != other.SystemManagedResourceSource) return false; + if (!object.Equals(TextAd, other.TextAd)) return false; + if (!object.Equals(ExpandedTextAd, other.ExpandedTextAd)) return false; + if (!object.Equals(CallOnlyAd, other.CallOnlyAd)) return false; + if (!object.Equals(ExpandedDynamicSearchAd, other.ExpandedDynamicSearchAd)) return false; + if (!object.Equals(HotelAd, other.HotelAd)) return false; + if (!object.Equals(ShoppingSmartAd, other.ShoppingSmartAd)) return false; + if (!object.Equals(ShoppingProductAd, other.ShoppingProductAd)) return false; + if (!object.Equals(GmailAd, other.GmailAd)) return false; + if (!object.Equals(ImageAd, other.ImageAd)) return false; + if (!object.Equals(VideoAd, other.VideoAd)) return false; + if (!object.Equals(ResponsiveSearchAd, other.ResponsiveSearchAd)) return false; + if (!object.Equals(LegacyResponsiveDisplayAd, other.LegacyResponsiveDisplayAd)) return false; + if (!object.Equals(AppAd, other.AppAd)) return false; + if (!object.Equals(LegacyAppInstallAd, other.LegacyAppInstallAd)) return false; + if (!object.Equals(ResponsiveDisplayAd, other.ResponsiveDisplayAd)) return false; + if (!object.Equals(DisplayUploadAd, other.DisplayUploadAd)) return false; + if (!object.Equals(AppEngagementAd, other.AppEngagementAd)) return false; + if (!object.Equals(ShoppingComparisonListingAd, other.ShoppingComparisonListingAd)) return false; + if (AdDataCase != other.AdDataCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + hash ^= finalUrls_.GetHashCode(); + hash ^= finalAppUrls_.GetHashCode(); + hash ^= finalMobileUrls_.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + hash ^= urlCustomParameters_.GetHashCode(); + if (displayUrl_ != null) hash ^= DisplayUrl.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (addedByGoogleAds_ != null) hash ^= AddedByGoogleAds.GetHashCode(); + if (DevicePreference != 0) hash ^= DevicePreference.GetHashCode(); + hash ^= urlCollections_.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (SystemManagedResourceSource != 0) hash ^= SystemManagedResourceSource.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.TextAd) hash ^= TextAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.ExpandedTextAd) hash ^= ExpandedTextAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.CallOnlyAd) hash ^= CallOnlyAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.ExpandedDynamicSearchAd) hash ^= ExpandedDynamicSearchAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.HotelAd) hash ^= HotelAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.ShoppingSmartAd) hash ^= ShoppingSmartAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.ShoppingProductAd) hash ^= ShoppingProductAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.GmailAd) hash ^= GmailAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.ImageAd) hash ^= ImageAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.VideoAd) hash ^= VideoAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.ResponsiveSearchAd) hash ^= ResponsiveSearchAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.LegacyResponsiveDisplayAd) hash ^= LegacyResponsiveDisplayAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.AppAd) hash ^= AppAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.LegacyAppInstallAd) hash ^= LegacyAppInstallAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.ResponsiveDisplayAd) hash ^= ResponsiveDisplayAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.DisplayUploadAd) hash ^= DisplayUploadAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.AppEngagementAd) hash ^= AppEngagementAd.GetHashCode(); + if (adDataCase_ == AdDataOneofCase.ShoppingComparisonListingAd) hash ^= ShoppingComparisonListingAd.GetHashCode(); + hash ^= (int) adDataCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + finalUrls_.WriteTo(output, _repeated_finalUrls_codec); + if (displayUrl_ != null) { + _single_displayUrl_codec.WriteTagAndValue(output, DisplayUrl); + } + if (Type != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Type); + } + if (adDataCase_ == AdDataOneofCase.TextAd) { + output.WriteRawTag(50); + output.WriteMessage(TextAd); + } + if (adDataCase_ == AdDataOneofCase.ExpandedTextAd) { + output.WriteRawTag(58); + output.WriteMessage(ExpandedTextAd); + } + urlCustomParameters_.WriteTo(output, _repeated_urlCustomParameters_codec); + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + if (adDataCase_ == AdDataOneofCase.CallOnlyAd) { + output.WriteRawTag(106); + output.WriteMessage(CallOnlyAd); + } + if (adDataCase_ == AdDataOneofCase.ExpandedDynamicSearchAd) { + output.WriteRawTag(114); + output.WriteMessage(ExpandedDynamicSearchAd); + } + if (adDataCase_ == AdDataOneofCase.HotelAd) { + output.WriteRawTag(122); + output.WriteMessage(HotelAd); + } + finalMobileUrls_.WriteTo(output, _repeated_finalMobileUrls_codec); + if (adDataCase_ == AdDataOneofCase.ShoppingSmartAd) { + output.WriteRawTag(138, 1); + output.WriteMessage(ShoppingSmartAd); + } + if (adDataCase_ == AdDataOneofCase.ShoppingProductAd) { + output.WriteRawTag(146, 1); + output.WriteMessage(ShoppingProductAd); + } + if (addedByGoogleAds_ != null) { + _single_addedByGoogleAds_codec.WriteTagAndValue(output, AddedByGoogleAds); + } + if (DevicePreference != 0) { + output.WriteRawTag(160, 1); + output.WriteEnum((int) DevicePreference); + } + if (adDataCase_ == AdDataOneofCase.GmailAd) { + output.WriteRawTag(170, 1); + output.WriteMessage(GmailAd); + } + if (adDataCase_ == AdDataOneofCase.ImageAd) { + output.WriteRawTag(178, 1); + output.WriteMessage(ImageAd); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (adDataCase_ == AdDataOneofCase.VideoAd) { + output.WriteRawTag(194, 1); + output.WriteMessage(VideoAd); + } + if (adDataCase_ == AdDataOneofCase.ResponsiveSearchAd) { + output.WriteRawTag(202, 1); + output.WriteMessage(ResponsiveSearchAd); + } + urlCollections_.WriteTo(output, _repeated_urlCollections_codec); + if (SystemManagedResourceSource != 0) { + output.WriteRawTag(216, 1); + output.WriteEnum((int) SystemManagedResourceSource); + } + if (adDataCase_ == AdDataOneofCase.LegacyResponsiveDisplayAd) { + output.WriteRawTag(226, 1); + output.WriteMessage(LegacyResponsiveDisplayAd); + } + if (adDataCase_ == AdDataOneofCase.AppAd) { + output.WriteRawTag(234, 1); + output.WriteMessage(AppAd); + } + if (adDataCase_ == AdDataOneofCase.LegacyAppInstallAd) { + output.WriteRawTag(242, 1); + output.WriteMessage(LegacyAppInstallAd); + } + if (adDataCase_ == AdDataOneofCase.ResponsiveDisplayAd) { + output.WriteRawTag(250, 1); + output.WriteMessage(ResponsiveDisplayAd); + } + if (adDataCase_ == AdDataOneofCase.DisplayUploadAd) { + output.WriteRawTag(138, 2); + output.WriteMessage(DisplayUploadAd); + } + if (adDataCase_ == AdDataOneofCase.AppEngagementAd) { + output.WriteRawTag(146, 2); + output.WriteMessage(AppEngagementAd); + } + finalAppUrls_.WriteTo(output, _repeated_finalAppUrls_codec); + if (adDataCase_ == AdDataOneofCase.ShoppingComparisonListingAd) { + output.WriteRawTag(162, 2); + output.WriteMessage(ShoppingComparisonListingAd); + } + if (ResourceName.Length != 0) { + output.WriteRawTag(170, 2); + output.WriteString(ResourceName); + } + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 2 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + size += finalUrls_.CalculateSize(_repeated_finalUrls_codec); + size += finalAppUrls_.CalculateSize(_repeated_finalAppUrls_codec); + size += finalMobileUrls_.CalculateSize(_repeated_finalMobileUrls_codec); + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + size += urlCustomParameters_.CalculateSize(_repeated_urlCustomParameters_codec); + if (displayUrl_ != null) { + size += _single_displayUrl_codec.CalculateSizeWithTag(DisplayUrl); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (addedByGoogleAds_ != null) { + size += _single_addedByGoogleAds_codec.CalculateSizeWithTag(AddedByGoogleAds); + } + if (DevicePreference != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) DevicePreference); + } + size += urlCollections_.CalculateSize(_repeated_urlCollections_codec); + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (SystemManagedResourceSource != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) SystemManagedResourceSource); + } + if (adDataCase_ == AdDataOneofCase.TextAd) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(TextAd); + } + if (adDataCase_ == AdDataOneofCase.ExpandedTextAd) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ExpandedTextAd); + } + if (adDataCase_ == AdDataOneofCase.CallOnlyAd) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CallOnlyAd); + } + if (adDataCase_ == AdDataOneofCase.ExpandedDynamicSearchAd) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ExpandedDynamicSearchAd); + } + if (adDataCase_ == AdDataOneofCase.HotelAd) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelAd); + } + if (adDataCase_ == AdDataOneofCase.ShoppingSmartAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ShoppingSmartAd); + } + if (adDataCase_ == AdDataOneofCase.ShoppingProductAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ShoppingProductAd); + } + if (adDataCase_ == AdDataOneofCase.GmailAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(GmailAd); + } + if (adDataCase_ == AdDataOneofCase.ImageAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ImageAd); + } + if (adDataCase_ == AdDataOneofCase.VideoAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(VideoAd); + } + if (adDataCase_ == AdDataOneofCase.ResponsiveSearchAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ResponsiveSearchAd); + } + if (adDataCase_ == AdDataOneofCase.LegacyResponsiveDisplayAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(LegacyResponsiveDisplayAd); + } + if (adDataCase_ == AdDataOneofCase.AppAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AppAd); + } + if (adDataCase_ == AdDataOneofCase.LegacyAppInstallAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(LegacyAppInstallAd); + } + if (adDataCase_ == AdDataOneofCase.ResponsiveDisplayAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ResponsiveDisplayAd); + } + if (adDataCase_ == AdDataOneofCase.DisplayUploadAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(DisplayUploadAd); + } + if (adDataCase_ == AdDataOneofCase.AppEngagementAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AppEngagementAd); + } + if (adDataCase_ == AdDataOneofCase.ShoppingComparisonListingAd) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ShoppingComparisonListingAd); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(Ad other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + finalUrls_.Add(other.finalUrls_); + finalAppUrls_.Add(other.finalAppUrls_); + finalMobileUrls_.Add(other.finalMobileUrls_); + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + urlCustomParameters_.Add(other.urlCustomParameters_); + if (other.displayUrl_ != null) { + if (displayUrl_ == null || other.DisplayUrl != "") { + DisplayUrl = other.DisplayUrl; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.addedByGoogleAds_ != null) { + if (addedByGoogleAds_ == null || other.AddedByGoogleAds != false) { + AddedByGoogleAds = other.AddedByGoogleAds; + } + } + if (other.DevicePreference != 0) { + DevicePreference = other.DevicePreference; + } + urlCollections_.Add(other.urlCollections_); + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.SystemManagedResourceSource != 0) { + SystemManagedResourceSource = other.SystemManagedResourceSource; + } + switch (other.AdDataCase) { + case AdDataOneofCase.TextAd: + if (TextAd == null) { + TextAd = new global::Google.Ads.GoogleAds.V3.Common.TextAdInfo(); + } + TextAd.MergeFrom(other.TextAd); + break; + case AdDataOneofCase.ExpandedTextAd: + if (ExpandedTextAd == null) { + ExpandedTextAd = new global::Google.Ads.GoogleAds.V3.Common.ExpandedTextAdInfo(); + } + ExpandedTextAd.MergeFrom(other.ExpandedTextAd); + break; + case AdDataOneofCase.CallOnlyAd: + if (CallOnlyAd == null) { + CallOnlyAd = new global::Google.Ads.GoogleAds.V3.Common.CallOnlyAdInfo(); + } + CallOnlyAd.MergeFrom(other.CallOnlyAd); + break; + case AdDataOneofCase.ExpandedDynamicSearchAd: + if (ExpandedDynamicSearchAd == null) { + ExpandedDynamicSearchAd = new global::Google.Ads.GoogleAds.V3.Common.ExpandedDynamicSearchAdInfo(); + } + ExpandedDynamicSearchAd.MergeFrom(other.ExpandedDynamicSearchAd); + break; + case AdDataOneofCase.HotelAd: + if (HotelAd == null) { + HotelAd = new global::Google.Ads.GoogleAds.V3.Common.HotelAdInfo(); + } + HotelAd.MergeFrom(other.HotelAd); + break; + case AdDataOneofCase.ShoppingSmartAd: + if (ShoppingSmartAd == null) { + ShoppingSmartAd = new global::Google.Ads.GoogleAds.V3.Common.ShoppingSmartAdInfo(); + } + ShoppingSmartAd.MergeFrom(other.ShoppingSmartAd); + break; + case AdDataOneofCase.ShoppingProductAd: + if (ShoppingProductAd == null) { + ShoppingProductAd = new global::Google.Ads.GoogleAds.V3.Common.ShoppingProductAdInfo(); + } + ShoppingProductAd.MergeFrom(other.ShoppingProductAd); + break; + case AdDataOneofCase.GmailAd: + if (GmailAd == null) { + GmailAd = new global::Google.Ads.GoogleAds.V3.Common.GmailAdInfo(); + } + GmailAd.MergeFrom(other.GmailAd); + break; + case AdDataOneofCase.ImageAd: + if (ImageAd == null) { + ImageAd = new global::Google.Ads.GoogleAds.V3.Common.ImageAdInfo(); + } + ImageAd.MergeFrom(other.ImageAd); + break; + case AdDataOneofCase.VideoAd: + if (VideoAd == null) { + VideoAd = new global::Google.Ads.GoogleAds.V3.Common.VideoAdInfo(); + } + VideoAd.MergeFrom(other.VideoAd); + break; + case AdDataOneofCase.ResponsiveSearchAd: + if (ResponsiveSearchAd == null) { + ResponsiveSearchAd = new global::Google.Ads.GoogleAds.V3.Common.ResponsiveSearchAdInfo(); + } + ResponsiveSearchAd.MergeFrom(other.ResponsiveSearchAd); + break; + case AdDataOneofCase.LegacyResponsiveDisplayAd: + if (LegacyResponsiveDisplayAd == null) { + LegacyResponsiveDisplayAd = new global::Google.Ads.GoogleAds.V3.Common.LegacyResponsiveDisplayAdInfo(); + } + LegacyResponsiveDisplayAd.MergeFrom(other.LegacyResponsiveDisplayAd); + break; + case AdDataOneofCase.AppAd: + if (AppAd == null) { + AppAd = new global::Google.Ads.GoogleAds.V3.Common.AppAdInfo(); + } + AppAd.MergeFrom(other.AppAd); + break; + case AdDataOneofCase.LegacyAppInstallAd: + if (LegacyAppInstallAd == null) { + LegacyAppInstallAd = new global::Google.Ads.GoogleAds.V3.Common.LegacyAppInstallAdInfo(); + } + LegacyAppInstallAd.MergeFrom(other.LegacyAppInstallAd); + break; + case AdDataOneofCase.ResponsiveDisplayAd: + if (ResponsiveDisplayAd == null) { + ResponsiveDisplayAd = new global::Google.Ads.GoogleAds.V3.Common.ResponsiveDisplayAdInfo(); + } + ResponsiveDisplayAd.MergeFrom(other.ResponsiveDisplayAd); + break; + case AdDataOneofCase.DisplayUploadAd: + if (DisplayUploadAd == null) { + DisplayUploadAd = new global::Google.Ads.GoogleAds.V3.Common.DisplayUploadAdInfo(); + } + DisplayUploadAd.MergeFrom(other.DisplayUploadAd); + break; + case AdDataOneofCase.AppEngagementAd: + if (AppEngagementAd == null) { + AppEngagementAd = new global::Google.Ads.GoogleAds.V3.Common.AppEngagementAdInfo(); + } + AppEngagementAd.MergeFrom(other.AppEngagementAd); + break; + case AdDataOneofCase.ShoppingComparisonListingAd: + if (ShoppingComparisonListingAd == null) { + ShoppingComparisonListingAd = new global::Google.Ads.GoogleAds.V3.Common.ShoppingComparisonListingAdInfo(); + } + ShoppingComparisonListingAd.MergeFrom(other.ShoppingComparisonListingAd); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 18: { + finalUrls_.AddEntriesFrom(input, _repeated_finalUrls_codec); + break; + } + case 34: { + string value = _single_displayUrl_codec.Read(input); + if (displayUrl_ == null || value != "") { + DisplayUrl = value; + } + break; + } + case 40: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.AdTypeEnum.Types.AdType) input.ReadEnum(); + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Common.TextAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TextAdInfo(); + if (adDataCase_ == AdDataOneofCase.TextAd) { + subBuilder.MergeFrom(TextAd); + } + input.ReadMessage(subBuilder); + TextAd = subBuilder; + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Common.ExpandedTextAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ExpandedTextAdInfo(); + if (adDataCase_ == AdDataOneofCase.ExpandedTextAd) { + subBuilder.MergeFrom(ExpandedTextAd); + } + input.ReadMessage(subBuilder); + ExpandedTextAd = subBuilder; + break; + } + case 82: { + urlCustomParameters_.AddEntriesFrom(input, _repeated_urlCustomParameters_codec); + break; + } + case 98: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 106: { + global::Google.Ads.GoogleAds.V3.Common.CallOnlyAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CallOnlyAdInfo(); + if (adDataCase_ == AdDataOneofCase.CallOnlyAd) { + subBuilder.MergeFrom(CallOnlyAd); + } + input.ReadMessage(subBuilder); + CallOnlyAd = subBuilder; + break; + } + case 114: { + global::Google.Ads.GoogleAds.V3.Common.ExpandedDynamicSearchAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ExpandedDynamicSearchAdInfo(); + if (adDataCase_ == AdDataOneofCase.ExpandedDynamicSearchAd) { + subBuilder.MergeFrom(ExpandedDynamicSearchAd); + } + input.ReadMessage(subBuilder); + ExpandedDynamicSearchAd = subBuilder; + break; + } + case 122: { + global::Google.Ads.GoogleAds.V3.Common.HotelAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelAdInfo(); + if (adDataCase_ == AdDataOneofCase.HotelAd) { + subBuilder.MergeFrom(HotelAd); + } + input.ReadMessage(subBuilder); + HotelAd = subBuilder; + break; + } + case 130: { + finalMobileUrls_.AddEntriesFrom(input, _repeated_finalMobileUrls_codec); + break; + } + case 138: { + global::Google.Ads.GoogleAds.V3.Common.ShoppingSmartAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ShoppingSmartAdInfo(); + if (adDataCase_ == AdDataOneofCase.ShoppingSmartAd) { + subBuilder.MergeFrom(ShoppingSmartAd); + } + input.ReadMessage(subBuilder); + ShoppingSmartAd = subBuilder; + break; + } + case 146: { + global::Google.Ads.GoogleAds.V3.Common.ShoppingProductAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ShoppingProductAdInfo(); + if (adDataCase_ == AdDataOneofCase.ShoppingProductAd) { + subBuilder.MergeFrom(ShoppingProductAd); + } + input.ReadMessage(subBuilder); + ShoppingProductAd = subBuilder; + break; + } + case 154: { + bool? value = _single_addedByGoogleAds_codec.Read(input); + if (addedByGoogleAds_ == null || value != false) { + AddedByGoogleAds = value; + } + break; + } + case 160: { + DevicePreference = (global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types.Device) input.ReadEnum(); + break; + } + case 170: { + global::Google.Ads.GoogleAds.V3.Common.GmailAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.GmailAdInfo(); + if (adDataCase_ == AdDataOneofCase.GmailAd) { + subBuilder.MergeFrom(GmailAd); + } + input.ReadMessage(subBuilder); + GmailAd = subBuilder; + break; + } + case 178: { + global::Google.Ads.GoogleAds.V3.Common.ImageAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ImageAdInfo(); + if (adDataCase_ == AdDataOneofCase.ImageAd) { + subBuilder.MergeFrom(ImageAd); + } + input.ReadMessage(subBuilder); + ImageAd = subBuilder; + break; + } + case 186: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 194: { + global::Google.Ads.GoogleAds.V3.Common.VideoAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.VideoAdInfo(); + if (adDataCase_ == AdDataOneofCase.VideoAd) { + subBuilder.MergeFrom(VideoAd); + } + input.ReadMessage(subBuilder); + VideoAd = subBuilder; + break; + } + case 202: { + global::Google.Ads.GoogleAds.V3.Common.ResponsiveSearchAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ResponsiveSearchAdInfo(); + if (adDataCase_ == AdDataOneofCase.ResponsiveSearchAd) { + subBuilder.MergeFrom(ResponsiveSearchAd); + } + input.ReadMessage(subBuilder); + ResponsiveSearchAd = subBuilder; + break; + } + case 210: { + urlCollections_.AddEntriesFrom(input, _repeated_urlCollections_codec); + break; + } + case 216: { + SystemManagedResourceSource = (global::Google.Ads.GoogleAds.V3.Enums.SystemManagedResourceSourceEnum.Types.SystemManagedResourceSource) input.ReadEnum(); + break; + } + case 226: { + global::Google.Ads.GoogleAds.V3.Common.LegacyResponsiveDisplayAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.LegacyResponsiveDisplayAdInfo(); + if (adDataCase_ == AdDataOneofCase.LegacyResponsiveDisplayAd) { + subBuilder.MergeFrom(LegacyResponsiveDisplayAd); + } + input.ReadMessage(subBuilder); + LegacyResponsiveDisplayAd = subBuilder; + break; + } + case 234: { + global::Google.Ads.GoogleAds.V3.Common.AppAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AppAdInfo(); + if (adDataCase_ == AdDataOneofCase.AppAd) { + subBuilder.MergeFrom(AppAd); + } + input.ReadMessage(subBuilder); + AppAd = subBuilder; + break; + } + case 242: { + global::Google.Ads.GoogleAds.V3.Common.LegacyAppInstallAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.LegacyAppInstallAdInfo(); + if (adDataCase_ == AdDataOneofCase.LegacyAppInstallAd) { + subBuilder.MergeFrom(LegacyAppInstallAd); + } + input.ReadMessage(subBuilder); + LegacyAppInstallAd = subBuilder; + break; + } + case 250: { + global::Google.Ads.GoogleAds.V3.Common.ResponsiveDisplayAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ResponsiveDisplayAdInfo(); + if (adDataCase_ == AdDataOneofCase.ResponsiveDisplayAd) { + subBuilder.MergeFrom(ResponsiveDisplayAd); + } + input.ReadMessage(subBuilder); + ResponsiveDisplayAd = subBuilder; + break; + } + case 266: { + global::Google.Ads.GoogleAds.V3.Common.DisplayUploadAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.DisplayUploadAdInfo(); + if (adDataCase_ == AdDataOneofCase.DisplayUploadAd) { + subBuilder.MergeFrom(DisplayUploadAd); + } + input.ReadMessage(subBuilder); + DisplayUploadAd = subBuilder; + break; + } + case 274: { + global::Google.Ads.GoogleAds.V3.Common.AppEngagementAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AppEngagementAdInfo(); + if (adDataCase_ == AdDataOneofCase.AppEngagementAd) { + subBuilder.MergeFrom(AppEngagementAd); + } + input.ReadMessage(subBuilder); + AppEngagementAd = subBuilder; + break; + } + case 282: { + finalAppUrls_.AddEntriesFrom(input, _repeated_finalAppUrls_codec); + break; + } + case 290: { + global::Google.Ads.GoogleAds.V3.Common.ShoppingComparisonListingAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ShoppingComparisonListingAdInfo(); + if (adDataCase_ == AdDataOneofCase.ShoppingComparisonListingAd) { + subBuilder.MergeFrom(ShoppingComparisonListingAd); + } + input.ReadMessage(subBuilder); + ShoppingComparisonListingAd = subBuilder; + break; + } + case 298: { + ResourceName = input.ReadString(); + break; + } + case 306: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdAsset.cs b/src/V3/Stubs/AdAsset.cs new file mode 100644 index 000000000..fe64ae54c --- /dev/null +++ b/src/V3/Stubs/AdAsset.cs @@ -0,0 +1,660 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/ad_asset.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/ad_asset.proto + public static partial class AdAssetReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/ad_asset.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdAssetReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vYWRfYXNzZXQucHJv", + "dG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbho7Z29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZW51bXMvc2VydmVkX2Fzc2V0X2ZpZWxkX3R5cGUu", + "cHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byKdAQoLQWRUZXh0QXNzZXQSKgoEdGV4", + "dBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJiCgxwaW5u", + "ZWRfZmllbGQYAiABKA4yTC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cy5TZXJ2ZWRBc3NldEZpZWxkVHlwZUVudW0uU2VydmVkQXNzZXRGaWVsZFR5", + "cGUiOwoMQWRJbWFnZUFzc2V0EisKBWFzc2V0GAEgASgLMhwuZ29vZ2xlLnBy", + "b3RvYnVmLlN0cmluZ1ZhbHVlIjsKDEFkVmlkZW9Bc3NldBIrCgVhc3NldBgB", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSJBChJBZE1lZGlh", + "QnVuZGxlQXNzZXQSKwoFYXNzZXQYASABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWVC5wEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5j", + "b21tb25CDEFkQXNzZXRQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5w", + "cm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uO2NvbW1v", + "bqICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkNvbW1vbsoCHkdv", + "b2dsZVxBZHNcR29vZ2xlQWRzXFYzXENvbW1vbuoCIkdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpDb21tb25iBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.ServedAssetFieldTypeReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AdTextAsset), global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser, new[]{ "Text", "PinnedField" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AdImageAsset), global::Google.Ads.GoogleAds.V3.Common.AdImageAsset.Parser, new[]{ "Asset" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AdVideoAsset), global::Google.Ads.GoogleAds.V3.Common.AdVideoAsset.Parser, new[]{ "Asset" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AdMediaBundleAsset), global::Google.Ads.GoogleAds.V3.Common.AdMediaBundleAsset.Parser, new[]{ "Asset" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A text asset used inside an ad. + /// + public sealed partial class AdTextAsset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdTextAsset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdAssetReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdTextAsset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdTextAsset(AdTextAsset other) : this() { + Text = other.Text; + pinnedField_ = other.pinnedField_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdTextAsset Clone() { + return new AdTextAsset(this); + } + + /// Field number for the "text" field. + public const int TextFieldNumber = 1; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(10); + private string text_; + /// + /// Asset text. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + /// Field number for the "pinned_field" field. + public const int PinnedFieldFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.ServedAssetFieldTypeEnum.Types.ServedAssetFieldType pinnedField_ = 0; + /// + /// The pinned field of the asset. This restricts the asset to only serve + /// within this field. Multiple assets can be pinned to the same field. An + /// asset that is unpinned or pinned to a different field will not serve in a + /// field where some other asset has been pinned. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ServedAssetFieldTypeEnum.Types.ServedAssetFieldType PinnedField { + get { return pinnedField_; } + set { + pinnedField_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdTextAsset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdTextAsset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Text != other.Text) return false; + if (PinnedField != other.PinnedField) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (text_ != null) hash ^= Text.GetHashCode(); + if (PinnedField != 0) hash ^= PinnedField.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (PinnedField != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) PinnedField); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (PinnedField != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PinnedField); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdTextAsset other) { + if (other == null) { + return; + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + if (other.PinnedField != 0) { + PinnedField = other.PinnedField; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + case 16: { + PinnedField = (global::Google.Ads.GoogleAds.V3.Enums.ServedAssetFieldTypeEnum.Types.ServedAssetFieldType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// An image asset used inside an ad. + /// + public sealed partial class AdImageAsset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdImageAsset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdAssetReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdImageAsset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdImageAsset(AdImageAsset other) : this() { + Asset = other.Asset; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdImageAsset Clone() { + return new AdImageAsset(this); + } + + /// Field number for the "asset" field. + public const int AssetFieldNumber = 1; + private static readonly pb::FieldCodec _single_asset_codec = pb::FieldCodec.ForClassWrapper(10); + private string asset_; + /// + /// The Asset resource name of this image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Asset { + get { return asset_; } + set { + asset_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdImageAsset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdImageAsset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Asset != other.Asset) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (asset_ != null) hash ^= Asset.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (asset_ != null) { + _single_asset_codec.WriteTagAndValue(output, Asset); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (asset_ != null) { + size += _single_asset_codec.CalculateSizeWithTag(Asset); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdImageAsset other) { + if (other == null) { + return; + } + if (other.asset_ != null) { + if (asset_ == null || other.Asset != "") { + Asset = other.Asset; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_asset_codec.Read(input); + if (asset_ == null || value != "") { + Asset = value; + } + break; + } + } + } + } + + } + + /// + /// A video asset used inside an ad. + /// + public sealed partial class AdVideoAsset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdVideoAsset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdAssetReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdVideoAsset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdVideoAsset(AdVideoAsset other) : this() { + Asset = other.Asset; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdVideoAsset Clone() { + return new AdVideoAsset(this); + } + + /// Field number for the "asset" field. + public const int AssetFieldNumber = 1; + private static readonly pb::FieldCodec _single_asset_codec = pb::FieldCodec.ForClassWrapper(10); + private string asset_; + /// + /// The Asset resource name of this video. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Asset { + get { return asset_; } + set { + asset_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdVideoAsset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdVideoAsset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Asset != other.Asset) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (asset_ != null) hash ^= Asset.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (asset_ != null) { + _single_asset_codec.WriteTagAndValue(output, Asset); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (asset_ != null) { + size += _single_asset_codec.CalculateSizeWithTag(Asset); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdVideoAsset other) { + if (other == null) { + return; + } + if (other.asset_ != null) { + if (asset_ == null || other.Asset != "") { + Asset = other.Asset; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_asset_codec.Read(input); + if (asset_ == null || value != "") { + Asset = value; + } + break; + } + } + } + } + + } + + /// + /// A media bundle asset used inside an ad. + /// + public sealed partial class AdMediaBundleAsset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdMediaBundleAsset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdAssetReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdMediaBundleAsset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdMediaBundleAsset(AdMediaBundleAsset other) : this() { + Asset = other.Asset; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdMediaBundleAsset Clone() { + return new AdMediaBundleAsset(this); + } + + /// Field number for the "asset" field. + public const int AssetFieldNumber = 1; + private static readonly pb::FieldCodec _single_asset_codec = pb::FieldCodec.ForClassWrapper(10); + private string asset_; + /// + /// The Asset resource name of this media bundle. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Asset { + get { return asset_; } + set { + asset_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdMediaBundleAsset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdMediaBundleAsset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Asset != other.Asset) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (asset_ != null) hash ^= Asset.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (asset_ != null) { + _single_asset_codec.WriteTagAndValue(output, Asset); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (asset_ != null) { + size += _single_asset_codec.CalculateSizeWithTag(Asset); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdMediaBundleAsset other) { + if (other == null) { + return; + } + if (other.asset_ != null) { + if (asset_ == null || other.Asset != "") { + Asset = other.Asset; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_asset_codec.Read(input); + if (asset_ == null || value != "") { + Asset = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdCustomizerError.cs b/src/V3/Stubs/AdCustomizerError.cs new file mode 100644 index 000000000..ee12452bb --- /dev/null +++ b/src/V3/Stubs/AdCustomizerError.cs @@ -0,0 +1,200 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_customizer_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_customizer_error.proto + public static partial class AdCustomizerErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_customizer_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdCustomizerErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfY3VzdG9taXpl", + "cl9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIugBChVBZEN1c3RvbWl6", + "ZXJFcnJvckVudW0izgEKEUFkQ3VzdG9taXplckVycm9yEg8KC1VOU1BFQ0lG", + "SUVEEAASCwoHVU5LTk9XThABEiEKHUNPVU5URE9XTl9JTlZBTElEX0RBVEVf", + "Rk9STUFUEAISGgoWQ09VTlRET1dOX0RBVEVfSU5fUEFTVBADEhwKGENPVU5U", + "RE9XTl9JTlZBTElEX0xPQ0FMRRAEEicKI0NPVU5URE9XTl9JTlZBTElEX1NU", + "QVJUX0RBWVNfQkVGT1JFEAUSFQoRVU5LTk9XTl9VU0VSX0xJU1QQBkLxAQoi", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IWQWRDdXN0b21p", + "emVyRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9n", + "b29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dB", + "QaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxB", + "ZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVB", + "ZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdCustomizerErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdCustomizerErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdCustomizerErrorEnum.Types.AdCustomizerError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad customizer errors. + /// + public sealed partial class AdCustomizerErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdCustomizerErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdCustomizerErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdCustomizerErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdCustomizerErrorEnum(AdCustomizerErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdCustomizerErrorEnum Clone() { + return new AdCustomizerErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdCustomizerErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdCustomizerErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdCustomizerErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdCustomizerErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad customizer errors. + /// + public enum AdCustomizerError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Invalid date argument in countdown function. + /// + [pbr::OriginalName("COUNTDOWN_INVALID_DATE_FORMAT")] CountdownInvalidDateFormat = 2, + /// + /// Countdown end date is in the past. + /// + [pbr::OriginalName("COUNTDOWN_DATE_IN_PAST")] CountdownDateInPast = 3, + /// + /// Invalid locale string in countdown function. + /// + [pbr::OriginalName("COUNTDOWN_INVALID_LOCALE")] CountdownInvalidLocale = 4, + /// + /// Days-before argument to countdown function is not positive. + /// + [pbr::OriginalName("COUNTDOWN_INVALID_START_DAYS_BEFORE")] CountdownInvalidStartDaysBefore = 5, + /// + /// A user list referenced in an IF function does not exist. + /// + [pbr::OriginalName("UNKNOWN_USER_LIST")] UnknownUserList = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdCustomizerPlaceholderField.cs b/src/V3/Stubs/AdCustomizerPlaceholderField.cs new file mode 100644 index 000000000..1782a468d --- /dev/null +++ b/src/V3/Stubs/AdCustomizerPlaceholderField.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_customizer_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_customizer_placeholder_field.proto + public static partial class AdCustomizerPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_customizer_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdCustomizerPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9jdXN0b21pemVy", + "X3BsYWNlaG9sZGVyX2ZpZWxkLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKOAQog", + "QWRDdXN0b21pemVyUGxhY2Vob2xkZXJGaWVsZEVudW0iagocQWRDdXN0b21p", + "emVyUGxhY2Vob2xkZXJGaWVsZBIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05P", + "V04QARILCgdJTlRFR0VSEAISCQoFUFJJQ0UQAxIICgREQVRFEAQSCgoGU1RS", + "SU5HEAVC9gEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0Ih", + "QWRDdXN0b21pemVyUGxhY2Vob2xkZXJGaWVsZFByb3RvUAFaQmdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdCustomizerPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.AdCustomizerPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdCustomizerPlaceholderFieldEnum.Types.AdCustomizerPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Ad Customizer placeholder fields. + /// + public sealed partial class AdCustomizerPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdCustomizerPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdCustomizerPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdCustomizerPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdCustomizerPlaceholderFieldEnum(AdCustomizerPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdCustomizerPlaceholderFieldEnum Clone() { + return new AdCustomizerPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdCustomizerPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdCustomizerPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdCustomizerPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdCustomizerPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Ad Customizers placeholder fields. + /// + public enum AdCustomizerPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: INT64. Integer value to be inserted. + /// + [pbr::OriginalName("INTEGER")] Integer = 2, + /// + /// Data Type: STRING. Price value to be inserted. + /// + [pbr::OriginalName("PRICE")] Price = 3, + /// + /// Data Type: DATE_TIME. Date value to be inserted. + /// + [pbr::OriginalName("DATE")] Date = 4, + /// + /// Data Type: STRING. String value to be inserted. + /// + [pbr::OriginalName("STRING")] String = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdError.cs b/src/V3/Stubs/AdError.cs new file mode 100644 index 000000000..b3450de4b --- /dev/null +++ b/src/V3/Stubs/AdError.cs @@ -0,0 +1,843 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_error.proto + public static partial class AdErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfZXJyb3IucHJv", + "dG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90byKLIwoLQWRFcnJvckVudW0i+yIKB0FkRXJy", + "b3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESLAooQURfQ1VTVE9N", + "SVpFUlNfTk9UX1NVUFBPUlRFRF9GT1JfQURfVFlQRRACEhoKFkFQUFJPWElN", + "QVRFTFlfVE9PX0xPTkcQAxIbChdBUFBST1hJTUFURUxZX1RPT19TSE9SVBAE", + "Eg8KC0JBRF9TTklQUEVUEAUSFAoQQ0FOTk9UX01PRElGWV9BRBAGEicKI0NB", + "Tk5PVF9TRVRfQlVTSU5FU1NfTkFNRV9JRl9VUkxfU0VUEAcSFAoQQ0FOTk9U", + "X1NFVF9GSUVMRBAIEioKJkNBTk5PVF9TRVRfRklFTERfV0lUSF9PUklHSU5f", + "QURfSURfU0VUEAkSLworQ0FOTk9UX1NFVF9GSUVMRF9XSVRIX0FEX0lEX1NF", + "VF9GT1JfU0hBUklORxAKEikKJUNBTk5PVF9TRVRfQUxMT1dfRkxFWElCTEVf", + "Q09MT1JfRkFMU0UQCxI3CjNDQU5OT1RfU0VUX0NPTE9SX0NPTlRST0xfV0hF", + "Tl9OQVRJVkVfRk9STUFUX1NFVFRJTkcQDBISCg5DQU5OT1RfU0VUX1VSTBAN", + "EiEKHUNBTk5PVF9TRVRfV0lUSE9VVF9GSU5BTF9VUkxTEA4SHgoaQ0FOTk9U", + "X1NFVF9XSVRIX0ZJTkFMX1VSTFMQDxIcChhDQU5OT1RfU0VUX1dJVEhfVVJM", + "X0RBVEEQERInCiNDQU5OT1RfVVNFX0FEX1NVQkNMQVNTX0ZPUl9PUEVSQVRP", + "UhASEiMKH0NVU1RPTUVSX05PVF9BUFBST1ZFRF9NT0JJTEVBRFMQExIoCiRD", + "VVNUT01FUl9OT1RfQVBQUk9WRURfVEhJUkRQQVJUWV9BRFMQFBIxCi1DVVNU", + "T01FUl9OT1RfQVBQUk9WRURfVEhJUkRQQVJUWV9SRURJUkVDVF9BRFMQFRIZ", + "ChVDVVNUT01FUl9OT1RfRUxJR0lCTEUQFhIxCi1DVVNUT01FUl9OT1RfRUxJ", + "R0lCTEVfRk9SX1VQREFUSU5HX0JFQUNPTl9VUkwQFxIeChpESU1FTlNJT05f", + "QUxSRUFEWV9JTl9VTklPThAYEhkKFURJTUVOU0lPTl9NVVNUX0JFX1NFVBAZ", + "EhoKFkRJTUVOU0lPTl9OT1RfSU5fVU5JT04QGhIjCh9ESVNQTEFZX1VSTF9D", + "QU5OT1RfQkVfU1BFQ0lGSUVEEBsSIAocRE9NRVNUSUNfUEhPTkVfTlVNQkVS", + "X0ZPUk1BVBAcEhoKFkVNRVJHRU5DWV9QSE9ORV9OVU1CRVIQHRIPCgtFTVBU", + "WV9GSUVMRBAeEjAKLEZFRURfQVRUUklCVVRFX01VU1RfSEFWRV9NQVBQSU5H", + "X0ZPUl9UWVBFX0lEEB8SKAokRkVFRF9BVFRSSUJVVEVfTUFQUElOR19UWVBF", + "X01JU01BVENIECASIQodSUxMRUdBTF9BRF9DVVNUT01JWkVSX1RBR19VU0UQ", + "IRITCg9JTExFR0FMX1RBR19VU0UQIhIbChdJTkNPTlNJU1RFTlRfRElNRU5T", + "SU9OUxAjEikKJUlOQ09OU0lTVEVOVF9TVEFUVVNfSU5fVEVNUExBVEVfVU5J", + "T04QJBIUChBJTkNPUlJFQ1RfTEVOR1RIECUSGgoWSU5FTElHSUJMRV9GT1Jf", + "VVBHUkFERRAmEiYKIklOVkFMSURfQURfQUREUkVTU19DQU1QQUlHTl9UQVJH", + "RVQQJxITCg9JTlZBTElEX0FEX1RZUEUQKBInCiNJTlZBTElEX0FUVFJJQlVU", + "RVNfRk9SX01PQklMRV9JTUFHRRApEiYKIklOVkFMSURfQVRUUklCVVRFU19G", + "T1JfTU9CSUxFX1RFWFQQKhIfChtJTlZBTElEX0NBTExfVE9fQUNUSU9OX1RF", + "WFQQKxIdChlJTlZBTElEX0NIQVJBQ1RFUl9GT1JfVVJMECwSGAoUSU5WQUxJ", + "RF9DT1VOVFJZX0NPREUQLRIqCiZJTlZBTElEX0VYUEFOREVEX0RZTkFNSUNf", + "U0VBUkNIX0FEX1RBRxAvEhEKDUlOVkFMSURfSU5QVVQQMBIbChdJTlZBTElE", + "X01BUktVUF9MQU5HVUFHRRAxEhoKFklOVkFMSURfTU9CSUxFX0NBUlJJRVIQ", + "MhIhCh1JTlZBTElEX01PQklMRV9DQVJSSUVSX1RBUkdFVBAzEh4KGklOVkFM", + "SURfTlVNQkVSX09GX0VMRU1FTlRTEDQSHwobSU5WQUxJRF9QSE9ORV9OVU1C", + "RVJfRk9STUFUEDUSMQotSU5WQUxJRF9SSUNIX01FRElBX0NFUlRJRklFRF9W", + "RU5ET1JfRk9STUFUX0lEEDYSGQoVSU5WQUxJRF9URU1QTEFURV9EQVRBEDcS", + "JwojSU5WQUxJRF9URU1QTEFURV9FTEVNRU5UX0ZJRUxEX1RZUEUQOBIXChNJ", + "TlZBTElEX1RFTVBMQVRFX0lEEDkSEQoNTElORV9UT09fV0lERRA6EiEKHU1J", + "U1NJTkdfQURfQ1VTVE9NSVpFUl9NQVBQSU5HEDsSHQoZTUlTU0lOR19BRERS", + "RVNTX0NPTVBPTkVOVBA8Eh4KGk1JU1NJTkdfQURWRVJUSVNFTUVOVF9OQU1F", + "ED0SGQoVTUlTU0lOR19CVVNJTkVTU19OQU1FED4SGAoUTUlTU0lOR19ERVND", + "UklQVElPTjEQPxIYChRNSVNTSU5HX0RFU0NSSVBUSU9OMhBAEh8KG01JU1NJ", + "TkdfREVTVElOQVRJT05fVVJMX1RBRxBBEiAKHE1JU1NJTkdfTEFORElOR19Q", + "QUdFX1VSTF9UQUcQQhIVChFNSVNTSU5HX0RJTUVOU0lPThBDEhcKE01JU1NJ", + "TkdfRElTUExBWV9VUkwQRBIUChBNSVNTSU5HX0hFQURMSU5FEEUSEgoOTUlT", + "U0lOR19IRUlHSFQQRhIRCg1NSVNTSU5HX0lNQUdFEEcSLQopTUlTU0lOR19N", + "QVJLRVRJTkdfSU1BR0VfT1JfUFJPRFVDVF9WSURFT1MQSBIcChhNSVNTSU5H", + "X01BUktVUF9MQU5HVUFHRVMQSRIaChZNSVNTSU5HX01PQklMRV9DQVJSSUVS", + "EEoSEQoNTUlTU0lOR19QSE9ORRBLEiQKIE1JU1NJTkdfUkVRVUlSRURfVEVN", + "UExBVEVfRklFTERTEEwSIAocTUlTU0lOR19URU1QTEFURV9GSUVMRF9WQUxV", + "RRBNEhAKDE1JU1NJTkdfVEVYVBBOEhcKE01JU1NJTkdfVklTSUJMRV9VUkwQ", + "TxIRCg1NSVNTSU5HX1dJRFRIEFASJwojTVVMVElQTEVfRElTVElOQ1RfRkVF", + "RFNfVU5TVVBQT1JURUQQURIkCiBNVVNUX1VTRV9URU1QX0FEX1VOSU9OX0lE", + "X09OX0FERBBSEgwKCFRPT19MT05HEFMSDQoJVE9PX1NIT1JUEFQSIgoeVU5J", + "T05fRElNRU5TSU9OU19DQU5OT1RfQ0hBTkdFEFUSHQoZVU5LTk9XTl9BRERS", + "RVNTX0NPTVBPTkVOVBBWEhYKElVOS05PV05fRklFTERfTkFNRRBXEhcKE1VO", + "S05PV05fVU5JUVVFX05BTUUQWBIaChZVTlNVUFBPUlRFRF9ESU1FTlNJT05T", + "EFkSFgoSVVJMX0lOVkFMSURfU0NIRU1FEFoSIAocVVJMX0lOVkFMSURfVE9Q", + "X0xFVkVMX0RPTUFJThBbEhEKDVVSTF9NQUxGT1JNRUQQXBIPCgtVUkxfTk9f", + "SE9TVBBdEhYKElVSTF9OT1RfRVFVSVZBTEVOVBBeEhoKFlVSTF9IT1NUX05B", + "TUVfVE9PX0xPTkcQXxIRCg1VUkxfTk9fU0NIRU1FEGASGwoXVVJMX05PX1RP", + "UF9MRVZFTF9ET01BSU4QYRIYChRVUkxfUEFUSF9OT1RfQUxMT1dFRBBiEhgK", + "FFVSTF9QT1JUX05PVF9BTExPV0VEEGMSGQoVVVJMX1FVRVJZX05PVF9BTExP", + "V0VEEGQSNAowVVJMX1NDSEVNRV9CRUZPUkVfRVhQQU5ERURfRFlOQU1JQ19T", + "RUFSQ0hfQURfVEFHEGYSKQolVVNFUl9ET0VTX05PVF9IQVZFX0FDQ0VTU19U", + "T19URU1QTEFURRBnEiQKIElOQ09OU0lTVEVOVF9FWFBBTkRBQkxFX1NFVFRJ", + "TkdTEGgSEgoOSU5WQUxJRF9GT1JNQVQQaRIWChJJTlZBTElEX0ZJRUxEX1RF", + "WFQQahIXChNFTEVNRU5UX05PVF9QUkVTRU5UEGsSDwoLSU1BR0VfRVJST1IQ", + "bBIWChJWQUxVRV9OT1RfSU5fUkFOR0UQbRIVChFGSUVMRF9OT1RfUFJFU0VO", + "VBBuEhgKFEFERFJFU1NfTk9UX0NPTVBMRVRFEG8SEwoPQUREUkVTU19JTlZB", + "TElEEHASGQoVVklERU9fUkVUUklFVkFMX0VSUk9SEHESDwoLQVVESU9fRVJS", + "T1IQchIfChtJTlZBTElEX1lPVVRVQkVfRElTUExBWV9VUkwQcxIbChdUT09f", + "TUFOWV9QUk9EVUNUX0lNQUdFUxB0EhsKF1RPT19NQU5ZX1BST0RVQ1RfVklE", + "RU9TEHUSLgoqSU5DT01QQVRJQkxFX0FEX1RZUEVfQU5EX0RFVklDRV9QUkVG", + "RVJFTkNFEHYSKgomQ0FMTFRSQUNLSU5HX05PVF9TVVBQT1JURURfRk9SX0NP", + "VU5UUlkQdxItCilDQVJSSUVSX1NQRUNJRklDX1NIT1JUX05VTUJFUl9OT1Rf", + "QUxMT1dFRBB4EhoKFkRJU0FMTE9XRURfTlVNQkVSX1RZUEUQeRIqCiZQSE9O", + "RV9OVU1CRVJfTk9UX1NVUFBPUlRFRF9GT1JfQ09VTlRSWRB6EjwKOFBIT05F", + "X05VTUJFUl9OT1RfU1VQUE9SVEVEX1dJVEhfQ0FMTFRSQUNLSU5HX0ZPUl9D", + "T1VOVFJZEHsSIwofUFJFTUlVTV9SQVRFX05VTUJFUl9OT1RfQUxMT1dFRBB8", + "EiMKH1ZBTklUWV9QSE9ORV9OVU1CRVJfTk9UX0FMTE9XRUQQfRIjCh9JTlZB", + "TElEX0NBTExfQ09OVkVSU0lPTl9UWVBFX0lEEH4SPQo5Q0FOTk9UX0RJU0FC", + "TEVfQ0FMTF9DT05WRVJTSU9OX0FORF9TRVRfQ09OVkVSU0lPTl9UWVBFX0lE", + "EH8SIwoeQ0FOTk9UX1NFVF9QQVRIMl9XSVRIT1VUX1BBVEgxEIABEjMKLk1J", + "U1NJTkdfRFlOQU1JQ19TRUFSQ0hfQURTX1NFVFRJTkdfRE9NQUlOX05BTUUQ", + "gQESJwoiSU5DT01QQVRJQkxFX1dJVEhfUkVTVFJJQ1RJT05fVFlQRRCCARIx", + "CixDVVNUT01FUl9DT05TRU5UX0ZPUl9DQUxMX1JFQ09SRElOR19SRVFVSVJF", + "RBCDARIiCh1NSVNTSU5HX0lNQUdFX09SX01FRElBX0JVTkRMRRCEARIwCitQ", + "Uk9EVUNUX1RZUEVfTk9UX1NVUFBPUlRFRF9JTl9USElTX0NBTVBBSUdOEIUB", + "EjAKK1BMQUNFSE9MREVSX0NBTk5PVF9IQVZFX0VNUFRZX0RFRkFVTFRfVkFM", + "VUUQhgESPQo4UExBQ0VIT0xERVJfQ09VTlRET1dOX0ZVTkNUSU9OX0NBTk5P", + "VF9IQVZFX0RFRkFVTFRfVkFMVUUQhwESJgohUExBQ0VIT0xERVJfREVGQVVM", + "VF9WQUxVRV9NSVNTSU5HEIgBEikKJFVORVhQRUNURURfUExBQ0VIT0xERVJf", + "REVGQVVMVF9WQUxVRRCJARInCiJBRF9DVVNUT01JWkVSU19NQVlfTk9UX0JF", + "X0FESkFDRU5UEIoBEiwKJ1VQREFUSU5HX0FEX1dJVEhfTk9fRU5BQkxFRF9B", + "U1NPQ0lBVElPThCLAULnAQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9yc0IMQWRFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJy", + "b3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIe", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdErrorEnum.Types.AdError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad errors. + /// + public sealed partial class AdErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdErrorEnum(AdErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdErrorEnum Clone() { + return new AdErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad errors. + /// + public enum AdError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Ad customizers are not supported for ad type. + /// + [pbr::OriginalName("AD_CUSTOMIZERS_NOT_SUPPORTED_FOR_AD_TYPE")] AdCustomizersNotSupportedForAdType = 2, + /// + /// Estimating character sizes the string is too long. + /// + [pbr::OriginalName("APPROXIMATELY_TOO_LONG")] ApproximatelyTooLong = 3, + /// + /// Estimating character sizes the string is too short. + /// + [pbr::OriginalName("APPROXIMATELY_TOO_SHORT")] ApproximatelyTooShort = 4, + /// + /// There is a problem with the snippet. + /// + [pbr::OriginalName("BAD_SNIPPET")] BadSnippet = 5, + /// + /// Cannot modify an ad. + /// + [pbr::OriginalName("CANNOT_MODIFY_AD")] CannotModifyAd = 6, + /// + /// business name and url cannot be set at the same time + /// + [pbr::OriginalName("CANNOT_SET_BUSINESS_NAME_IF_URL_SET")] CannotSetBusinessNameIfUrlSet = 7, + /// + /// The specified field is incompatible with this ad's type or settings. + /// + [pbr::OriginalName("CANNOT_SET_FIELD")] CannotSetField = 8, + /// + /// Cannot set field when originAdId is set. + /// + [pbr::OriginalName("CANNOT_SET_FIELD_WITH_ORIGIN_AD_ID_SET")] CannotSetFieldWithOriginAdIdSet = 9, + /// + /// Cannot set field when an existing ad id is set for sharing. + /// + [pbr::OriginalName("CANNOT_SET_FIELD_WITH_AD_ID_SET_FOR_SHARING")] CannotSetFieldWithAdIdSetForSharing = 10, + /// + /// Cannot set allowFlexibleColor false if no color is provided by user. + /// + [pbr::OriginalName("CANNOT_SET_ALLOW_FLEXIBLE_COLOR_FALSE")] CannotSetAllowFlexibleColorFalse = 11, + /// + /// When user select native, no color control is allowed because we will + /// always respect publisher color for native format serving. + /// + [pbr::OriginalName("CANNOT_SET_COLOR_CONTROL_WHEN_NATIVE_FORMAT_SETTING")] CannotSetColorControlWhenNativeFormatSetting = 12, + /// + /// Cannot specify a url for the ad type + /// + [pbr::OriginalName("CANNOT_SET_URL")] CannotSetUrl = 13, + /// + /// Cannot specify a tracking or mobile url without also setting final urls + /// + [pbr::OriginalName("CANNOT_SET_WITHOUT_FINAL_URLS")] CannotSetWithoutFinalUrls = 14, + /// + /// Cannot specify a legacy url and a final url simultaneously + /// + [pbr::OriginalName("CANNOT_SET_WITH_FINAL_URLS")] CannotSetWithFinalUrls = 15, + /// + /// Cannot specify a urls in UrlData and in template fields simultaneously. + /// + [pbr::OriginalName("CANNOT_SET_WITH_URL_DATA")] CannotSetWithUrlData = 17, + /// + /// This operator cannot be used with a subclass of Ad. + /// + [pbr::OriginalName("CANNOT_USE_AD_SUBCLASS_FOR_OPERATOR")] CannotUseAdSubclassForOperator = 18, + /// + /// Customer is not approved for mobile ads. + /// + [pbr::OriginalName("CUSTOMER_NOT_APPROVED_MOBILEADS")] CustomerNotApprovedMobileads = 19, + /// + /// Customer is not approved for 3PAS richmedia ads. + /// + [pbr::OriginalName("CUSTOMER_NOT_APPROVED_THIRDPARTY_ADS")] CustomerNotApprovedThirdpartyAds = 20, + /// + /// Customer is not approved for 3PAS redirect richmedia (Ad Exchange) ads. + /// + [pbr::OriginalName("CUSTOMER_NOT_APPROVED_THIRDPARTY_REDIRECT_ADS")] CustomerNotApprovedThirdpartyRedirectAds = 21, + /// + /// Not an eligible customer + /// + [pbr::OriginalName("CUSTOMER_NOT_ELIGIBLE")] CustomerNotEligible = 22, + /// + /// Customer is not eligible for updating beacon url + /// + [pbr::OriginalName("CUSTOMER_NOT_ELIGIBLE_FOR_UPDATING_BEACON_URL")] CustomerNotEligibleForUpdatingBeaconUrl = 23, + /// + /// There already exists an ad with the same dimensions in the union. + /// + [pbr::OriginalName("DIMENSION_ALREADY_IN_UNION")] DimensionAlreadyInUnion = 24, + /// + /// Ad's dimension must be set before setting union dimension. + /// + [pbr::OriginalName("DIMENSION_MUST_BE_SET")] DimensionMustBeSet = 25, + /// + /// Ad's dimension must be included in the union dimensions. + /// + [pbr::OriginalName("DIMENSION_NOT_IN_UNION")] DimensionNotInUnion = 26, + /// + /// Display Url cannot be specified (applies to Ad Exchange Ads) + /// + [pbr::OriginalName("DISPLAY_URL_CANNOT_BE_SPECIFIED")] DisplayUrlCannotBeSpecified = 27, + /// + /// Telephone number contains invalid characters or invalid format. Please + /// re-enter your number using digits (0-9), dashes (-), and parentheses + /// only. + /// + [pbr::OriginalName("DOMESTIC_PHONE_NUMBER_FORMAT")] DomesticPhoneNumberFormat = 28, + /// + /// Emergency telephone numbers are not allowed. Please enter a valid + /// domestic phone number to connect customers to your business. + /// + [pbr::OriginalName("EMERGENCY_PHONE_NUMBER")] EmergencyPhoneNumber = 29, + /// + /// A required field was not specified or is an empty string. + /// + [pbr::OriginalName("EMPTY_FIELD")] EmptyField = 30, + /// + /// A feed attribute referenced in an ad customizer tag is not in the ad + /// customizer mapping for the feed. + /// + [pbr::OriginalName("FEED_ATTRIBUTE_MUST_HAVE_MAPPING_FOR_TYPE_ID")] FeedAttributeMustHaveMappingForTypeId = 31, + /// + /// The ad customizer field mapping for the feed attribute does not match the + /// expected field type. + /// + [pbr::OriginalName("FEED_ATTRIBUTE_MAPPING_TYPE_MISMATCH")] FeedAttributeMappingTypeMismatch = 32, + /// + /// The use of ad customizer tags in the ad text is disallowed. Details in + /// trigger. + /// + [pbr::OriginalName("ILLEGAL_AD_CUSTOMIZER_TAG_USE")] IllegalAdCustomizerTagUse = 33, + /// + /// Tags of the form {PH_x}, where x is a number, are disallowed in ad text. + /// + [pbr::OriginalName("ILLEGAL_TAG_USE")] IllegalTagUse = 34, + /// + /// The dimensions of the ad are specified or derived in multiple ways and + /// are not consistent. + /// + [pbr::OriginalName("INCONSISTENT_DIMENSIONS")] InconsistentDimensions = 35, + /// + /// The status cannot differ among template ads of the same union. + /// + [pbr::OriginalName("INCONSISTENT_STATUS_IN_TEMPLATE_UNION")] InconsistentStatusInTemplateUnion = 36, + /// + /// The length of the string is not valid. + /// + [pbr::OriginalName("INCORRECT_LENGTH")] IncorrectLength = 37, + /// + /// The ad is ineligible for upgrade. + /// + [pbr::OriginalName("INELIGIBLE_FOR_UPGRADE")] IneligibleForUpgrade = 38, + /// + /// User cannot create mobile ad for countries targeted in specified + /// campaign. + /// + [pbr::OriginalName("INVALID_AD_ADDRESS_CAMPAIGN_TARGET")] InvalidAdAddressCampaignTarget = 39, + /// + /// Invalid Ad type. A specific type of Ad is required. + /// + [pbr::OriginalName("INVALID_AD_TYPE")] InvalidAdType = 40, + /// + /// Headline, description or phone cannot be present when creating mobile + /// image ad. + /// + [pbr::OriginalName("INVALID_ATTRIBUTES_FOR_MOBILE_IMAGE")] InvalidAttributesForMobileImage = 41, + /// + /// Image cannot be present when creating mobile text ad. + /// + [pbr::OriginalName("INVALID_ATTRIBUTES_FOR_MOBILE_TEXT")] InvalidAttributesForMobileText = 42, + /// + /// Invalid call to action text. + /// + [pbr::OriginalName("INVALID_CALL_TO_ACTION_TEXT")] InvalidCallToActionText = 43, + /// + /// Invalid character in URL. + /// + [pbr::OriginalName("INVALID_CHARACTER_FOR_URL")] InvalidCharacterForUrl = 44, + /// + /// Creative's country code is not valid. + /// + [pbr::OriginalName("INVALID_COUNTRY_CODE")] InvalidCountryCode = 45, + /// + /// Invalid use of Expanded Dynamic Search Ads tags ({lpurl} etc.) + /// + [pbr::OriginalName("INVALID_EXPANDED_DYNAMIC_SEARCH_AD_TAG")] InvalidExpandedDynamicSearchAdTag = 47, + /// + /// An input error whose real reason was not properly mapped (should not + /// happen). + /// + [pbr::OriginalName("INVALID_INPUT")] InvalidInput = 48, + /// + /// An invalid markup language was entered. + /// + [pbr::OriginalName("INVALID_MARKUP_LANGUAGE")] InvalidMarkupLanguage = 49, + /// + /// An invalid mobile carrier was entered. + /// + [pbr::OriginalName("INVALID_MOBILE_CARRIER")] InvalidMobileCarrier = 50, + /// + /// Specified mobile carriers target a country not targeted by the campaign. + /// + [pbr::OriginalName("INVALID_MOBILE_CARRIER_TARGET")] InvalidMobileCarrierTarget = 51, + /// + /// Wrong number of elements for given element type + /// + [pbr::OriginalName("INVALID_NUMBER_OF_ELEMENTS")] InvalidNumberOfElements = 52, + /// + /// The format of the telephone number is incorrect. Please re-enter the + /// number using the correct format. + /// + [pbr::OriginalName("INVALID_PHONE_NUMBER_FORMAT")] InvalidPhoneNumberFormat = 53, + /// + /// The certified vendor format id is incorrect. + /// + [pbr::OriginalName("INVALID_RICH_MEDIA_CERTIFIED_VENDOR_FORMAT_ID")] InvalidRichMediaCertifiedVendorFormatId = 54, + /// + /// The template ad data contains validation errors. + /// + [pbr::OriginalName("INVALID_TEMPLATE_DATA")] InvalidTemplateData = 55, + /// + /// The template field doesn't have have the correct type. + /// + [pbr::OriginalName("INVALID_TEMPLATE_ELEMENT_FIELD_TYPE")] InvalidTemplateElementFieldType = 56, + /// + /// Invalid template id. + /// + [pbr::OriginalName("INVALID_TEMPLATE_ID")] InvalidTemplateId = 57, + /// + /// After substituting replacement strings, the line is too wide. + /// + [pbr::OriginalName("LINE_TOO_WIDE")] LineTooWide = 58, + /// + /// The feed referenced must have ad customizer mapping to be used in a + /// customizer tag. + /// + [pbr::OriginalName("MISSING_AD_CUSTOMIZER_MAPPING")] MissingAdCustomizerMapping = 59, + /// + /// Missing address component in template element address field. + /// + [pbr::OriginalName("MISSING_ADDRESS_COMPONENT")] MissingAddressComponent = 60, + /// + /// An ad name must be entered. + /// + [pbr::OriginalName("MISSING_ADVERTISEMENT_NAME")] MissingAdvertisementName = 61, + /// + /// Business name must be entered. + /// + [pbr::OriginalName("MISSING_BUSINESS_NAME")] MissingBusinessName = 62, + /// + /// Description (line 2) must be entered. + /// + [pbr::OriginalName("MISSING_DESCRIPTION1")] MissingDescription1 = 63, + /// + /// Description (line 3) must be entered. + /// + [pbr::OriginalName("MISSING_DESCRIPTION2")] MissingDescription2 = 64, + /// + /// The destination url must contain at least one tag (e.g. {lpurl}) + /// + [pbr::OriginalName("MISSING_DESTINATION_URL_TAG")] MissingDestinationUrlTag = 65, + /// + /// The tracking url template of ExpandedDynamicSearchAd must contain at + /// least one tag. (e.g. {lpurl}) + /// + [pbr::OriginalName("MISSING_LANDING_PAGE_URL_TAG")] MissingLandingPageUrlTag = 66, + /// + /// A valid dimension must be specified for this ad. + /// + [pbr::OriginalName("MISSING_DIMENSION")] MissingDimension = 67, + /// + /// A display URL must be entered. + /// + [pbr::OriginalName("MISSING_DISPLAY_URL")] MissingDisplayUrl = 68, + /// + /// Headline must be entered. + /// + [pbr::OriginalName("MISSING_HEADLINE")] MissingHeadline = 69, + /// + /// A height must be entered. + /// + [pbr::OriginalName("MISSING_HEIGHT")] MissingHeight = 70, + /// + /// An image must be entered. + /// + [pbr::OriginalName("MISSING_IMAGE")] MissingImage = 71, + /// + /// Marketing image or product videos are required. + /// + [pbr::OriginalName("MISSING_MARKETING_IMAGE_OR_PRODUCT_VIDEOS")] MissingMarketingImageOrProductVideos = 72, + /// + /// The markup language in which your site is written must be entered. + /// + [pbr::OriginalName("MISSING_MARKUP_LANGUAGES")] MissingMarkupLanguages = 73, + /// + /// A mobile carrier must be entered. + /// + [pbr::OriginalName("MISSING_MOBILE_CARRIER")] MissingMobileCarrier = 74, + /// + /// Phone number must be entered. + /// + [pbr::OriginalName("MISSING_PHONE")] MissingPhone = 75, + /// + /// Missing required template fields + /// + [pbr::OriginalName("MISSING_REQUIRED_TEMPLATE_FIELDS")] MissingRequiredTemplateFields = 76, + /// + /// Missing a required field value + /// + [pbr::OriginalName("MISSING_TEMPLATE_FIELD_VALUE")] MissingTemplateFieldValue = 77, + /// + /// The ad must have text. + /// + [pbr::OriginalName("MISSING_TEXT")] MissingText = 78, + /// + /// A visible URL must be entered. + /// + [pbr::OriginalName("MISSING_VISIBLE_URL")] MissingVisibleUrl = 79, + /// + /// A width must be entered. + /// + [pbr::OriginalName("MISSING_WIDTH")] MissingWidth = 80, + /// + /// Only 1 feed can be used as the source of ad customizer substitutions in a + /// single ad. + /// + [pbr::OriginalName("MULTIPLE_DISTINCT_FEEDS_UNSUPPORTED")] MultipleDistinctFeedsUnsupported = 81, + /// + /// TempAdUnionId must be use when adding template ads. + /// + [pbr::OriginalName("MUST_USE_TEMP_AD_UNION_ID_ON_ADD")] MustUseTempAdUnionIdOnAdd = 82, + /// + /// The string has too many characters. + /// + [pbr::OriginalName("TOO_LONG")] TooLong = 83, + /// + /// The string has too few characters. + /// + [pbr::OriginalName("TOO_SHORT")] TooShort = 84, + /// + /// Ad union dimensions cannot change for saved ads. + /// + [pbr::OriginalName("UNION_DIMENSIONS_CANNOT_CHANGE")] UnionDimensionsCannotChange = 85, + /// + /// Address component is not {country, lat, lng}. + /// + [pbr::OriginalName("UNKNOWN_ADDRESS_COMPONENT")] UnknownAddressComponent = 86, + /// + /// Unknown unique field name + /// + [pbr::OriginalName("UNKNOWN_FIELD_NAME")] UnknownFieldName = 87, + /// + /// Unknown unique name (template element type specifier) + /// + [pbr::OriginalName("UNKNOWN_UNIQUE_NAME")] UnknownUniqueName = 88, + /// + /// Unsupported ad dimension + /// + [pbr::OriginalName("UNSUPPORTED_DIMENSIONS")] UnsupportedDimensions = 89, + /// + /// URL starts with an invalid scheme. + /// + [pbr::OriginalName("URL_INVALID_SCHEME")] UrlInvalidScheme = 90, + /// + /// URL ends with an invalid top-level domain name. + /// + [pbr::OriginalName("URL_INVALID_TOP_LEVEL_DOMAIN")] UrlInvalidTopLevelDomain = 91, + /// + /// URL contains illegal characters. + /// + [pbr::OriginalName("URL_MALFORMED")] UrlMalformed = 92, + /// + /// URL must contain a host name. + /// + [pbr::OriginalName("URL_NO_HOST")] UrlNoHost = 93, + /// + /// URL not equivalent during upgrade. + /// + [pbr::OriginalName("URL_NOT_EQUIVALENT")] UrlNotEquivalent = 94, + /// + /// URL host name too long to be stored as visible URL (applies to Ad + /// Exchange ads) + /// + [pbr::OriginalName("URL_HOST_NAME_TOO_LONG")] UrlHostNameTooLong = 95, + /// + /// URL must start with a scheme. + /// + [pbr::OriginalName("URL_NO_SCHEME")] UrlNoScheme = 96, + /// + /// URL should end in a valid domain extension, such as .com or .net. + /// + [pbr::OriginalName("URL_NO_TOP_LEVEL_DOMAIN")] UrlNoTopLevelDomain = 97, + /// + /// URL must not end with a path. + /// + [pbr::OriginalName("URL_PATH_NOT_ALLOWED")] UrlPathNotAllowed = 98, + /// + /// URL must not specify a port. + /// + [pbr::OriginalName("URL_PORT_NOT_ALLOWED")] UrlPortNotAllowed = 99, + /// + /// URL must not contain a query. + /// + [pbr::OriginalName("URL_QUERY_NOT_ALLOWED")] UrlQueryNotAllowed = 100, + /// + /// A url scheme is not allowed in front of tag in tracking url template + /// (e.g. http://{lpurl}) + /// + [pbr::OriginalName("URL_SCHEME_BEFORE_EXPANDED_DYNAMIC_SEARCH_AD_TAG")] UrlSchemeBeforeExpandedDynamicSearchAdTag = 102, + /// + /// The user does not have permissions to create a template ad for the given + /// template. + /// + [pbr::OriginalName("USER_DOES_NOT_HAVE_ACCESS_TO_TEMPLATE")] UserDoesNotHaveAccessToTemplate = 103, + /// + /// Expandable setting is inconsistent/wrong. For example, an AdX ad is + /// invalid if it has a expandable vendor format but no expanding directions + /// specified, or expanding directions is specified, but the vendor format is + /// not expandable. + /// + [pbr::OriginalName("INCONSISTENT_EXPANDABLE_SETTINGS")] InconsistentExpandableSettings = 104, + /// + /// Format is invalid + /// + [pbr::OriginalName("INVALID_FORMAT")] InvalidFormat = 105, + /// + /// The text of this field did not match a pattern of allowed values. + /// + [pbr::OriginalName("INVALID_FIELD_TEXT")] InvalidFieldText = 106, + /// + /// Template element is mising + /// + [pbr::OriginalName("ELEMENT_NOT_PRESENT")] ElementNotPresent = 107, + /// + /// Error occurred during image processing + /// + [pbr::OriginalName("IMAGE_ERROR")] ImageError = 108, + /// + /// The value is not within the valid range + /// + [pbr::OriginalName("VALUE_NOT_IN_RANGE")] ValueNotInRange = 109, + /// + /// Template element field is not present + /// + [pbr::OriginalName("FIELD_NOT_PRESENT")] FieldNotPresent = 110, + /// + /// Address is incomplete + /// + [pbr::OriginalName("ADDRESS_NOT_COMPLETE")] AddressNotComplete = 111, + /// + /// Invalid address + /// + [pbr::OriginalName("ADDRESS_INVALID")] AddressInvalid = 112, + /// + /// Error retrieving specified video + /// + [pbr::OriginalName("VIDEO_RETRIEVAL_ERROR")] VideoRetrievalError = 113, + /// + /// Error processing audio + /// + [pbr::OriginalName("AUDIO_ERROR")] AudioError = 114, + /// + /// Display URL is incorrect for YouTube PYV ads + /// + [pbr::OriginalName("INVALID_YOUTUBE_DISPLAY_URL")] InvalidYoutubeDisplayUrl = 115, + /// + /// Too many product Images in GmailAd + /// + [pbr::OriginalName("TOO_MANY_PRODUCT_IMAGES")] TooManyProductImages = 116, + /// + /// Too many product Videos in GmailAd + /// + [pbr::OriginalName("TOO_MANY_PRODUCT_VIDEOS")] TooManyProductVideos = 117, + /// + /// The device preference is not compatible with the ad type + /// + [pbr::OriginalName("INCOMPATIBLE_AD_TYPE_AND_DEVICE_PREFERENCE")] IncompatibleAdTypeAndDevicePreference = 118, + /// + /// Call tracking is not supported for specified country. + /// + [pbr::OriginalName("CALLTRACKING_NOT_SUPPORTED_FOR_COUNTRY")] CalltrackingNotSupportedForCountry = 119, + /// + /// Carrier specific short number is not allowed. + /// + [pbr::OriginalName("CARRIER_SPECIFIC_SHORT_NUMBER_NOT_ALLOWED")] CarrierSpecificShortNumberNotAllowed = 120, + /// + /// Specified phone number type is disallowed. + /// + [pbr::OriginalName("DISALLOWED_NUMBER_TYPE")] DisallowedNumberType = 121, + /// + /// Phone number not supported for country. + /// + [pbr::OriginalName("PHONE_NUMBER_NOT_SUPPORTED_FOR_COUNTRY")] PhoneNumberNotSupportedForCountry = 122, + /// + /// Phone number not supported with call tracking enabled for country. + /// + [pbr::OriginalName("PHONE_NUMBER_NOT_SUPPORTED_WITH_CALLTRACKING_FOR_COUNTRY")] PhoneNumberNotSupportedWithCalltrackingForCountry = 123, + /// + /// Premium rate phone number is not allowed. + /// + [pbr::OriginalName("PREMIUM_RATE_NUMBER_NOT_ALLOWED")] PremiumRateNumberNotAllowed = 124, + /// + /// Vanity phone number is not allowed. + /// + [pbr::OriginalName("VANITY_PHONE_NUMBER_NOT_ALLOWED")] VanityPhoneNumberNotAllowed = 125, + /// + /// Invalid call conversion type id. + /// + [pbr::OriginalName("INVALID_CALL_CONVERSION_TYPE_ID")] InvalidCallConversionTypeId = 126, + /// + /// Cannot disable call conversion and set conversion type id. + /// + [pbr::OriginalName("CANNOT_DISABLE_CALL_CONVERSION_AND_SET_CONVERSION_TYPE_ID")] CannotDisableCallConversionAndSetConversionTypeId = 127, + /// + /// Cannot set path2 without path1. + /// + [pbr::OriginalName("CANNOT_SET_PATH2_WITHOUT_PATH1")] CannotSetPath2WithoutPath1 = 128, + /// + /// Missing domain name in campaign setting when adding expanded dynamic + /// search ad. + /// + [pbr::OriginalName("MISSING_DYNAMIC_SEARCH_ADS_SETTING_DOMAIN_NAME")] MissingDynamicSearchAdsSettingDomainName = 129, + /// + /// The associated ad is not compatible with restriction type. + /// + [pbr::OriginalName("INCOMPATIBLE_WITH_RESTRICTION_TYPE")] IncompatibleWithRestrictionType = 130, + /// + /// Consent for call recording is required for creating/updating call only + /// ads. Please see https://support.google.com/google-ads/answer/7412639. + /// + [pbr::OriginalName("CUSTOMER_CONSENT_FOR_CALL_RECORDING_REQUIRED")] CustomerConsentForCallRecordingRequired = 131, + /// + /// Either an image or a media bundle is required in a display upload ad. + /// + [pbr::OriginalName("MISSING_IMAGE_OR_MEDIA_BUNDLE")] MissingImageOrMediaBundle = 132, + /// + /// The display upload product type is not supported in this campaign. + /// + [pbr::OriginalName("PRODUCT_TYPE_NOT_SUPPORTED_IN_THIS_CAMPAIGN")] ProductTypeNotSupportedInThisCampaign = 133, + /// + /// The default value of an ad placeholder can not be the empty string. + /// + [pbr::OriginalName("PLACEHOLDER_CANNOT_HAVE_EMPTY_DEFAULT_VALUE")] PlaceholderCannotHaveEmptyDefaultValue = 134, + /// + /// Ad placeholders with countdown functions must not have a default value. + /// + [pbr::OriginalName("PLACEHOLDER_COUNTDOWN_FUNCTION_CANNOT_HAVE_DEFAULT_VALUE")] PlaceholderCountdownFunctionCannotHaveDefaultValue = 135, + /// + /// A previous ad placeholder that had a default value was found which means + /// that all (non-countdown) placeholders must have a default value. This + /// ad placeholder does not have a default value. + /// + [pbr::OriginalName("PLACEHOLDER_DEFAULT_VALUE_MISSING")] PlaceholderDefaultValueMissing = 136, + /// + /// A previous ad placeholder that did not have a default value was found + /// which means that no placeholders may have a default value. This + /// ad placeholder does have a default value. + /// + [pbr::OriginalName("UNEXPECTED_PLACEHOLDER_DEFAULT_VALUE")] UnexpectedPlaceholderDefaultValue = 137, + /// + /// Two ad customizers may not be directly adjacent in an ad text. They must + /// be separated by at least one character. + /// + [pbr::OriginalName("AD_CUSTOMIZERS_MAY_NOT_BE_ADJACENT")] AdCustomizersMayNotBeAdjacent = 138, + /// + /// The ad is not associated with any enabled AdGroupAd, and cannot be + /// updated. + /// + [pbr::OriginalName("UPDATING_AD_WITH_NO_ENABLED_ASSOCIATION")] UpdatingAdWithNoEnabledAssociation = 139, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroup.cs b/src/V3/Stubs/AdGroup.cs new file mode 100644 index 000000000..2c9ef3792 --- /dev/null +++ b/src/V3/Stubs/AdGroup.cs @@ -0,0 +1,1133 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group.proto + public static partial class AdGroupReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXAu", + "cHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcxo1Z29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL2N1c3RvbV9wYXJhbWV0ZXIu", + "cHJvdG8aRGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9leHBsb3Jl", + "cl9hdXRvX29wdGltaXplcl9zZXR0aW5nLnByb3RvGjZnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9jb21tb24vdGFyZ2V0aW5nX3NldHRpbmcucHJvdG8aPWdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2FkX2dyb3VwX2FkX3JvdGF0", + "aW9uX21vZGUucHJvdG8aM2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1z", + "L2FkX2dyb3VwX3N0YXR1cy5wcm90bxoxZ29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZW51bXMvYWRfZ3JvdXBfdHlwZS5wcm90bxoyZ29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvZW51bXMvYmlkZGluZ19zb3VyY2UucHJvdG8aN2dvb2dsZS9h", + "ZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3RhcmdldGluZ19kaW1lbnNpb24ucHJv", + "dG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9h", + "cGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5w", + "cm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLgDwoHQWRHcm91", + "cBI/Cg1yZXNvdXJjZV9uYW1lGAEgASgJQijgQQX6QSIKIGdvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbS9BZEdyb3VwEiwKAmlkGAMgASgLMhsuZ29vZ2xlLnBy", + "b3RvYnVmLkludDY0VmFsdWVCA+BBAxIqCgRuYW1lGAQgASgLMhwuZ29vZ2xl", + "LnByb3RvYnVmLlN0cmluZ1ZhbHVlEk4KBnN0YXR1cxgFIAEoDjI+Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkFkR3JvdXBTdGF0dXNFbnVtLkFk", + "R3JvdXBTdGF0dXMSTQoEdHlwZRgMIAEoDjI6Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zLkFkR3JvdXBUeXBlRW51bS5BZEdyb3VwVHlwZUID4EEF", + "EmgKEGFkX3JvdGF0aW9uX21vZGUYFiABKA4yTi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lbnVtcy5BZEdyb3VwQWRSb3RhdGlvbk1vZGVFbnVtLkFkR3Jv", + "dXBBZFJvdGF0aW9uTW9kZRJdCg1iYXNlX2FkX2dyb3VwGBIgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQijgQQP6QSIKIGdvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbS9BZEdyb3VwEjsKFXRyYWNraW5nX3VybF90ZW1wbGF0", + "ZRgNIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJOChV1cmxf", + "Y3VzdG9tX3BhcmFtZXRlcnMYBiADKAsyLy5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5jb21tb24uQ3VzdG9tUGFyYW1ldGVyElkKCGNhbXBhaWduGAogASgL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQingQQX6QSMKIWdvb2ds", + "ZWFkcy5nb29nbGVhcGlzLmNvbS9DYW1wYWlnbhIzCg5jcGNfYmlkX21pY3Jv", + "cxgOIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlEjMKDmNwbV9i", + "aWRfbWljcm9zGA8gASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUS", + "NgoRdGFyZ2V0X2NwYV9taWNyb3MYGyABKAsyGy5nb29nbGUucHJvdG9idWYu", + "SW50NjRWYWx1ZRI4Cg5jcHZfYmlkX21pY3JvcxgRIAEoCzIbLmdvb2dsZS5w", + "cm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSNgoRdGFyZ2V0X2NwbV9taWNyb3MY", + "GiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZRIxCgt0YXJnZXRf", + "cm9hcxgeIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5Eb3VibGVWYWx1ZRI7ChZw", + "ZXJjZW50X2NwY19iaWRfbWljcm9zGBQgASgLMhsuZ29vZ2xlLnByb3RvYnVm", + "LkludDY0VmFsdWUSZQofZXhwbG9yZXJfYXV0b19vcHRpbWl6ZXJfc2V0dGlu", + "ZxgVIAEoCzI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5FeHBs", + "b3JlckF1dG9PcHRpbWl6ZXJTZXR0aW5nEm4KHGRpc3BsYXlfY3VzdG9tX2Jp", + "ZF9kaW1lbnNpb24YFyABKA4ySC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcy5UYXJnZXRpbmdEaW1lbnNpb25FbnVtLlRhcmdldGluZ0RpbWVuc2lv", + "bhI2ChBmaW5hbF91cmxfc3VmZml4GBggASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlEksKEXRhcmdldGluZ19zZXR0aW5nGBkgASgLMjAuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLlRhcmdldGluZ1NldHRpbmcS", + "RQobZWZmZWN0aXZlX3RhcmdldF9jcGFfbWljcm9zGBwgASgLMhsuZ29vZ2xl", + "LnByb3RvYnVmLkludDY0VmFsdWVCA+BBAxJoChtlZmZlY3RpdmVfdGFyZ2V0", + "X2NwYV9zb3VyY2UYHSABKA4yPi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcy5CaWRkaW5nU291cmNlRW51bS5CaWRkaW5nU291cmNlQgPgQQMSQAoV", + "ZWZmZWN0aXZlX3RhcmdldF9yb2FzGB8gASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LkRvdWJsZVZhbHVlQgPgQQMSaQocZWZmZWN0aXZlX3RhcmdldF9yb2FzX3Nv", + "dXJjZRggIAEoDjI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkJp", + "ZGRpbmdTb3VyY2VFbnVtLkJpZGRpbmdTb3VyY2VCA+BBAxJbCgZsYWJlbHMY", + "ISADKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCLeBBA/pBJwol", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0FkR3JvdXBMYWJlbDpP6kFMCiBn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91cBIoY3VzdG9tZXJzL3tj", + "dXN0b21lcn0vYWRHcm91cHMve2FkX2dyb3VwfUL5AQolY29tLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IMQWRHcm91cFByb3RvUAFaSmdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFk", + "cy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVB", + "ZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6", + "OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CustomParameterReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.ExplorerAutoOptimizerSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.TargetingSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdGroupStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdGroupTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.TargetingDimensionReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroup), global::Google.Ads.GoogleAds.V3.Resources.AdGroup.Parser, new[]{ "ResourceName", "Id", "Name", "Status", "Type", "AdRotationMode", "BaseAdGroup", "TrackingUrlTemplate", "UrlCustomParameters", "Campaign", "CpcBidMicros", "CpmBidMicros", "TargetCpaMicros", "CpvBidMicros", "TargetCpmMicros", "TargetRoas", "PercentCpcBidMicros", "ExplorerAutoOptimizerSetting", "DisplayCustomBidDimension", "FinalUrlSuffix", "TargetingSetting", "EffectiveTargetCpaMicros", "EffectiveTargetCpaSource", "EffectiveTargetRoas", "EffectiveTargetRoasSource", "Labels" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad group. + /// + public sealed partial class AdGroup : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroup()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroup() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroup(AdGroup other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + status_ = other.status_; + type_ = other.type_; + adRotationMode_ = other.adRotationMode_; + BaseAdGroup = other.BaseAdGroup; + TrackingUrlTemplate = other.TrackingUrlTemplate; + urlCustomParameters_ = other.urlCustomParameters_.Clone(); + Campaign = other.Campaign; + CpcBidMicros = other.CpcBidMicros; + CpmBidMicros = other.CpmBidMicros; + TargetCpaMicros = other.TargetCpaMicros; + CpvBidMicros = other.CpvBidMicros; + TargetCpmMicros = other.TargetCpmMicros; + TargetRoas = other.TargetRoas; + PercentCpcBidMicros = other.PercentCpcBidMicros; + explorerAutoOptimizerSetting_ = other.explorerAutoOptimizerSetting_ != null ? other.explorerAutoOptimizerSetting_.Clone() : null; + displayCustomBidDimension_ = other.displayCustomBidDimension_; + FinalUrlSuffix = other.FinalUrlSuffix; + targetingSetting_ = other.targetingSetting_ != null ? other.targetingSetting_.Clone() : null; + EffectiveTargetCpaMicros = other.EffectiveTargetCpaMicros; + effectiveTargetCpaSource_ = other.effectiveTargetCpaSource_; + EffectiveTargetRoas = other.EffectiveTargetRoas; + effectiveTargetRoasSource_ = other.effectiveTargetRoasSource_; + labels_ = other.labels_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroup Clone() { + return new AdGroup(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group. + /// Ad group resource names have the form: + /// + /// `customers/{customer_id}/adGroups/{ad_group_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// The name of the ad group. + /// + /// This field is required and should not be empty when creating new ad + /// groups. + /// + /// It must contain fewer than 255 UTF-8 full-width characters. + /// + /// It must not contain any null (code point 0x0), NL line feed + /// (code point 0xA) or carriage return (code point 0xD) characters. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types.AdGroupStatus status_ = 0; + /// + /// The status of the ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types.AdGroupStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 12; + private global::Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Types.AdGroupType type_ = 0; + /// + /// Immutable. The type of the ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Types.AdGroupType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "ad_rotation_mode" field. + public const int AdRotationModeFieldNumber = 22; + private global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode adRotationMode_ = 0; + /// + /// The ad rotation mode of the ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode AdRotationMode { + get { return adRotationMode_; } + set { + adRotationMode_ = value; + } + } + + /// Field number for the "base_ad_group" field. + public const int BaseAdGroupFieldNumber = 18; + private static readonly pb::FieldCodec _single_baseAdGroup_codec = pb::FieldCodec.ForClassWrapper(146); + private string baseAdGroup_; + /// + /// Output only. For draft or experiment ad groups, this field is the resource name of the + /// base ad group from which this ad group was created. If a draft or + /// experiment ad group does not have a base ad group, then this field is null. + /// + /// For base ad groups, this field equals the ad group resource name. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BaseAdGroup { + get { return baseAdGroup_; } + set { + baseAdGroup_ = value; + } + } + + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 13; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(106); + private string trackingUrlTemplate_; + /// + /// The URL template for constructing a tracking URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "url_custom_parameters" field. + public const int UrlCustomParametersFieldNumber = 6; + private static readonly pb::FieldCodec _repeated_urlCustomParameters_codec + = pb::FieldCodec.ForMessage(50, global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser); + private readonly pbc::RepeatedField urlCustomParameters_ = new pbc::RepeatedField(); + /// + /// The list of mappings used to substitute custom parameter tags in a + /// `tracking_url_template`, `final_urls`, or `mobile_final_urls`. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCustomParameters { + get { return urlCustomParameters_; } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 10; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(82); + private string campaign_; + /// + /// Immutable. The campaign to which the ad group belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "cpc_bid_micros" field. + public const int CpcBidMicrosFieldNumber = 14; + private static readonly pb::FieldCodec _single_cpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(114); + private long? cpcBidMicros_; + /// + /// The maximum CPC (cost-per-click) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidMicros { + get { return cpcBidMicros_; } + set { + cpcBidMicros_ = value; + } + } + + + /// Field number for the "cpm_bid_micros" field. + public const int CpmBidMicrosFieldNumber = 15; + private static readonly pb::FieldCodec _single_cpmBidMicros_codec = pb::FieldCodec.ForStructWrapper(122); + private long? cpmBidMicros_; + /// + /// The maximum CPM (cost-per-thousand viewable impressions) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpmBidMicros { + get { return cpmBidMicros_; } + set { + cpmBidMicros_ = value; + } + } + + + /// Field number for the "target_cpa_micros" field. + public const int TargetCpaMicrosFieldNumber = 27; + private static readonly pb::FieldCodec _single_targetCpaMicros_codec = pb::FieldCodec.ForStructWrapper(218); + private long? targetCpaMicros_; + /// + /// The target CPA (cost-per-acquisition). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TargetCpaMicros { + get { return targetCpaMicros_; } + set { + targetCpaMicros_ = value; + } + } + + + /// Field number for the "cpv_bid_micros" field. + public const int CpvBidMicrosFieldNumber = 17; + private static readonly pb::FieldCodec _single_cpvBidMicros_codec = pb::FieldCodec.ForStructWrapper(138); + private long? cpvBidMicros_; + /// + /// Output only. The CPV (cost-per-view) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpvBidMicros { + get { return cpvBidMicros_; } + set { + cpvBidMicros_ = value; + } + } + + + /// Field number for the "target_cpm_micros" field. + public const int TargetCpmMicrosFieldNumber = 26; + private static readonly pb::FieldCodec _single_targetCpmMicros_codec = pb::FieldCodec.ForStructWrapper(210); + private long? targetCpmMicros_; + /// + /// Average amount in micros that the advertiser is willing to pay for every + /// thousand times the ad is shown. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TargetCpmMicros { + get { return targetCpmMicros_; } + set { + targetCpmMicros_ = value; + } + } + + + /// Field number for the "target_roas" field. + public const int TargetRoasFieldNumber = 30; + private static readonly pb::FieldCodec _single_targetRoas_codec = pb::FieldCodec.ForStructWrapper(242); + private double? targetRoas_; + /// + /// The target ROAS (return-on-ad-spend) override. If the ad group's campaign + /// bidding strategy is a standard Target ROAS strategy, then this field + /// overrides the target ROAS specified in the campaign's bidding strategy. + /// Otherwise, this value is ignored. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? TargetRoas { + get { return targetRoas_; } + set { + targetRoas_ = value; + } + } + + + /// Field number for the "percent_cpc_bid_micros" field. + public const int PercentCpcBidMicrosFieldNumber = 20; + private static readonly pb::FieldCodec _single_percentCpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(162); + private long? percentCpcBidMicros_; + /// + /// The percent cpc bid amount, expressed as a fraction of the advertised price + /// for some good or service. The valid range for the fraction is [0,1) and the + /// value stored here is 1,000,000 * [fraction]. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PercentCpcBidMicros { + get { return percentCpcBidMicros_; } + set { + percentCpcBidMicros_ = value; + } + } + + + /// Field number for the "explorer_auto_optimizer_setting" field. + public const int ExplorerAutoOptimizerSettingFieldNumber = 21; + private global::Google.Ads.GoogleAds.V3.Common.ExplorerAutoOptimizerSetting explorerAutoOptimizerSetting_; + /// + /// Settings for the Display Campaign Optimizer, initially termed "Explorer". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ExplorerAutoOptimizerSetting ExplorerAutoOptimizerSetting { + get { return explorerAutoOptimizerSetting_; } + set { + explorerAutoOptimizerSetting_ = value; + } + } + + /// Field number for the "display_custom_bid_dimension" field. + public const int DisplayCustomBidDimensionFieldNumber = 23; + private global::Google.Ads.GoogleAds.V3.Enums.TargetingDimensionEnum.Types.TargetingDimension displayCustomBidDimension_ = 0; + /// + /// Allows advertisers to specify a targeting dimension on which to place + /// absolute bids. This is only applicable for campaigns that target only the + /// display network and not search. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TargetingDimensionEnum.Types.TargetingDimension DisplayCustomBidDimension { + get { return displayCustomBidDimension_; } + set { + displayCustomBidDimension_ = value; + } + } + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 24; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(194); + private string finalUrlSuffix_; + /// + /// URL template for appending params to Final URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + /// Field number for the "targeting_setting" field. + public const int TargetingSettingFieldNumber = 25; + private global::Google.Ads.GoogleAds.V3.Common.TargetingSetting targetingSetting_; + /// + /// Setting for targeting related features. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetingSetting TargetingSetting { + get { return targetingSetting_; } + set { + targetingSetting_ = value; + } + } + + /// Field number for the "effective_target_cpa_micros" field. + public const int EffectiveTargetCpaMicrosFieldNumber = 28; + private static readonly pb::FieldCodec _single_effectiveTargetCpaMicros_codec = pb::FieldCodec.ForStructWrapper(226); + private long? effectiveTargetCpaMicros_; + /// + /// Output only. The effective target CPA (cost-per-acquisition). + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? EffectiveTargetCpaMicros { + get { return effectiveTargetCpaMicros_; } + set { + effectiveTargetCpaMicros_ = value; + } + } + + + /// Field number for the "effective_target_cpa_source" field. + public const int EffectiveTargetCpaSourceFieldNumber = 29; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource effectiveTargetCpaSource_ = 0; + /// + /// Output only. Source of the effective target CPA. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource EffectiveTargetCpaSource { + get { return effectiveTargetCpaSource_; } + set { + effectiveTargetCpaSource_ = value; + } + } + + /// Field number for the "effective_target_roas" field. + public const int EffectiveTargetRoasFieldNumber = 31; + private static readonly pb::FieldCodec _single_effectiveTargetRoas_codec = pb::FieldCodec.ForStructWrapper(250); + private double? effectiveTargetRoas_; + /// + /// Output only. The effective target ROAS (return-on-ad-spend). + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? EffectiveTargetRoas { + get { return effectiveTargetRoas_; } + set { + effectiveTargetRoas_ = value; + } + } + + + /// Field number for the "effective_target_roas_source" field. + public const int EffectiveTargetRoasSourceFieldNumber = 32; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource effectiveTargetRoasSource_ = 0; + /// + /// Output only. Source of the effective target ROAS. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource EffectiveTargetRoasSource { + get { return effectiveTargetRoasSource_; } + set { + effectiveTargetRoasSource_ = value; + } + } + + /// Field number for the "labels" field. + public const int LabelsFieldNumber = 33; + private static readonly pb::FieldCodec _repeated_labels_codec + = pb::FieldCodec.ForClassWrapper(266); + private readonly pbc::RepeatedField labels_ = new pbc::RepeatedField(); + /// + /// Output only. The resource names of labels attached to this ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Labels { + get { return labels_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroup); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroup other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (Status != other.Status) return false; + if (Type != other.Type) return false; + if (AdRotationMode != other.AdRotationMode) return false; + if (BaseAdGroup != other.BaseAdGroup) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if(!urlCustomParameters_.Equals(other.urlCustomParameters_)) return false; + if (Campaign != other.Campaign) return false; + if (CpcBidMicros != other.CpcBidMicros) return false; + if (CpmBidMicros != other.CpmBidMicros) return false; + if (TargetCpaMicros != other.TargetCpaMicros) return false; + if (CpvBidMicros != other.CpvBidMicros) return false; + if (TargetCpmMicros != other.TargetCpmMicros) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(TargetRoas, other.TargetRoas)) return false; + if (PercentCpcBidMicros != other.PercentCpcBidMicros) return false; + if (!object.Equals(ExplorerAutoOptimizerSetting, other.ExplorerAutoOptimizerSetting)) return false; + if (DisplayCustomBidDimension != other.DisplayCustomBidDimension) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + if (!object.Equals(TargetingSetting, other.TargetingSetting)) return false; + if (EffectiveTargetCpaMicros != other.EffectiveTargetCpaMicros) return false; + if (EffectiveTargetCpaSource != other.EffectiveTargetCpaSource) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(EffectiveTargetRoas, other.EffectiveTargetRoas)) return false; + if (EffectiveTargetRoasSource != other.EffectiveTargetRoasSource) return false; + if(!labels_.Equals(other.labels_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (AdRotationMode != 0) hash ^= AdRotationMode.GetHashCode(); + if (baseAdGroup_ != null) hash ^= BaseAdGroup.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + hash ^= urlCustomParameters_.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + if (cpcBidMicros_ != null) hash ^= CpcBidMicros.GetHashCode(); + if (cpmBidMicros_ != null) hash ^= CpmBidMicros.GetHashCode(); + if (targetCpaMicros_ != null) hash ^= TargetCpaMicros.GetHashCode(); + if (cpvBidMicros_ != null) hash ^= CpvBidMicros.GetHashCode(); + if (targetCpmMicros_ != null) hash ^= TargetCpmMicros.GetHashCode(); + if (targetRoas_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(TargetRoas); + if (percentCpcBidMicros_ != null) hash ^= PercentCpcBidMicros.GetHashCode(); + if (explorerAutoOptimizerSetting_ != null) hash ^= ExplorerAutoOptimizerSetting.GetHashCode(); + if (DisplayCustomBidDimension != 0) hash ^= DisplayCustomBidDimension.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + if (targetingSetting_ != null) hash ^= TargetingSetting.GetHashCode(); + if (effectiveTargetCpaMicros_ != null) hash ^= EffectiveTargetCpaMicros.GetHashCode(); + if (EffectiveTargetCpaSource != 0) hash ^= EffectiveTargetCpaSource.GetHashCode(); + if (effectiveTargetRoas_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(EffectiveTargetRoas); + if (EffectiveTargetRoasSource != 0) hash ^= EffectiveTargetRoasSource.GetHashCode(); + hash ^= labels_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (Status != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Status); + } + urlCustomParameters_.WriteTo(output, _repeated_urlCustomParameters_codec); + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + if (Type != 0) { + output.WriteRawTag(96); + output.WriteEnum((int) Type); + } + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + if (cpcBidMicros_ != null) { + _single_cpcBidMicros_codec.WriteTagAndValue(output, CpcBidMicros); + } + if (cpmBidMicros_ != null) { + _single_cpmBidMicros_codec.WriteTagAndValue(output, CpmBidMicros); + } + if (cpvBidMicros_ != null) { + _single_cpvBidMicros_codec.WriteTagAndValue(output, CpvBidMicros); + } + if (baseAdGroup_ != null) { + _single_baseAdGroup_codec.WriteTagAndValue(output, BaseAdGroup); + } + if (percentCpcBidMicros_ != null) { + _single_percentCpcBidMicros_codec.WriteTagAndValue(output, PercentCpcBidMicros); + } + if (explorerAutoOptimizerSetting_ != null) { + output.WriteRawTag(170, 1); + output.WriteMessage(ExplorerAutoOptimizerSetting); + } + if (AdRotationMode != 0) { + output.WriteRawTag(176, 1); + output.WriteEnum((int) AdRotationMode); + } + if (DisplayCustomBidDimension != 0) { + output.WriteRawTag(184, 1); + output.WriteEnum((int) DisplayCustomBidDimension); + } + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + if (targetingSetting_ != null) { + output.WriteRawTag(202, 1); + output.WriteMessage(TargetingSetting); + } + if (targetCpmMicros_ != null) { + _single_targetCpmMicros_codec.WriteTagAndValue(output, TargetCpmMicros); + } + if (targetCpaMicros_ != null) { + _single_targetCpaMicros_codec.WriteTagAndValue(output, TargetCpaMicros); + } + if (effectiveTargetCpaMicros_ != null) { + _single_effectiveTargetCpaMicros_codec.WriteTagAndValue(output, EffectiveTargetCpaMicros); + } + if (EffectiveTargetCpaSource != 0) { + output.WriteRawTag(232, 1); + output.WriteEnum((int) EffectiveTargetCpaSource); + } + if (targetRoas_ != null) { + _single_targetRoas_codec.WriteTagAndValue(output, TargetRoas); + } + if (effectiveTargetRoas_ != null) { + _single_effectiveTargetRoas_codec.WriteTagAndValue(output, EffectiveTargetRoas); + } + if (EffectiveTargetRoasSource != 0) { + output.WriteRawTag(128, 2); + output.WriteEnum((int) EffectiveTargetRoasSource); + } + labels_.WriteTo(output, _repeated_labels_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (AdRotationMode != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdRotationMode); + } + if (baseAdGroup_ != null) { + size += _single_baseAdGroup_codec.CalculateSizeWithTag(BaseAdGroup); + } + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + size += urlCustomParameters_.CalculateSize(_repeated_urlCustomParameters_codec); + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + if (cpcBidMicros_ != null) { + size += _single_cpcBidMicros_codec.CalculateSizeWithTag(CpcBidMicros); + } + if (cpmBidMicros_ != null) { + size += _single_cpmBidMicros_codec.CalculateSizeWithTag(CpmBidMicros); + } + if (targetCpaMicros_ != null) { + size += _single_targetCpaMicros_codec.CalculateSizeWithTag(TargetCpaMicros); + } + if (cpvBidMicros_ != null) { + size += _single_cpvBidMicros_codec.CalculateSizeWithTag(CpvBidMicros); + } + if (targetCpmMicros_ != null) { + size += _single_targetCpmMicros_codec.CalculateSizeWithTag(TargetCpmMicros); + } + if (targetRoas_ != null) { + size += _single_targetRoas_codec.CalculateSizeWithTag(TargetRoas); + } + if (percentCpcBidMicros_ != null) { + size += _single_percentCpcBidMicros_codec.CalculateSizeWithTag(PercentCpcBidMicros); + } + if (explorerAutoOptimizerSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ExplorerAutoOptimizerSetting); + } + if (DisplayCustomBidDimension != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) DisplayCustomBidDimension); + } + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + if (targetingSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetingSetting); + } + if (effectiveTargetCpaMicros_ != null) { + size += _single_effectiveTargetCpaMicros_codec.CalculateSizeWithTag(EffectiveTargetCpaMicros); + } + if (EffectiveTargetCpaSource != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EffectiveTargetCpaSource); + } + if (effectiveTargetRoas_ != null) { + size += _single_effectiveTargetRoas_codec.CalculateSizeWithTag(EffectiveTargetRoas); + } + if (EffectiveTargetRoasSource != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EffectiveTargetRoasSource); + } + size += labels_.CalculateSize(_repeated_labels_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroup other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.AdRotationMode != 0) { + AdRotationMode = other.AdRotationMode; + } + if (other.baseAdGroup_ != null) { + if (baseAdGroup_ == null || other.BaseAdGroup != "") { + BaseAdGroup = other.BaseAdGroup; + } + } + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + urlCustomParameters_.Add(other.urlCustomParameters_); + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + if (other.cpcBidMicros_ != null) { + if (cpcBidMicros_ == null || other.CpcBidMicros != 0L) { + CpcBidMicros = other.CpcBidMicros; + } + } + if (other.cpmBidMicros_ != null) { + if (cpmBidMicros_ == null || other.CpmBidMicros != 0L) { + CpmBidMicros = other.CpmBidMicros; + } + } + if (other.targetCpaMicros_ != null) { + if (targetCpaMicros_ == null || other.TargetCpaMicros != 0L) { + TargetCpaMicros = other.TargetCpaMicros; + } + } + if (other.cpvBidMicros_ != null) { + if (cpvBidMicros_ == null || other.CpvBidMicros != 0L) { + CpvBidMicros = other.CpvBidMicros; + } + } + if (other.targetCpmMicros_ != null) { + if (targetCpmMicros_ == null || other.TargetCpmMicros != 0L) { + TargetCpmMicros = other.TargetCpmMicros; + } + } + if (other.targetRoas_ != null) { + if (targetRoas_ == null || other.TargetRoas != 0D) { + TargetRoas = other.TargetRoas; + } + } + if (other.percentCpcBidMicros_ != null) { + if (percentCpcBidMicros_ == null || other.PercentCpcBidMicros != 0L) { + PercentCpcBidMicros = other.PercentCpcBidMicros; + } + } + if (other.explorerAutoOptimizerSetting_ != null) { + if (explorerAutoOptimizerSetting_ == null) { + ExplorerAutoOptimizerSetting = new global::Google.Ads.GoogleAds.V3.Common.ExplorerAutoOptimizerSetting(); + } + ExplorerAutoOptimizerSetting.MergeFrom(other.ExplorerAutoOptimizerSetting); + } + if (other.DisplayCustomBidDimension != 0) { + DisplayCustomBidDimension = other.DisplayCustomBidDimension; + } + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + if (other.targetingSetting_ != null) { + if (targetingSetting_ == null) { + TargetingSetting = new global::Google.Ads.GoogleAds.V3.Common.TargetingSetting(); + } + TargetingSetting.MergeFrom(other.TargetingSetting); + } + if (other.effectiveTargetCpaMicros_ != null) { + if (effectiveTargetCpaMicros_ == null || other.EffectiveTargetCpaMicros != 0L) { + EffectiveTargetCpaMicros = other.EffectiveTargetCpaMicros; + } + } + if (other.EffectiveTargetCpaSource != 0) { + EffectiveTargetCpaSource = other.EffectiveTargetCpaSource; + } + if (other.effectiveTargetRoas_ != null) { + if (effectiveTargetRoas_ == null || other.EffectiveTargetRoas != 0D) { + EffectiveTargetRoas = other.EffectiveTargetRoas; + } + } + if (other.EffectiveTargetRoasSource != 0) { + EffectiveTargetRoasSource = other.EffectiveTargetRoasSource; + } + labels_.Add(other.labels_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 40: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types.AdGroupStatus) input.ReadEnum(); + break; + } + case 50: { + urlCustomParameters_.AddEntriesFrom(input, _repeated_urlCustomParameters_codec); + break; + } + case 82: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 96: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Types.AdGroupType) input.ReadEnum(); + break; + } + case 106: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 114: { + long? value = _single_cpcBidMicros_codec.Read(input); + if (cpcBidMicros_ == null || value != 0L) { + CpcBidMicros = value; + } + break; + } + case 122: { + long? value = _single_cpmBidMicros_codec.Read(input); + if (cpmBidMicros_ == null || value != 0L) { + CpmBidMicros = value; + } + break; + } + case 138: { + long? value = _single_cpvBidMicros_codec.Read(input); + if (cpvBidMicros_ == null || value != 0L) { + CpvBidMicros = value; + } + break; + } + case 146: { + string value = _single_baseAdGroup_codec.Read(input); + if (baseAdGroup_ == null || value != "") { + BaseAdGroup = value; + } + break; + } + case 162: { + long? value = _single_percentCpcBidMicros_codec.Read(input); + if (percentCpcBidMicros_ == null || value != 0L) { + PercentCpcBidMicros = value; + } + break; + } + case 170: { + if (explorerAutoOptimizerSetting_ == null) { + ExplorerAutoOptimizerSetting = new global::Google.Ads.GoogleAds.V3.Common.ExplorerAutoOptimizerSetting(); + } + input.ReadMessage(ExplorerAutoOptimizerSetting); + break; + } + case 176: { + AdRotationMode = (global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode) input.ReadEnum(); + break; + } + case 184: { + DisplayCustomBidDimension = (global::Google.Ads.GoogleAds.V3.Enums.TargetingDimensionEnum.Types.TargetingDimension) input.ReadEnum(); + break; + } + case 194: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + case 202: { + if (targetingSetting_ == null) { + TargetingSetting = new global::Google.Ads.GoogleAds.V3.Common.TargetingSetting(); + } + input.ReadMessage(TargetingSetting); + break; + } + case 210: { + long? value = _single_targetCpmMicros_codec.Read(input); + if (targetCpmMicros_ == null || value != 0L) { + TargetCpmMicros = value; + } + break; + } + case 218: { + long? value = _single_targetCpaMicros_codec.Read(input); + if (targetCpaMicros_ == null || value != 0L) { + TargetCpaMicros = value; + } + break; + } + case 226: { + long? value = _single_effectiveTargetCpaMicros_codec.Read(input); + if (effectiveTargetCpaMicros_ == null || value != 0L) { + EffectiveTargetCpaMicros = value; + } + break; + } + case 232: { + EffectiveTargetCpaSource = (global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource) input.ReadEnum(); + break; + } + case 242: { + double? value = _single_targetRoas_codec.Read(input); + if (targetRoas_ == null || value != 0D) { + TargetRoas = value; + } + break; + } + case 250: { + double? value = _single_effectiveTargetRoas_codec.Read(input); + if (effectiveTargetRoas_ == null || value != 0D) { + EffectiveTargetRoas = value; + } + break; + } + case 256: { + EffectiveTargetRoasSource = (global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource) input.ReadEnum(); + break; + } + case 266: { + labels_.AddEntriesFrom(input, _repeated_labels_codec); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAd.cs b/src/V3/Stubs/AdGroupAd.cs new file mode 100644 index 000000000..147fb2734 --- /dev/null +++ b/src/V3/Stubs/AdGroupAd.cs @@ -0,0 +1,581 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_ad.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_ad.proto + public static partial class AdGroupAdReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_ad.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "YWQucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcxor", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL3BvbGljeS5wcm90bxo2", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvYWRfZ3JvdXBfYWRfc3Rh", + "dHVzLnByb3RvGi9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9z", + "dHJlbmd0aC5wcm90bxo6Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMv", + "cG9saWN5X2FwcHJvdmFsX3N0YXR1cy5wcm90bxo4Z29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvZW51bXMvcG9saWN5X3Jldmlld19zdGF0dXMucHJvdG8aKmdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9hZC5wcm90bxofZ29v", + "Z2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNv", + "dXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIrgECglBZEdyb3VwQWQSQQoN", + "cmVzb3VyY2VfbmFtZRgBIAEoCUIq4EEF+kEkCiJnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vQWRHcm91cEFkElIKBnN0YXR1cxgDIAEoDjJCLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkFkR3JvdXBBZFN0YXR1c0VudW0uQWRH", + "cm91cEFkU3RhdHVzElgKCGFkX2dyb3VwGAQgASgLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlQijgQQX6QSIKIGdvb2dsZWFkcy5nb29nbGVhcGlz", + "LmNvbS9BZEdyb3VwEjYKAmFkGAUgASgLMiUuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMucmVzb3VyY2VzLkFkQgPgQQUSVgoOcG9saWN5X3N1bW1hcnkYBiAB", + "KAsyOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91", + "cEFkUG9saWN5U3VtbWFyeUID4EEDElIKC2FkX3N0cmVuZ3RoGAcgASgOMjgu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQWRTdHJlbmd0aEVudW0u", + "QWRTdHJlbmd0aEID4EEDOlbqQVMKImdvb2dsZWFkcy5nb29nbGVhcGlzLmNv", + "bS9BZEdyb3VwQWQSLWN1c3RvbWVycy97Y3VzdG9tZXJ9L2FkR3JvdXBBZHMv", + "e2FkX2dyb3VwX2FkfSK/AgoWQWRHcm91cEFkUG9saWN5U3VtbWFyeRJTChRw", + "b2xpY3lfdG9waWNfZW50cmllcxgBIAMoCzIwLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmNvbW1vbi5Qb2xpY3lUb3BpY0VudHJ5QgPgQQMSZAoNcmV2aWV3", + "X3N0YXR1cxgCIAEoDjJILmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "LlBvbGljeVJldmlld1N0YXR1c0VudW0uUG9saWN5UmV2aWV3U3RhdHVzQgPg", + "QQMSagoPYXBwcm92YWxfc3RhdHVzGAMgASgOMkwuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXMuUG9saWN5QXBwcm92YWxTdGF0dXNFbnVtLlBvbGlj", + "eUFwcHJvdmFsU3RhdHVzQgPgQQNC+wEKJWNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5yZXNvdXJjZXNCDkFkR3JvdXBBZFByb3RvUAFaSmdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29n", + "bGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "UmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291", + "cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.PolicyReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdStrengthReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd.Parser, new[]{ "ResourceName", "Status", "AdGroup", "Ad", "PolicySummary", "AdStrength" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdPolicySummary), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdPolicySummary.Parser, new[]{ "PolicyTopicEntries", "ReviewStatus", "ApprovalStatus" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad group ad. + /// + public sealed partial class AdGroupAd : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAd()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAd() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAd(AdGroupAd other) : this() { + resourceName_ = other.resourceName_; + status_ = other.status_; + AdGroup = other.AdGroup; + ad_ = other.ad_ != null ? other.ad_.Clone() : null; + policySummary_ = other.policySummary_ != null ? other.policySummary_.Clone() : null; + adStrength_ = other.adStrength_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAd Clone() { + return new AdGroupAd(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad. + /// Ad group ad resource names have the form: + /// + /// `customers/{customer_id}/adGroupAds/{ad_group_id}~{ad_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types.AdGroupAdStatus status_ = 0; + /// + /// The status of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types.AdGroupAdStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 4; + private static readonly pb::FieldCodec _single_adGroup_codec = pb::FieldCodec.ForClassWrapper(34); + private string adGroup_; + /// + /// Immutable. The ad group to which the ad belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroup { + get { return adGroup_; } + set { + adGroup_ = value; + } + } + + + /// Field number for the "ad" field. + public const int AdFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Resources.Ad ad_; + /// + /// Immutable. The ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Ad Ad { + get { return ad_; } + set { + ad_ = value; + } + } + + /// Field number for the "policy_summary" field. + public const int PolicySummaryFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdPolicySummary policySummary_; + /// + /// Output only. Policy information for the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdPolicySummary PolicySummary { + get { return policySummary_; } + set { + policySummary_ = value; + } + } + + /// Field number for the "ad_strength" field. + public const int AdStrengthFieldNumber = 7; + private global::Google.Ads.GoogleAds.V3.Enums.AdStrengthEnum.Types.AdStrength adStrength_ = 0; + /// + /// Output only. Overall ad strength for this ad group ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdStrengthEnum.Types.AdStrength AdStrength { + get { return adStrength_; } + set { + adStrength_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAd); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAd other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Status != other.Status) return false; + if (AdGroup != other.AdGroup) return false; + if (!object.Equals(Ad, other.Ad)) return false; + if (!object.Equals(PolicySummary, other.PolicySummary)) return false; + if (AdStrength != other.AdStrength) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (adGroup_ != null) hash ^= AdGroup.GetHashCode(); + if (ad_ != null) hash ^= Ad.GetHashCode(); + if (policySummary_ != null) hash ^= PolicySummary.GetHashCode(); + if (AdStrength != 0) hash ^= AdStrength.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (Status != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Status); + } + if (adGroup_ != null) { + _single_adGroup_codec.WriteTagAndValue(output, AdGroup); + } + if (ad_ != null) { + output.WriteRawTag(42); + output.WriteMessage(Ad); + } + if (policySummary_ != null) { + output.WriteRawTag(50); + output.WriteMessage(PolicySummary); + } + if (AdStrength != 0) { + output.WriteRawTag(56); + output.WriteEnum((int) AdStrength); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (adGroup_ != null) { + size += _single_adGroup_codec.CalculateSizeWithTag(AdGroup); + } + if (ad_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Ad); + } + if (policySummary_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PolicySummary); + } + if (AdStrength != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdStrength); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAd other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.adGroup_ != null) { + if (adGroup_ == null || other.AdGroup != "") { + AdGroup = other.AdGroup; + } + } + if (other.ad_ != null) { + if (ad_ == null) { + Ad = new global::Google.Ads.GoogleAds.V3.Resources.Ad(); + } + Ad.MergeFrom(other.Ad); + } + if (other.policySummary_ != null) { + if (policySummary_ == null) { + PolicySummary = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdPolicySummary(); + } + PolicySummary.MergeFrom(other.PolicySummary); + } + if (other.AdStrength != 0) { + AdStrength = other.AdStrength; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 24: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types.AdGroupAdStatus) input.ReadEnum(); + break; + } + case 34: { + string value = _single_adGroup_codec.Read(input); + if (adGroup_ == null || value != "") { + AdGroup = value; + } + break; + } + case 42: { + if (ad_ == null) { + Ad = new global::Google.Ads.GoogleAds.V3.Resources.Ad(); + } + input.ReadMessage(Ad); + break; + } + case 50: { + if (policySummary_ == null) { + PolicySummary = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdPolicySummary(); + } + input.ReadMessage(PolicySummary); + break; + } + case 56: { + AdStrength = (global::Google.Ads.GoogleAds.V3.Enums.AdStrengthEnum.Types.AdStrength) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Contains policy information for an ad. + /// + public sealed partial class AdGroupAdPolicySummary : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdPolicySummary()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdPolicySummary() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdPolicySummary(AdGroupAdPolicySummary other) : this() { + policyTopicEntries_ = other.policyTopicEntries_.Clone(); + reviewStatus_ = other.reviewStatus_; + approvalStatus_ = other.approvalStatus_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdPolicySummary Clone() { + return new AdGroupAdPolicySummary(this); + } + + /// Field number for the "policy_topic_entries" field. + public const int PolicyTopicEntriesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_policyTopicEntries_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Common.PolicyTopicEntry.Parser); + private readonly pbc::RepeatedField policyTopicEntries_ = new pbc::RepeatedField(); + /// + /// Output only. The list of policy findings for this ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PolicyTopicEntries { + get { return policyTopicEntries_; } + } + + /// Field number for the "review_status" field. + public const int ReviewStatusFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus reviewStatus_ = 0; + /// + /// Output only. Where in the review process this ad is. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus ReviewStatus { + get { return reviewStatus_; } + set { + reviewStatus_ = value; + } + } + + /// Field number for the "approval_status" field. + public const int ApprovalStatusFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus approvalStatus_ = 0; + /// + /// Output only. The overall approval status of this ad, calculated based on the status of + /// its individual policy topic entries. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus ApprovalStatus { + get { return approvalStatus_; } + set { + approvalStatus_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdPolicySummary); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdPolicySummary other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!policyTopicEntries_.Equals(other.policyTopicEntries_)) return false; + if (ReviewStatus != other.ReviewStatus) return false; + if (ApprovalStatus != other.ApprovalStatus) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= policyTopicEntries_.GetHashCode(); + if (ReviewStatus != 0) hash ^= ReviewStatus.GetHashCode(); + if (ApprovalStatus != 0) hash ^= ApprovalStatus.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + policyTopicEntries_.WriteTo(output, _repeated_policyTopicEntries_codec); + if (ReviewStatus != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) ReviewStatus); + } + if (ApprovalStatus != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) ApprovalStatus); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += policyTopicEntries_.CalculateSize(_repeated_policyTopicEntries_codec); + if (ReviewStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ReviewStatus); + } + if (ApprovalStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ApprovalStatus); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdPolicySummary other) { + if (other == null) { + return; + } + policyTopicEntries_.Add(other.policyTopicEntries_); + if (other.ReviewStatus != 0) { + ReviewStatus = other.ReviewStatus; + } + if (other.ApprovalStatus != 0) { + ApprovalStatus = other.ApprovalStatus; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + policyTopicEntries_.AddEntriesFrom(input, _repeated_policyTopicEntries_codec); + break; + } + case 16: { + ReviewStatus = (global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus) input.ReadEnum(); + break; + } + case 24: { + ApprovalStatus = (global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAdAssetView.cs b/src/V3/Stubs/AdGroupAdAssetView.cs new file mode 100644 index 000000000..dbc33cd92 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdAssetView.cs @@ -0,0 +1,583 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_ad_asset_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_ad_asset_view.proto + public static partial class AdGroupAdAssetViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_ad_asset_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdAssetViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "YWRfYXNzZXRfdmlldy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzGitnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vcG9s", + "aWN5LnByb3RvGjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hc3Nl", + "dF9maWVsZF90eXBlLnByb3RvGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9l", + "bnVtcy9hc3NldF9wZXJmb3JtYW5jZV9sYWJlbC5wcm90bxo6Z29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZW51bXMvcG9saWN5X2FwcHJvdmFsX3N0YXR1cy5w", + "cm90bxo4Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvcG9saWN5X3Jl", + "dmlld19zdGF0dXMucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3Iu", + "cHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90", + "b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5w", + "cm90byKtBQoSQWRHcm91cEFkQXNzZXRWaWV3EkoKDXJlc291cmNlX25hbWUY", + "ASABKAlCM+BBBfpBLQorZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0FkR3Jv", + "dXBBZEFzc2V0VmlldxJdCgthZF9ncm91cF9hZBgFIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZUIq4EED+kEkCiJnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vQWRHcm91cEFkElMKBWFzc2V0GAYgASgLMhwuZ29vZ2xlLnBy", + "b3RvYnVmLlN0cmluZ1ZhbHVlQibgQQP6QSAKHmdvb2dsZWFkcy5nb29nbGVh", + "cGlzLmNvbS9Bc3NldBJZCgpmaWVsZF90eXBlGAIgASgOMkAuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMuQXNzZXRGaWVsZFR5cGVFbnVtLkFzc2V0", + "RmllbGRUeXBlQgPgQQMSWwoOcG9saWN5X3N1bW1hcnkYAyABKAsyPi5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cEFkQXNzZXRQ", + "b2xpY3lTdW1tYXJ5QgPgQQMSbgoRcGVyZm9ybWFuY2VfbGFiZWwYBCABKA4y", + "Ti5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5Bc3NldFBlcmZvcm1h", + "bmNlTGFiZWxFbnVtLkFzc2V0UGVyZm9ybWFuY2VMYWJlbEID4EEDOm/qQWwK", + "K2dvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZEdyb3VwQWRBc3NldFZpZXcS", + "PWN1c3RvbWVycy97Y3VzdG9tZXJ9L2FkR3JvdXBBZEFzc2V0cy97YWRfZ3Jv", + "dXBfYWRfYXNzZXRfdmlld30ixAIKG0FkR3JvdXBBZEFzc2V0UG9saWN5U3Vt", + "bWFyeRJTChRwb2xpY3lfdG9waWNfZW50cmllcxgBIAMoCzIwLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Qb2xpY3lUb3BpY0VudHJ5QgPgQQMS", + "ZAoNcmV2aWV3X3N0YXR1cxgCIAEoDjJILmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zLlBvbGljeVJldmlld1N0YXR1c0VudW0uUG9saWN5UmV2aWV3", + "U3RhdHVzQgPgQQMSagoPYXBwcm92YWxfc3RhdHVzGAMgASgOMkwuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXMuUG9saWN5QXBwcm92YWxTdGF0dXNF", + "bnVtLlBvbGljeUFwcHJvdmFsU3RhdHVzQgPgQQNChAIKJWNvbS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNCF0FkR3JvdXBBZEFzc2V0Vmll", + "d1Byb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFw", + "aXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FB", + "qgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xl", + "XEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdv", + "b2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.PolicyReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AssetFieldTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AssetPerformanceLabelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView.Parser, new[]{ "ResourceName", "AdGroupAd", "Asset", "FieldType", "PolicySummary", "PerformanceLabel" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetPolicySummary), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetPolicySummary.Parser, new[]{ "PolicyTopicEntries", "ReviewStatus", "ApprovalStatus" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A link between an AdGroupAd and an Asset. + /// + public sealed partial class AdGroupAdAssetView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdAssetView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdAssetView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdAssetView(AdGroupAdAssetView other) : this() { + resourceName_ = other.resourceName_; + AdGroupAd = other.AdGroupAd; + Asset = other.Asset; + fieldType_ = other.fieldType_; + policySummary_ = other.policySummary_ != null ? other.policySummary_.Clone() : null; + performanceLabel_ = other.performanceLabel_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdAssetView Clone() { + return new AdGroupAdAssetView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group ad asset view. + /// Ad group ad asset view resource names have the form: + /// + /// `customers/{customer_id}/adGroupAdAssets/{AdGroupAdAsset.ad_group_id}~{AdGroupAdAsset.ad.ad_id}~{AdGroupAdAsset.asset_id}~{AdGroupAdAsset.asset_field_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "ad_group_ad" field. + public const int AdGroupAdFieldNumber = 5; + private static readonly pb::FieldCodec _single_adGroupAd_codec = pb::FieldCodec.ForClassWrapper(42); + private string adGroupAd_; + /// + /// Output only. The ad group ad to which the asset is linked. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupAd { + get { return adGroupAd_; } + set { + adGroupAd_ = value; + } + } + + + /// Field number for the "asset" field. + public const int AssetFieldNumber = 6; + private static readonly pb::FieldCodec _single_asset_codec = pb::FieldCodec.ForClassWrapper(50); + private string asset_; + /// + /// Output only. The asset which is linked to the ad group ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Asset { + get { return asset_; } + set { + asset_ = value; + } + } + + + /// Field number for the "field_type" field. + public const int FieldTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.AssetFieldTypeEnum.Types.AssetFieldType fieldType_ = 0; + /// + /// Output only. Role that the asset takes in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AssetFieldTypeEnum.Types.AssetFieldType FieldType { + get { return fieldType_; } + set { + fieldType_ = value; + } + } + + /// Field number for the "policy_summary" field. + public const int PolicySummaryFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetPolicySummary policySummary_; + /// + /// Output only. Policy information for the ad group ad asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetPolicySummary PolicySummary { + get { return policySummary_; } + set { + policySummary_ = value; + } + } + + /// Field number for the "performance_label" field. + public const int PerformanceLabelFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.AssetPerformanceLabelEnum.Types.AssetPerformanceLabel performanceLabel_ = 0; + /// + /// Output only. Performance of an asset linkage. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AssetPerformanceLabelEnum.Types.AssetPerformanceLabel PerformanceLabel { + get { return performanceLabel_; } + set { + performanceLabel_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdAssetView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdAssetView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (AdGroupAd != other.AdGroupAd) return false; + if (Asset != other.Asset) return false; + if (FieldType != other.FieldType) return false; + if (!object.Equals(PolicySummary, other.PolicySummary)) return false; + if (PerformanceLabel != other.PerformanceLabel) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (adGroupAd_ != null) hash ^= AdGroupAd.GetHashCode(); + if (asset_ != null) hash ^= Asset.GetHashCode(); + if (FieldType != 0) hash ^= FieldType.GetHashCode(); + if (policySummary_ != null) hash ^= PolicySummary.GetHashCode(); + if (PerformanceLabel != 0) hash ^= PerformanceLabel.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (FieldType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) FieldType); + } + if (policySummary_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PolicySummary); + } + if (PerformanceLabel != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) PerformanceLabel); + } + if (adGroupAd_ != null) { + _single_adGroupAd_codec.WriteTagAndValue(output, AdGroupAd); + } + if (asset_ != null) { + _single_asset_codec.WriteTagAndValue(output, Asset); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (adGroupAd_ != null) { + size += _single_adGroupAd_codec.CalculateSizeWithTag(AdGroupAd); + } + if (asset_ != null) { + size += _single_asset_codec.CalculateSizeWithTag(Asset); + } + if (FieldType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) FieldType); + } + if (policySummary_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PolicySummary); + } + if (PerformanceLabel != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PerformanceLabel); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdAssetView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.adGroupAd_ != null) { + if (adGroupAd_ == null || other.AdGroupAd != "") { + AdGroupAd = other.AdGroupAd; + } + } + if (other.asset_ != null) { + if (asset_ == null || other.Asset != "") { + Asset = other.Asset; + } + } + if (other.FieldType != 0) { + FieldType = other.FieldType; + } + if (other.policySummary_ != null) { + if (policySummary_ == null) { + PolicySummary = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetPolicySummary(); + } + PolicySummary.MergeFrom(other.PolicySummary); + } + if (other.PerformanceLabel != 0) { + PerformanceLabel = other.PerformanceLabel; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 16: { + FieldType = (global::Google.Ads.GoogleAds.V3.Enums.AssetFieldTypeEnum.Types.AssetFieldType) input.ReadEnum(); + break; + } + case 26: { + if (policySummary_ == null) { + PolicySummary = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetPolicySummary(); + } + input.ReadMessage(PolicySummary); + break; + } + case 32: { + PerformanceLabel = (global::Google.Ads.GoogleAds.V3.Enums.AssetPerformanceLabelEnum.Types.AssetPerformanceLabel) input.ReadEnum(); + break; + } + case 42: { + string value = _single_adGroupAd_codec.Read(input); + if (adGroupAd_ == null || value != "") { + AdGroupAd = value; + } + break; + } + case 50: { + string value = _single_asset_codec.Read(input); + if (asset_ == null || value != "") { + Asset = value; + } + break; + } + } + } + } + + } + + /// + /// Contains policy information for an ad group ad asset. + /// + public sealed partial class AdGroupAdAssetPolicySummary : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdAssetPolicySummary()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetViewReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdAssetPolicySummary() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdAssetPolicySummary(AdGroupAdAssetPolicySummary other) : this() { + policyTopicEntries_ = other.policyTopicEntries_.Clone(); + reviewStatus_ = other.reviewStatus_; + approvalStatus_ = other.approvalStatus_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdAssetPolicySummary Clone() { + return new AdGroupAdAssetPolicySummary(this); + } + + /// Field number for the "policy_topic_entries" field. + public const int PolicyTopicEntriesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_policyTopicEntries_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Common.PolicyTopicEntry.Parser); + private readonly pbc::RepeatedField policyTopicEntries_ = new pbc::RepeatedField(); + /// + /// Output only. The list of policy findings for the ad group ad asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PolicyTopicEntries { + get { return policyTopicEntries_; } + } + + /// Field number for the "review_status" field. + public const int ReviewStatusFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus reviewStatus_ = 0; + /// + /// Output only. Where in the review process this ad group ad asset is. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus ReviewStatus { + get { return reviewStatus_; } + set { + reviewStatus_ = value; + } + } + + /// Field number for the "approval_status" field. + public const int ApprovalStatusFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus approvalStatus_ = 0; + /// + /// Output only. The overall approval status of this ad group ad asset, calculated based on + /// the status of its individual policy topic entries. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus ApprovalStatus { + get { return approvalStatus_; } + set { + approvalStatus_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdAssetPolicySummary); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdAssetPolicySummary other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!policyTopicEntries_.Equals(other.policyTopicEntries_)) return false; + if (ReviewStatus != other.ReviewStatus) return false; + if (ApprovalStatus != other.ApprovalStatus) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= policyTopicEntries_.GetHashCode(); + if (ReviewStatus != 0) hash ^= ReviewStatus.GetHashCode(); + if (ApprovalStatus != 0) hash ^= ApprovalStatus.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + policyTopicEntries_.WriteTo(output, _repeated_policyTopicEntries_codec); + if (ReviewStatus != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) ReviewStatus); + } + if (ApprovalStatus != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) ApprovalStatus); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += policyTopicEntries_.CalculateSize(_repeated_policyTopicEntries_codec); + if (ReviewStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ReviewStatus); + } + if (ApprovalStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ApprovalStatus); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdAssetPolicySummary other) { + if (other == null) { + return; + } + policyTopicEntries_.Add(other.policyTopicEntries_); + if (other.ReviewStatus != 0) { + ReviewStatus = other.ReviewStatus; + } + if (other.ApprovalStatus != 0) { + ApprovalStatus = other.ApprovalStatus; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + policyTopicEntries_.AddEntriesFrom(input, _repeated_policyTopicEntries_codec); + break; + } + case 16: { + ReviewStatus = (global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus) input.ReadEnum(); + break; + } + case 24: { + ApprovalStatus = (global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAdAssetViewService.cs b/src/V3/Stubs/AdGroupAdAssetViewService.cs new file mode 100644 index 000000000..11ab9689b --- /dev/null +++ b/src/V3/Stubs/AdGroupAdAssetViewService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_ad_asset_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_ad_asset_view_service.proto + public static partial class AdGroupAdAssetViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_ad_asset_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdAssetViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9h", + "ZF9hc3NldF92aWV3X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNv", + "dXJjZXMvYWRfZ3JvdXBfYWRfYXNzZXRfdmlldy5wcm90bxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8a", + "H2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8iOgocR2V0QWRHcm91", + "cEFkQXNzZXRWaWV3UmVxdWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPg", + "QQIymAIKGUFkR3JvdXBBZEFzc2V0Vmlld1NlcnZpY2US3QEKFUdldEFkR3Jv", + "dXBBZEFzc2V0VmlldxI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzLkdldEFkR3JvdXBBZEFzc2V0Vmlld1JlcXVlc3QaNS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cEFkQXNzZXRWaWV3Ik2C", + "0+STAjcSNS92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9hZEdyb3Vw", + "QWRBc3NldFZpZXdzLyp92kENcmVzb3VyY2VfbmFtZRobykEYZ29vZ2xlYWRz", + "Lmdvb2dsZWFwaXMuY29tQoUCCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXNCHkFkR3JvdXBBZEFzc2V0Vmlld1NlcnZpY2VQcm90b1AB", + "Wkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xl", + "QWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6", + "OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdAssetViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdAssetViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupAdAssetViewService.GetAdGroupAdAssetView][google.ads.googleads.v3.services.AdGroupAdAssetViewService.GetAdGroupAdAssetView]. + /// + public sealed partial class GetAdGroupAdAssetViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupAdAssetViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdAssetViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdAssetViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdAssetViewRequest(GetAdGroupAdAssetViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdAssetViewRequest Clone() { + return new GetAdGroupAdAssetViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group ad asset view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupAdAssetViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupAdAssetViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupAdAssetViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAdAssetViewServiceClient.cs b/src/V3/Stubs/AdGroupAdAssetViewServiceClient.cs new file mode 100644 index 000000000..54fecfd38 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdAssetViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupAdAssetViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupAdAssetViewServiceSettings GetDefault() => new AdGroupAdAssetViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupAdAssetViewServiceSettings() { } + + private AdGroupAdAssetViewServiceSettings(AdGroupAdAssetViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupAdAssetViewSettings = existing.GetAdGroupAdAssetViewSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupAdAssetViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupAdAssetViewServiceClient.GetAdGroupAdAssetView and AdGroupAdAssetViewServiceClient.GetAdGroupAdAssetViewAsync. + /// + /// + /// The default AdGroupAdAssetViewServiceClient.GetAdGroupAdAssetView and + /// AdGroupAdAssetViewServiceClient.GetAdGroupAdAssetViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupAdAssetViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupAdAssetViewServiceSettings Clone() => new AdGroupAdAssetViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupAdAssetViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupAdAssetViewServiceSettings Settings { get; set; } + + /// + public override AdGroupAdAssetViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupAdAssetViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupAdAssetViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupAdAssetViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupAdAssetViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupAdAssetViewServiceClient.ChannelPool; + } + + /// + /// AdGroupAdAssetViewService client wrapper, for convenient use. + /// + public abstract partial class AdGroupAdAssetViewServiceClient + { + /// + /// The default endpoint for the AdGroupAdAssetViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupAdAssetViewService scopes. + /// + /// + /// The default AdGroupAdAssetViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupAdAssetViewServiceClient client = await AdGroupAdAssetViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupAdAssetViewServiceClient.DefaultEndpoint.Host, AdGroupAdAssetViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupAdAssetViewServiceClient client = AdGroupAdAssetViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupAdAssetViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupAdAssetViewServiceClient client = AdGroupAdAssetViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupAdAssetViewServiceClient.DefaultEndpoint.Host, AdGroupAdAssetViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupAdAssetViewServiceClient client = AdGroupAdAssetViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupAdAssetViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupAdAssetViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupAdAssetViewServiceClient Create(grpccore::Channel channel, AdGroupAdAssetViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupAdAssetViewServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupAdAssetViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupAdAssetViewService.AdGroupAdAssetViewServiceClient grpcClient = new AdGroupAdAssetViewService.AdGroupAdAssetViewServiceClient(callInvoker); + return new AdGroupAdAssetViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupAdAssetViewService client. + /// + public virtual AdGroupAdAssetViewService.AdGroupAdAssetViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// + /// Required. The resource name of the ad group ad asset view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdAssetViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAdAssetViewAsync( + new GetAdGroupAdAssetViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// + /// Required. The resource name of the ad group ad asset view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdAssetViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupAdAssetViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// + /// Required. The resource name of the ad group ad asset view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupAdAssetView GetAdGroupAdAssetView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAdAssetView( + new GetAdGroupAdAssetViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdAssetViewAsync( + GetAdGroupAdAssetViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdAssetViewAsync( + GetAdGroupAdAssetViewRequest request, + st::CancellationToken cancellationToken) => GetAdGroupAdAssetViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupAdAssetView GetAdGroupAdAssetView( + GetAdGroupAdAssetViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupAdAssetViewService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupAdAssetViewServiceClientImpl : AdGroupAdAssetViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupAdAssetView; + + /// + /// Constructs a client wrapper for the AdGroupAdAssetViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupAdAssetViewServiceClientImpl(AdGroupAdAssetViewService.AdGroupAdAssetViewServiceClient grpcClient, AdGroupAdAssetViewServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupAdAssetViewServiceSettings effectiveSettings = settings ?? AdGroupAdAssetViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupAdAssetView = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupAdAssetViewAsync, GrpcClient.GetAdGroupAdAssetView, effectiveSettings.GetAdGroupAdAssetViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetAdGroupAdAssetView); + Modify_GetAdGroupAdAssetViewApiCall(ref _callGetAdGroupAdAssetView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupAdAssetViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupAdAssetViewService.AdGroupAdAssetViewServiceClient grpcClient, AdGroupAdAssetViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupAdAssetViewService client. + /// + public override AdGroupAdAssetViewService.AdGroupAdAssetViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupAdAssetViewRequest(ref GetAdGroupAdAssetViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupAdAssetViewAsync( + GetAdGroupAdAssetViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupAdAssetViewRequest(ref request, ref callSettings); + return _callGetAdGroupAdAssetView.Async(request, callSettings); + } + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupAdAssetView GetAdGroupAdAssetView( + GetAdGroupAdAssetViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupAdAssetViewRequest(ref request, ref callSettings); + return _callGetAdGroupAdAssetView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupAdAssetViewServiceGrpc.cs b/src/V3/Stubs/AdGroupAdAssetViewServiceGrpc.cs new file mode 100644 index 000000000..14b6a4f88 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdAssetViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_ad_asset_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch ad group ad asset views. + /// + public static partial class AdGroupAdAssetViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupAdAssetViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupAdAssetViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdAssetViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupAdAssetView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupAdAssetView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupAdAssetView", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupAdAssetViewRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupAdAssetView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdAssetViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupAdAssetViewService + public abstract partial class AdGroupAdAssetViewServiceBase + { + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupAdAssetView(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdAssetViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupAdAssetViewService + public partial class AdGroupAdAssetViewServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupAdAssetViewService + /// The channel to use to make remote calls. + public AdGroupAdAssetViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupAdAssetViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupAdAssetViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupAdAssetViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupAdAssetViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView GetAdGroupAdAssetView(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdAssetViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAdAssetView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView GetAdGroupAdAssetView(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdAssetViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupAdAssetView, null, options, request); + } + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAdAssetViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdAssetViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAdAssetViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group ad asset view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAdAssetViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdAssetViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupAdAssetView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupAdAssetViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupAdAssetViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupAdAssetViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupAdAssetView, serviceImpl.GetAdGroupAdAssetView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupAdAssetViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupAdAssetView, serviceImpl.GetAdGroupAdAssetView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupAdError.cs b/src/V3/Stubs/AdGroupAdError.cs new file mode 100644 index 000000000..79ca9bb61 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdError.cs @@ -0,0 +1,216 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_group_ad_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_group_ad_error.proto + public static partial class AdGroupAdErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_group_ad_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfZ3JvdXBfYWRf", + "ZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxoc", + "Z29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLMAgoSQWRHcm91cEFkRXJy", + "b3JFbnVtIrUCCg5BZEdyb3VwQWRFcnJvchIPCgtVTlNQRUNJRklFRBAAEgsK", + "B1VOS05PV04QARIkCiBBRF9HUk9VUF9BRF9MQUJFTF9ET0VTX05PVF9FWElT", + "VBACEiQKIEFEX0dST1VQX0FEX0xBQkVMX0FMUkVBRFlfRVhJU1RTEAMSGAoU", + "QURfTk9UX1VOREVSX0FER1JPVVAQBBInCiNDQU5OT1RfT1BFUkFURV9PTl9S", + "RU1PVkVEX0FER1JPVVBBRBAFEiAKHENBTk5PVF9DUkVBVEVfREVQUkVDQVRF", + "RF9BRFMQBhIaChZDQU5OT1RfQ1JFQVRFX1RFWFRfQURTEAcSDwoLRU1QVFlf", + "RklFTEQQCBInCiNSRVNPVVJDRV9SRUZFUkVOQ0VEX0lOX01VTFRJUExFX09Q", + "UxAJQu4BCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQhNB", + "ZEdyb3VwQWRFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnBy", + "b3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJyb3Jz", + "ogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIeR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdv", + "b2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupAdErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdGroupAdErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupAdErrorEnum.Types.AdGroupAdError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad group ad errors. + /// + public sealed partial class AdGroupAdErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdGroupAdErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdErrorEnum(AdGroupAdErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdErrorEnum Clone() { + return new AdGroupAdErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupAdErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad group ad errors. + /// + public enum AdGroupAdError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// No link found between the adgroup ad and the label. + /// + [pbr::OriginalName("AD_GROUP_AD_LABEL_DOES_NOT_EXIST")] AdGroupAdLabelDoesNotExist = 2, + /// + /// The label has already been attached to the adgroup ad. + /// + [pbr::OriginalName("AD_GROUP_AD_LABEL_ALREADY_EXISTS")] AdGroupAdLabelAlreadyExists = 3, + /// + /// The specified ad was not found in the adgroup + /// + [pbr::OriginalName("AD_NOT_UNDER_ADGROUP")] AdNotUnderAdgroup = 4, + /// + /// Removed ads may not be modified + /// + [pbr::OriginalName("CANNOT_OPERATE_ON_REMOVED_ADGROUPAD")] CannotOperateOnRemovedAdgroupad = 5, + /// + /// An ad of this type is deprecated and cannot be created. Only deletions + /// are permitted. + /// + [pbr::OriginalName("CANNOT_CREATE_DEPRECATED_ADS")] CannotCreateDeprecatedAds = 6, + /// + /// Text ads are deprecated and cannot be created. Use expanded text ads + /// instead. + /// + [pbr::OriginalName("CANNOT_CREATE_TEXT_ADS")] CannotCreateTextAds = 7, + /// + /// A required field was not specified or is an empty string. + /// + [pbr::OriginalName("EMPTY_FIELD")] EmptyField = 8, + /// + /// An ad may only be modified once per call + /// + [pbr::OriginalName("RESOURCE_REFERENCED_IN_MULTIPLE_OPS")] ResourceReferencedInMultipleOps = 9, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAdLabel.cs b/src/V3/Stubs/AdGroupAdLabel.cs new file mode 100644 index 000000000..a2a85f156 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdLabel.cs @@ -0,0 +1,272 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_ad_label.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_ad_label.proto + public static partial class AdGroupAdLabelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_ad_label.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdLabelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "YWRfbGFiZWwucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291", + "cmNlcxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xl", + "L2FwaS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJz", + "LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvQCCg5BZEdy", + "b3VwQWRMYWJlbBJGCg1yZXNvdXJjZV9uYW1lGAEgASgJQi/gQQX6QSkKJ2dv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZEdyb3VwQWRMYWJlbBJdCgthZF9n", + "cm91cF9hZBgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIq", + "4EEF+kEkCiJnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91cEFkElMK", + "BWxhYmVsGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQibg", + "QQX6QSAKHmdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9MYWJlbDpm6kFjCidn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91cEFkTGFiZWwSOGN1c3Rv", + "bWVycy97Y3VzdG9tZXJ9L2FkR3JvdXBBZExhYmVscy97YWRfZ3JvdXBfYWRf", + "bGFiZWx9QoACCiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzQhNBZEdyb3VwQWRMYWJlbFByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMu", + "UmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz", + "6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJv", + "dG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel.Parser, new[]{ "ResourceName", "AdGroupAd", "Label" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A relationship between an ad group ad and a label. + /// + public sealed partial class AdGroupAdLabel : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdLabel()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdLabel() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdLabel(AdGroupAdLabel other) : this() { + resourceName_ = other.resourceName_; + AdGroupAd = other.AdGroupAd; + Label = other.Label; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdLabel Clone() { + return new AdGroupAdLabel(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group ad label. + /// Ad group ad label resource names have the form: + /// `customers/{customer_id}/adGroupAdLabels/{ad_group_id}~{ad_id}~{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "ad_group_ad" field. + public const int AdGroupAdFieldNumber = 2; + private static readonly pb::FieldCodec _single_adGroupAd_codec = pb::FieldCodec.ForClassWrapper(18); + private string adGroupAd_; + /// + /// Immutable. The ad group ad to which the label is attached. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupAd { + get { return adGroupAd_; } + set { + adGroupAd_ = value; + } + } + + + /// Field number for the "label" field. + public const int LabelFieldNumber = 3; + private static readonly pb::FieldCodec _single_label_codec = pb::FieldCodec.ForClassWrapper(26); + private string label_; + /// + /// Immutable. The label assigned to the ad group ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Label { + get { return label_; } + set { + label_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdLabel); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdLabel other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (AdGroupAd != other.AdGroupAd) return false; + if (Label != other.Label) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (adGroupAd_ != null) hash ^= AdGroupAd.GetHashCode(); + if (label_ != null) hash ^= Label.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (adGroupAd_ != null) { + _single_adGroupAd_codec.WriteTagAndValue(output, AdGroupAd); + } + if (label_ != null) { + _single_label_codec.WriteTagAndValue(output, Label); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (adGroupAd_ != null) { + size += _single_adGroupAd_codec.CalculateSizeWithTag(AdGroupAd); + } + if (label_ != null) { + size += _single_label_codec.CalculateSizeWithTag(Label); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdLabel other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.adGroupAd_ != null) { + if (adGroupAd_ == null || other.AdGroupAd != "") { + AdGroupAd = other.AdGroupAd; + } + } + if (other.label_ != null) { + if (label_ == null || other.Label != "") { + Label = other.Label; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_adGroupAd_codec.Read(input); + if (adGroupAd_ == null || value != "") { + AdGroupAd = value; + } + break; + } + case 26: { + string value = _single_label_codec.Read(input); + if (label_ == null || value != "") { + Label = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAdLabelService.cs b/src/V3/Stubs/AdGroupAdLabelService.cs new file mode 100644 index 000000000..53c01d030 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdLabelService.cs @@ -0,0 +1,953 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_ad_label_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_ad_label_service.proto + public static partial class AdGroupAdLabelServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_ad_label_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdLabelServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9h", + "ZF9sYWJlbF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2Vz", + "L2FkX2dyb3VwX2FkX2xhYmVsLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2Fw", + "aS9maWVsZF9iZWhhdmlvci5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJv", + "dG8iNgoYR2V0QWRHcm91cEFkTGFiZWxSZXF1ZXN0EhoKDXJlc291cmNlX25h", + "bWUYASABKAlCA+BBAiK8AQocTXV0YXRlQWRHcm91cEFkTGFiZWxzUmVxdWVz", + "dBIYCgtjdXN0b21lcl9pZBgBIAEoCUID4EECElIKCm9wZXJhdGlvbnMYAiAD", + "KAsyOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5BZEdyb3Vw", + "QWRMYWJlbE9wZXJhdGlvbkID4EECEhcKD3BhcnRpYWxfZmFpbHVyZRgDIAEo", + "CBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIn0KF0FkR3JvdXBBZExhYmVsT3Bl", + "cmF0aW9uEkMKBmNyZWF0ZRgBIAEoCzIxLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5BZEdyb3VwQWRMYWJlbEgAEhAKBnJlbW92ZRgCIAEo", + "CUgAQgsKCW9wZXJhdGlvbiKhAQodTXV0YXRlQWRHcm91cEFkTGFiZWxzUmVz", + "cG9uc2USMQoVcGFydGlhbF9mYWlsdXJlX2Vycm9yGAMgASgLMhIuZ29vZ2xl", + "LnJwYy5TdGF0dXMSTQoHcmVzdWx0cxgCIAMoCzI8Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBBZExhYmVsUmVzdWx0", + "IjMKGk11dGF0ZUFkR3JvdXBBZExhYmVsUmVzdWx0EhUKDXJlc291cmNlX25h", + "bWUYASABKAky+QMKFUFkR3JvdXBBZExhYmVsU2VydmljZRLNAQoRR2V0QWRH", + "cm91cEFkTGFiZWwSOi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5HZXRBZEdyb3VwQWRMYWJlbFJlcXVlc3QaMS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cEFkTGFiZWwiSYLT5JMCMxIxL3Yz", + "L3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2FkR3JvdXBBZExhYmVscy8q", + "fdpBDXJlc291cmNlX25hbWUS8gEKFU11dGF0ZUFkR3JvdXBBZExhYmVscxI+", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3Jv", + "dXBBZExhYmVsc1JlcXVlc3QaPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5NdXRhdGVBZEdyb3VwQWRMYWJlbHNSZXNwb25zZSJYgtPkkwI5", + "IjQvdjMvY3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfS9hZEdyb3VwQWRMYWJl", + "bHM6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9ucxobykEYZ29v", + "Z2xlYWRzLmdvb2dsZWFwaXMuY29tQoECCiRjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXNCGkFkR3JvdXBBZExhYmVsU2VydmljZVByb3Rv", + "UAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2ds", + "ZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29n", + "bGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabelReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdLabelRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdLabelRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupAdLabelService.GetAdGroupAdLabel][google.ads.googleads.v3.services.AdGroupAdLabelService.GetAdGroupAdLabel]. + /// + public sealed partial class GetAdGroupAdLabelRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupAdLabelRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdLabelRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdLabelRequest(GetAdGroupAdLabelRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdLabelRequest Clone() { + return new GetAdGroupAdLabelRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group ad label to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupAdLabelRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupAdLabelRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupAdLabelRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdGroupAdLabelService.MutateAdGroupAdLabels][google.ads.googleads.v3.services.AdGroupAdLabelService.MutateAdGroupAdLabels]. + /// + public sealed partial class MutateAdGroupAdLabelsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupAdLabelsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelsRequest(MutateAdGroupAdLabelsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelsRequest Clone() { + return new MutateAdGroupAdLabelsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. ID of the customer whose ad group ad labels are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on ad group ad labels. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupAdLabelsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupAdLabelsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupAdLabelsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove) on an ad group ad label. + /// + public sealed partial class AdGroupAdLabelOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdLabelOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdLabelOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdLabelOperation(AdGroupAdLabelOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdLabelOperation Clone() { + return new AdGroupAdLabelOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad group ad + /// label. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 2; + /// + /// Remove operation: A resource name for the ad group ad label + /// being removed, in this format: + /// + /// `customers/{customer_id}/adGroupAdLabels/{ad_group_id}~{ad_id} + /// _{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdLabelOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdLabelOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(18); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdLabelOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for an ad group ad labels mutate. + /// + public sealed partial class MutateAdGroupAdLabelsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupAdLabelsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelsResponse(MutateAdGroupAdLabelsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelsResponse Clone() { + return new MutateAdGroupAdLabelsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupAdLabelsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupAdLabelsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupAdLabelsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for an ad group ad label mutate. + /// + public sealed partial class MutateAdGroupAdLabelResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupAdLabelResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelResult(MutateAdGroupAdLabelResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdLabelResult Clone() { + return new MutateAdGroupAdLabelResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupAdLabelResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupAdLabelResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupAdLabelResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAdLabelServiceClient.cs b/src/V3/Stubs/AdGroupAdLabelServiceClient.cs new file mode 100644 index 000000000..008f42f88 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdLabelServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupAdLabelServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupAdLabelServiceSettings GetDefault() => new AdGroupAdLabelServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupAdLabelServiceSettings() { } + + private AdGroupAdLabelServiceSettings(AdGroupAdLabelServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupAdLabelSettings = existing.GetAdGroupAdLabelSettings; + MutateAdGroupAdLabelsSettings = existing.MutateAdGroupAdLabelsSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupAdLabelServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupAdLabelServiceClient.GetAdGroupAdLabel and AdGroupAdLabelServiceClient.GetAdGroupAdLabelAsync. + /// + /// + /// The default AdGroupAdLabelServiceClient.GetAdGroupAdLabel and + /// AdGroupAdLabelServiceClient.GetAdGroupAdLabelAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupAdLabelSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupAdLabelServiceClient.MutateAdGroupAdLabels and AdGroupAdLabelServiceClient.MutateAdGroupAdLabelsAsync. + /// + /// + /// The default AdGroupAdLabelServiceClient.MutateAdGroupAdLabels and + /// AdGroupAdLabelServiceClient.MutateAdGroupAdLabelsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupAdLabelsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupAdLabelServiceSettings Clone() => new AdGroupAdLabelServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupAdLabelServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupAdLabelServiceSettings Settings { get; set; } + + /// + public override AdGroupAdLabelServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupAdLabelServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupAdLabelServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupAdLabelServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupAdLabelServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupAdLabelServiceClient.ChannelPool; + } + + /// + /// AdGroupAdLabelService client wrapper, for convenient use. + /// + public abstract partial class AdGroupAdLabelServiceClient + { + /// + /// The default endpoint for the AdGroupAdLabelService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupAdLabelService scopes. + /// + /// + /// The default AdGroupAdLabelService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupAdLabelServiceClient client = await AdGroupAdLabelServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupAdLabelServiceClient.DefaultEndpoint.Host, AdGroupAdLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupAdLabelServiceClient client = AdGroupAdLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupAdLabelServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupAdLabelServiceClient client = AdGroupAdLabelServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupAdLabelServiceClient.DefaultEndpoint.Host, AdGroupAdLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupAdLabelServiceClient client = AdGroupAdLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupAdLabelServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupAdLabelServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupAdLabelServiceClient Create(grpccore::Channel channel, AdGroupAdLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupAdLabelServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupAdLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupAdLabelService.AdGroupAdLabelServiceClient grpcClient = new AdGroupAdLabelService.AdGroupAdLabelServiceClient(callInvoker); + return new AdGroupAdLabelServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupAdLabelService client. + /// + public virtual AdGroupAdLabelService.AdGroupAdLabelServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// + /// Required. The resource name of the ad group ad label to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdLabelAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAdLabelAsync( + new GetAdGroupAdLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// + /// Required. The resource name of the ad group ad label to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdLabelAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupAdLabelAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// + /// Required. The resource name of the ad group ad label to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupAdLabel GetAdGroupAdLabel( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAdLabel( + new GetAdGroupAdLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdLabelAsync( + GetAdGroupAdLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdLabelAsync( + GetAdGroupAdLabelRequest request, + st::CancellationToken cancellationToken) => GetAdGroupAdLabelAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupAdLabel GetAdGroupAdLabel( + GetAdGroupAdLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group ad labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group ad labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupAdLabelsAsync( + new MutateAdGroupAdLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group ad labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group ad labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupAdLabelsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group ad labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group ad labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupAdLabelsResponse MutateAdGroupAdLabels( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupAdLabels( + new MutateAdGroupAdLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group ad labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group ad labels. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdLabelsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupAdLabelsAsync( + new MutateAdGroupAdLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group ad labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group ad labels. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdLabelsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupAdLabelsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group ad labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group ad labels. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupAdLabelsResponse MutateAdGroupAdLabels( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupAdLabels( + new MutateAdGroupAdLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdLabelsAsync( + MutateAdGroupAdLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdLabelsAsync( + MutateAdGroupAdLabelsRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupAdLabelsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupAdLabelsResponse MutateAdGroupAdLabels( + MutateAdGroupAdLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupAdLabelService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupAdLabelServiceClientImpl : AdGroupAdLabelServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupAdLabel; + private readonly gaxgrpc::ApiCall _callMutateAdGroupAdLabels; + + /// + /// Constructs a client wrapper for the AdGroupAdLabelService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupAdLabelServiceClientImpl(AdGroupAdLabelService.AdGroupAdLabelServiceClient grpcClient, AdGroupAdLabelServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupAdLabelServiceSettings effectiveSettings = settings ?? AdGroupAdLabelServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupAdLabel = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupAdLabelAsync, GrpcClient.GetAdGroupAdLabel, effectiveSettings.GetAdGroupAdLabelSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroupAdLabels = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupAdLabelsAsync, GrpcClient.MutateAdGroupAdLabels, effectiveSettings.MutateAdGroupAdLabelsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroupAdLabel); + Modify_GetAdGroupAdLabelApiCall(ref _callGetAdGroupAdLabel); + Modify_ApiCall(ref _callMutateAdGroupAdLabels); + Modify_MutateAdGroupAdLabelsApiCall(ref _callMutateAdGroupAdLabels); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupAdLabelApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupAdLabelsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupAdLabelService.AdGroupAdLabelServiceClient grpcClient, AdGroupAdLabelServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupAdLabelService client. + /// + public override AdGroupAdLabelService.AdGroupAdLabelServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupAdLabelRequest(ref GetAdGroupAdLabelRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupAdLabelsRequest(ref MutateAdGroupAdLabelsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupAdLabelAsync( + GetAdGroupAdLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupAdLabelRequest(ref request, ref callSettings); + return _callGetAdGroupAdLabel.Async(request, callSettings); + } + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupAdLabel GetAdGroupAdLabel( + GetAdGroupAdLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupAdLabelRequest(ref request, ref callSettings); + return _callGetAdGroupAdLabel.Sync(request, callSettings); + } + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupAdLabelsAsync( + MutateAdGroupAdLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupAdLabelsRequest(ref request, ref callSettings); + return _callMutateAdGroupAdLabels.Async(request, callSettings); + } + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupAdLabelsResponse MutateAdGroupAdLabels( + MutateAdGroupAdLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupAdLabelsRequest(ref request, ref callSettings); + return _callMutateAdGroupAdLabels.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupAdLabelServiceGrpc.cs b/src/V3/Stubs/AdGroupAdLabelServiceGrpc.cs new file mode 100644 index 000000000..f01a77b5a --- /dev/null +++ b/src/V3/Stubs/AdGroupAdLabelServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_ad_label_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage labels on ad group ads. + /// + public static partial class AdGroupAdLabelService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupAdLabelService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupAdLabelRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdLabelRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupAdLabel = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupAdLabelsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupAdLabelsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupAdLabel = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupAdLabel", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupAdLabelRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupAdLabel); + + static readonly grpc::Method __Method_MutateAdGroupAdLabels = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroupAdLabels", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupAdLabelsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupAdLabelsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupAdLabelService + public abstract partial class AdGroupAdLabelServiceBase + { + /// + /// Returns the requested ad group ad label in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupAdLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdLabelRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroupAdLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupAdLabelService + public partial class AdGroupAdLabelServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupAdLabelService + /// The channel to use to make remote calls. + public AdGroupAdLabelServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupAdLabelService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupAdLabelServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupAdLabelServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupAdLabelServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group ad label in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel GetAdGroupAdLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAdLabel(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group ad label in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel GetAdGroupAdLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupAdLabel, null, options, request); + } + /// + /// Returns the requested ad group ad label in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAdLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAdLabelAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group ad label in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAdLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupAdLabel, null, options, request); + } + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsResponse MutateAdGroupAdLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupAdLabels(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsResponse MutateAdGroupAdLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroupAdLabels, null, options, request); + } + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupAdLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupAdLabelsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes ad group ad labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupAdLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroupAdLabels, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupAdLabelServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupAdLabelServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupAdLabelServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupAdLabel, serviceImpl.GetAdGroupAdLabel) + .AddMethod(__Method_MutateAdGroupAdLabels, serviceImpl.MutateAdGroupAdLabels).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupAdLabelServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupAdLabel, serviceImpl.GetAdGroupAdLabel); + serviceBinder.AddMethod(__Method_MutateAdGroupAdLabels, serviceImpl.MutateAdGroupAdLabels); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupAdRotationMode.cs b/src/V3/Stubs/AdGroupAdRotationMode.cs new file mode 100644 index 000000000..14466115c --- /dev/null +++ b/src/V3/Stubs/AdGroupAdRotationMode.cs @@ -0,0 +1,188 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_group_ad_rotation_mode.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_group_ad_rotation_mode.proto + public static partial class AdGroupAdRotationModeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_group_ad_rotation_mode.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdRotationModeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9ncm91cF9hZF9y", + "b3RhdGlvbl9tb2RlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJ0ChlBZEdyb3Vw", + "QWRSb3RhdGlvbk1vZGVFbnVtIlcKFUFkR3JvdXBBZFJvdGF0aW9uTW9kZRIP", + "CgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIMCghPUFRJTUlaRRACEhIK", + "DlJPVEFURV9GT1JFVkVSEANC7wEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtc0IaQWRHcm91cEFkUm90YXRpb25Nb2RlUHJvdG9QAVpCZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVB", + "ZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oC", + "IUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum), global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeEnum.Types.AdGroupAdRotationMode) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad rotation modes of ads within an + /// ad group. + /// + public sealed partial class AdGroupAdRotationModeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdRotationModeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdRotationModeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdRotationModeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdRotationModeEnum(AdGroupAdRotationModeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdRotationModeEnum Clone() { + return new AdGroupAdRotationModeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdRotationModeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdRotationModeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdRotationModeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupAdRotationModeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible ad rotation modes of an ad group. + /// + public enum AdGroupAdRotationMode { + /// + /// The ad rotation mode has not been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Optimize ad group ads based on clicks or conversions. + /// + [pbr::OriginalName("OPTIMIZE")] Optimize = 2, + /// + /// Rotate evenly forever. + /// + [pbr::OriginalName("ROTATE_FOREVER")] RotateForever = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAdService.cs b/src/V3/Stubs/AdGroupAdService.cs new file mode 100644 index 000000000..25677cdf2 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdService.cs @@ -0,0 +1,1071 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_ad_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_ad_service.proto + public static partial class AdGroupAdServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_ad_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9h", + "ZF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcxorZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL3BvbGljeS5w", + "cm90bxozZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2FkX2dy", + "b3VwX2FkLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdn", + "b29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhh", + "dmlvci5wcm90bxogZ29vZ2xlL3Byb3RvYnVmL2ZpZWxkX21hc2sucHJvdG8a", + "F2dvb2dsZS9ycGMvc3RhdHVzLnByb3RvIjEKE0dldEFkR3JvdXBBZFJlcXVl", + "c3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEoCUID4EECIrIBChdNdXRhdGVBZEdy", + "b3VwQWRzUmVxdWVzdBIYCgtjdXN0b21lcl9pZBgBIAEoCUID4EECEk0KCm9w", + "ZXJhdGlvbnMYAiADKAsyNC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5BZEdyb3VwQWRPcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1", + "cmUYAyABKAgSFQoNdmFsaWRhdGVfb25seRgEIAEoCCLEAgoSQWRHcm91cEFk", + "T3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAQgASgLMhouZ29vZ2xlLnByb3Rv", + "YnVmLkZpZWxkTWFzaxJeChtwb2xpY3lfdmFsaWRhdGlvbl9wYXJhbWV0ZXIY", + "BSABKAsyOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uUG9saWN5", + "VmFsaWRhdGlvblBhcmFtZXRlchI+CgZjcmVhdGUYASABKAsyLC5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cEFkSAASPgoGdXBk", + "YXRlGAIgASgLMiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "LkFkR3JvdXBBZEgAEhAKBnJlbW92ZRgDIAEoCUgAQgsKCW9wZXJhdGlvbiKX", + "AQoYTXV0YXRlQWRHcm91cEFkc1Jlc3BvbnNlEjEKFXBhcnRpYWxfZmFpbHVy", + "ZV9lcnJvchgDIAEoCzISLmdvb2dsZS5ycGMuU3RhdHVzEkgKB3Jlc3VsdHMY", + "AiADKAsyNy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRh", + "dGVBZEdyb3VwQWRSZXN1bHQiLgoVTXV0YXRlQWRHcm91cEFkUmVzdWx0EhUK", + "DXJlc291cmNlX25hbWUYASABKAkyzAMKEEFkR3JvdXBBZFNlcnZpY2USuQEK", + "DEdldEFkR3JvdXBBZBI1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzLkdldEFkR3JvdXBBZFJlcXVlc3QaLC5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXMuQWRHcm91cEFkIkSC0+STAi4SLC92My97cmVzb3Vy", + "Y2VfbmFtZT1jdXN0b21lcnMvKi9hZEdyb3VwQWRzLyp92kENcmVzb3VyY2Vf", + "bmFtZRLeAQoQTXV0YXRlQWRHcm91cEFkcxI5Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBBZHNSZXF1ZXN0GjouZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQWRHcm91cEFk", + "c1Jlc3BvbnNlIlOC0+STAjQiLy92My9jdXN0b21lcnMve2N1c3RvbWVyX2lk", + "PSp9L2FkR3JvdXBBZHM6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0", + "aW9ucxobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQvwBCiRjb20uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCFUFkR3JvdXBBZFNlcnZp", + "Y2VQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGq", + "AiBHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxB", + "ZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2ds", + "ZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.PolicyReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupAdOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupAdOperation.Parser, new[]{ "UpdateMask", "PolicyValidationParameter", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupAdService.GetAdGroupAd][google.ads.googleads.v3.services.AdGroupAdService.GetAdGroupAd]. + /// + public sealed partial class GetAdGroupAdRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupAdRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdRequest(GetAdGroupAdRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAdRequest Clone() { + return new GetAdGroupAdRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupAdRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupAdRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupAdRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdGroupAdService.MutateAdGroupAds][google.ads.googleads.v3.services.AdGroupAdService.MutateAdGroupAds]. + /// + public sealed partial class MutateAdGroupAdsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupAdsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdsRequest(MutateAdGroupAdsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdsRequest Clone() { + return new MutateAdGroupAdsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose ads are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupAdOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual ads. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupAdsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupAdsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupAdsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on an ad group ad. + /// + public sealed partial class AdGroupAdOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdOperation(AdGroupAdOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + policyValidationParameter_ = other.policyValidationParameter_ != null ? other.policyValidationParameter_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdOperation Clone() { + return new AdGroupAdOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "policy_validation_parameter" field. + public const int PolicyValidationParameterFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Common.PolicyValidationParameter policyValidationParameter_; + /// + /// Configuration for how policies are validated. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PolicyValidationParameter PolicyValidationParameter { + get { return policyValidationParameter_; } + set { + policyValidationParameter_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The ad is expected to have a valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed ad is expected, + /// in this format: + /// + /// `customers/{customer_id}/adGroupAds/{ad_group_id}~{ad_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(PolicyValidationParameter, other.PolicyValidationParameter)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (policyValidationParameter_ != null) hash ^= PolicyValidationParameter.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (policyValidationParameter_ != null) { + output.WriteRawTag(42); + output.WriteMessage(PolicyValidationParameter); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (policyValidationParameter_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PolicyValidationParameter); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + if (other.policyValidationParameter_ != null) { + if (policyValidationParameter_ == null) { + PolicyValidationParameter = new global::Google.Ads.GoogleAds.V3.Common.PolicyValidationParameter(); + } + PolicyValidationParameter.MergeFrom(other.PolicyValidationParameter); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + case 42: { + if (policyValidationParameter_ == null) { + PolicyValidationParameter = new global::Google.Ads.GoogleAds.V3.Common.PolicyValidationParameter(); + } + input.ReadMessage(PolicyValidationParameter); + break; + } + } + } + } + + } + + /// + /// Response message for an ad group ad mutate. + /// + public sealed partial class MutateAdGroupAdsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupAdsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdsResponse(MutateAdGroupAdsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdsResponse Clone() { + return new MutateAdGroupAdsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupAdsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupAdsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupAdsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the ad mutate. + /// + public sealed partial class MutateAdGroupAdResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupAdResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdResult(MutateAdGroupAdResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupAdResult Clone() { + return new MutateAdGroupAdResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// The resource name returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupAdResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupAdResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupAdResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAdServiceClient.cs b/src/V3/Stubs/AdGroupAdServiceClient.cs new file mode 100644 index 000000000..47a4d8d98 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdServiceClient.cs @@ -0,0 +1,887 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupAdServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupAdServiceSettings GetDefault() => new AdGroupAdServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupAdServiceSettings() { } + + private AdGroupAdServiceSettings(AdGroupAdServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupAdSettings = existing.GetAdGroupAdSettings; + MutateAdGroupAdsSettings = existing.MutateAdGroupAdsSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupAdServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupAdServiceClient.GetAdGroupAd and AdGroupAdServiceClient.GetAdGroupAdAsync. + /// + /// + /// The default AdGroupAdServiceClient.GetAdGroupAd and + /// AdGroupAdServiceClient.GetAdGroupAdAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupAdSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupAdServiceClient.MutateAdGroupAds and AdGroupAdServiceClient.MutateAdGroupAdsAsync. + /// + /// + /// The default AdGroupAdServiceClient.MutateAdGroupAds and + /// AdGroupAdServiceClient.MutateAdGroupAdsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupAdsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupAdServiceSettings Clone() => new AdGroupAdServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupAdServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupAdServiceSettings Settings { get; set; } + + /// + public override AdGroupAdServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupAdServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupAdServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupAdServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupAdServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupAdServiceClient.ChannelPool; + } + + /// + /// AdGroupAdService client wrapper, for convenient use. + /// + public abstract partial class AdGroupAdServiceClient + { + /// + /// The default endpoint for the AdGroupAdService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupAdService scopes. + /// + /// + /// The default AdGroupAdService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupAdServiceClient client = await AdGroupAdServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupAdServiceClient.DefaultEndpoint.Host, AdGroupAdServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupAdServiceClient client = AdGroupAdServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupAdServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupAdServiceClient client = AdGroupAdServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupAdServiceClient.DefaultEndpoint.Host, AdGroupAdServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupAdServiceClient client = AdGroupAdServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupAdServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupAdServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupAdServiceClient Create(grpccore::Channel channel, AdGroupAdServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupAdServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupAdServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupAdService.AdGroupAdServiceClient grpcClient = new AdGroupAdService.AdGroupAdServiceClient(callInvoker); + return new AdGroupAdServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupAdService client. + /// + public virtual AdGroupAdService.AdGroupAdServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad in full detail. + /// + /// + /// Required. The resource name of the ad to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAdAsync( + new GetAdGroupAdRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// Required. The resource name of the ad to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupAdAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// Required. The resource name of the ad to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupAd GetAdGroupAd( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAd( + new GetAdGroupAdRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdAsync( + GetAdGroupAdRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAdAsync( + GetAdGroupAdRequest request, + st::CancellationToken cancellationToken) => GetAdGroupAdAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupAd GetAdGroupAd( + GetAdGroupAdRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupAdsAsync( + new MutateAdGroupAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupAdsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupAdsResponse MutateAdGroupAds( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupAds( + new MutateAdGroupAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupAdsAsync( + new MutateAdGroupAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupAdsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupAdsResponse MutateAdGroupAds( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupAds( + new MutateAdGroupAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdsAsync( + MutateAdGroupAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupAdsAsync( + MutateAdGroupAdsRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupAdsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupAdsResponse MutateAdGroupAds( + MutateAdGroupAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupAdService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupAdServiceClientImpl : AdGroupAdServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupAd; + private readonly gaxgrpc::ApiCall _callMutateAdGroupAds; + + /// + /// Constructs a client wrapper for the AdGroupAdService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupAdServiceClientImpl(AdGroupAdService.AdGroupAdServiceClient grpcClient, AdGroupAdServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupAdServiceSettings effectiveSettings = settings ?? AdGroupAdServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupAd = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupAdAsync, GrpcClient.GetAdGroupAd, effectiveSettings.GetAdGroupAdSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroupAds = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupAdsAsync, GrpcClient.MutateAdGroupAds, effectiveSettings.MutateAdGroupAdsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroupAd); + Modify_GetAdGroupAdApiCall(ref _callGetAdGroupAd); + Modify_ApiCall(ref _callMutateAdGroupAds); + Modify_MutateAdGroupAdsApiCall(ref _callMutateAdGroupAds); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupAdApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupAdsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupAdService.AdGroupAdServiceClient grpcClient, AdGroupAdServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupAdService client. + /// + public override AdGroupAdService.AdGroupAdServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupAdRequest(ref GetAdGroupAdRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupAdsRequest(ref MutateAdGroupAdsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupAdAsync( + GetAdGroupAdRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupAdRequest(ref request, ref callSettings); + return _callGetAdGroupAd.Async(request, callSettings); + } + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupAd GetAdGroupAd( + GetAdGroupAdRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupAdRequest(ref request, ref callSettings); + return _callGetAdGroupAd.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupAdsAsync( + MutateAdGroupAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupAdsRequest(ref request, ref callSettings); + return _callMutateAdGroupAds.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupAdsResponse MutateAdGroupAds( + MutateAdGroupAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupAdsRequest(ref request, ref callSettings); + return _callMutateAdGroupAds.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupAdServiceGrpc.cs b/src/V3/Stubs/AdGroupAdServiceGrpc.cs new file mode 100644 index 000000000..955230723 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_ad_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ads in an ad group. + /// + public static partial class AdGroupAdService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupAdService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupAdRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupAd = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupAdsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupAdsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupAd = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupAd", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupAdRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupAd); + + static readonly grpc::Method __Method_MutateAdGroupAds = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroupAds", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupAdsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupAdsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAdServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupAdService + public abstract partial class AdGroupAdServiceBase + { + /// + /// Returns the requested ad in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupAd(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroupAds(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupAdService + public partial class AdGroupAdServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupAdService + /// The channel to use to make remote calls. + public AdGroupAdServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupAdService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupAdServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupAdServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupAdServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd GetAdGroupAd(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAd(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd GetAdGroupAd(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupAd, null, options, request); + } + /// + /// Returns the requested ad in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAdAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAdAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAdAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAdRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupAd, null, options, request); + } + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsResponse MutateAdGroupAds(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupAds(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsResponse MutateAdGroupAds(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroupAds, null, options, request); + } + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupAdsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupAdsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ads. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupAdsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroupAds, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupAdServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupAdServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupAdServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupAd, serviceImpl.GetAdGroupAd) + .AddMethod(__Method_MutateAdGroupAds, serviceImpl.MutateAdGroupAds).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupAdServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupAd, serviceImpl.GetAdGroupAd); + serviceBinder.AddMethod(__Method_MutateAdGroupAds, serviceImpl.MutateAdGroupAds); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupAdStatus.cs b/src/V3/Stubs/AdGroupAdStatus.cs new file mode 100644 index 000000000..148961fd0 --- /dev/null +++ b/src/V3/Stubs/AdGroupAdStatus.cs @@ -0,0 +1,191 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_group_ad_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_group_ad_status.proto + public static partial class AdGroupAdStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_group_ad_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAdStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9ncm91cF9hZF9z", + "dGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvImwKE0FkR3JvdXBBZFN0YXR1", + "c0VudW0iVQoPQWRHcm91cEFkU3RhdHVzEg8KC1VOU1BFQ0lGSUVEEAASCwoH", + "VU5LTk9XThABEgsKB0VOQUJMRUQQAhIKCgZQQVVTRUQQAxILCgdSRU1PVkVE", + "EARC6QEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IUQWRH", + "cm91cEFkU3RhdHVzUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogID", + "R0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVc", + "QWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVB", + "ZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusEnum.Types.AdGroupAdStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of an AdGroupAd. + /// + public sealed partial class AdGroupAdStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAdStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdGroupAdStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdStatusEnum(AdGroupAdStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAdStatusEnum Clone() { + return new AdGroupAdStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAdStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAdStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAdStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupAdStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of an AdGroupAd. + /// + public enum AdGroupAdStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The ad group ad is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// The ad group ad is paused. + /// + [pbr::OriginalName("PAUSED")] Paused = 3, + /// + /// The ad group ad is removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAudienceView.cs b/src/V3/Stubs/AdGroupAudienceView.cs new file mode 100644 index 000000000..0b41f4617 --- /dev/null +++ b/src/V3/Stubs/AdGroupAudienceView.cs @@ -0,0 +1,198 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_audience_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_audience_view.proto + public static partial class AdGroupAudienceViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_audience_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAudienceViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "YXVkaWVuY2Vfdmlldy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhln", + "b29nbGUvYXBpL3Jlc291cmNlLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvItkBChNBZEdyb3VwQXVkaWVuY2VWaWV3EksKDXJlc291cmNl", + "X25hbWUYASABKAlCNOBBBfpBLgosZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29t", + "L0FkR3JvdXBBdWRpZW5jZVZpZXc6depBcgosZ29vZ2xlYWRzLmdvb2dsZWFw", + "aXMuY29tL0FkR3JvdXBBdWRpZW5jZVZpZXcSQmN1c3RvbWVycy97Y3VzdG9t", + "ZXJ9L2FkR3JvdXBBdWRpZW5jZVZpZXdzL3thZF9ncm91cF9hdWRpZW5jZV92", + "aWV3fUKFAgolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "c0IYQWRHcm91cEF1ZGllbmNlVmlld1Byb3RvUAFaSmdvb2dsZS5nb2xhbmcu", + "b3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNv", + "dXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMu", + "VjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3Vy", + "Y2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IG", + "cHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad group audience view. + /// Includes performance data from interests and remarketing lists for Display + /// Network and YouTube Network ads, and remarketing lists for search ads (RLSA), + /// aggregated at the audience level. + /// + public sealed partial class AdGroupAudienceView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupAudienceView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAudienceView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAudienceView(AdGroupAudienceView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupAudienceView Clone() { + return new AdGroupAudienceView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group audience view. + /// Ad group audience view resource names have the form: + /// + /// `customers/{customer_id}/adGroupAudienceViews/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupAudienceView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupAudienceView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupAudienceView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAudienceViewService.cs b/src/V3/Stubs/AdGroupAudienceViewService.cs new file mode 100644 index 000000000..850d38a9f --- /dev/null +++ b/src/V3/Stubs/AdGroupAudienceViewService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_audience_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_audience_view_service.proto + public static partial class AdGroupAudienceViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_audience_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupAudienceViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9h", + "dWRpZW5jZV92aWV3X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNv", + "dXJjZXMvYWRfZ3JvdXBfYXVkaWVuY2Vfdmlldy5wcm90bxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8a", + "H2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8iOwodR2V0QWRHcm91", + "cEF1ZGllbmNlVmlld1JlcXVlc3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEoCUID", + "4EECMp0CChpBZEdyb3VwQXVkaWVuY2VWaWV3U2VydmljZRLhAQoWR2V0QWRH", + "cm91cEF1ZGllbmNlVmlldxI/Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzLkdldEFkR3JvdXBBdWRpZW5jZVZpZXdSZXF1ZXN0GjYuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkFkR3JvdXBBdWRpZW5jZVZp", + "ZXciToLT5JMCOBI2L3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2Fk", + "R3JvdXBBdWRpZW5jZVZpZXdzLyp92kENcmVzb3VyY2VfbmFtZRobykEYZ29v", + "Z2xlYWRzLmdvb2dsZWFwaXMuY29tQoYCCiRjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXNCH0FkR3JvdXBBdWRpZW5jZVZpZXdTZXJ2aWNl", + "UHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBp", + "cy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIg", + "R29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRz", + "XEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVB", + "ZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAudienceViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAudienceViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupAudienceViewService.GetAdGoupAudienceView][]. + /// + public sealed partial class GetAdGroupAudienceViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupAudienceViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAudienceViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAudienceViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAudienceViewRequest(GetAdGroupAudienceViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupAudienceViewRequest Clone() { + return new GetAdGroupAudienceViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group audience view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupAudienceViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupAudienceViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupAudienceViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupAudienceViewServiceClient.cs b/src/V3/Stubs/AdGroupAudienceViewServiceClient.cs new file mode 100644 index 000000000..be6ce615c --- /dev/null +++ b/src/V3/Stubs/AdGroupAudienceViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupAudienceViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupAudienceViewServiceSettings GetDefault() => new AdGroupAudienceViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupAudienceViewServiceSettings() { } + + private AdGroupAudienceViewServiceSettings(AdGroupAudienceViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupAudienceViewSettings = existing.GetAdGroupAudienceViewSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupAudienceViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupAudienceViewServiceClient.GetAdGroupAudienceView and AdGroupAudienceViewServiceClient.GetAdGroupAudienceViewAsync. + /// + /// + /// The default AdGroupAudienceViewServiceClient.GetAdGroupAudienceView and + /// AdGroupAudienceViewServiceClient.GetAdGroupAudienceViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupAudienceViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupAudienceViewServiceSettings Clone() => new AdGroupAudienceViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupAudienceViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupAudienceViewServiceSettings Settings { get; set; } + + /// + public override AdGroupAudienceViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupAudienceViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupAudienceViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupAudienceViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupAudienceViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupAudienceViewServiceClient.ChannelPool; + } + + /// + /// AdGroupAudienceViewService client wrapper, for convenient use. + /// + public abstract partial class AdGroupAudienceViewServiceClient + { + /// + /// The default endpoint for the AdGroupAudienceViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupAudienceViewService scopes. + /// + /// + /// The default AdGroupAudienceViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupAudienceViewServiceClient client = await AdGroupAudienceViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupAudienceViewServiceClient.DefaultEndpoint.Host, AdGroupAudienceViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupAudienceViewServiceClient client = AdGroupAudienceViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupAudienceViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupAudienceViewServiceClient client = AdGroupAudienceViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupAudienceViewServiceClient.DefaultEndpoint.Host, AdGroupAudienceViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupAudienceViewServiceClient client = AdGroupAudienceViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupAudienceViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupAudienceViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupAudienceViewServiceClient Create(grpccore::Channel channel, AdGroupAudienceViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupAudienceViewServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupAudienceViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupAudienceViewService.AdGroupAudienceViewServiceClient grpcClient = new AdGroupAudienceViewService.AdGroupAudienceViewServiceClient(callInvoker); + return new AdGroupAudienceViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupAudienceViewService client. + /// + public virtual AdGroupAudienceViewService.AdGroupAudienceViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// + /// Required. The resource name of the ad group audience view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAudienceViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAudienceViewAsync( + new GetAdGroupAudienceViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// + /// Required. The resource name of the ad group audience view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAudienceViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupAudienceViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// + /// Required. The resource name of the ad group audience view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupAudienceView GetAdGroupAudienceView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAudienceView( + new GetAdGroupAudienceViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAudienceViewAsync( + GetAdGroupAudienceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAudienceViewAsync( + GetAdGroupAudienceViewRequest request, + st::CancellationToken cancellationToken) => GetAdGroupAudienceViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupAudienceView GetAdGroupAudienceView( + GetAdGroupAudienceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupAudienceViewService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupAudienceViewServiceClientImpl : AdGroupAudienceViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupAudienceView; + + /// + /// Constructs a client wrapper for the AdGroupAudienceViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupAudienceViewServiceClientImpl(AdGroupAudienceViewService.AdGroupAudienceViewServiceClient grpcClient, AdGroupAudienceViewServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupAudienceViewServiceSettings effectiveSettings = settings ?? AdGroupAudienceViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupAudienceView = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupAudienceViewAsync, GrpcClient.GetAdGroupAudienceView, effectiveSettings.GetAdGroupAudienceViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetAdGroupAudienceView); + Modify_GetAdGroupAudienceViewApiCall(ref _callGetAdGroupAudienceView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupAudienceViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupAudienceViewService.AdGroupAudienceViewServiceClient grpcClient, AdGroupAudienceViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupAudienceViewService client. + /// + public override AdGroupAudienceViewService.AdGroupAudienceViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupAudienceViewRequest(ref GetAdGroupAudienceViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupAudienceViewAsync( + GetAdGroupAudienceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupAudienceViewRequest(ref request, ref callSettings); + return _callGetAdGroupAudienceView.Async(request, callSettings); + } + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupAudienceView GetAdGroupAudienceView( + GetAdGroupAudienceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupAudienceViewRequest(ref request, ref callSettings); + return _callGetAdGroupAudienceView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupAudienceViewServiceGrpc.cs b/src/V3/Stubs/AdGroupAudienceViewServiceGrpc.cs new file mode 100644 index 000000000..4def6a413 --- /dev/null +++ b/src/V3/Stubs/AdGroupAudienceViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_audience_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ad group audience views. + /// + public static partial class AdGroupAudienceViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupAudienceViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupAudienceViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAudienceViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupAudienceView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupAudienceView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupAudienceView", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupAudienceViewRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupAudienceView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupAudienceViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupAudienceViewService + public abstract partial class AdGroupAudienceViewServiceBase + { + /// + /// Returns the requested ad group audience view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupAudienceView(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAudienceViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupAudienceViewService + public partial class AdGroupAudienceViewServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupAudienceViewService + /// The channel to use to make remote calls. + public AdGroupAudienceViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupAudienceViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupAudienceViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupAudienceViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupAudienceViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group audience view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView GetAdGroupAudienceView(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAudienceViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAudienceView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group audience view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView GetAdGroupAudienceView(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAudienceViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupAudienceView, null, options, request); + } + /// + /// Returns the requested ad group audience view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAudienceViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAudienceViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAudienceViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group audience view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAudienceViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupAudienceViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupAudienceView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupAudienceViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupAudienceViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupAudienceViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupAudienceView, serviceImpl.GetAdGroupAudienceView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupAudienceViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupAudienceView, serviceImpl.GetAdGroupAudienceView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupBidModifier.cs b/src/V3/Stubs/AdGroupBidModifier.cs new file mode 100644 index 000000000..77a72c312 --- /dev/null +++ b/src/V3/Stubs/AdGroupBidModifier.cs @@ -0,0 +1,683 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_bid_modifier.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_bid_modifier.proto + public static partial class AdGroupBidModifierReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_bid_modifier.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupBidModifierReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "YmlkX21vZGlmaWVyLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMaLWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9jcml0", + "ZXJpYS5wcm90bxo3Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvYmlk", + "X21vZGlmaWVyX3NvdXJjZS5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhh", + "dmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xl", + "L3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvIpEJChJBZEdyb3VwQmlkTW9kaWZpZXISSgoNcmVzb3VyY2Vf", + "bmFtZRgBIAEoCUIz4EEF+kEtCitnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20v", + "QWRHcm91cEJpZE1vZGlmaWVyElgKCGFkX2dyb3VwGAIgASgLMhwuZ29vZ2xl", + "LnByb3RvYnVmLlN0cmluZ1ZhbHVlQijgQQX6QSIKIGdvb2dsZWFkcy5nb29n", + "bGVhcGlzLmNvbS9BZEdyb3VwEjYKDGNyaXRlcmlvbl9pZBgDIAEoCzIbLmdv", + "b2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSMgoMYmlkX21vZGlmaWVy", + "GAQgASgLMhwuZ29vZ2xlLnByb3RvYnVmLkRvdWJsZVZhbHVlEl0KDWJhc2Vf", + "YWRfZ3JvdXAYCSABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVC", + "KOBBA/pBIgogZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0FkR3JvdXASaAoT", + "YmlkX21vZGlmaWVyX3NvdXJjZRgKIAEoDjJGLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zLkJpZE1vZGlmaWVyU291cmNlRW51bS5CaWRNb2RpZmll", + "clNvdXJjZUID4EEDEmQKGWhvdGVsX2RhdGVfc2VsZWN0aW9uX3R5cGUYBSAB", + "KAsyOi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uSG90ZWxEYXRl", + "U2VsZWN0aW9uVHlwZUluZm9CA+BBBUgAEmoKHGhvdGVsX2FkdmFuY2VfYm9v", + "a2luZ193aW5kb3cYBiABKAsyPS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5j", + "b21tb24uSG90ZWxBZHZhbmNlQm9va2luZ1dpbmRvd0luZm9CA+BBBUgAEloK", + "FGhvdGVsX2xlbmd0aF9vZl9zdGF5GAcgASgLMjUuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLkhvdGVsTGVuZ3RoT2ZTdGF5SW5mb0ID4EEFSAAS", + "VgoSaG90ZWxfY2hlY2tfaW5fZGF5GAggASgLMjMuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLkhvdGVsQ2hlY2tJbkRheUluZm9CA+BBBUgAEkEK", + "BmRldmljZRgLIAEoCzIqLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1v", + "bi5EZXZpY2VJbmZvQgPgQQVIABJWChFwcmVmZXJyZWRfY29udGVudBgMIAEo", + "CzI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5QcmVmZXJyZWRD", + "b250ZW50SW5mb0ID4EEFSAA6cupBbworZ29vZ2xlYWRzLmdvb2dsZWFwaXMu", + "Y29tL0FkR3JvdXBCaWRNb2RpZmllchJAY3VzdG9tZXJzL3tjdXN0b21lcn0v", + "YWRHcm91cEJpZE1vZGlmaWVycy97YWRfZ3JvdXBfYmlkX21vZGlmaWVyfUIL", + "Cgljcml0ZXJpb25ChAIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXNCF0FkR3JvdXBCaWRNb2RpZmllclByb3RvUAFaSmdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29n", + "bGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "UmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291", + "cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BidModifierSourceReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier), global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier.Parser, new[]{ "ResourceName", "AdGroup", "CriterionId", "BidModifier", "BaseAdGroup", "BidModifierSource", "HotelDateSelectionType", "HotelAdvanceBookingWindow", "HotelLengthOfStay", "HotelCheckInDay", "Device", "PreferredContent" }, new[]{ "Criterion" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents an ad group bid modifier. + /// + public sealed partial class AdGroupBidModifier : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupBidModifier()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifierReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifier() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifier(AdGroupBidModifier other) : this() { + resourceName_ = other.resourceName_; + AdGroup = other.AdGroup; + CriterionId = other.CriterionId; + BidModifier = other.BidModifier; + BaseAdGroup = other.BaseAdGroup; + bidModifierSource_ = other.bidModifierSource_; + switch (other.CriterionCase) { + case CriterionOneofCase.HotelDateSelectionType: + HotelDateSelectionType = other.HotelDateSelectionType.Clone(); + break; + case CriterionOneofCase.HotelAdvanceBookingWindow: + HotelAdvanceBookingWindow = other.HotelAdvanceBookingWindow.Clone(); + break; + case CriterionOneofCase.HotelLengthOfStay: + HotelLengthOfStay = other.HotelLengthOfStay.Clone(); + break; + case CriterionOneofCase.HotelCheckInDay: + HotelCheckInDay = other.HotelCheckInDay.Clone(); + break; + case CriterionOneofCase.Device: + Device = other.Device.Clone(); + break; + case CriterionOneofCase.PreferredContent: + PreferredContent = other.PreferredContent.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifier Clone() { + return new AdGroupBidModifier(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group bid modifier. + /// Ad group bid modifier resource names have the form: + /// + /// `customers/{customer_id}/adGroupBidModifiers/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 2; + private static readonly pb::FieldCodec _single_adGroup_codec = pb::FieldCodec.ForClassWrapper(18); + private string adGroup_; + /// + /// Immutable. The ad group to which this criterion belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroup { + get { return adGroup_; } + set { + adGroup_ = value; + } + } + + + /// Field number for the "criterion_id" field. + public const int CriterionIdFieldNumber = 3; + private static readonly pb::FieldCodec _single_criterionId_codec = pb::FieldCodec.ForStructWrapper(26); + private long? criterionId_; + /// + /// Output only. The ID of the criterion to bid modify. + /// + /// This field is ignored for mutates. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CriterionId { + get { return criterionId_; } + set { + criterionId_ = value; + } + } + + + /// Field number for the "bid_modifier" field. + public const int BidModifierFieldNumber = 4; + private static readonly pb::FieldCodec _single_bidModifier_codec = pb::FieldCodec.ForStructWrapper(34); + private double? bidModifier_; + /// + /// The modifier for the bid when the criterion matches. The modifier must be + /// in the range: 0.1 - 10.0. The range is 1.0 - 6.0 for PreferredContent. + /// Use 0 to opt out of a Device type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? BidModifier { + get { return bidModifier_; } + set { + bidModifier_ = value; + } + } + + + /// Field number for the "base_ad_group" field. + public const int BaseAdGroupFieldNumber = 9; + private static readonly pb::FieldCodec _single_baseAdGroup_codec = pb::FieldCodec.ForClassWrapper(74); + private string baseAdGroup_; + /// + /// Output only. The base ad group from which this draft/trial adgroup bid modifier was + /// created. If ad_group is a base ad group then this field will be equal to + /// ad_group. If the ad group was created in the draft or trial and has no + /// corresponding base ad group, then this field will be null. + /// This field is readonly. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BaseAdGroup { + get { return baseAdGroup_; } + set { + baseAdGroup_ = value; + } + } + + + /// Field number for the "bid_modifier_source" field. + public const int BidModifierSourceFieldNumber = 10; + private global::Google.Ads.GoogleAds.V3.Enums.BidModifierSourceEnum.Types.BidModifierSource bidModifierSource_ = 0; + /// + /// Output only. Bid modifier source. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BidModifierSourceEnum.Types.BidModifierSource BidModifierSource { + get { return bidModifierSource_; } + set { + bidModifierSource_ = value; + } + } + + /// Field number for the "hotel_date_selection_type" field. + public const int HotelDateSelectionTypeFieldNumber = 5; + /// + /// Immutable. Criterion for hotel date selection (default dates vs. user selected). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelDateSelectionTypeInfo HotelDateSelectionType { + get { return criterionCase_ == CriterionOneofCase.HotelDateSelectionType ? (global::Google.Ads.GoogleAds.V3.Common.HotelDateSelectionTypeInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.HotelDateSelectionType; + } + } + + /// Field number for the "hotel_advance_booking_window" field. + public const int HotelAdvanceBookingWindowFieldNumber = 6; + /// + /// Immutable. Criterion for number of days prior to the stay the booking is being made. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelAdvanceBookingWindowInfo HotelAdvanceBookingWindow { + get { return criterionCase_ == CriterionOneofCase.HotelAdvanceBookingWindow ? (global::Google.Ads.GoogleAds.V3.Common.HotelAdvanceBookingWindowInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.HotelAdvanceBookingWindow; + } + } + + /// Field number for the "hotel_length_of_stay" field. + public const int HotelLengthOfStayFieldNumber = 7; + /// + /// Immutable. Criterion for length of hotel stay in nights. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelLengthOfStayInfo HotelLengthOfStay { + get { return criterionCase_ == CriterionOneofCase.HotelLengthOfStay ? (global::Google.Ads.GoogleAds.V3.Common.HotelLengthOfStayInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.HotelLengthOfStay; + } + } + + /// Field number for the "hotel_check_in_day" field. + public const int HotelCheckInDayFieldNumber = 8; + /// + /// Immutable. Criterion for day of the week the booking is for. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelCheckInDayInfo HotelCheckInDay { + get { return criterionCase_ == CriterionOneofCase.HotelCheckInDay ? (global::Google.Ads.GoogleAds.V3.Common.HotelCheckInDayInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.HotelCheckInDay; + } + } + + /// Field number for the "device" field. + public const int DeviceFieldNumber = 11; + /// + /// Immutable. A device criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.DeviceInfo Device { + get { return criterionCase_ == CriterionOneofCase.Device ? (global::Google.Ads.GoogleAds.V3.Common.DeviceInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Device; + } + } + + /// Field number for the "preferred_content" field. + public const int PreferredContentFieldNumber = 12; + /// + /// Immutable. A preferred content criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PreferredContentInfo PreferredContent { + get { return criterionCase_ == CriterionOneofCase.PreferredContent ? (global::Google.Ads.GoogleAds.V3.Common.PreferredContentInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.PreferredContent; + } + } + + private object criterion_; + /// Enum of possible cases for the "criterion" oneof. + public enum CriterionOneofCase { + None = 0, + HotelDateSelectionType = 5, + HotelAdvanceBookingWindow = 6, + HotelLengthOfStay = 7, + HotelCheckInDay = 8, + Device = 11, + PreferredContent = 12, + } + private CriterionOneofCase criterionCase_ = CriterionOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionOneofCase CriterionCase { + get { return criterionCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearCriterion() { + criterionCase_ = CriterionOneofCase.None; + criterion_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupBidModifier); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupBidModifier other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (AdGroup != other.AdGroup) return false; + if (CriterionId != other.CriterionId) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(BidModifier, other.BidModifier)) return false; + if (BaseAdGroup != other.BaseAdGroup) return false; + if (BidModifierSource != other.BidModifierSource) return false; + if (!object.Equals(HotelDateSelectionType, other.HotelDateSelectionType)) return false; + if (!object.Equals(HotelAdvanceBookingWindow, other.HotelAdvanceBookingWindow)) return false; + if (!object.Equals(HotelLengthOfStay, other.HotelLengthOfStay)) return false; + if (!object.Equals(HotelCheckInDay, other.HotelCheckInDay)) return false; + if (!object.Equals(Device, other.Device)) return false; + if (!object.Equals(PreferredContent, other.PreferredContent)) return false; + if (CriterionCase != other.CriterionCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (adGroup_ != null) hash ^= AdGroup.GetHashCode(); + if (criterionId_ != null) hash ^= CriterionId.GetHashCode(); + if (bidModifier_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(BidModifier); + if (baseAdGroup_ != null) hash ^= BaseAdGroup.GetHashCode(); + if (BidModifierSource != 0) hash ^= BidModifierSource.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.HotelDateSelectionType) hash ^= HotelDateSelectionType.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.HotelAdvanceBookingWindow) hash ^= HotelAdvanceBookingWindow.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.HotelLengthOfStay) hash ^= HotelLengthOfStay.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.HotelCheckInDay) hash ^= HotelCheckInDay.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Device) hash ^= Device.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.PreferredContent) hash ^= PreferredContent.GetHashCode(); + hash ^= (int) criterionCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (adGroup_ != null) { + _single_adGroup_codec.WriteTagAndValue(output, AdGroup); + } + if (criterionId_ != null) { + _single_criterionId_codec.WriteTagAndValue(output, CriterionId); + } + if (bidModifier_ != null) { + _single_bidModifier_codec.WriteTagAndValue(output, BidModifier); + } + if (criterionCase_ == CriterionOneofCase.HotelDateSelectionType) { + output.WriteRawTag(42); + output.WriteMessage(HotelDateSelectionType); + } + if (criterionCase_ == CriterionOneofCase.HotelAdvanceBookingWindow) { + output.WriteRawTag(50); + output.WriteMessage(HotelAdvanceBookingWindow); + } + if (criterionCase_ == CriterionOneofCase.HotelLengthOfStay) { + output.WriteRawTag(58); + output.WriteMessage(HotelLengthOfStay); + } + if (criterionCase_ == CriterionOneofCase.HotelCheckInDay) { + output.WriteRawTag(66); + output.WriteMessage(HotelCheckInDay); + } + if (baseAdGroup_ != null) { + _single_baseAdGroup_codec.WriteTagAndValue(output, BaseAdGroup); + } + if (BidModifierSource != 0) { + output.WriteRawTag(80); + output.WriteEnum((int) BidModifierSource); + } + if (criterionCase_ == CriterionOneofCase.Device) { + output.WriteRawTag(90); + output.WriteMessage(Device); + } + if (criterionCase_ == CriterionOneofCase.PreferredContent) { + output.WriteRawTag(98); + output.WriteMessage(PreferredContent); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (adGroup_ != null) { + size += _single_adGroup_codec.CalculateSizeWithTag(AdGroup); + } + if (criterionId_ != null) { + size += _single_criterionId_codec.CalculateSizeWithTag(CriterionId); + } + if (bidModifier_ != null) { + size += _single_bidModifier_codec.CalculateSizeWithTag(BidModifier); + } + if (baseAdGroup_ != null) { + size += _single_baseAdGroup_codec.CalculateSizeWithTag(BaseAdGroup); + } + if (BidModifierSource != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) BidModifierSource); + } + if (criterionCase_ == CriterionOneofCase.HotelDateSelectionType) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelDateSelectionType); + } + if (criterionCase_ == CriterionOneofCase.HotelAdvanceBookingWindow) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelAdvanceBookingWindow); + } + if (criterionCase_ == CriterionOneofCase.HotelLengthOfStay) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelLengthOfStay); + } + if (criterionCase_ == CriterionOneofCase.HotelCheckInDay) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelCheckInDay); + } + if (criterionCase_ == CriterionOneofCase.Device) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Device); + } + if (criterionCase_ == CriterionOneofCase.PreferredContent) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PreferredContent); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupBidModifier other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.adGroup_ != null) { + if (adGroup_ == null || other.AdGroup != "") { + AdGroup = other.AdGroup; + } + } + if (other.criterionId_ != null) { + if (criterionId_ == null || other.CriterionId != 0L) { + CriterionId = other.CriterionId; + } + } + if (other.bidModifier_ != null) { + if (bidModifier_ == null || other.BidModifier != 0D) { + BidModifier = other.BidModifier; + } + } + if (other.baseAdGroup_ != null) { + if (baseAdGroup_ == null || other.BaseAdGroup != "") { + BaseAdGroup = other.BaseAdGroup; + } + } + if (other.BidModifierSource != 0) { + BidModifierSource = other.BidModifierSource; + } + switch (other.CriterionCase) { + case CriterionOneofCase.HotelDateSelectionType: + if (HotelDateSelectionType == null) { + HotelDateSelectionType = new global::Google.Ads.GoogleAds.V3.Common.HotelDateSelectionTypeInfo(); + } + HotelDateSelectionType.MergeFrom(other.HotelDateSelectionType); + break; + case CriterionOneofCase.HotelAdvanceBookingWindow: + if (HotelAdvanceBookingWindow == null) { + HotelAdvanceBookingWindow = new global::Google.Ads.GoogleAds.V3.Common.HotelAdvanceBookingWindowInfo(); + } + HotelAdvanceBookingWindow.MergeFrom(other.HotelAdvanceBookingWindow); + break; + case CriterionOneofCase.HotelLengthOfStay: + if (HotelLengthOfStay == null) { + HotelLengthOfStay = new global::Google.Ads.GoogleAds.V3.Common.HotelLengthOfStayInfo(); + } + HotelLengthOfStay.MergeFrom(other.HotelLengthOfStay); + break; + case CriterionOneofCase.HotelCheckInDay: + if (HotelCheckInDay == null) { + HotelCheckInDay = new global::Google.Ads.GoogleAds.V3.Common.HotelCheckInDayInfo(); + } + HotelCheckInDay.MergeFrom(other.HotelCheckInDay); + break; + case CriterionOneofCase.Device: + if (Device == null) { + Device = new global::Google.Ads.GoogleAds.V3.Common.DeviceInfo(); + } + Device.MergeFrom(other.Device); + break; + case CriterionOneofCase.PreferredContent: + if (PreferredContent == null) { + PreferredContent = new global::Google.Ads.GoogleAds.V3.Common.PreferredContentInfo(); + } + PreferredContent.MergeFrom(other.PreferredContent); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_adGroup_codec.Read(input); + if (adGroup_ == null || value != "") { + AdGroup = value; + } + break; + } + case 26: { + long? value = _single_criterionId_codec.Read(input); + if (criterionId_ == null || value != 0L) { + CriterionId = value; + } + break; + } + case 34: { + double? value = _single_bidModifier_codec.Read(input); + if (bidModifier_ == null || value != 0D) { + BidModifier = value; + } + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Common.HotelDateSelectionTypeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelDateSelectionTypeInfo(); + if (criterionCase_ == CriterionOneofCase.HotelDateSelectionType) { + subBuilder.MergeFrom(HotelDateSelectionType); + } + input.ReadMessage(subBuilder); + HotelDateSelectionType = subBuilder; + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Common.HotelAdvanceBookingWindowInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelAdvanceBookingWindowInfo(); + if (criterionCase_ == CriterionOneofCase.HotelAdvanceBookingWindow) { + subBuilder.MergeFrom(HotelAdvanceBookingWindow); + } + input.ReadMessage(subBuilder); + HotelAdvanceBookingWindow = subBuilder; + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Common.HotelLengthOfStayInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelLengthOfStayInfo(); + if (criterionCase_ == CriterionOneofCase.HotelLengthOfStay) { + subBuilder.MergeFrom(HotelLengthOfStay); + } + input.ReadMessage(subBuilder); + HotelLengthOfStay = subBuilder; + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.HotelCheckInDayInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelCheckInDayInfo(); + if (criterionCase_ == CriterionOneofCase.HotelCheckInDay) { + subBuilder.MergeFrom(HotelCheckInDay); + } + input.ReadMessage(subBuilder); + HotelCheckInDay = subBuilder; + break; + } + case 74: { + string value = _single_baseAdGroup_codec.Read(input); + if (baseAdGroup_ == null || value != "") { + BaseAdGroup = value; + } + break; + } + case 80: { + BidModifierSource = (global::Google.Ads.GoogleAds.V3.Enums.BidModifierSourceEnum.Types.BidModifierSource) input.ReadEnum(); + break; + } + case 90: { + global::Google.Ads.GoogleAds.V3.Common.DeviceInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.DeviceInfo(); + if (criterionCase_ == CriterionOneofCase.Device) { + subBuilder.MergeFrom(Device); + } + input.ReadMessage(subBuilder); + Device = subBuilder; + break; + } + case 98: { + global::Google.Ads.GoogleAds.V3.Common.PreferredContentInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.PreferredContentInfo(); + if (criterionCase_ == CriterionOneofCase.PreferredContent) { + subBuilder.MergeFrom(PreferredContent); + } + input.ReadMessage(subBuilder); + PreferredContent = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupBidModifierError.cs b/src/V3/Stubs/AdGroupBidModifierError.cs new file mode 100644 index 000000000..a8ec76dec --- /dev/null +++ b/src/V3/Stubs/AdGroupBidModifierError.cs @@ -0,0 +1,188 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_group_bid_modifier_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_group_bid_modifier_error.proto + public static partial class AdGroupBidModifierErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_group_bid_modifier_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupBidModifierErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfZ3JvdXBfYmlk", + "X21vZGlmaWVyX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lcnJvcnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8itgEKG0Fk", + "R3JvdXBCaWRNb2RpZmllckVycm9yRW51bSKWAQoXQWRHcm91cEJpZE1vZGlm", + "aWVyRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESHgoaQ1JJ", + "VEVSSU9OX0lEX05PVF9TVVBQT1JURUQQAhI9CjlDQU5OT1RfT1ZFUlJJREVf", + "T1BURURfT1VUX0NBTVBBSUdOX0NSSVRFUklPTl9CSURfTU9ESUZJRVIQA0L3", + "AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IcQWRHcm91", + "cEJpZE1vZGlmaWVyRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9n", + "ZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vy", + "cm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oC", + "Hkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupBidModifierErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdGroupBidModifierErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupBidModifierErrorEnum.Types.AdGroupBidModifierError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad group bid modifier errors. + /// + public sealed partial class AdGroupBidModifierErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupBidModifierErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdGroupBidModifierErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifierErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifierErrorEnum(AdGroupBidModifierErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifierErrorEnum Clone() { + return new AdGroupBidModifierErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupBidModifierErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupBidModifierErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupBidModifierErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupBidModifierErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad group bid modifier errors. + /// + public enum AdGroupBidModifierError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The criterion ID does not support bid modification. + /// + [pbr::OriginalName("CRITERION_ID_NOT_SUPPORTED")] CriterionIdNotSupported = 2, + /// + /// Cannot override the bid modifier for the given criterion ID if the parent + /// campaign is opted out of the same criterion. + /// + [pbr::OriginalName("CANNOT_OVERRIDE_OPTED_OUT_CAMPAIGN_CRITERION_BID_MODIFIER")] CannotOverrideOptedOutCampaignCriterionBidModifier = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupBidModifierService.cs b/src/V3/Stubs/AdGroupBidModifierService.cs new file mode 100644 index 000000000..de38fb958 --- /dev/null +++ b/src/V3/Stubs/AdGroupBidModifierService.cs @@ -0,0 +1,1037 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_bid_modifier_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_bid_modifier_service.proto + public static partial class AdGroupBidModifierServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_bid_modifier_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupBidModifierServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9i", + "aWRfbW9kaWZpZXJfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMaPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcy9hZF9ncm91cF9iaWRfbW9kaWZpZXIucHJvdG8aHGdvb2dsZS9hcGkv", + "YW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9n", + "b29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9i", + "dWYvZmllbGRfbWFzay5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8i", + "OgocR2V0QWRHcm91cEJpZE1vZGlmaWVyUmVxdWVzdBIaCg1yZXNvdXJjZV9u", + "YW1lGAEgASgJQgPgQQIixAEKIE11dGF0ZUFkR3JvdXBCaWRNb2RpZmllcnNS", + "ZXF1ZXN0EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPgQQISVgoKb3BlcmF0aW9u", + "cxgCIAMoCzI9Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkFk", + "R3JvdXBCaWRNb2RpZmllck9wZXJhdGlvbkID4EECEhcKD3BhcnRpYWxfZmFp", + "bHVyZRgDIAEoCBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIv8BChtBZEdyb3Vw", + "QmlkTW9kaWZpZXJPcGVyYXRpb24SLwoLdXBkYXRlX21hc2sYBCABKAsyGi5n", + "b29nbGUucHJvdG9idWYuRmllbGRNYXNrEkcKBmNyZWF0ZRgBIAEoCzI1Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZEdyb3VwQmlkTW9k", + "aWZpZXJIABJHCgZ1cGRhdGUYAiABKAsyNS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXMuQWRHcm91cEJpZE1vZGlmaWVySAASEAoGcmVtb3Zl", + "GAMgASgJSABCCwoJb3BlcmF0aW9uIqkBCiFNdXRhdGVBZEdyb3VwQmlkTW9k", + "aWZpZXJzUmVzcG9uc2USMQoVcGFydGlhbF9mYWlsdXJlX2Vycm9yGAMgASgL", + "MhIuZ29vZ2xlLnJwYy5TdGF0dXMSUQoHcmVzdWx0cxgCIAMoCzJALmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBCaWRN", + "b2RpZmllclJlc3VsdCI3Ch5NdXRhdGVBZEdyb3VwQmlkTW9kaWZpZXJSZXN1", + "bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTKdBAoZQWRHcm91cEJpZE1vZGlm", + "aWVyU2VydmljZRLdAQoVR2V0QWRHcm91cEJpZE1vZGlmaWVyEj4uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR2V0QWRHcm91cEJpZE1vZGlm", + "aWVyUmVxdWVzdBo1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cy5BZEdyb3VwQmlkTW9kaWZpZXIiTYLT5JMCNxI1L3YzL3tyZXNvdXJjZV9u", + "YW1lPWN1c3RvbWVycy8qL2FkR3JvdXBCaWRNb2RpZmllcnMvKn3aQQ1yZXNv", + "dXJjZV9uYW1lEoICChlNdXRhdGVBZEdyb3VwQmlkTW9kaWZpZXJzEkIuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQWRHcm91cEJp", + "ZE1vZGlmaWVyc1JlcXVlc3QaQy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5NdXRhdGVBZEdyb3VwQmlkTW9kaWZpZXJzUmVzcG9uc2UiXILT", + "5JMCPSI4L3YzL2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn0vYWRHcm91cEJp", + "ZE1vZGlmaWVyczptdXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVyYXRpb25z", + "GhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21ChQIKJGNvbS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0IeQWRHcm91cEJpZE1vZGlmaWVy", + "U2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6IC", + "A0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifierReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupBidModifierRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupBidModifierRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifierResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifierResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupBidModifierService.GetAdGroupBidModifier][google.ads.googleads.v3.services.AdGroupBidModifierService.GetAdGroupBidModifier]. + /// + public sealed partial class GetAdGroupBidModifierRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupBidModifierRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupBidModifierRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupBidModifierRequest(GetAdGroupBidModifierRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupBidModifierRequest Clone() { + return new GetAdGroupBidModifierRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group bid modifier to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupBidModifierRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupBidModifierRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupBidModifierRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdGroupBidModifierService.MutateAdGroupBidModifiers][google.ads.googleads.v3.services.AdGroupBidModifierService.MutateAdGroupBidModifiers]. + /// + public sealed partial class MutateAdGroupBidModifiersRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupBidModifiersRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifiersRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifiersRequest(MutateAdGroupBidModifiersRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifiersRequest Clone() { + return new MutateAdGroupBidModifiersRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. ID of the customer whose ad group bid modifiers are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual ad group bid modifiers. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupBidModifiersRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupBidModifiersRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupBidModifiersRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove, update) on an ad group bid modifier. + /// + public sealed partial class AdGroupBidModifierOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupBidModifierOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifierOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifierOperation(AdGroupBidModifierOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupBidModifierOperation Clone() { + return new AdGroupBidModifierOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad group bid + /// modifier. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The ad group bid modifier is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed ad group bid modifier + /// is expected, in this format: + /// + /// `customers/{customer_id}/adGroupBidModifiers/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupBidModifierOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupBidModifierOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupBidModifierOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for ad group bid modifiers mutate. + /// + public sealed partial class MutateAdGroupBidModifiersResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupBidModifiersResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifiersResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifiersResponse(MutateAdGroupBidModifiersResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifiersResponse Clone() { + return new MutateAdGroupBidModifiersResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifierResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupBidModifiersResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupBidModifiersResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupBidModifiersResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the criterion mutate. + /// + public sealed partial class MutateAdGroupBidModifierResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupBidModifierResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifierResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifierResult(MutateAdGroupBidModifierResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupBidModifierResult Clone() { + return new MutateAdGroupBidModifierResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupBidModifierResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupBidModifierResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupBidModifierResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupBidModifierServiceClient.cs b/src/V3/Stubs/AdGroupBidModifierServiceClient.cs new file mode 100644 index 000000000..a86412de4 --- /dev/null +++ b/src/V3/Stubs/AdGroupBidModifierServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupBidModifierServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupBidModifierServiceSettings GetDefault() => new AdGroupBidModifierServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupBidModifierServiceSettings() { } + + private AdGroupBidModifierServiceSettings(AdGroupBidModifierServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupBidModifierSettings = existing.GetAdGroupBidModifierSettings; + MutateAdGroupBidModifiersSettings = existing.MutateAdGroupBidModifiersSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupBidModifierServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupBidModifierServiceClient.GetAdGroupBidModifier and AdGroupBidModifierServiceClient.GetAdGroupBidModifierAsync. + /// + /// + /// The default AdGroupBidModifierServiceClient.GetAdGroupBidModifier and + /// AdGroupBidModifierServiceClient.GetAdGroupBidModifierAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupBidModifierSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupBidModifierServiceClient.MutateAdGroupBidModifiers and AdGroupBidModifierServiceClient.MutateAdGroupBidModifiersAsync. + /// + /// + /// The default AdGroupBidModifierServiceClient.MutateAdGroupBidModifiers and + /// AdGroupBidModifierServiceClient.MutateAdGroupBidModifiersAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupBidModifiersSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupBidModifierServiceSettings Clone() => new AdGroupBidModifierServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupBidModifierServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupBidModifierServiceSettings Settings { get; set; } + + /// + public override AdGroupBidModifierServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupBidModifierServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupBidModifierServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupBidModifierServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupBidModifierServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupBidModifierServiceClient.ChannelPool; + } + + /// + /// AdGroupBidModifierService client wrapper, for convenient use. + /// + public abstract partial class AdGroupBidModifierServiceClient + { + /// + /// The default endpoint for the AdGroupBidModifierService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupBidModifierService scopes. + /// + /// + /// The default AdGroupBidModifierService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupBidModifierServiceClient client = await AdGroupBidModifierServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupBidModifierServiceClient.DefaultEndpoint.Host, AdGroupBidModifierServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupBidModifierServiceClient client = AdGroupBidModifierServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupBidModifierServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupBidModifierServiceClient client = AdGroupBidModifierServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupBidModifierServiceClient.DefaultEndpoint.Host, AdGroupBidModifierServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupBidModifierServiceClient client = AdGroupBidModifierServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupBidModifierServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupBidModifierServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupBidModifierServiceClient Create(grpccore::Channel channel, AdGroupBidModifierServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupBidModifierServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupBidModifierServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupBidModifierService.AdGroupBidModifierServiceClient grpcClient = new AdGroupBidModifierService.AdGroupBidModifierServiceClient(callInvoker); + return new AdGroupBidModifierServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupBidModifierService client. + /// + public virtual AdGroupBidModifierService.AdGroupBidModifierServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// + /// Required. The resource name of the ad group bid modifier to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupBidModifierAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupBidModifierAsync( + new GetAdGroupBidModifierRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// + /// Required. The resource name of the ad group bid modifier to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupBidModifierAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupBidModifierAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// + /// Required. The resource name of the ad group bid modifier to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupBidModifier GetAdGroupBidModifier( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupBidModifier( + new GetAdGroupBidModifierRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupBidModifierAsync( + GetAdGroupBidModifierRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupBidModifierAsync( + GetAdGroupBidModifierRequest request, + st::CancellationToken cancellationToken) => GetAdGroupBidModifierAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupBidModifier GetAdGroupBidModifier( + GetAdGroupBidModifierRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group bid modifiers. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupBidModifiersAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupBidModifiersAsync( + new MutateAdGroupBidModifiersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group bid modifiers. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupBidModifiersAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupBidModifiersAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group bid modifiers. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupBidModifiersResponse MutateAdGroupBidModifiers( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupBidModifiers( + new MutateAdGroupBidModifiersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group bid modifiers. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupBidModifiersAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupBidModifiersAsync( + new MutateAdGroupBidModifiersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group bid modifiers. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupBidModifiersAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupBidModifiersAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group bid modifiers. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupBidModifiersResponse MutateAdGroupBidModifiers( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupBidModifiers( + new MutateAdGroupBidModifiersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupBidModifiersAsync( + MutateAdGroupBidModifiersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupBidModifiersAsync( + MutateAdGroupBidModifiersRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupBidModifiersAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupBidModifiersResponse MutateAdGroupBidModifiers( + MutateAdGroupBidModifiersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupBidModifierService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupBidModifierServiceClientImpl : AdGroupBidModifierServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupBidModifier; + private readonly gaxgrpc::ApiCall _callMutateAdGroupBidModifiers; + + /// + /// Constructs a client wrapper for the AdGroupBidModifierService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupBidModifierServiceClientImpl(AdGroupBidModifierService.AdGroupBidModifierServiceClient grpcClient, AdGroupBidModifierServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupBidModifierServiceSettings effectiveSettings = settings ?? AdGroupBidModifierServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupBidModifier = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupBidModifierAsync, GrpcClient.GetAdGroupBidModifier, effectiveSettings.GetAdGroupBidModifierSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroupBidModifiers = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupBidModifiersAsync, GrpcClient.MutateAdGroupBidModifiers, effectiveSettings.MutateAdGroupBidModifiersSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroupBidModifier); + Modify_GetAdGroupBidModifierApiCall(ref _callGetAdGroupBidModifier); + Modify_ApiCall(ref _callMutateAdGroupBidModifiers); + Modify_MutateAdGroupBidModifiersApiCall(ref _callMutateAdGroupBidModifiers); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupBidModifierApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupBidModifiersApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupBidModifierService.AdGroupBidModifierServiceClient grpcClient, AdGroupBidModifierServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupBidModifierService client. + /// + public override AdGroupBidModifierService.AdGroupBidModifierServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupBidModifierRequest(ref GetAdGroupBidModifierRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupBidModifiersRequest(ref MutateAdGroupBidModifiersRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupBidModifierAsync( + GetAdGroupBidModifierRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupBidModifierRequest(ref request, ref callSettings); + return _callGetAdGroupBidModifier.Async(request, callSettings); + } + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupBidModifier GetAdGroupBidModifier( + GetAdGroupBidModifierRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupBidModifierRequest(ref request, ref callSettings); + return _callGetAdGroupBidModifier.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupBidModifiersAsync( + MutateAdGroupBidModifiersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupBidModifiersRequest(ref request, ref callSettings); + return _callMutateAdGroupBidModifiers.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupBidModifiersResponse MutateAdGroupBidModifiers( + MutateAdGroupBidModifiersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupBidModifiersRequest(ref request, ref callSettings); + return _callMutateAdGroupBidModifiers.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupBidModifierServiceGrpc.cs b/src/V3/Stubs/AdGroupBidModifierServiceGrpc.cs new file mode 100644 index 000000000..829e00024 --- /dev/null +++ b/src/V3/Stubs/AdGroupBidModifierServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_bid_modifier_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ad group bid modifiers. + /// + public static partial class AdGroupBidModifierService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupBidModifierService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupBidModifierRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupBidModifierRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupBidModifier = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupBidModifiersRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupBidModifiersResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupBidModifier = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupBidModifier", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupBidModifierRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupBidModifier); + + static readonly grpc::Method __Method_MutateAdGroupBidModifiers = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroupBidModifiers", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupBidModifiersRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupBidModifiersResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupBidModifierService + public abstract partial class AdGroupBidModifierServiceBase + { + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupBidModifier(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupBidModifierRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroupBidModifiers(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupBidModifierService + public partial class AdGroupBidModifierServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupBidModifierService + /// The channel to use to make remote calls. + public AdGroupBidModifierServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupBidModifierService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupBidModifierServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupBidModifierServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupBidModifierServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier GetAdGroupBidModifier(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupBidModifierRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupBidModifier(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier GetAdGroupBidModifier(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupBidModifierRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupBidModifier, null, options, request); + } + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupBidModifierAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupBidModifierRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupBidModifierAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group bid modifier in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupBidModifierAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupBidModifierRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupBidModifier, null, options, request); + } + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersResponse MutateAdGroupBidModifiers(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupBidModifiers(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersResponse MutateAdGroupBidModifiers(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroupBidModifiers, null, options, request); + } + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupBidModifiersAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupBidModifiersAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad group bid modifiers. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupBidModifiersAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifiersRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroupBidModifiers, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupBidModifierServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupBidModifierServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupBidModifierServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupBidModifier, serviceImpl.GetAdGroupBidModifier) + .AddMethod(__Method_MutateAdGroupBidModifiers, serviceImpl.MutateAdGroupBidModifiers).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupBidModifierServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupBidModifier, serviceImpl.GetAdGroupBidModifier); + serviceBinder.AddMethod(__Method_MutateAdGroupBidModifiers, serviceImpl.MutateAdGroupBidModifiers); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupCriterion.cs b/src/V3/Stubs/AdGroupCriterion.cs new file mode 100644 index 000000000..74a68ba6f --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterion.cs @@ -0,0 +1,2540 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_criterion.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_criterion.proto + public static partial class AdGroupCriterionReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_criterion.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "Y3JpdGVyaW9uLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNv", + "dXJjZXMaLWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9jcml0ZXJp", + "YS5wcm90bxo1Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL2N1c3Rv", + "bV9wYXJhbWV0ZXIucHJvdG8aRmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vu", + "dW1zL2FkX2dyb3VwX2NyaXRlcmlvbl9hcHByb3ZhbF9zdGF0dXMucHJvdG8a", + "PWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2FkX2dyb3VwX2NyaXRl", + "cmlvbl9zdGF0dXMucHJvdG8aMmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vu", + "dW1zL2JpZGRpbmdfc291cmNlLnByb3RvGkNnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9lbnVtcy9jcml0ZXJpb25fc3lzdGVtX3NlcnZpbmdfc3RhdHVzLnBy", + "b3RvGjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jcml0ZXJpb25f", + "dHlwZS5wcm90bxo4Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvcXVh", + "bGl0eV9zY29yZV9idWNrZXQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVo", + "YXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2ds", + "ZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0", + "aW9ucy5wcm90byKsIwoQQWRHcm91cENyaXRlcmlvbhJICg1yZXNvdXJjZV9u", + "YW1lGAEgASgJQjHgQQX6QSsKKWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9B", + "ZEdyb3VwQ3JpdGVyaW9uEjYKDGNyaXRlcmlvbl9pZBgaIAEoCzIbLmdvb2ds", + "ZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSYAoGc3RhdHVzGAMgASgOMlAu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQWRHcm91cENyaXRlcmlv", + "blN0YXR1c0VudW0uQWRHcm91cENyaXRlcmlvblN0YXR1cxJaCgxxdWFsaXR5", + "X2luZm8YBCABKAsyPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMuQWRHcm91cENyaXRlcmlvbi5RdWFsaXR5SW5mb0ID4EEDElgKCGFkX2dy", + "b3VwGAUgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQijgQQX6", + "QSIKIGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZEdyb3VwElEKBHR5cGUY", + "GSABKA4yPi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5Dcml0ZXJp", + "b25UeXBlRW51bS5Dcml0ZXJpb25UeXBlQgPgQQMSMQoIbmVnYXRpdmUYHyAB", + "KAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlQgPgQQUSgAEKFXN5c3Rl", + "bV9zZXJ2aW5nX3N0YXR1cxg0IAEoDjJcLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zLkNyaXRlcmlvblN5c3RlbVNlcnZpbmdTdGF0dXNFbnVtLkNy", + "aXRlcmlvblN5c3RlbVNlcnZpbmdTdGF0dXNCA+BBAxJ+Cg9hcHByb3ZhbF9z", + "dGF0dXMYNSABKA4yYC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5B", + "ZEdyb3VwQ3JpdGVyaW9uQXBwcm92YWxTdGF0dXNFbnVtLkFkR3JvdXBDcml0", + "ZXJpb25BcHByb3ZhbFN0YXR1c0ID4EEDEjIKDGJpZF9tb2RpZmllchgsIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5Eb3VibGVWYWx1ZRIzCg5jcGNfYmlkX21p", + "Y3JvcxgQIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlEjMKDmNw", + "bV9iaWRfbWljcm9zGBEgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFs", + "dWUSMwoOY3B2X2JpZF9taWNyb3MYGCABKAsyGy5nb29nbGUucHJvdG9idWYu", + "SW50NjRWYWx1ZRI7ChZwZXJjZW50X2NwY19iaWRfbWljcm9zGCEgASgLMhsu", + "Z29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUSQgoYZWZmZWN0aXZlX2NwY19i", + "aWRfbWljcm9zGBIgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWVC", + "A+BBAxJCChhlZmZlY3RpdmVfY3BtX2JpZF9taWNyb3MYEyABKAsyGy5nb29n", + "bGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEkIKGGVmZmVjdGl2ZV9jcHZf", + "YmlkX21pY3JvcxgUIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVl", + "QgPgQQMSSgogZWZmZWN0aXZlX3BlcmNlbnRfY3BjX2JpZF9taWNyb3MYIiAB", + "KAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEmUKGGVmZmVj", + "dGl2ZV9jcGNfYmlkX3NvdXJjZRgVIAEoDjI+Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zLkJpZGRpbmdTb3VyY2VFbnVtLkJpZGRpbmdTb3VyY2VC", + "A+BBAxJlChhlZmZlY3RpdmVfY3BtX2JpZF9zb3VyY2UYFiABKA4yPi5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5CaWRkaW5nU291cmNlRW51bS5C", + "aWRkaW5nU291cmNlQgPgQQMSZQoYZWZmZWN0aXZlX2Nwdl9iaWRfc291cmNl", + "GBcgASgOMj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQmlkZGlu", + "Z1NvdXJjZUVudW0uQmlkZGluZ1NvdXJjZUID4EEDEm0KIGVmZmVjdGl2ZV9w", + "ZXJjZW50X2NwY19iaWRfc291cmNlGCMgASgOMj4uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXMuQmlkZGluZ1NvdXJjZUVudW0uQmlkZGluZ1NvdXJj", + "ZUID4EEDEmYKEnBvc2l0aW9uX2VzdGltYXRlcxgKIAEoCzJFLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZEdyb3VwQ3JpdGVyaW9uLlBv", + "c2l0aW9uRXN0aW1hdGVzQgPgQQMSMAoKZmluYWxfdXJscxgLIAMoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI3ChFmaW5hbF9tb2JpbGVfdXJs", + "cxgzIAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI2ChBmaW5h", + "bF91cmxfc3VmZml4GDIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1Zh", + "bHVlEjsKFXRyYWNraW5nX3VybF90ZW1wbGF0ZRgNIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZRJOChV1cmxfY3VzdG9tX3BhcmFtZXRlcnMY", + "DiADKAsyLy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQ3VzdG9t", + "UGFyYW1ldGVyEkMKB2tleXdvcmQYGyABKAsyKy5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5jb21tb24uS2V5d29yZEluZm9CA+BBBUgAEkcKCXBsYWNlbWVu", + "dBgcIAEoCzItLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5QbGFj", + "ZW1lbnRJbmZvQgPgQQVIABJZChNtb2JpbGVfYXBwX2NhdGVnb3J5GB0gASgL", + "MjUuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLk1vYmlsZUFwcENh", + "dGVnb3J5SW5mb0ID4EEFSAASWAoSbW9iaWxlX2FwcGxpY2F0aW9uGB4gASgL", + "MjUuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLk1vYmlsZUFwcGxp", + "Y2F0aW9uSW5mb0ID4EEFSAASTgoNbGlzdGluZ19ncm91cBggIAEoCzIwLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5MaXN0aW5nR3JvdXBJbmZv", + "QgPgQQVIABJGCglhZ2VfcmFuZ2UYJCABKAsyLC5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5jb21tb24uQWdlUmFuZ2VJbmZvQgPgQQVIABJBCgZnZW5kZXIY", + "JSABKAsyKi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uR2VuZGVy", + "SW5mb0ID4EEFSAASTAoMaW5jb21lX3JhbmdlGCYgASgLMi8uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuY29tbW9uLkluY29tZVJhbmdlSW5mb0ID4EEFSAAS", + "UgoPcGFyZW50YWxfc3RhdHVzGCcgASgLMjIuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuY29tbW9uLlBhcmVudGFsU3RhdHVzSW5mb0ID4EEFSAASRgoJdXNl", + "cl9saXN0GCogASgLMiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9u", + "LlVzZXJMaXN0SW5mb0ID4EEFSAASTgoNeW91dHViZV92aWRlbxgoIAEoCzIw", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Zb3VUdWJlVmlkZW9J", + "bmZvQgPgQQVIABJSCg95b3V0dWJlX2NoYW5uZWwYKSABKAsyMi5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5jb21tb24uWW91VHViZUNoYW5uZWxJbmZvQgPg", + "QQVIABI/CgV0b3BpYxgrIAEoCzIpLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmNvbW1vbi5Ub3BpY0luZm9CA+BBBUgAEk4KDXVzZXJfaW50ZXJlc3QYLSAB", + "KAsyMC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uVXNlckludGVy", + "ZXN0SW5mb0ID4EEFSAASQwoHd2VicGFnZRguIAEoCzIrLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmNvbW1vbi5XZWJwYWdlSW5mb0ID4EEFSAASVQoRYXBw", + "X3BheW1lbnRfbW9kZWwYLyABKAsyMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5jb21tb24uQXBwUGF5bWVudE1vZGVsSW5mb0ID4EEFSAASUgoPY3VzdG9t", + "X2FmZmluaXR5GDAgASgLMjIuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29t", + "bW9uLkN1c3RvbUFmZmluaXR5SW5mb0ID4EEFSAASTgoNY3VzdG9tX2ludGVu", + "dBgxIAEoCzIwLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5DdXN0", + "b21JbnRlbnRJbmZvQgPgQQVIABqTAwoLUXVhbGl0eUluZm8SNwoNcXVhbGl0", + "eV9zY29yZRgBIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQzMlZhbHVlQgPg", + "QQMSbQoWY3JlYXRpdmVfcXVhbGl0eV9zY29yZRgCIAEoDjJILmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVudW1zLlF1YWxpdHlTY29yZUJ1Y2tldEVudW0u", + "UXVhbGl0eVNjb3JlQnVja2V0QgPgQQMSbwoYcG9zdF9jbGlja19xdWFsaXR5", + "X3Njb3JlGAMgASgOMkguZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMu", + "UXVhbGl0eVNjb3JlQnVja2V0RW51bS5RdWFsaXR5U2NvcmVCdWNrZXRCA+BB", + "AxJrChRzZWFyY2hfcHJlZGljdGVkX2N0chgEIAEoDjJILmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zLlF1YWxpdHlTY29yZUJ1Y2tldEVudW0uUXVh", + "bGl0eVNjb3JlQnVja2V0QgPgQQMahQMKEVBvc2l0aW9uRXN0aW1hdGVzEj8K", + "FWZpcnN0X3BhZ2VfY3BjX21pY3JvcxgBIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQ2NFZhbHVlQgPgQQMSQwoZZmlyc3RfcG9zaXRpb25fY3BjX21pY3Jv", + "cxgCIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSQAoW", + "dG9wX29mX3BhZ2VfY3BjX21pY3JvcxgDIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQ2NFZhbHVlQgPgQQMSVAoqZXN0aW1hdGVkX2FkZF9jbGlja3NfYXRf", + "Zmlyc3RfcG9zaXRpb25fY3BjGAQgASgLMhsuZ29vZ2xlLnByb3RvYnVmLklu", + "dDY0VmFsdWVCA+BBAxJSCihlc3RpbWF0ZWRfYWRkX2Nvc3RfYXRfZmlyc3Rf", + "cG9zaXRpb25fY3BjGAUgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFs", + "dWVCA+BBAzpp6kFmCilnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91", + "cENyaXRlcmlvbhI5Y3VzdG9tZXJzL3tjdXN0b21lcn0vYWRHcm91cENyaXRl", + "cmlhL3thZF9ncm91cF9jcml0ZXJpb259QgsKCWNyaXRlcmlvbkKCAgolY29t", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IVQWRHcm91cENy", + "aXRlcmlvblByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2Vz", + "ogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIh", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.CustomParameterReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionApprovalStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CriterionSystemServingStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion), global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Parser, new[]{ "ResourceName", "CriterionId", "Status", "QualityInfo", "AdGroup", "Type", "Negative", "SystemServingStatus", "ApprovalStatus", "BidModifier", "CpcBidMicros", "CpmBidMicros", "CpvBidMicros", "PercentCpcBidMicros", "EffectiveCpcBidMicros", "EffectiveCpmBidMicros", "EffectiveCpvBidMicros", "EffectivePercentCpcBidMicros", "EffectiveCpcBidSource", "EffectiveCpmBidSource", "EffectiveCpvBidSource", "EffectivePercentCpcBidSource", "PositionEstimates", "FinalUrls", "FinalMobileUrls", "FinalUrlSuffix", "TrackingUrlTemplate", "UrlCustomParameters", "Keyword", "Placement", "MobileAppCategory", "MobileApplication", "ListingGroup", "AgeRange", "Gender", "IncomeRange", "ParentalStatus", "UserList", "YoutubeVideo", "YoutubeChannel", "Topic", "UserInterest", "Webpage", "AppPaymentModel", "CustomAffinity", "CustomIntent" }, new[]{ "Criterion" }, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.QualityInfo), global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.QualityInfo.Parser, new[]{ "QualityScore", "CreativeQualityScore", "PostClickQualityScore", "SearchPredictedCtr" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.PositionEstimates), global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.PositionEstimates.Parser, new[]{ "FirstPageCpcMicros", "FirstPositionCpcMicros", "TopOfPageCpcMicros", "EstimatedAddClicksAtFirstPositionCpc", "EstimatedAddCostAtFirstPositionCpc" }, null, null, null)}) + })); + } + #endregion + + } + #region Messages + /// + /// An ad group criterion. + /// + public sealed partial class AdGroupCriterion : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupCriterion()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterion() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterion(AdGroupCriterion other) : this() { + resourceName_ = other.resourceName_; + CriterionId = other.CriterionId; + status_ = other.status_; + qualityInfo_ = other.qualityInfo_ != null ? other.qualityInfo_.Clone() : null; + AdGroup = other.AdGroup; + type_ = other.type_; + Negative = other.Negative; + systemServingStatus_ = other.systemServingStatus_; + approvalStatus_ = other.approvalStatus_; + BidModifier = other.BidModifier; + CpcBidMicros = other.CpcBidMicros; + CpmBidMicros = other.CpmBidMicros; + CpvBidMicros = other.CpvBidMicros; + PercentCpcBidMicros = other.PercentCpcBidMicros; + EffectiveCpcBidMicros = other.EffectiveCpcBidMicros; + EffectiveCpmBidMicros = other.EffectiveCpmBidMicros; + EffectiveCpvBidMicros = other.EffectiveCpvBidMicros; + EffectivePercentCpcBidMicros = other.EffectivePercentCpcBidMicros; + effectiveCpcBidSource_ = other.effectiveCpcBidSource_; + effectiveCpmBidSource_ = other.effectiveCpmBidSource_; + effectiveCpvBidSource_ = other.effectiveCpvBidSource_; + effectivePercentCpcBidSource_ = other.effectivePercentCpcBidSource_; + positionEstimates_ = other.positionEstimates_ != null ? other.positionEstimates_.Clone() : null; + finalUrls_ = other.finalUrls_.Clone(); + finalMobileUrls_ = other.finalMobileUrls_.Clone(); + FinalUrlSuffix = other.FinalUrlSuffix; + TrackingUrlTemplate = other.TrackingUrlTemplate; + urlCustomParameters_ = other.urlCustomParameters_.Clone(); + switch (other.CriterionCase) { + case CriterionOneofCase.Keyword: + Keyword = other.Keyword.Clone(); + break; + case CriterionOneofCase.Placement: + Placement = other.Placement.Clone(); + break; + case CriterionOneofCase.MobileAppCategory: + MobileAppCategory = other.MobileAppCategory.Clone(); + break; + case CriterionOneofCase.MobileApplication: + MobileApplication = other.MobileApplication.Clone(); + break; + case CriterionOneofCase.ListingGroup: + ListingGroup = other.ListingGroup.Clone(); + break; + case CriterionOneofCase.AgeRange: + AgeRange = other.AgeRange.Clone(); + break; + case CriterionOneofCase.Gender: + Gender = other.Gender.Clone(); + break; + case CriterionOneofCase.IncomeRange: + IncomeRange = other.IncomeRange.Clone(); + break; + case CriterionOneofCase.ParentalStatus: + ParentalStatus = other.ParentalStatus.Clone(); + break; + case CriterionOneofCase.UserList: + UserList = other.UserList.Clone(); + break; + case CriterionOneofCase.YoutubeVideo: + YoutubeVideo = other.YoutubeVideo.Clone(); + break; + case CriterionOneofCase.YoutubeChannel: + YoutubeChannel = other.YoutubeChannel.Clone(); + break; + case CriterionOneofCase.Topic: + Topic = other.Topic.Clone(); + break; + case CriterionOneofCase.UserInterest: + UserInterest = other.UserInterest.Clone(); + break; + case CriterionOneofCase.Webpage: + Webpage = other.Webpage.Clone(); + break; + case CriterionOneofCase.AppPaymentModel: + AppPaymentModel = other.AppPaymentModel.Clone(); + break; + case CriterionOneofCase.CustomAffinity: + CustomAffinity = other.CustomAffinity.Clone(); + break; + case CriterionOneofCase.CustomIntent: + CustomIntent = other.CustomIntent.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterion Clone() { + return new AdGroupCriterion(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group criterion. + /// Ad group criterion resource names have the form: + /// + /// `customers/{customer_id}/adGroupCriteria/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "criterion_id" field. + public const int CriterionIdFieldNumber = 26; + private static readonly pb::FieldCodec _single_criterionId_codec = pb::FieldCodec.ForStructWrapper(210); + private long? criterionId_; + /// + /// Output only. The ID of the criterion. + /// + /// This field is ignored for mutates. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CriterionId { + get { return criterionId_; } + set { + criterionId_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types.AdGroupCriterionStatus status_ = 0; + /// + /// The status of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types.AdGroupCriterionStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "quality_info" field. + public const int QualityInfoFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.QualityInfo qualityInfo_; + /// + /// Output only. Information regarding the quality of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.QualityInfo QualityInfo { + get { return qualityInfo_; } + set { + qualityInfo_ = value; + } + } + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 5; + private static readonly pb::FieldCodec _single_adGroup_codec = pb::FieldCodec.ForClassWrapper(42); + private string adGroup_; + /// + /// Immutable. The ad group to which the criterion belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroup { + get { return adGroup_; } + set { + adGroup_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 25; + private global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType type_ = 0; + /// + /// Output only. The type of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "negative" field. + public const int NegativeFieldNumber = 31; + private static readonly pb::FieldCodec _single_negative_codec = pb::FieldCodec.ForStructWrapper(250); + private bool? negative_; + /// + /// Immutable. Whether to target (`false`) or exclude (`true`) the criterion. + /// + /// This field is immutable. To switch a criterion from positive to negative, + /// remove then re-add it. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Negative { + get { return negative_; } + set { + negative_ = value; + } + } + + + /// Field number for the "system_serving_status" field. + public const int SystemServingStatusFieldNumber = 52; + private global::Google.Ads.GoogleAds.V3.Enums.CriterionSystemServingStatusEnum.Types.CriterionSystemServingStatus systemServingStatus_ = 0; + /// + /// Output only. Serving status of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CriterionSystemServingStatusEnum.Types.CriterionSystemServingStatus SystemServingStatus { + get { return systemServingStatus_; } + set { + systemServingStatus_ = value; + } + } + + /// Field number for the "approval_status" field. + public const int ApprovalStatusFieldNumber = 53; + private global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionApprovalStatusEnum.Types.AdGroupCriterionApprovalStatus approvalStatus_ = 0; + /// + /// Output only. Approval status of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionApprovalStatusEnum.Types.AdGroupCriterionApprovalStatus ApprovalStatus { + get { return approvalStatus_; } + set { + approvalStatus_ = value; + } + } + + /// Field number for the "bid_modifier" field. + public const int BidModifierFieldNumber = 44; + private static readonly pb::FieldCodec _single_bidModifier_codec = pb::FieldCodec.ForStructWrapper(354); + private double? bidModifier_; + /// + /// The modifier for the bid when the criterion matches. The modifier must be + /// in the range: 0.1 - 10.0. Most targetable criteria types support modifiers. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? BidModifier { + get { return bidModifier_; } + set { + bidModifier_ = value; + } + } + + + /// Field number for the "cpc_bid_micros" field. + public const int CpcBidMicrosFieldNumber = 16; + private static readonly pb::FieldCodec _single_cpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(130); + private long? cpcBidMicros_; + /// + /// The CPC (cost-per-click) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidMicros { + get { return cpcBidMicros_; } + set { + cpcBidMicros_ = value; + } + } + + + /// Field number for the "cpm_bid_micros" field. + public const int CpmBidMicrosFieldNumber = 17; + private static readonly pb::FieldCodec _single_cpmBidMicros_codec = pb::FieldCodec.ForStructWrapper(138); + private long? cpmBidMicros_; + /// + /// The CPM (cost-per-thousand viewable impressions) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpmBidMicros { + get { return cpmBidMicros_; } + set { + cpmBidMicros_ = value; + } + } + + + /// Field number for the "cpv_bid_micros" field. + public const int CpvBidMicrosFieldNumber = 24; + private static readonly pb::FieldCodec _single_cpvBidMicros_codec = pb::FieldCodec.ForStructWrapper(194); + private long? cpvBidMicros_; + /// + /// The CPV (cost-per-view) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpvBidMicros { + get { return cpvBidMicros_; } + set { + cpvBidMicros_ = value; + } + } + + + /// Field number for the "percent_cpc_bid_micros" field. + public const int PercentCpcBidMicrosFieldNumber = 33; + private static readonly pb::FieldCodec _single_percentCpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(266); + private long? percentCpcBidMicros_; + /// + /// The CPC bid amount, expressed as a fraction of the advertised price + /// for some good or service. The valid range for the fraction is [0,1) and the + /// value stored here is 1,000,000 * [fraction]. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PercentCpcBidMicros { + get { return percentCpcBidMicros_; } + set { + percentCpcBidMicros_ = value; + } + } + + + /// Field number for the "effective_cpc_bid_micros" field. + public const int EffectiveCpcBidMicrosFieldNumber = 18; + private static readonly pb::FieldCodec _single_effectiveCpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(146); + private long? effectiveCpcBidMicros_; + /// + /// Output only. The effective CPC (cost-per-click) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? EffectiveCpcBidMicros { + get { return effectiveCpcBidMicros_; } + set { + effectiveCpcBidMicros_ = value; + } + } + + + /// Field number for the "effective_cpm_bid_micros" field. + public const int EffectiveCpmBidMicrosFieldNumber = 19; + private static readonly pb::FieldCodec _single_effectiveCpmBidMicros_codec = pb::FieldCodec.ForStructWrapper(154); + private long? effectiveCpmBidMicros_; + /// + /// Output only. The effective CPM (cost-per-thousand viewable impressions) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? EffectiveCpmBidMicros { + get { return effectiveCpmBidMicros_; } + set { + effectiveCpmBidMicros_ = value; + } + } + + + /// Field number for the "effective_cpv_bid_micros" field. + public const int EffectiveCpvBidMicrosFieldNumber = 20; + private static readonly pb::FieldCodec _single_effectiveCpvBidMicros_codec = pb::FieldCodec.ForStructWrapper(162); + private long? effectiveCpvBidMicros_; + /// + /// Output only. The effective CPV (cost-per-view) bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? EffectiveCpvBidMicros { + get { return effectiveCpvBidMicros_; } + set { + effectiveCpvBidMicros_ = value; + } + } + + + /// Field number for the "effective_percent_cpc_bid_micros" field. + public const int EffectivePercentCpcBidMicrosFieldNumber = 34; + private static readonly pb::FieldCodec _single_effectivePercentCpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(274); + private long? effectivePercentCpcBidMicros_; + /// + /// Output only. The effective Percent CPC bid amount. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? EffectivePercentCpcBidMicros { + get { return effectivePercentCpcBidMicros_; } + set { + effectivePercentCpcBidMicros_ = value; + } + } + + + /// Field number for the "effective_cpc_bid_source" field. + public const int EffectiveCpcBidSourceFieldNumber = 21; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource effectiveCpcBidSource_ = 0; + /// + /// Output only. Source of the effective CPC bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource EffectiveCpcBidSource { + get { return effectiveCpcBidSource_; } + set { + effectiveCpcBidSource_ = value; + } + } + + /// Field number for the "effective_cpm_bid_source" field. + public const int EffectiveCpmBidSourceFieldNumber = 22; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource effectiveCpmBidSource_ = 0; + /// + /// Output only. Source of the effective CPM bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource EffectiveCpmBidSource { + get { return effectiveCpmBidSource_; } + set { + effectiveCpmBidSource_ = value; + } + } + + /// Field number for the "effective_cpv_bid_source" field. + public const int EffectiveCpvBidSourceFieldNumber = 23; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource effectiveCpvBidSource_ = 0; + /// + /// Output only. Source of the effective CPV bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource EffectiveCpvBidSource { + get { return effectiveCpvBidSource_; } + set { + effectiveCpvBidSource_ = value; + } + } + + /// Field number for the "effective_percent_cpc_bid_source" field. + public const int EffectivePercentCpcBidSourceFieldNumber = 35; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource effectivePercentCpcBidSource_ = 0; + /// + /// Output only. Source of the effective Percent CPC bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource EffectivePercentCpcBidSource { + get { return effectivePercentCpcBidSource_; } + set { + effectivePercentCpcBidSource_ = value; + } + } + + /// Field number for the "position_estimates" field. + public const int PositionEstimatesFieldNumber = 10; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.PositionEstimates positionEstimates_; + /// + /// Output only. Estimates for criterion bids at various positions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.PositionEstimates PositionEstimates { + get { return positionEstimates_; } + set { + positionEstimates_ = value; + } + } + + /// Field number for the "final_urls" field. + public const int FinalUrlsFieldNumber = 11; + private static readonly pb::FieldCodec _repeated_finalUrls_codec + = pb::FieldCodec.ForClassWrapper(90); + private readonly pbc::RepeatedField finalUrls_ = new pbc::RepeatedField(); + /// + /// The list of possible final URLs after all cross-domain redirects for the + /// ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalUrls { + get { return finalUrls_; } + } + + /// Field number for the "final_mobile_urls" field. + public const int FinalMobileUrlsFieldNumber = 51; + private static readonly pb::FieldCodec _repeated_finalMobileUrls_codec + = pb::FieldCodec.ForClassWrapper(410); + private readonly pbc::RepeatedField finalMobileUrls_ = new pbc::RepeatedField(); + /// + /// The list of possible final mobile URLs after all cross-domain redirects. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalMobileUrls { + get { return finalMobileUrls_; } + } + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 50; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(402); + private string finalUrlSuffix_; + /// + /// URL template for appending params to final URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 13; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(106); + private string trackingUrlTemplate_; + /// + /// The URL template for constructing a tracking URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "url_custom_parameters" field. + public const int UrlCustomParametersFieldNumber = 14; + private static readonly pb::FieldCodec _repeated_urlCustomParameters_codec + = pb::FieldCodec.ForMessage(114, global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser); + private readonly pbc::RepeatedField urlCustomParameters_ = new pbc::RepeatedField(); + /// + /// The list of mappings used to substitute custom parameter tags in a + /// `tracking_url_template`, `final_urls`, or `mobile_final_urls`. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCustomParameters { + get { return urlCustomParameters_; } + } + + /// Field number for the "keyword" field. + public const int KeywordFieldNumber = 27; + /// + /// Immutable. Keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.KeywordInfo Keyword { + get { return criterionCase_ == CriterionOneofCase.Keyword ? (global::Google.Ads.GoogleAds.V3.Common.KeywordInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Keyword; + } + } + + /// Field number for the "placement" field. + public const int PlacementFieldNumber = 28; + /// + /// Immutable. Placement. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PlacementInfo Placement { + get { return criterionCase_ == CriterionOneofCase.Placement ? (global::Google.Ads.GoogleAds.V3.Common.PlacementInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Placement; + } + } + + /// Field number for the "mobile_app_category" field. + public const int MobileAppCategoryFieldNumber = 29; + /// + /// Immutable. Mobile app category. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo MobileAppCategory { + get { return criterionCase_ == CriterionOneofCase.MobileAppCategory ? (global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.MobileAppCategory; + } + } + + /// Field number for the "mobile_application" field. + public const int MobileApplicationFieldNumber = 30; + /// + /// Immutable. Mobile application. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo MobileApplication { + get { return criterionCase_ == CriterionOneofCase.MobileApplication ? (global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.MobileApplication; + } + } + + /// Field number for the "listing_group" field. + public const int ListingGroupFieldNumber = 32; + /// + /// Immutable. Listing group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ListingGroupInfo ListingGroup { + get { return criterionCase_ == CriterionOneofCase.ListingGroup ? (global::Google.Ads.GoogleAds.V3.Common.ListingGroupInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.ListingGroup; + } + } + + /// Field number for the "age_range" field. + public const int AgeRangeFieldNumber = 36; + /// + /// Immutable. Age range. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo AgeRange { + get { return criterionCase_ == CriterionOneofCase.AgeRange ? (global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.AgeRange; + } + } + + /// Field number for the "gender" field. + public const int GenderFieldNumber = 37; + /// + /// Immutable. Gender. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.GenderInfo Gender { + get { return criterionCase_ == CriterionOneofCase.Gender ? (global::Google.Ads.GoogleAds.V3.Common.GenderInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Gender; + } + } + + /// Field number for the "income_range" field. + public const int IncomeRangeFieldNumber = 38; + /// + /// Immutable. Income range. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo IncomeRange { + get { return criterionCase_ == CriterionOneofCase.IncomeRange ? (global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.IncomeRange; + } + } + + /// Field number for the "parental_status" field. + public const int ParentalStatusFieldNumber = 39; + /// + /// Immutable. Parental status. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo ParentalStatus { + get { return criterionCase_ == CriterionOneofCase.ParentalStatus ? (global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.ParentalStatus; + } + } + + /// Field number for the "user_list" field. + public const int UserListFieldNumber = 42; + /// + /// Immutable. User List. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.UserListInfo UserList { + get { return criterionCase_ == CriterionOneofCase.UserList ? (global::Google.Ads.GoogleAds.V3.Common.UserListInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.UserList; + } + } + + /// Field number for the "youtube_video" field. + public const int YoutubeVideoFieldNumber = 40; + /// + /// Immutable. YouTube Video. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo YoutubeVideo { + get { return criterionCase_ == CriterionOneofCase.YoutubeVideo ? (global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.YoutubeVideo; + } + } + + /// Field number for the "youtube_channel" field. + public const int YoutubeChannelFieldNumber = 41; + /// + /// Immutable. YouTube Channel. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo YoutubeChannel { + get { return criterionCase_ == CriterionOneofCase.YoutubeChannel ? (global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.YoutubeChannel; + } + } + + /// Field number for the "topic" field. + public const int TopicFieldNumber = 43; + /// + /// Immutable. Topic. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TopicInfo Topic { + get { return criterionCase_ == CriterionOneofCase.Topic ? (global::Google.Ads.GoogleAds.V3.Common.TopicInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Topic; + } + } + + /// Field number for the "user_interest" field. + public const int UserInterestFieldNumber = 45; + /// + /// Immutable. User Interest. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo UserInterest { + get { return criterionCase_ == CriterionOneofCase.UserInterest ? (global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.UserInterest; + } + } + + /// Field number for the "webpage" field. + public const int WebpageFieldNumber = 46; + /// + /// Immutable. Webpage + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.WebpageInfo Webpage { + get { return criterionCase_ == CriterionOneofCase.Webpage ? (global::Google.Ads.GoogleAds.V3.Common.WebpageInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Webpage; + } + } + + /// Field number for the "app_payment_model" field. + public const int AppPaymentModelFieldNumber = 47; + /// + /// Immutable. App Payment Model. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AppPaymentModelInfo AppPaymentModel { + get { return criterionCase_ == CriterionOneofCase.AppPaymentModel ? (global::Google.Ads.GoogleAds.V3.Common.AppPaymentModelInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.AppPaymentModel; + } + } + + /// Field number for the "custom_affinity" field. + public const int CustomAffinityFieldNumber = 48; + /// + /// Immutable. Custom Affinity. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo CustomAffinity { + get { return criterionCase_ == CriterionOneofCase.CustomAffinity ? (global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.CustomAffinity; + } + } + + /// Field number for the "custom_intent" field. + public const int CustomIntentFieldNumber = 49; + /// + /// Immutable. Custom Intent. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CustomIntentInfo CustomIntent { + get { return criterionCase_ == CriterionOneofCase.CustomIntent ? (global::Google.Ads.GoogleAds.V3.Common.CustomIntentInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.CustomIntent; + } + } + + private object criterion_; + /// Enum of possible cases for the "criterion" oneof. + public enum CriterionOneofCase { + None = 0, + Keyword = 27, + Placement = 28, + MobileAppCategory = 29, + MobileApplication = 30, + ListingGroup = 32, + AgeRange = 36, + Gender = 37, + IncomeRange = 38, + ParentalStatus = 39, + UserList = 42, + YoutubeVideo = 40, + YoutubeChannel = 41, + Topic = 43, + UserInterest = 45, + Webpage = 46, + AppPaymentModel = 47, + CustomAffinity = 48, + CustomIntent = 49, + } + private CriterionOneofCase criterionCase_ = CriterionOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionOneofCase CriterionCase { + get { return criterionCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearCriterion() { + criterionCase_ = CriterionOneofCase.None; + criterion_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupCriterion); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupCriterion other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (CriterionId != other.CriterionId) return false; + if (Status != other.Status) return false; + if (!object.Equals(QualityInfo, other.QualityInfo)) return false; + if (AdGroup != other.AdGroup) return false; + if (Type != other.Type) return false; + if (Negative != other.Negative) return false; + if (SystemServingStatus != other.SystemServingStatus) return false; + if (ApprovalStatus != other.ApprovalStatus) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(BidModifier, other.BidModifier)) return false; + if (CpcBidMicros != other.CpcBidMicros) return false; + if (CpmBidMicros != other.CpmBidMicros) return false; + if (CpvBidMicros != other.CpvBidMicros) return false; + if (PercentCpcBidMicros != other.PercentCpcBidMicros) return false; + if (EffectiveCpcBidMicros != other.EffectiveCpcBidMicros) return false; + if (EffectiveCpmBidMicros != other.EffectiveCpmBidMicros) return false; + if (EffectiveCpvBidMicros != other.EffectiveCpvBidMicros) return false; + if (EffectivePercentCpcBidMicros != other.EffectivePercentCpcBidMicros) return false; + if (EffectiveCpcBidSource != other.EffectiveCpcBidSource) return false; + if (EffectiveCpmBidSource != other.EffectiveCpmBidSource) return false; + if (EffectiveCpvBidSource != other.EffectiveCpvBidSource) return false; + if (EffectivePercentCpcBidSource != other.EffectivePercentCpcBidSource) return false; + if (!object.Equals(PositionEstimates, other.PositionEstimates)) return false; + if(!finalUrls_.Equals(other.finalUrls_)) return false; + if(!finalMobileUrls_.Equals(other.finalMobileUrls_)) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if(!urlCustomParameters_.Equals(other.urlCustomParameters_)) return false; + if (!object.Equals(Keyword, other.Keyword)) return false; + if (!object.Equals(Placement, other.Placement)) return false; + if (!object.Equals(MobileAppCategory, other.MobileAppCategory)) return false; + if (!object.Equals(MobileApplication, other.MobileApplication)) return false; + if (!object.Equals(ListingGroup, other.ListingGroup)) return false; + if (!object.Equals(AgeRange, other.AgeRange)) return false; + if (!object.Equals(Gender, other.Gender)) return false; + if (!object.Equals(IncomeRange, other.IncomeRange)) return false; + if (!object.Equals(ParentalStatus, other.ParentalStatus)) return false; + if (!object.Equals(UserList, other.UserList)) return false; + if (!object.Equals(YoutubeVideo, other.YoutubeVideo)) return false; + if (!object.Equals(YoutubeChannel, other.YoutubeChannel)) return false; + if (!object.Equals(Topic, other.Topic)) return false; + if (!object.Equals(UserInterest, other.UserInterest)) return false; + if (!object.Equals(Webpage, other.Webpage)) return false; + if (!object.Equals(AppPaymentModel, other.AppPaymentModel)) return false; + if (!object.Equals(CustomAffinity, other.CustomAffinity)) return false; + if (!object.Equals(CustomIntent, other.CustomIntent)) return false; + if (CriterionCase != other.CriterionCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (criterionId_ != null) hash ^= CriterionId.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (qualityInfo_ != null) hash ^= QualityInfo.GetHashCode(); + if (adGroup_ != null) hash ^= AdGroup.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (negative_ != null) hash ^= Negative.GetHashCode(); + if (SystemServingStatus != 0) hash ^= SystemServingStatus.GetHashCode(); + if (ApprovalStatus != 0) hash ^= ApprovalStatus.GetHashCode(); + if (bidModifier_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(BidModifier); + if (cpcBidMicros_ != null) hash ^= CpcBidMicros.GetHashCode(); + if (cpmBidMicros_ != null) hash ^= CpmBidMicros.GetHashCode(); + if (cpvBidMicros_ != null) hash ^= CpvBidMicros.GetHashCode(); + if (percentCpcBidMicros_ != null) hash ^= PercentCpcBidMicros.GetHashCode(); + if (effectiveCpcBidMicros_ != null) hash ^= EffectiveCpcBidMicros.GetHashCode(); + if (effectiveCpmBidMicros_ != null) hash ^= EffectiveCpmBidMicros.GetHashCode(); + if (effectiveCpvBidMicros_ != null) hash ^= EffectiveCpvBidMicros.GetHashCode(); + if (effectivePercentCpcBidMicros_ != null) hash ^= EffectivePercentCpcBidMicros.GetHashCode(); + if (EffectiveCpcBidSource != 0) hash ^= EffectiveCpcBidSource.GetHashCode(); + if (EffectiveCpmBidSource != 0) hash ^= EffectiveCpmBidSource.GetHashCode(); + if (EffectiveCpvBidSource != 0) hash ^= EffectiveCpvBidSource.GetHashCode(); + if (EffectivePercentCpcBidSource != 0) hash ^= EffectivePercentCpcBidSource.GetHashCode(); + if (positionEstimates_ != null) hash ^= PositionEstimates.GetHashCode(); + hash ^= finalUrls_.GetHashCode(); + hash ^= finalMobileUrls_.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + hash ^= urlCustomParameters_.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Keyword) hash ^= Keyword.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Placement) hash ^= Placement.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) hash ^= MobileAppCategory.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.MobileApplication) hash ^= MobileApplication.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.ListingGroup) hash ^= ListingGroup.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.AgeRange) hash ^= AgeRange.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Gender) hash ^= Gender.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.IncomeRange) hash ^= IncomeRange.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.ParentalStatus) hash ^= ParentalStatus.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.UserList) hash ^= UserList.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) hash ^= YoutubeVideo.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) hash ^= YoutubeChannel.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Topic) hash ^= Topic.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.UserInterest) hash ^= UserInterest.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Webpage) hash ^= Webpage.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.AppPaymentModel) hash ^= AppPaymentModel.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.CustomAffinity) hash ^= CustomAffinity.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.CustomIntent) hash ^= CustomIntent.GetHashCode(); + hash ^= (int) criterionCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (Status != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Status); + } + if (qualityInfo_ != null) { + output.WriteRawTag(34); + output.WriteMessage(QualityInfo); + } + if (adGroup_ != null) { + _single_adGroup_codec.WriteTagAndValue(output, AdGroup); + } + if (positionEstimates_ != null) { + output.WriteRawTag(82); + output.WriteMessage(PositionEstimates); + } + finalUrls_.WriteTo(output, _repeated_finalUrls_codec); + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + urlCustomParameters_.WriteTo(output, _repeated_urlCustomParameters_codec); + if (cpcBidMicros_ != null) { + _single_cpcBidMicros_codec.WriteTagAndValue(output, CpcBidMicros); + } + if (cpmBidMicros_ != null) { + _single_cpmBidMicros_codec.WriteTagAndValue(output, CpmBidMicros); + } + if (effectiveCpcBidMicros_ != null) { + _single_effectiveCpcBidMicros_codec.WriteTagAndValue(output, EffectiveCpcBidMicros); + } + if (effectiveCpmBidMicros_ != null) { + _single_effectiveCpmBidMicros_codec.WriteTagAndValue(output, EffectiveCpmBidMicros); + } + if (effectiveCpvBidMicros_ != null) { + _single_effectiveCpvBidMicros_codec.WriteTagAndValue(output, EffectiveCpvBidMicros); + } + if (EffectiveCpcBidSource != 0) { + output.WriteRawTag(168, 1); + output.WriteEnum((int) EffectiveCpcBidSource); + } + if (EffectiveCpmBidSource != 0) { + output.WriteRawTag(176, 1); + output.WriteEnum((int) EffectiveCpmBidSource); + } + if (EffectiveCpvBidSource != 0) { + output.WriteRawTag(184, 1); + output.WriteEnum((int) EffectiveCpvBidSource); + } + if (cpvBidMicros_ != null) { + _single_cpvBidMicros_codec.WriteTagAndValue(output, CpvBidMicros); + } + if (Type != 0) { + output.WriteRawTag(200, 1); + output.WriteEnum((int) Type); + } + if (criterionId_ != null) { + _single_criterionId_codec.WriteTagAndValue(output, CriterionId); + } + if (criterionCase_ == CriterionOneofCase.Keyword) { + output.WriteRawTag(218, 1); + output.WriteMessage(Keyword); + } + if (criterionCase_ == CriterionOneofCase.Placement) { + output.WriteRawTag(226, 1); + output.WriteMessage(Placement); + } + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + output.WriteRawTag(234, 1); + output.WriteMessage(MobileAppCategory); + } + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + output.WriteRawTag(242, 1); + output.WriteMessage(MobileApplication); + } + if (negative_ != null) { + _single_negative_codec.WriteTagAndValue(output, Negative); + } + if (criterionCase_ == CriterionOneofCase.ListingGroup) { + output.WriteRawTag(130, 2); + output.WriteMessage(ListingGroup); + } + if (percentCpcBidMicros_ != null) { + _single_percentCpcBidMicros_codec.WriteTagAndValue(output, PercentCpcBidMicros); + } + if (effectivePercentCpcBidMicros_ != null) { + _single_effectivePercentCpcBidMicros_codec.WriteTagAndValue(output, EffectivePercentCpcBidMicros); + } + if (EffectivePercentCpcBidSource != 0) { + output.WriteRawTag(152, 2); + output.WriteEnum((int) EffectivePercentCpcBidSource); + } + if (criterionCase_ == CriterionOneofCase.AgeRange) { + output.WriteRawTag(162, 2); + output.WriteMessage(AgeRange); + } + if (criterionCase_ == CriterionOneofCase.Gender) { + output.WriteRawTag(170, 2); + output.WriteMessage(Gender); + } + if (criterionCase_ == CriterionOneofCase.IncomeRange) { + output.WriteRawTag(178, 2); + output.WriteMessage(IncomeRange); + } + if (criterionCase_ == CriterionOneofCase.ParentalStatus) { + output.WriteRawTag(186, 2); + output.WriteMessage(ParentalStatus); + } + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + output.WriteRawTag(194, 2); + output.WriteMessage(YoutubeVideo); + } + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + output.WriteRawTag(202, 2); + output.WriteMessage(YoutubeChannel); + } + if (criterionCase_ == CriterionOneofCase.UserList) { + output.WriteRawTag(210, 2); + output.WriteMessage(UserList); + } + if (criterionCase_ == CriterionOneofCase.Topic) { + output.WriteRawTag(218, 2); + output.WriteMessage(Topic); + } + if (bidModifier_ != null) { + _single_bidModifier_codec.WriteTagAndValue(output, BidModifier); + } + if (criterionCase_ == CriterionOneofCase.UserInterest) { + output.WriteRawTag(234, 2); + output.WriteMessage(UserInterest); + } + if (criterionCase_ == CriterionOneofCase.Webpage) { + output.WriteRawTag(242, 2); + output.WriteMessage(Webpage); + } + if (criterionCase_ == CriterionOneofCase.AppPaymentModel) { + output.WriteRawTag(250, 2); + output.WriteMessage(AppPaymentModel); + } + if (criterionCase_ == CriterionOneofCase.CustomAffinity) { + output.WriteRawTag(130, 3); + output.WriteMessage(CustomAffinity); + } + if (criterionCase_ == CriterionOneofCase.CustomIntent) { + output.WriteRawTag(138, 3); + output.WriteMessage(CustomIntent); + } + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + finalMobileUrls_.WriteTo(output, _repeated_finalMobileUrls_codec); + if (SystemServingStatus != 0) { + output.WriteRawTag(160, 3); + output.WriteEnum((int) SystemServingStatus); + } + if (ApprovalStatus != 0) { + output.WriteRawTag(168, 3); + output.WriteEnum((int) ApprovalStatus); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (criterionId_ != null) { + size += _single_criterionId_codec.CalculateSizeWithTag(CriterionId); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (qualityInfo_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(QualityInfo); + } + if (adGroup_ != null) { + size += _single_adGroup_codec.CalculateSizeWithTag(AdGroup); + } + if (Type != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (negative_ != null) { + size += _single_negative_codec.CalculateSizeWithTag(Negative); + } + if (SystemServingStatus != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) SystemServingStatus); + } + if (ApprovalStatus != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ApprovalStatus); + } + if (bidModifier_ != null) { + size += _single_bidModifier_codec.CalculateSizeWithTag(BidModifier); + } + if (cpcBidMicros_ != null) { + size += _single_cpcBidMicros_codec.CalculateSizeWithTag(CpcBidMicros); + } + if (cpmBidMicros_ != null) { + size += _single_cpmBidMicros_codec.CalculateSizeWithTag(CpmBidMicros); + } + if (cpvBidMicros_ != null) { + size += _single_cpvBidMicros_codec.CalculateSizeWithTag(CpvBidMicros); + } + if (percentCpcBidMicros_ != null) { + size += _single_percentCpcBidMicros_codec.CalculateSizeWithTag(PercentCpcBidMicros); + } + if (effectiveCpcBidMicros_ != null) { + size += _single_effectiveCpcBidMicros_codec.CalculateSizeWithTag(EffectiveCpcBidMicros); + } + if (effectiveCpmBidMicros_ != null) { + size += _single_effectiveCpmBidMicros_codec.CalculateSizeWithTag(EffectiveCpmBidMicros); + } + if (effectiveCpvBidMicros_ != null) { + size += _single_effectiveCpvBidMicros_codec.CalculateSizeWithTag(EffectiveCpvBidMicros); + } + if (effectivePercentCpcBidMicros_ != null) { + size += _single_effectivePercentCpcBidMicros_codec.CalculateSizeWithTag(EffectivePercentCpcBidMicros); + } + if (EffectiveCpcBidSource != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EffectiveCpcBidSource); + } + if (EffectiveCpmBidSource != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EffectiveCpmBidSource); + } + if (EffectiveCpvBidSource != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EffectiveCpvBidSource); + } + if (EffectivePercentCpcBidSource != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EffectivePercentCpcBidSource); + } + if (positionEstimates_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PositionEstimates); + } + size += finalUrls_.CalculateSize(_repeated_finalUrls_codec); + size += finalMobileUrls_.CalculateSize(_repeated_finalMobileUrls_codec); + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + size += urlCustomParameters_.CalculateSize(_repeated_urlCustomParameters_codec); + if (criterionCase_ == CriterionOneofCase.Keyword) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Keyword); + } + if (criterionCase_ == CriterionOneofCase.Placement) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Placement); + } + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MobileAppCategory); + } + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MobileApplication); + } + if (criterionCase_ == CriterionOneofCase.ListingGroup) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ListingGroup); + } + if (criterionCase_ == CriterionOneofCase.AgeRange) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AgeRange); + } + if (criterionCase_ == CriterionOneofCase.Gender) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Gender); + } + if (criterionCase_ == CriterionOneofCase.IncomeRange) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(IncomeRange); + } + if (criterionCase_ == CriterionOneofCase.ParentalStatus) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ParentalStatus); + } + if (criterionCase_ == CriterionOneofCase.UserList) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserList); + } + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(YoutubeVideo); + } + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(YoutubeChannel); + } + if (criterionCase_ == CriterionOneofCase.Topic) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Topic); + } + if (criterionCase_ == CriterionOneofCase.UserInterest) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserInterest); + } + if (criterionCase_ == CriterionOneofCase.Webpage) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Webpage); + } + if (criterionCase_ == CriterionOneofCase.AppPaymentModel) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AppPaymentModel); + } + if (criterionCase_ == CriterionOneofCase.CustomAffinity) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomAffinity); + } + if (criterionCase_ == CriterionOneofCase.CustomIntent) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomIntent); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupCriterion other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.criterionId_ != null) { + if (criterionId_ == null || other.CriterionId != 0L) { + CriterionId = other.CriterionId; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.qualityInfo_ != null) { + if (qualityInfo_ == null) { + QualityInfo = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.QualityInfo(); + } + QualityInfo.MergeFrom(other.QualityInfo); + } + if (other.adGroup_ != null) { + if (adGroup_ == null || other.AdGroup != "") { + AdGroup = other.AdGroup; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.negative_ != null) { + if (negative_ == null || other.Negative != false) { + Negative = other.Negative; + } + } + if (other.SystemServingStatus != 0) { + SystemServingStatus = other.SystemServingStatus; + } + if (other.ApprovalStatus != 0) { + ApprovalStatus = other.ApprovalStatus; + } + if (other.bidModifier_ != null) { + if (bidModifier_ == null || other.BidModifier != 0D) { + BidModifier = other.BidModifier; + } + } + if (other.cpcBidMicros_ != null) { + if (cpcBidMicros_ == null || other.CpcBidMicros != 0L) { + CpcBidMicros = other.CpcBidMicros; + } + } + if (other.cpmBidMicros_ != null) { + if (cpmBidMicros_ == null || other.CpmBidMicros != 0L) { + CpmBidMicros = other.CpmBidMicros; + } + } + if (other.cpvBidMicros_ != null) { + if (cpvBidMicros_ == null || other.CpvBidMicros != 0L) { + CpvBidMicros = other.CpvBidMicros; + } + } + if (other.percentCpcBidMicros_ != null) { + if (percentCpcBidMicros_ == null || other.PercentCpcBidMicros != 0L) { + PercentCpcBidMicros = other.PercentCpcBidMicros; + } + } + if (other.effectiveCpcBidMicros_ != null) { + if (effectiveCpcBidMicros_ == null || other.EffectiveCpcBidMicros != 0L) { + EffectiveCpcBidMicros = other.EffectiveCpcBidMicros; + } + } + if (other.effectiveCpmBidMicros_ != null) { + if (effectiveCpmBidMicros_ == null || other.EffectiveCpmBidMicros != 0L) { + EffectiveCpmBidMicros = other.EffectiveCpmBidMicros; + } + } + if (other.effectiveCpvBidMicros_ != null) { + if (effectiveCpvBidMicros_ == null || other.EffectiveCpvBidMicros != 0L) { + EffectiveCpvBidMicros = other.EffectiveCpvBidMicros; + } + } + if (other.effectivePercentCpcBidMicros_ != null) { + if (effectivePercentCpcBidMicros_ == null || other.EffectivePercentCpcBidMicros != 0L) { + EffectivePercentCpcBidMicros = other.EffectivePercentCpcBidMicros; + } + } + if (other.EffectiveCpcBidSource != 0) { + EffectiveCpcBidSource = other.EffectiveCpcBidSource; + } + if (other.EffectiveCpmBidSource != 0) { + EffectiveCpmBidSource = other.EffectiveCpmBidSource; + } + if (other.EffectiveCpvBidSource != 0) { + EffectiveCpvBidSource = other.EffectiveCpvBidSource; + } + if (other.EffectivePercentCpcBidSource != 0) { + EffectivePercentCpcBidSource = other.EffectivePercentCpcBidSource; + } + if (other.positionEstimates_ != null) { + if (positionEstimates_ == null) { + PositionEstimates = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.PositionEstimates(); + } + PositionEstimates.MergeFrom(other.PositionEstimates); + } + finalUrls_.Add(other.finalUrls_); + finalMobileUrls_.Add(other.finalMobileUrls_); + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + urlCustomParameters_.Add(other.urlCustomParameters_); + switch (other.CriterionCase) { + case CriterionOneofCase.Keyword: + if (Keyword == null) { + Keyword = new global::Google.Ads.GoogleAds.V3.Common.KeywordInfo(); + } + Keyword.MergeFrom(other.Keyword); + break; + case CriterionOneofCase.Placement: + if (Placement == null) { + Placement = new global::Google.Ads.GoogleAds.V3.Common.PlacementInfo(); + } + Placement.MergeFrom(other.Placement); + break; + case CriterionOneofCase.MobileAppCategory: + if (MobileAppCategory == null) { + MobileAppCategory = new global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo(); + } + MobileAppCategory.MergeFrom(other.MobileAppCategory); + break; + case CriterionOneofCase.MobileApplication: + if (MobileApplication == null) { + MobileApplication = new global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo(); + } + MobileApplication.MergeFrom(other.MobileApplication); + break; + case CriterionOneofCase.ListingGroup: + if (ListingGroup == null) { + ListingGroup = new global::Google.Ads.GoogleAds.V3.Common.ListingGroupInfo(); + } + ListingGroup.MergeFrom(other.ListingGroup); + break; + case CriterionOneofCase.AgeRange: + if (AgeRange == null) { + AgeRange = new global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo(); + } + AgeRange.MergeFrom(other.AgeRange); + break; + case CriterionOneofCase.Gender: + if (Gender == null) { + Gender = new global::Google.Ads.GoogleAds.V3.Common.GenderInfo(); + } + Gender.MergeFrom(other.Gender); + break; + case CriterionOneofCase.IncomeRange: + if (IncomeRange == null) { + IncomeRange = new global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo(); + } + IncomeRange.MergeFrom(other.IncomeRange); + break; + case CriterionOneofCase.ParentalStatus: + if (ParentalStatus == null) { + ParentalStatus = new global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo(); + } + ParentalStatus.MergeFrom(other.ParentalStatus); + break; + case CriterionOneofCase.UserList: + if (UserList == null) { + UserList = new global::Google.Ads.GoogleAds.V3.Common.UserListInfo(); + } + UserList.MergeFrom(other.UserList); + break; + case CriterionOneofCase.YoutubeVideo: + if (YoutubeVideo == null) { + YoutubeVideo = new global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo(); + } + YoutubeVideo.MergeFrom(other.YoutubeVideo); + break; + case CriterionOneofCase.YoutubeChannel: + if (YoutubeChannel == null) { + YoutubeChannel = new global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo(); + } + YoutubeChannel.MergeFrom(other.YoutubeChannel); + break; + case CriterionOneofCase.Topic: + if (Topic == null) { + Topic = new global::Google.Ads.GoogleAds.V3.Common.TopicInfo(); + } + Topic.MergeFrom(other.Topic); + break; + case CriterionOneofCase.UserInterest: + if (UserInterest == null) { + UserInterest = new global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo(); + } + UserInterest.MergeFrom(other.UserInterest); + break; + case CriterionOneofCase.Webpage: + if (Webpage == null) { + Webpage = new global::Google.Ads.GoogleAds.V3.Common.WebpageInfo(); + } + Webpage.MergeFrom(other.Webpage); + break; + case CriterionOneofCase.AppPaymentModel: + if (AppPaymentModel == null) { + AppPaymentModel = new global::Google.Ads.GoogleAds.V3.Common.AppPaymentModelInfo(); + } + AppPaymentModel.MergeFrom(other.AppPaymentModel); + break; + case CriterionOneofCase.CustomAffinity: + if (CustomAffinity == null) { + CustomAffinity = new global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo(); + } + CustomAffinity.MergeFrom(other.CustomAffinity); + break; + case CriterionOneofCase.CustomIntent: + if (CustomIntent == null) { + CustomIntent = new global::Google.Ads.GoogleAds.V3.Common.CustomIntentInfo(); + } + CustomIntent.MergeFrom(other.CustomIntent); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 24: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types.AdGroupCriterionStatus) input.ReadEnum(); + break; + } + case 34: { + if (qualityInfo_ == null) { + QualityInfo = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.QualityInfo(); + } + input.ReadMessage(QualityInfo); + break; + } + case 42: { + string value = _single_adGroup_codec.Read(input); + if (adGroup_ == null || value != "") { + AdGroup = value; + } + break; + } + case 82: { + if (positionEstimates_ == null) { + PositionEstimates = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Types.PositionEstimates(); + } + input.ReadMessage(PositionEstimates); + break; + } + case 90: { + finalUrls_.AddEntriesFrom(input, _repeated_finalUrls_codec); + break; + } + case 106: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 114: { + urlCustomParameters_.AddEntriesFrom(input, _repeated_urlCustomParameters_codec); + break; + } + case 130: { + long? value = _single_cpcBidMicros_codec.Read(input); + if (cpcBidMicros_ == null || value != 0L) { + CpcBidMicros = value; + } + break; + } + case 138: { + long? value = _single_cpmBidMicros_codec.Read(input); + if (cpmBidMicros_ == null || value != 0L) { + CpmBidMicros = value; + } + break; + } + case 146: { + long? value = _single_effectiveCpcBidMicros_codec.Read(input); + if (effectiveCpcBidMicros_ == null || value != 0L) { + EffectiveCpcBidMicros = value; + } + break; + } + case 154: { + long? value = _single_effectiveCpmBidMicros_codec.Read(input); + if (effectiveCpmBidMicros_ == null || value != 0L) { + EffectiveCpmBidMicros = value; + } + break; + } + case 162: { + long? value = _single_effectiveCpvBidMicros_codec.Read(input); + if (effectiveCpvBidMicros_ == null || value != 0L) { + EffectiveCpvBidMicros = value; + } + break; + } + case 168: { + EffectiveCpcBidSource = (global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource) input.ReadEnum(); + break; + } + case 176: { + EffectiveCpmBidSource = (global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource) input.ReadEnum(); + break; + } + case 184: { + EffectiveCpvBidSource = (global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource) input.ReadEnum(); + break; + } + case 194: { + long? value = _single_cpvBidMicros_codec.Read(input); + if (cpvBidMicros_ == null || value != 0L) { + CpvBidMicros = value; + } + break; + } + case 200: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType) input.ReadEnum(); + break; + } + case 210: { + long? value = _single_criterionId_codec.Read(input); + if (criterionId_ == null || value != 0L) { + CriterionId = value; + } + break; + } + case 218: { + global::Google.Ads.GoogleAds.V3.Common.KeywordInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.KeywordInfo(); + if (criterionCase_ == CriterionOneofCase.Keyword) { + subBuilder.MergeFrom(Keyword); + } + input.ReadMessage(subBuilder); + Keyword = subBuilder; + break; + } + case 226: { + global::Google.Ads.GoogleAds.V3.Common.PlacementInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.PlacementInfo(); + if (criterionCase_ == CriterionOneofCase.Placement) { + subBuilder.MergeFrom(Placement); + } + input.ReadMessage(subBuilder); + Placement = subBuilder; + break; + } + case 234: { + global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo(); + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + subBuilder.MergeFrom(MobileAppCategory); + } + input.ReadMessage(subBuilder); + MobileAppCategory = subBuilder; + break; + } + case 242: { + global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo(); + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + subBuilder.MergeFrom(MobileApplication); + } + input.ReadMessage(subBuilder); + MobileApplication = subBuilder; + break; + } + case 250: { + bool? value = _single_negative_codec.Read(input); + if (negative_ == null || value != false) { + Negative = value; + } + break; + } + case 258: { + global::Google.Ads.GoogleAds.V3.Common.ListingGroupInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ListingGroupInfo(); + if (criterionCase_ == CriterionOneofCase.ListingGroup) { + subBuilder.MergeFrom(ListingGroup); + } + input.ReadMessage(subBuilder); + ListingGroup = subBuilder; + break; + } + case 266: { + long? value = _single_percentCpcBidMicros_codec.Read(input); + if (percentCpcBidMicros_ == null || value != 0L) { + PercentCpcBidMicros = value; + } + break; + } + case 274: { + long? value = _single_effectivePercentCpcBidMicros_codec.Read(input); + if (effectivePercentCpcBidMicros_ == null || value != 0L) { + EffectivePercentCpcBidMicros = value; + } + break; + } + case 280: { + EffectivePercentCpcBidSource = (global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource) input.ReadEnum(); + break; + } + case 290: { + global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo(); + if (criterionCase_ == CriterionOneofCase.AgeRange) { + subBuilder.MergeFrom(AgeRange); + } + input.ReadMessage(subBuilder); + AgeRange = subBuilder; + break; + } + case 298: { + global::Google.Ads.GoogleAds.V3.Common.GenderInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.GenderInfo(); + if (criterionCase_ == CriterionOneofCase.Gender) { + subBuilder.MergeFrom(Gender); + } + input.ReadMessage(subBuilder); + Gender = subBuilder; + break; + } + case 306: { + global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo(); + if (criterionCase_ == CriterionOneofCase.IncomeRange) { + subBuilder.MergeFrom(IncomeRange); + } + input.ReadMessage(subBuilder); + IncomeRange = subBuilder; + break; + } + case 314: { + global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo(); + if (criterionCase_ == CriterionOneofCase.ParentalStatus) { + subBuilder.MergeFrom(ParentalStatus); + } + input.ReadMessage(subBuilder); + ParentalStatus = subBuilder; + break; + } + case 322: { + global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo(); + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + subBuilder.MergeFrom(YoutubeVideo); + } + input.ReadMessage(subBuilder); + YoutubeVideo = subBuilder; + break; + } + case 330: { + global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo(); + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + subBuilder.MergeFrom(YoutubeChannel); + } + input.ReadMessage(subBuilder); + YoutubeChannel = subBuilder; + break; + } + case 338: { + global::Google.Ads.GoogleAds.V3.Common.UserListInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.UserListInfo(); + if (criterionCase_ == CriterionOneofCase.UserList) { + subBuilder.MergeFrom(UserList); + } + input.ReadMessage(subBuilder); + UserList = subBuilder; + break; + } + case 346: { + global::Google.Ads.GoogleAds.V3.Common.TopicInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TopicInfo(); + if (criterionCase_ == CriterionOneofCase.Topic) { + subBuilder.MergeFrom(Topic); + } + input.ReadMessage(subBuilder); + Topic = subBuilder; + break; + } + case 354: { + double? value = _single_bidModifier_codec.Read(input); + if (bidModifier_ == null || value != 0D) { + BidModifier = value; + } + break; + } + case 362: { + global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo(); + if (criterionCase_ == CriterionOneofCase.UserInterest) { + subBuilder.MergeFrom(UserInterest); + } + input.ReadMessage(subBuilder); + UserInterest = subBuilder; + break; + } + case 370: { + global::Google.Ads.GoogleAds.V3.Common.WebpageInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.WebpageInfo(); + if (criterionCase_ == CriterionOneofCase.Webpage) { + subBuilder.MergeFrom(Webpage); + } + input.ReadMessage(subBuilder); + Webpage = subBuilder; + break; + } + case 378: { + global::Google.Ads.GoogleAds.V3.Common.AppPaymentModelInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AppPaymentModelInfo(); + if (criterionCase_ == CriterionOneofCase.AppPaymentModel) { + subBuilder.MergeFrom(AppPaymentModel); + } + input.ReadMessage(subBuilder); + AppPaymentModel = subBuilder; + break; + } + case 386: { + global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo(); + if (criterionCase_ == CriterionOneofCase.CustomAffinity) { + subBuilder.MergeFrom(CustomAffinity); + } + input.ReadMessage(subBuilder); + CustomAffinity = subBuilder; + break; + } + case 394: { + global::Google.Ads.GoogleAds.V3.Common.CustomIntentInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CustomIntentInfo(); + if (criterionCase_ == CriterionOneofCase.CustomIntent) { + subBuilder.MergeFrom(CustomIntent); + } + input.ReadMessage(subBuilder); + CustomIntent = subBuilder; + break; + } + case 402: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + case 410: { + finalMobileUrls_.AddEntriesFrom(input, _repeated_finalMobileUrls_codec); + break; + } + case 416: { + SystemServingStatus = (global::Google.Ads.GoogleAds.V3.Enums.CriterionSystemServingStatusEnum.Types.CriterionSystemServingStatus) input.ReadEnum(); + break; + } + case 424: { + ApprovalStatus = (global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionApprovalStatusEnum.Types.AdGroupCriterionApprovalStatus) input.ReadEnum(); + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupCriterion message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// A container for ad group criterion quality information. + /// + public sealed partial class QualityInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new QualityInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public QualityInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public QualityInfo(QualityInfo other) : this() { + QualityScore = other.QualityScore; + creativeQualityScore_ = other.creativeQualityScore_; + postClickQualityScore_ = other.postClickQualityScore_; + searchPredictedCtr_ = other.searchPredictedCtr_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public QualityInfo Clone() { + return new QualityInfo(this); + } + + /// Field number for the "quality_score" field. + public const int QualityScoreFieldNumber = 1; + private static readonly pb::FieldCodec _single_qualityScore_codec = pb::FieldCodec.ForStructWrapper(10); + private int? qualityScore_; + /// + /// Output only. The quality score. + /// + /// This field may not be populated if Google does not have enough + /// information to determine a value. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int? QualityScore { + get { return qualityScore_; } + set { + qualityScore_ = value; + } + } + + + /// Field number for the "creative_quality_score" field. + public const int CreativeQualityScoreFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket creativeQualityScore_ = 0; + /// + /// Output only. The performance of the ad compared to other advertisers. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket CreativeQualityScore { + get { return creativeQualityScore_; } + set { + creativeQualityScore_ = value; + } + } + + /// Field number for the "post_click_quality_score" field. + public const int PostClickQualityScoreFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket postClickQualityScore_ = 0; + /// + /// Output only. The quality score of the landing page. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket PostClickQualityScore { + get { return postClickQualityScore_; } + set { + postClickQualityScore_ = value; + } + } + + /// Field number for the "search_predicted_ctr" field. + public const int SearchPredictedCtrFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket searchPredictedCtr_ = 0; + /// + /// Output only. The click-through rate compared to that of other advertisers. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket SearchPredictedCtr { + get { return searchPredictedCtr_; } + set { + searchPredictedCtr_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as QualityInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(QualityInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (QualityScore != other.QualityScore) return false; + if (CreativeQualityScore != other.CreativeQualityScore) return false; + if (PostClickQualityScore != other.PostClickQualityScore) return false; + if (SearchPredictedCtr != other.SearchPredictedCtr) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (qualityScore_ != null) hash ^= QualityScore.GetHashCode(); + if (CreativeQualityScore != 0) hash ^= CreativeQualityScore.GetHashCode(); + if (PostClickQualityScore != 0) hash ^= PostClickQualityScore.GetHashCode(); + if (SearchPredictedCtr != 0) hash ^= SearchPredictedCtr.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (qualityScore_ != null) { + _single_qualityScore_codec.WriteTagAndValue(output, QualityScore); + } + if (CreativeQualityScore != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) CreativeQualityScore); + } + if (PostClickQualityScore != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) PostClickQualityScore); + } + if (SearchPredictedCtr != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) SearchPredictedCtr); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (qualityScore_ != null) { + size += _single_qualityScore_codec.CalculateSizeWithTag(QualityScore); + } + if (CreativeQualityScore != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) CreativeQualityScore); + } + if (PostClickQualityScore != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PostClickQualityScore); + } + if (SearchPredictedCtr != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) SearchPredictedCtr); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(QualityInfo other) { + if (other == null) { + return; + } + if (other.qualityScore_ != null) { + if (qualityScore_ == null || other.QualityScore != 0) { + QualityScore = other.QualityScore; + } + } + if (other.CreativeQualityScore != 0) { + CreativeQualityScore = other.CreativeQualityScore; + } + if (other.PostClickQualityScore != 0) { + PostClickQualityScore = other.PostClickQualityScore; + } + if (other.SearchPredictedCtr != 0) { + SearchPredictedCtr = other.SearchPredictedCtr; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + int? value = _single_qualityScore_codec.Read(input); + if (qualityScore_ == null || value != 0) { + QualityScore = value; + } + break; + } + case 16: { + CreativeQualityScore = (global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket) input.ReadEnum(); + break; + } + case 24: { + PostClickQualityScore = (global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket) input.ReadEnum(); + break; + } + case 32: { + SearchPredictedCtr = (global::Google.Ads.GoogleAds.V3.Enums.QualityScoreBucketEnum.Types.QualityScoreBucket) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Estimates for criterion bids at various positions. + /// + public sealed partial class PositionEstimates : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PositionEstimates()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Descriptor.NestedTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PositionEstimates() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PositionEstimates(PositionEstimates other) : this() { + FirstPageCpcMicros = other.FirstPageCpcMicros; + FirstPositionCpcMicros = other.FirstPositionCpcMicros; + TopOfPageCpcMicros = other.TopOfPageCpcMicros; + EstimatedAddClicksAtFirstPositionCpc = other.EstimatedAddClicksAtFirstPositionCpc; + EstimatedAddCostAtFirstPositionCpc = other.EstimatedAddCostAtFirstPositionCpc; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PositionEstimates Clone() { + return new PositionEstimates(this); + } + + /// Field number for the "first_page_cpc_micros" field. + public const int FirstPageCpcMicrosFieldNumber = 1; + private static readonly pb::FieldCodec _single_firstPageCpcMicros_codec = pb::FieldCodec.ForStructWrapper(10); + private long? firstPageCpcMicros_; + /// + /// Output only. The estimate of the CPC bid required for ad to be shown on first + /// page of search results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? FirstPageCpcMicros { + get { return firstPageCpcMicros_; } + set { + firstPageCpcMicros_ = value; + } + } + + + /// Field number for the "first_position_cpc_micros" field. + public const int FirstPositionCpcMicrosFieldNumber = 2; + private static readonly pb::FieldCodec _single_firstPositionCpcMicros_codec = pb::FieldCodec.ForStructWrapper(18); + private long? firstPositionCpcMicros_; + /// + /// Output only. The estimate of the CPC bid required for ad to be displayed in first + /// position, at the top of the first page of search results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? FirstPositionCpcMicros { + get { return firstPositionCpcMicros_; } + set { + firstPositionCpcMicros_ = value; + } + } + + + /// Field number for the "top_of_page_cpc_micros" field. + public const int TopOfPageCpcMicrosFieldNumber = 3; + private static readonly pb::FieldCodec _single_topOfPageCpcMicros_codec = pb::FieldCodec.ForStructWrapper(26); + private long? topOfPageCpcMicros_; + /// + /// Output only. The estimate of the CPC bid required for ad to be displayed at the top + /// of the first page of search results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TopOfPageCpcMicros { + get { return topOfPageCpcMicros_; } + set { + topOfPageCpcMicros_ = value; + } + } + + + /// Field number for the "estimated_add_clicks_at_first_position_cpc" field. + public const int EstimatedAddClicksAtFirstPositionCpcFieldNumber = 4; + private static readonly pb::FieldCodec _single_estimatedAddClicksAtFirstPositionCpc_codec = pb::FieldCodec.ForStructWrapper(34); + private long? estimatedAddClicksAtFirstPositionCpc_; + /// + /// Output only. Estimate of how many clicks per week you might get by changing your + /// keyword bid to the value in first_position_cpc_micros. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? EstimatedAddClicksAtFirstPositionCpc { + get { return estimatedAddClicksAtFirstPositionCpc_; } + set { + estimatedAddClicksAtFirstPositionCpc_ = value; + } + } + + + /// Field number for the "estimated_add_cost_at_first_position_cpc" field. + public const int EstimatedAddCostAtFirstPositionCpcFieldNumber = 5; + private static readonly pb::FieldCodec _single_estimatedAddCostAtFirstPositionCpc_codec = pb::FieldCodec.ForStructWrapper(42); + private long? estimatedAddCostAtFirstPositionCpc_; + /// + /// Output only. Estimate of how your cost per week might change when changing your + /// keyword bid to the value in first_position_cpc_micros. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? EstimatedAddCostAtFirstPositionCpc { + get { return estimatedAddCostAtFirstPositionCpc_; } + set { + estimatedAddCostAtFirstPositionCpc_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PositionEstimates); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PositionEstimates other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (FirstPageCpcMicros != other.FirstPageCpcMicros) return false; + if (FirstPositionCpcMicros != other.FirstPositionCpcMicros) return false; + if (TopOfPageCpcMicros != other.TopOfPageCpcMicros) return false; + if (EstimatedAddClicksAtFirstPositionCpc != other.EstimatedAddClicksAtFirstPositionCpc) return false; + if (EstimatedAddCostAtFirstPositionCpc != other.EstimatedAddCostAtFirstPositionCpc) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (firstPageCpcMicros_ != null) hash ^= FirstPageCpcMicros.GetHashCode(); + if (firstPositionCpcMicros_ != null) hash ^= FirstPositionCpcMicros.GetHashCode(); + if (topOfPageCpcMicros_ != null) hash ^= TopOfPageCpcMicros.GetHashCode(); + if (estimatedAddClicksAtFirstPositionCpc_ != null) hash ^= EstimatedAddClicksAtFirstPositionCpc.GetHashCode(); + if (estimatedAddCostAtFirstPositionCpc_ != null) hash ^= EstimatedAddCostAtFirstPositionCpc.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (firstPageCpcMicros_ != null) { + _single_firstPageCpcMicros_codec.WriteTagAndValue(output, FirstPageCpcMicros); + } + if (firstPositionCpcMicros_ != null) { + _single_firstPositionCpcMicros_codec.WriteTagAndValue(output, FirstPositionCpcMicros); + } + if (topOfPageCpcMicros_ != null) { + _single_topOfPageCpcMicros_codec.WriteTagAndValue(output, TopOfPageCpcMicros); + } + if (estimatedAddClicksAtFirstPositionCpc_ != null) { + _single_estimatedAddClicksAtFirstPositionCpc_codec.WriteTagAndValue(output, EstimatedAddClicksAtFirstPositionCpc); + } + if (estimatedAddCostAtFirstPositionCpc_ != null) { + _single_estimatedAddCostAtFirstPositionCpc_codec.WriteTagAndValue(output, EstimatedAddCostAtFirstPositionCpc); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (firstPageCpcMicros_ != null) { + size += _single_firstPageCpcMicros_codec.CalculateSizeWithTag(FirstPageCpcMicros); + } + if (firstPositionCpcMicros_ != null) { + size += _single_firstPositionCpcMicros_codec.CalculateSizeWithTag(FirstPositionCpcMicros); + } + if (topOfPageCpcMicros_ != null) { + size += _single_topOfPageCpcMicros_codec.CalculateSizeWithTag(TopOfPageCpcMicros); + } + if (estimatedAddClicksAtFirstPositionCpc_ != null) { + size += _single_estimatedAddClicksAtFirstPositionCpc_codec.CalculateSizeWithTag(EstimatedAddClicksAtFirstPositionCpc); + } + if (estimatedAddCostAtFirstPositionCpc_ != null) { + size += _single_estimatedAddCostAtFirstPositionCpc_codec.CalculateSizeWithTag(EstimatedAddCostAtFirstPositionCpc); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PositionEstimates other) { + if (other == null) { + return; + } + if (other.firstPageCpcMicros_ != null) { + if (firstPageCpcMicros_ == null || other.FirstPageCpcMicros != 0L) { + FirstPageCpcMicros = other.FirstPageCpcMicros; + } + } + if (other.firstPositionCpcMicros_ != null) { + if (firstPositionCpcMicros_ == null || other.FirstPositionCpcMicros != 0L) { + FirstPositionCpcMicros = other.FirstPositionCpcMicros; + } + } + if (other.topOfPageCpcMicros_ != null) { + if (topOfPageCpcMicros_ == null || other.TopOfPageCpcMicros != 0L) { + TopOfPageCpcMicros = other.TopOfPageCpcMicros; + } + } + if (other.estimatedAddClicksAtFirstPositionCpc_ != null) { + if (estimatedAddClicksAtFirstPositionCpc_ == null || other.EstimatedAddClicksAtFirstPositionCpc != 0L) { + EstimatedAddClicksAtFirstPositionCpc = other.EstimatedAddClicksAtFirstPositionCpc; + } + } + if (other.estimatedAddCostAtFirstPositionCpc_ != null) { + if (estimatedAddCostAtFirstPositionCpc_ == null || other.EstimatedAddCostAtFirstPositionCpc != 0L) { + EstimatedAddCostAtFirstPositionCpc = other.EstimatedAddCostAtFirstPositionCpc; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_firstPageCpcMicros_codec.Read(input); + if (firstPageCpcMicros_ == null || value != 0L) { + FirstPageCpcMicros = value; + } + break; + } + case 18: { + long? value = _single_firstPositionCpcMicros_codec.Read(input); + if (firstPositionCpcMicros_ == null || value != 0L) { + FirstPositionCpcMicros = value; + } + break; + } + case 26: { + long? value = _single_topOfPageCpcMicros_codec.Read(input); + if (topOfPageCpcMicros_ == null || value != 0L) { + TopOfPageCpcMicros = value; + } + break; + } + case 34: { + long? value = _single_estimatedAddClicksAtFirstPositionCpc_codec.Read(input); + if (estimatedAddClicksAtFirstPositionCpc_ == null || value != 0L) { + EstimatedAddClicksAtFirstPositionCpc = value; + } + break; + } + case 42: { + long? value = _single_estimatedAddCostAtFirstPositionCpc_codec.Read(input); + if (estimatedAddCostAtFirstPositionCpc_ == null || value != 0L) { + EstimatedAddCostAtFirstPositionCpc = value; + } + break; + } + } + } + } + + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupCriterionApprovalStatus.cs b/src/V3/Stubs/AdGroupCriterionApprovalStatus.cs new file mode 100644 index 000000000..a2b6a3fe7 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionApprovalStatus.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_group_criterion_approval_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_group_criterion_approval_status.proto + public static partial class AdGroupCriterionApprovalStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_group_criterion_approval_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionApprovalStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9ncm91cF9jcml0", + "ZXJpb25fYXBwcm92YWxfc3RhdHVzLnByb3RvEh1nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lbnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKq", + "AQoiQWRHcm91cENyaXRlcmlvbkFwcHJvdmFsU3RhdHVzRW51bSKDAQoeQWRH", + "cm91cENyaXRlcmlvbkFwcHJvdmFsU3RhdHVzEg8KC1VOU1BFQ0lGSUVEEAAS", + "CwoHVU5LTk9XThABEgwKCEFQUFJPVkVEEAISDwoLRElTQVBQUk9WRUQQAxIS", + "Cg5QRU5ESU5HX1JFVklFVxAEEhAKDFVOREVSX1JFVklFVxAFQvgBCiFjb20u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCI0FkR3JvdXBDcml0ZXJp", + "b25BcHByb3ZhbFN0YXR1c1Byb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVt", + "c6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionApprovalStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionApprovalStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionApprovalStatusEnum.Types.AdGroupCriterionApprovalStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible AdGroupCriterion approval statuses. + /// + public sealed partial class AdGroupCriterionApprovalStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupCriterionApprovalStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionApprovalStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionApprovalStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionApprovalStatusEnum(AdGroupCriterionApprovalStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionApprovalStatusEnum Clone() { + return new AdGroupCriterionApprovalStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupCriterionApprovalStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupCriterionApprovalStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupCriterionApprovalStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupCriterionApprovalStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates AdGroupCriterion approval statuses. + /// + public enum AdGroupCriterionApprovalStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Approved. + /// + [pbr::OriginalName("APPROVED")] Approved = 2, + /// + /// Disapproved. + /// + [pbr::OriginalName("DISAPPROVED")] Disapproved = 3, + /// + /// Pending Review. + /// + [pbr::OriginalName("PENDING_REVIEW")] PendingReview = 4, + /// + /// Under review. + /// + [pbr::OriginalName("UNDER_REVIEW")] UnderReview = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupCriterionError.cs b/src/V3/Stubs/AdGroupCriterionError.cs new file mode 100644 index 000000000..ea6284d86 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionError.cs @@ -0,0 +1,369 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_group_criterion_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_group_criterion_error.proto + public static partial class AdGroupCriterionErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_group_criterion_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfZ3JvdXBfY3Jp", + "dGVyaW9uX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i1wwKGUFkR3Jv", + "dXBDcml0ZXJpb25FcnJvckVudW0iuQwKFUFkR3JvdXBDcml0ZXJpb25FcnJv", + "chIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIrCidBRF9HUk9VUF9D", + "UklURVJJT05fTEFCRUxfRE9FU19OT1RfRVhJU1QQAhIrCidBRF9HUk9VUF9D", + "UklURVJJT05fTEFCRUxfQUxSRUFEWV9FWElTVFMQAxIqCiZDQU5OT1RfQURE", + "X0xBQkVMX1RPX05FR0FUSVZFX0NSSVRFUklPThAEEhcKE1RPT19NQU5ZX09Q", + "RVJBVElPTlMQBRIYChRDQU5UX1VQREFURV9ORUdBVElWRRAGEhoKFkNPTkNS", + "RVRFX1RZUEVfUkVRVUlSRUQQBxIhCh1CSURfSU5DT01QQVRJQkxFX1dJVEhf", + "QURHUk9VUBAIEh0KGUNBTk5PVF9UQVJHRVRfQU5EX0VYQ0xVREUQCRIPCgtJ", + "TExFR0FMX1VSTBAKEhgKFElOVkFMSURfS0VZV09SRF9URVhUEAsSGwoXSU5W", + "QUxJRF9ERVNUSU5BVElPTl9VUkwQDBIfChtNSVNTSU5HX0RFU1RJTkFUSU9O", + "X1VSTF9UQUcQDRIxCi1LRVlXT1JEX0xFVkVMX0JJRF9OT1RfU1VQUE9SVEVE", + "X0ZPUl9NQU5VQUxDUE0QDhIXChNJTlZBTElEX1VTRVJfU1RBVFVTEA8SHAoY", + "Q0FOTk9UX0FERF9DUklURVJJQV9UWVBFEBASIAocQ0FOTk9UX0VYQ0xVREVf", + "Q1JJVEVSSUFfVFlQRRAREjUKMUNBTVBBSUdOX1RZUEVfTk9UX0NPTVBBVElC", + "TEVfV0lUSF9QQVJUSUFMX0ZBSUxVUkUQGxItCilPUEVSQVRJT05TX0ZPUl9U", + "T09fTUFOWV9TSE9QUElOR19BREdST1VQUxAcEjQKMENBTk5PVF9NT0RJRllf", + "VVJMX0ZJRUxEU19XSVRIX0RVUExJQ0FURV9FTEVNRU5UUxAdEiEKHUNBTk5P", + "VF9TRVRfV0lUSE9VVF9GSU5BTF9VUkxTEB4SNgoyQ0FOTk9UX0NMRUFSX0ZJ", + "TkFMX1VSTFNfSUZfRklOQUxfTU9CSUxFX1VSTFNfRVhJU1QQHxIzCi9DQU5O", + "T1RfQ0xFQVJfRklOQUxfVVJMU19JRl9GSU5BTF9BUFBfVVJMU19FWElTVBAg", + "EjsKN0NBTk5PVF9DTEVBUl9GSU5BTF9VUkxTX0lGX1RSQUNLSU5HX1VSTF9U", + "RU1QTEFURV9FWElTVFMQIRI6CjZDQU5OT1RfQ0xFQVJfRklOQUxfVVJMU19J", + "Rl9VUkxfQ1VTVE9NX1BBUkFNRVRFUlNfRVhJU1QQIhIyCi5DQU5OT1RfU0VU", + "X0JPVEhfREVTVElOQVRJT05fVVJMX0FORF9GSU5BTF9VUkxTECMSPQo5Q0FO", + "Tk9UX1NFVF9CT1RIX0RFU1RJTkFUSU9OX1VSTF9BTkRfVFJBQ0tJTkdfVVJM", + "X1RFTVBMQVRFECQSLworRklOQUxfVVJMU19OT1RfU1VQUE9SVEVEX0ZPUl9D", + "UklURVJJT05fVFlQRRAlEjYKMkZJTkFMX01PQklMRV9VUkxTX05PVF9TVVBQ", + "T1JURURfRk9SX0NSSVRFUklPTl9UWVBFECYSIwofSU5WQUxJRF9MSVNUSU5H", + "X0dST1VQX0hJRVJBUkNIWRAnEisKJ0xJU1RJTkdfR1JPVVBfVU5JVF9DQU5O", + "T1RfSEFWRV9DSElMRFJFThAoEjIKLkxJU1RJTkdfR1JPVVBfU1VCRElWSVNJ", + "T05fUkVRVUlSRVNfT1RIRVJTX0NBU0UQKRI6CjZMSVNUSU5HX0dST1VQX1JF", + "UVVJUkVTX1NBTUVfRElNRU5TSU9OX1RZUEVfQVNfU0lCTElOR1MQKhIgChxM", + "SVNUSU5HX0dST1VQX0FMUkVBRFlfRVhJU1RTECsSIAocTElTVElOR19HUk9V", + "UF9ET0VTX05PVF9FWElTVBAsEiMKH0xJU1RJTkdfR1JPVVBfQ0FOTk9UX0JF", + "X1JFTU9WRUQQLRIeChpJTlZBTElEX0xJU1RJTkdfR1JPVVBfVFlQRRAuEioK", + "JkxJU1RJTkdfR1JPVVBfQUREX01BWV9PTkxZX1VTRV9URU1QX0lEEC9C9QEK", + "ImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNCGkFkR3JvdXBD", + "cml0ZXJpb25FcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnBy", + "b3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJyb3Jz", + "ogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIeR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdv", + "b2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupCriterionErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdGroupCriterionErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupCriterionErrorEnum.Types.AdGroupCriterionError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad group criterion errors. + /// + public sealed partial class AdGroupCriterionErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupCriterionErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdGroupCriterionErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionErrorEnum(AdGroupCriterionErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionErrorEnum Clone() { + return new AdGroupCriterionErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupCriterionErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupCriterionErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupCriterionErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupCriterionErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad group criterion errors. + /// + public enum AdGroupCriterionError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// No link found between the AdGroupCriterion and the label. + /// + [pbr::OriginalName("AD_GROUP_CRITERION_LABEL_DOES_NOT_EXIST")] AdGroupCriterionLabelDoesNotExist = 2, + /// + /// The label has already been attached to the AdGroupCriterion. + /// + [pbr::OriginalName("AD_GROUP_CRITERION_LABEL_ALREADY_EXISTS")] AdGroupCriterionLabelAlreadyExists = 3, + /// + /// Negative AdGroupCriterion cannot have labels. + /// + [pbr::OriginalName("CANNOT_ADD_LABEL_TO_NEGATIVE_CRITERION")] CannotAddLabelToNegativeCriterion = 4, + /// + /// Too many operations for a single call. + /// + [pbr::OriginalName("TOO_MANY_OPERATIONS")] TooManyOperations = 5, + /// + /// Negative ad group criteria are not updateable. + /// + [pbr::OriginalName("CANT_UPDATE_NEGATIVE")] CantUpdateNegative = 6, + /// + /// Concrete type of criterion (keyword v.s. placement) is required for ADD + /// and SET operations. + /// + [pbr::OriginalName("CONCRETE_TYPE_REQUIRED")] ConcreteTypeRequired = 7, + /// + /// Bid is incompatible with ad group's bidding settings. + /// + [pbr::OriginalName("BID_INCOMPATIBLE_WITH_ADGROUP")] BidIncompatibleWithAdgroup = 8, + /// + /// Cannot target and exclude the same criterion at once. + /// + [pbr::OriginalName("CANNOT_TARGET_AND_EXCLUDE")] CannotTargetAndExclude = 9, + /// + /// The URL of a placement is invalid. + /// + [pbr::OriginalName("ILLEGAL_URL")] IllegalUrl = 10, + /// + /// Keyword text was invalid. + /// + [pbr::OriginalName("INVALID_KEYWORD_TEXT")] InvalidKeywordText = 11, + /// + /// Destination URL was invalid. + /// + [pbr::OriginalName("INVALID_DESTINATION_URL")] InvalidDestinationUrl = 12, + /// + /// The destination url must contain at least one tag (e.g. {lpurl}) + /// + [pbr::OriginalName("MISSING_DESTINATION_URL_TAG")] MissingDestinationUrlTag = 13, + /// + /// Keyword-level cpm bid is not supported + /// + [pbr::OriginalName("KEYWORD_LEVEL_BID_NOT_SUPPORTED_FOR_MANUALCPM")] KeywordLevelBidNotSupportedForManualcpm = 14, + /// + /// For example, cannot add a biddable ad group criterion that had been + /// removed. + /// + [pbr::OriginalName("INVALID_USER_STATUS")] InvalidUserStatus = 15, + /// + /// Criteria type cannot be targeted for the ad group. Either the account is + /// restricted to keywords only, the criteria type is incompatible with the + /// campaign's bidding strategy, or the criteria type can only be applied to + /// campaigns. + /// + [pbr::OriginalName("CANNOT_ADD_CRITERIA_TYPE")] CannotAddCriteriaType = 16, + /// + /// Criteria type cannot be excluded for the ad group. Refer to the + /// documentation for a specific criterion to check if it is excludable. + /// + [pbr::OriginalName("CANNOT_EXCLUDE_CRITERIA_TYPE")] CannotExcludeCriteriaType = 17, + /// + /// Partial failure is not supported for shopping campaign mutate operations. + /// + [pbr::OriginalName("CAMPAIGN_TYPE_NOT_COMPATIBLE_WITH_PARTIAL_FAILURE")] CampaignTypeNotCompatibleWithPartialFailure = 27, + /// + /// Operations in the mutate request changes too many shopping ad groups. + /// Please split requests for multiple shopping ad groups across multiple + /// requests. + /// + [pbr::OriginalName("OPERATIONS_FOR_TOO_MANY_SHOPPING_ADGROUPS")] OperationsForTooManyShoppingAdgroups = 28, + /// + /// Not allowed to modify url fields of an ad group criterion if there are + /// duplicate elements for that ad group criterion in the request. + /// + [pbr::OriginalName("CANNOT_MODIFY_URL_FIELDS_WITH_DUPLICATE_ELEMENTS")] CannotModifyUrlFieldsWithDuplicateElements = 29, + /// + /// Cannot set url fields without also setting final urls. + /// + [pbr::OriginalName("CANNOT_SET_WITHOUT_FINAL_URLS")] CannotSetWithoutFinalUrls = 30, + /// + /// Cannot clear final urls if final mobile urls exist. + /// + [pbr::OriginalName("CANNOT_CLEAR_FINAL_URLS_IF_FINAL_MOBILE_URLS_EXIST")] CannotClearFinalUrlsIfFinalMobileUrlsExist = 31, + /// + /// Cannot clear final urls if final app urls exist. + /// + [pbr::OriginalName("CANNOT_CLEAR_FINAL_URLS_IF_FINAL_APP_URLS_EXIST")] CannotClearFinalUrlsIfFinalAppUrlsExist = 32, + /// + /// Cannot clear final urls if tracking url template exists. + /// + [pbr::OriginalName("CANNOT_CLEAR_FINAL_URLS_IF_TRACKING_URL_TEMPLATE_EXISTS")] CannotClearFinalUrlsIfTrackingUrlTemplateExists = 33, + /// + /// Cannot clear final urls if url custom parameters exist. + /// + [pbr::OriginalName("CANNOT_CLEAR_FINAL_URLS_IF_URL_CUSTOM_PARAMETERS_EXIST")] CannotClearFinalUrlsIfUrlCustomParametersExist = 34, + /// + /// Cannot set both destination url and final urls. + /// + [pbr::OriginalName("CANNOT_SET_BOTH_DESTINATION_URL_AND_FINAL_URLS")] CannotSetBothDestinationUrlAndFinalUrls = 35, + /// + /// Cannot set both destination url and tracking url template. + /// + [pbr::OriginalName("CANNOT_SET_BOTH_DESTINATION_URL_AND_TRACKING_URL_TEMPLATE")] CannotSetBothDestinationUrlAndTrackingUrlTemplate = 36, + /// + /// Final urls are not supported for this criterion type. + /// + [pbr::OriginalName("FINAL_URLS_NOT_SUPPORTED_FOR_CRITERION_TYPE")] FinalUrlsNotSupportedForCriterionType = 37, + /// + /// Final mobile urls are not supported for this criterion type. + /// + [pbr::OriginalName("FINAL_MOBILE_URLS_NOT_SUPPORTED_FOR_CRITERION_TYPE")] FinalMobileUrlsNotSupportedForCriterionType = 38, + /// + /// Ad group is invalid due to the listing groups it contains. + /// + [pbr::OriginalName("INVALID_LISTING_GROUP_HIERARCHY")] InvalidListingGroupHierarchy = 39, + /// + /// Listing group unit cannot have children. + /// + [pbr::OriginalName("LISTING_GROUP_UNIT_CANNOT_HAVE_CHILDREN")] ListingGroupUnitCannotHaveChildren = 40, + /// + /// Subdivided listing groups must have an "others" case. + /// + [pbr::OriginalName("LISTING_GROUP_SUBDIVISION_REQUIRES_OTHERS_CASE")] ListingGroupSubdivisionRequiresOthersCase = 41, + /// + /// Dimension type of listing group must be the same as that of its siblings. + /// + [pbr::OriginalName("LISTING_GROUP_REQUIRES_SAME_DIMENSION_TYPE_AS_SIBLINGS")] ListingGroupRequiresSameDimensionTypeAsSiblings = 42, + /// + /// Listing group cannot be added to the ad group because it already exists. + /// + [pbr::OriginalName("LISTING_GROUP_ALREADY_EXISTS")] ListingGroupAlreadyExists = 43, + /// + /// Listing group referenced in the operation was not found in the ad group. + /// + [pbr::OriginalName("LISTING_GROUP_DOES_NOT_EXIST")] ListingGroupDoesNotExist = 44, + /// + /// Recursive removal failed because listing group subdivision is being + /// created or modified in this request. + /// + [pbr::OriginalName("LISTING_GROUP_CANNOT_BE_REMOVED")] ListingGroupCannotBeRemoved = 45, + /// + /// Listing group type is not allowed for specified ad group criterion type. + /// + [pbr::OriginalName("INVALID_LISTING_GROUP_TYPE")] InvalidListingGroupType = 46, + /// + /// Listing group in an ADD operation specifies a non temporary criterion id. + /// + [pbr::OriginalName("LISTING_GROUP_ADD_MAY_ONLY_USE_TEMP_ID")] ListingGroupAddMayOnlyUseTempId = 47, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupCriterionLabel.cs b/src/V3/Stubs/AdGroupCriterionLabel.cs new file mode 100644 index 000000000..23a85219e --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionLabel.cs @@ -0,0 +1,273 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_criterion_label.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_criterion_label.proto + public static partial class AdGroupCriterionLabelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_criterion_label.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionLabelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "Y3JpdGVyaW9uX2xhYmVsLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5yZXNvdXJjZXMaH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8a", + "GWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93", + "cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKl", + "AwoVQWRHcm91cENyaXRlcmlvbkxhYmVsEk0KDXJlc291cmNlX25hbWUYASAB", + "KAlCNuBBBfpBMAouZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0FkR3JvdXBD", + "cml0ZXJpb25MYWJlbBJrChJhZF9ncm91cF9jcml0ZXJpb24YAiABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCMeBBBfpBKwopZ29vZ2xlYWRz", + "Lmdvb2dsZWFwaXMuY29tL0FkR3JvdXBDcml0ZXJpb24SUwoFbGFiZWwYAyAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCJuBBBfpBIAoeZ29v", + "Z2xlYWRzLmdvb2dsZWFwaXMuY29tL0xhYmVsOnvqQXgKLmdvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbS9BZEdyb3VwQ3JpdGVyaW9uTGFiZWwSRmN1c3RvbWVy", + "cy97Y3VzdG9tZXJ9L2FkR3JvdXBDcml0ZXJpb25MYWJlbHMve2FkX2dyb3Vw", + "X2NyaXRlcmlvbl9sYWJlbH1ChwIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXNCGkFkR3JvdXBDcml0ZXJpb25MYWJlbFByb3RvUAFa", + "Smdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xl", + "LkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29n", + "bGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel), global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel.Parser, new[]{ "ResourceName", "AdGroupCriterion", "Label" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A relationship between an ad group criterion and a label. + /// + public sealed partial class AdGroupCriterionLabel : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupCriterionLabel()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionLabel() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionLabel(AdGroupCriterionLabel other) : this() { + resourceName_ = other.resourceName_; + AdGroupCriterion = other.AdGroupCriterion; + Label = other.Label; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionLabel Clone() { + return new AdGroupCriterionLabel(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group criterion label. + /// Ad group criterion label resource names have the form: + /// `customers/{customer_id}/adGroupCriterionLabels/{ad_group_id}~{criterion_id}~{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "ad_group_criterion" field. + public const int AdGroupCriterionFieldNumber = 2; + private static readonly pb::FieldCodec _single_adGroupCriterion_codec = pb::FieldCodec.ForClassWrapper(18); + private string adGroupCriterion_; + /// + /// Immutable. The ad group criterion to which the label is attached. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupCriterion { + get { return adGroupCriterion_; } + set { + adGroupCriterion_ = value; + } + } + + + /// Field number for the "label" field. + public const int LabelFieldNumber = 3; + private static readonly pb::FieldCodec _single_label_codec = pb::FieldCodec.ForClassWrapper(26); + private string label_; + /// + /// Immutable. The label assigned to the ad group criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Label { + get { return label_; } + set { + label_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupCriterionLabel); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupCriterionLabel other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (AdGroupCriterion != other.AdGroupCriterion) return false; + if (Label != other.Label) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (adGroupCriterion_ != null) hash ^= AdGroupCriterion.GetHashCode(); + if (label_ != null) hash ^= Label.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (adGroupCriterion_ != null) { + _single_adGroupCriterion_codec.WriteTagAndValue(output, AdGroupCriterion); + } + if (label_ != null) { + _single_label_codec.WriteTagAndValue(output, Label); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (adGroupCriterion_ != null) { + size += _single_adGroupCriterion_codec.CalculateSizeWithTag(AdGroupCriterion); + } + if (label_ != null) { + size += _single_label_codec.CalculateSizeWithTag(Label); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupCriterionLabel other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.adGroupCriterion_ != null) { + if (adGroupCriterion_ == null || other.AdGroupCriterion != "") { + AdGroupCriterion = other.AdGroupCriterion; + } + } + if (other.label_ != null) { + if (label_ == null || other.Label != "") { + Label = other.Label; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_adGroupCriterion_codec.Read(input); + if (adGroupCriterion_ == null || value != "") { + AdGroupCriterion = value; + } + break; + } + case 26: { + string value = _single_label_codec.Read(input); + if (label_ == null || value != "") { + Label = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupCriterionLabelService.cs b/src/V3/Stubs/AdGroupCriterionLabelService.cs new file mode 100644 index 000000000..331db5333 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionLabelService.cs @@ -0,0 +1,957 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_criterion_label_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_criterion_label_service.proto + public static partial class AdGroupCriterionLabelServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_criterion_label_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionLabelServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9j", + "cml0ZXJpb25fbGFiZWxfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXMaQGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jl", + "c291cmNlcy9hZF9ncm91cF9jcml0ZXJpb25fbGFiZWwucHJvdG8aHGdvb2ds", + "ZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnBy", + "b3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhdnb29nbGUv", + "cnBjL3N0YXR1cy5wcm90byI9Ch9HZXRBZEdyb3VwQ3JpdGVyaW9uTGFiZWxS", + "ZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiLKAQojTXV0YXRl", + "QWRHcm91cENyaXRlcmlvbkxhYmVsc1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQY", + "ASABKAlCA+BBAhJZCgpvcGVyYXRpb25zGAIgAygLMkAuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuQWRHcm91cENyaXRlcmlvbkxhYmVsT3Bl", + "cmF0aW9uQgPgQQISFwoPcGFydGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlk", + "YXRlX29ubHkYBCABKAgiiwEKHkFkR3JvdXBDcml0ZXJpb25MYWJlbE9wZXJh", + "dGlvbhJKCgZjcmVhdGUYASABKAsyOC5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5yZXNvdXJjZXMuQWRHcm91cENyaXRlcmlvbkxhYmVsSAASEAoGcmVtb3Zl", + "GAIgASgJSABCCwoJb3BlcmF0aW9uIq8BCiRNdXRhdGVBZEdyb3VwQ3JpdGVy", + "aW9uTGFiZWxzUmVzcG9uc2USMQoVcGFydGlhbF9mYWlsdXJlX2Vycm9yGAMg", + "ASgLMhIuZ29vZ2xlLnJwYy5TdGF0dXMSVAoHcmVzdWx0cxgCIAMoCzJDLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBD", + "cml0ZXJpb25MYWJlbFJlc3VsdCI6CiFNdXRhdGVBZEdyb3VwQ3JpdGVyaW9u", + "TGFiZWxSZXN1bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTK4BAocQWRHcm91", + "cENyaXRlcmlvbkxhYmVsU2VydmljZRLpAQoYR2V0QWRHcm91cENyaXRlcmlv", + "bkxhYmVsEkEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR2V0", + "QWRHcm91cENyaXRlcmlvbkxhYmVsUmVxdWVzdBo4Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5BZEdyb3VwQ3JpdGVyaW9uTGFiZWwiUILT", + "5JMCOhI4L3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2FkR3JvdXBD", + "cml0ZXJpb25MYWJlbHMvKn3aQQ1yZXNvdXJjZV9uYW1lEo4CChxNdXRhdGVB", + "ZEdyb3VwQ3JpdGVyaW9uTGFiZWxzEkUuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMuTXV0YXRlQWRHcm91cENyaXRlcmlvbkxhYmVsc1JlcXVl", + "c3QaRi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVB", + "ZEdyb3VwQ3JpdGVyaW9uTGFiZWxzUmVzcG9uc2UiX4LT5JMCQCI7L3YzL2N1", + "c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn0vYWRHcm91cENyaXRlcmlvbkxhYmVs", + "czptdXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVyYXRpb25zGhvKQRhnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb21CiAIKJGNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlc0IhQWRHcm91cENyaXRlcmlvbkxhYmVsU2Vydmlj", + "ZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFw", + "aXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoC", + "IEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFk", + "c1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xl", + "QWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabelReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionLabelRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionLabelRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [AdGroupCriterionLabelService.GetAdGroupCriterionLabel][google.ads.googleads.v3.services.AdGroupCriterionLabelService.GetAdGroupCriterionLabel]. + /// + public sealed partial class GetAdGroupCriterionLabelRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupCriterionLabelRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionLabelRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionLabelRequest(GetAdGroupCriterionLabelRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionLabelRequest Clone() { + return new GetAdGroupCriterionLabelRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group criterion label to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupCriterionLabelRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupCriterionLabelRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupCriterionLabelRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [AdGroupCriterionLabelService.MutateAdGroupCriterionLabels][google.ads.googleads.v3.services.AdGroupCriterionLabelService.MutateAdGroupCriterionLabels]. + /// + public sealed partial class MutateAdGroupCriterionLabelsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupCriterionLabelsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelsRequest(MutateAdGroupCriterionLabelsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelsRequest Clone() { + return new MutateAdGroupCriterionLabelsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. ID of the customer whose ad group criterion labels are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on ad group criterion labels. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupCriterionLabelsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupCriterionLabelsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupCriterionLabelsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove) on an ad group criterion label. + /// + public sealed partial class AdGroupCriterionLabelOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupCriterionLabelOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionLabelOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionLabelOperation(AdGroupCriterionLabelOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionLabelOperation Clone() { + return new AdGroupCriterionLabelOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad group + /// label. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 2; + /// + /// Remove operation: A resource name for the ad group criterion label + /// being removed, in this format: + /// + /// `customers/{customer_id}/adGroupCriterionLabels/{ad_group_id}~{criterion_id}~{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupCriterionLabelOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupCriterionLabelOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(18); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupCriterionLabelOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for an ad group criterion labels mutate. + /// + public sealed partial class MutateAdGroupCriterionLabelsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupCriterionLabelsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelsResponse(MutateAdGroupCriterionLabelsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelsResponse Clone() { + return new MutateAdGroupCriterionLabelsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupCriterionLabelsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupCriterionLabelsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupCriterionLabelsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for an ad group criterion label mutate. + /// + public sealed partial class MutateAdGroupCriterionLabelResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupCriterionLabelResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelResult(MutateAdGroupCriterionLabelResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionLabelResult Clone() { + return new MutateAdGroupCriterionLabelResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupCriterionLabelResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupCriterionLabelResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupCriterionLabelResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupCriterionLabelServiceClient.cs b/src/V3/Stubs/AdGroupCriterionLabelServiceClient.cs new file mode 100644 index 000000000..af1152120 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionLabelServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupCriterionLabelServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupCriterionLabelServiceSettings GetDefault() => new AdGroupCriterionLabelServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupCriterionLabelServiceSettings() { } + + private AdGroupCriterionLabelServiceSettings(AdGroupCriterionLabelServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupCriterionLabelSettings = existing.GetAdGroupCriterionLabelSettings; + MutateAdGroupCriterionLabelsSettings = existing.MutateAdGroupCriterionLabelsSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupCriterionLabelServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupCriterionLabelServiceClient.GetAdGroupCriterionLabel and AdGroupCriterionLabelServiceClient.GetAdGroupCriterionLabelAsync. + /// + /// + /// The default AdGroupCriterionLabelServiceClient.GetAdGroupCriterionLabel and + /// AdGroupCriterionLabelServiceClient.GetAdGroupCriterionLabelAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupCriterionLabelSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupCriterionLabelServiceClient.MutateAdGroupCriterionLabels and AdGroupCriterionLabelServiceClient.MutateAdGroupCriterionLabelsAsync. + /// + /// + /// The default AdGroupCriterionLabelServiceClient.MutateAdGroupCriterionLabels and + /// AdGroupCriterionLabelServiceClient.MutateAdGroupCriterionLabelsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupCriterionLabelsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupCriterionLabelServiceSettings Clone() => new AdGroupCriterionLabelServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupCriterionLabelServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupCriterionLabelServiceSettings Settings { get; set; } + + /// + public override AdGroupCriterionLabelServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupCriterionLabelServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupCriterionLabelServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupCriterionLabelServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupCriterionLabelServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupCriterionLabelServiceClient.ChannelPool; + } + + /// + /// AdGroupCriterionLabelService client wrapper, for convenient use. + /// + public abstract partial class AdGroupCriterionLabelServiceClient + { + /// + /// The default endpoint for the AdGroupCriterionLabelService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupCriterionLabelService scopes. + /// + /// + /// The default AdGroupCriterionLabelService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupCriterionLabelServiceClient client = await AdGroupCriterionLabelServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupCriterionLabelServiceClient.DefaultEndpoint.Host, AdGroupCriterionLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupCriterionLabelServiceClient client = AdGroupCriterionLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupCriterionLabelServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupCriterionLabelServiceClient client = AdGroupCriterionLabelServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupCriterionLabelServiceClient.DefaultEndpoint.Host, AdGroupCriterionLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupCriterionLabelServiceClient client = AdGroupCriterionLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupCriterionLabelServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupCriterionLabelServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupCriterionLabelServiceClient Create(grpccore::Channel channel, AdGroupCriterionLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupCriterionLabelServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupCriterionLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupCriterionLabelService.AdGroupCriterionLabelServiceClient grpcClient = new AdGroupCriterionLabelService.AdGroupCriterionLabelServiceClient(callInvoker); + return new AdGroupCriterionLabelServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupCriterionLabelService client. + /// + public virtual AdGroupCriterionLabelService.AdGroupCriterionLabelServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// + /// Required. The resource name of the ad group criterion label to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionLabelAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupCriterionLabelAsync( + new GetAdGroupCriterionLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// + /// Required. The resource name of the ad group criterion label to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionLabelAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupCriterionLabelAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// + /// Required. The resource name of the ad group criterion label to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupCriterionLabel GetAdGroupCriterionLabel( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupCriterionLabel( + new GetAdGroupCriterionLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionLabelAsync( + GetAdGroupCriterionLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionLabelAsync( + GetAdGroupCriterionLabelRequest request, + st::CancellationToken cancellationToken) => GetAdGroupCriterionLabelAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupCriterionLabel GetAdGroupCriterionLabel( + GetAdGroupCriterionLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group criterion labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group criterion labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriterionLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupCriterionLabelsAsync( + new MutateAdGroupCriterionLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group criterion labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group criterion labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriterionLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupCriterionLabelsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group criterion labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group criterion labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupCriterionLabelsResponse MutateAdGroupCriterionLabels( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupCriterionLabels( + new MutateAdGroupCriterionLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group criterion labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group criterion labels. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriterionLabelsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupCriterionLabelsAsync( + new MutateAdGroupCriterionLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group criterion labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group criterion labels. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriterionLabelsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupCriterionLabelsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group criterion labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group criterion labels. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupCriterionLabelsResponse MutateAdGroupCriterionLabels( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupCriterionLabels( + new MutateAdGroupCriterionLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriterionLabelsAsync( + MutateAdGroupCriterionLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriterionLabelsAsync( + MutateAdGroupCriterionLabelsRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupCriterionLabelsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupCriterionLabelsResponse MutateAdGroupCriterionLabels( + MutateAdGroupCriterionLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupCriterionLabelService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupCriterionLabelServiceClientImpl : AdGroupCriterionLabelServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupCriterionLabel; + private readonly gaxgrpc::ApiCall _callMutateAdGroupCriterionLabels; + + /// + /// Constructs a client wrapper for the AdGroupCriterionLabelService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupCriterionLabelServiceClientImpl(AdGroupCriterionLabelService.AdGroupCriterionLabelServiceClient grpcClient, AdGroupCriterionLabelServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupCriterionLabelServiceSettings effectiveSettings = settings ?? AdGroupCriterionLabelServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupCriterionLabel = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupCriterionLabelAsync, GrpcClient.GetAdGroupCriterionLabel, effectiveSettings.GetAdGroupCriterionLabelSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroupCriterionLabels = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupCriterionLabelsAsync, GrpcClient.MutateAdGroupCriterionLabels, effectiveSettings.MutateAdGroupCriterionLabelsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroupCriterionLabel); + Modify_GetAdGroupCriterionLabelApiCall(ref _callGetAdGroupCriterionLabel); + Modify_ApiCall(ref _callMutateAdGroupCriterionLabels); + Modify_MutateAdGroupCriterionLabelsApiCall(ref _callMutateAdGroupCriterionLabels); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupCriterionLabelApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupCriterionLabelsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupCriterionLabelService.AdGroupCriterionLabelServiceClient grpcClient, AdGroupCriterionLabelServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupCriterionLabelService client. + /// + public override AdGroupCriterionLabelService.AdGroupCriterionLabelServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupCriterionLabelRequest(ref GetAdGroupCriterionLabelRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupCriterionLabelsRequest(ref MutateAdGroupCriterionLabelsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupCriterionLabelAsync( + GetAdGroupCriterionLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupCriterionLabelRequest(ref request, ref callSettings); + return _callGetAdGroupCriterionLabel.Async(request, callSettings); + } + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupCriterionLabel GetAdGroupCriterionLabel( + GetAdGroupCriterionLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupCriterionLabelRequest(ref request, ref callSettings); + return _callGetAdGroupCriterionLabel.Sync(request, callSettings); + } + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupCriterionLabelsAsync( + MutateAdGroupCriterionLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupCriterionLabelsRequest(ref request, ref callSettings); + return _callMutateAdGroupCriterionLabels.Async(request, callSettings); + } + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupCriterionLabelsResponse MutateAdGroupCriterionLabels( + MutateAdGroupCriterionLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupCriterionLabelsRequest(ref request, ref callSettings); + return _callMutateAdGroupCriterionLabels.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupCriterionLabelServiceGrpc.cs b/src/V3/Stubs/AdGroupCriterionLabelServiceGrpc.cs new file mode 100644 index 000000000..5ae9b00e9 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionLabelServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_criterion_label_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage labels on ad group criteria. + /// + public static partial class AdGroupCriterionLabelService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupCriterionLabelService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupCriterionLabelRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionLabelRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupCriterionLabel = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupCriterionLabelsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupCriterionLabelsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupCriterionLabel = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupCriterionLabel", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupCriterionLabelRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupCriterionLabel); + + static readonly grpc::Method __Method_MutateAdGroupCriterionLabels = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroupCriterionLabels", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupCriterionLabelsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupCriterionLabelsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupCriterionLabelService + public abstract partial class AdGroupCriterionLabelServiceBase + { + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupCriterionLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionLabelRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroupCriterionLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupCriterionLabelService + public partial class AdGroupCriterionLabelServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupCriterionLabelService + /// The channel to use to make remote calls. + public AdGroupCriterionLabelServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupCriterionLabelService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupCriterionLabelServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupCriterionLabelServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupCriterionLabelServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel GetAdGroupCriterionLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupCriterionLabel(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel GetAdGroupCriterionLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupCriterionLabel, null, options, request); + } + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupCriterionLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupCriterionLabelAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group criterion label in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupCriterionLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupCriterionLabel, null, options, request); + } + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsResponse MutateAdGroupCriterionLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupCriterionLabels(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsResponse MutateAdGroupCriterionLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroupCriterionLabels, null, options, request); + } + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupCriterionLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupCriterionLabelsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes ad group criterion labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupCriterionLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroupCriterionLabels, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupCriterionLabelServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupCriterionLabelServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupCriterionLabelServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupCriterionLabel, serviceImpl.GetAdGroupCriterionLabel) + .AddMethod(__Method_MutateAdGroupCriterionLabels, serviceImpl.MutateAdGroupCriterionLabels).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupCriterionLabelServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupCriterionLabel, serviceImpl.GetAdGroupCriterionLabel); + serviceBinder.AddMethod(__Method_MutateAdGroupCriterionLabels, serviceImpl.MutateAdGroupCriterionLabels); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupCriterionService.cs b/src/V3/Stubs/AdGroupCriterionService.cs new file mode 100644 index 000000000..8794fb631 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionService.cs @@ -0,0 +1,1069 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_criterion_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_criterion_service.proto + public static partial class AdGroupCriterionServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_criterion_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9j", + "cml0ZXJpb25fc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMaK2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9w", + "b2xpY3kucHJvdG8aOmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNl", + "cy9hZF9ncm91cF9jcml0ZXJpb24ucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3Rh", + "dGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUv", + "YXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9idWYvZmll", + "bGRfbWFzay5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8iOAoaR2V0", + "QWRHcm91cENyaXRlcmlvblJlcXVlc3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEo", + "CUID4EECIr4BChxNdXRhdGVBZEdyb3VwQ3JpdGVyaWFSZXF1ZXN0EhgKC2N1", + "c3RvbWVyX2lkGAEgASgJQgPgQQISVAoKb3BlcmF0aW9ucxgCIAMoCzI7Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkFkR3JvdXBDcml0ZXJp", + "b25PcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyABKAgSFQoN", + "dmFsaWRhdGVfb25seRgEIAEoCCLTAgoZQWRHcm91cENyaXRlcmlvbk9wZXJh", + "dGlvbhIvCgt1cGRhdGVfbWFzaxgEIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5G", + "aWVsZE1hc2sSWAocZXhlbXB0X3BvbGljeV92aW9sYXRpb25fa2V5cxgFIAMo", + "CzIyLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Qb2xpY3lWaW9s", + "YXRpb25LZXkSRQoGY3JlYXRlGAEgASgLMjMuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMucmVzb3VyY2VzLkFkR3JvdXBDcml0ZXJpb25IABJFCgZ1cGRhdGUY", + "AiABKAsyMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRH", + "cm91cENyaXRlcmlvbkgAEhAKBnJlbW92ZRgDIAEoCUgAQgsKCW9wZXJhdGlv", + "biKjAQodTXV0YXRlQWRHcm91cENyaXRlcmlhUmVzcG9uc2USMQoVcGFydGlh", + "bF9mYWlsdXJlX2Vycm9yGAMgASgLMhIuZ29vZ2xlLnJwYy5TdGF0dXMSTwoH", + "cmVzdWx0cxgCIAMoCzI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzLk11dGF0ZUFkR3JvdXBDcml0ZXJpb25SZXN1bHQiNQocTXV0YXRlQWRH", + "cm91cENyaXRlcmlvblJlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJMoEE", + "ChdBZEdyb3VwQ3JpdGVyaW9uU2VydmljZRLTAQoTR2V0QWRHcm91cENyaXRl", + "cmlvbhI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEFk", + "R3JvdXBDcml0ZXJpb25SZXF1ZXN0GjMuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzLkFkR3JvdXBDcml0ZXJpb24iSYLT5JMCMxIxL3YzL3ty", + "ZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2FkR3JvdXBDcml0ZXJpYS8qfdpB", + "DXJlc291cmNlX25hbWUS8gEKFU11dGF0ZUFkR3JvdXBDcml0ZXJpYRI+Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBD", + "cml0ZXJpYVJlcXVlc3QaPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5NdXRhdGVBZEdyb3VwQ3JpdGVyaWFSZXNwb25zZSJYgtPkkwI5IjQv", + "djMvY3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfS9hZEdyb3VwQ3JpdGVyaWE6", + "bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9ucxobykEYZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tQoMCCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXNCHEFkR3JvdXBDcml0ZXJpb25TZXJ2aWNlUHJvdG9Q", + "AVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMv", + "Z29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29vZ2xl", + "LkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdvb2ds", + "ZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYz", + "OjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.PolicyReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionOperation.Parser, new[]{ "UpdateMask", "ExemptPolicyViolationKeys", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupCriterionService.GetAdGroupCriterion][google.ads.googleads.v3.services.AdGroupCriterionService.GetAdGroupCriterion]. + /// + public sealed partial class GetAdGroupCriterionRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupCriterionRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionRequest(GetAdGroupCriterionRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionRequest Clone() { + return new GetAdGroupCriterionRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the criterion to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupCriterionRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupCriterionRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupCriterionRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdGroupCriterionService.MutateAdGroupCriteria][google.ads.googleads.v3.services.AdGroupCriterionService.MutateAdGroupCriteria]. + /// + public sealed partial class MutateAdGroupCriteriaRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupCriteriaRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriteriaRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriteriaRequest(MutateAdGroupCriteriaRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriteriaRequest Clone() { + return new MutateAdGroupCriteriaRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. ID of the customer whose criteria are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual criteria. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupCriteriaRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupCriteriaRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupCriteriaRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove, update) on an ad group criterion. + /// + public sealed partial class AdGroupCriterionOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupCriterionOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionOperation(AdGroupCriterionOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + exemptPolicyViolationKeys_ = other.exemptPolicyViolationKeys_.Clone(); + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionOperation Clone() { + return new AdGroupCriterionOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "exempt_policy_violation_keys" field. + public const int ExemptPolicyViolationKeysFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_exemptPolicyViolationKeys_codec + = pb::FieldCodec.ForMessage(42, global::Google.Ads.GoogleAds.V3.Common.PolicyViolationKey.Parser); + private readonly pbc::RepeatedField exemptPolicyViolationKeys_ = new pbc::RepeatedField(); + /// + /// The list of policy violation keys that should not cause a + /// PolicyViolationError to be reported. Not all policy violations are + /// exemptable, please refer to the is_exemptible field in the returned + /// PolicyViolationError. + /// + /// Resources violating these polices will be saved, but will not be eligible + /// to serve. They may begin serving at a later time due to a change in + /// policies, re-review of the resource, or a change in advertiser + /// certificates. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ExemptPolicyViolationKeys { + get { return exemptPolicyViolationKeys_; } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The criterion is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed criterion is expected, + /// in this format: + /// + /// `customers/{customer_id}/adGroupCriteria/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupCriterionOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupCriterionOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if(!exemptPolicyViolationKeys_.Equals(other.exemptPolicyViolationKeys_)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + hash ^= exemptPolicyViolationKeys_.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + exemptPolicyViolationKeys_.WriteTo(output, _repeated_exemptPolicyViolationKeys_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + size += exemptPolicyViolationKeys_.CalculateSize(_repeated_exemptPolicyViolationKeys_codec); + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupCriterionOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + exemptPolicyViolationKeys_.Add(other.exemptPolicyViolationKeys_); + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + case 42: { + exemptPolicyViolationKeys_.AddEntriesFrom(input, _repeated_exemptPolicyViolationKeys_codec); + break; + } + } + } + } + + } + + /// + /// Response message for an ad group criterion mutate. + /// + public sealed partial class MutateAdGroupCriteriaResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupCriteriaResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriteriaResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriteriaResponse(MutateAdGroupCriteriaResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriteriaResponse Clone() { + return new MutateAdGroupCriteriaResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupCriteriaResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupCriteriaResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupCriteriaResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the criterion mutate. + /// + public sealed partial class MutateAdGroupCriterionResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupCriterionResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionResult(MutateAdGroupCriterionResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupCriterionResult Clone() { + return new MutateAdGroupCriterionResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupCriterionResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupCriterionResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupCriterionResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupCriterionServiceClient.cs b/src/V3/Stubs/AdGroupCriterionServiceClient.cs new file mode 100644 index 000000000..816e65bff --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionServiceClient.cs @@ -0,0 +1,887 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupCriterionServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupCriterionServiceSettings GetDefault() => new AdGroupCriterionServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupCriterionServiceSettings() { } + + private AdGroupCriterionServiceSettings(AdGroupCriterionServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupCriterionSettings = existing.GetAdGroupCriterionSettings; + MutateAdGroupCriteriaSettings = existing.MutateAdGroupCriteriaSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupCriterionServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupCriterionServiceClient.GetAdGroupCriterion and AdGroupCriterionServiceClient.GetAdGroupCriterionAsync. + /// + /// + /// The default AdGroupCriterionServiceClient.GetAdGroupCriterion and + /// AdGroupCriterionServiceClient.GetAdGroupCriterionAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupCriterionSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupCriterionServiceClient.MutateAdGroupCriteria and AdGroupCriterionServiceClient.MutateAdGroupCriteriaAsync. + /// + /// + /// The default AdGroupCriterionServiceClient.MutateAdGroupCriteria and + /// AdGroupCriterionServiceClient.MutateAdGroupCriteriaAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupCriteriaSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupCriterionServiceSettings Clone() => new AdGroupCriterionServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupCriterionServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupCriterionServiceSettings Settings { get; set; } + + /// + public override AdGroupCriterionServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupCriterionServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupCriterionServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupCriterionServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupCriterionServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupCriterionServiceClient.ChannelPool; + } + + /// + /// AdGroupCriterionService client wrapper, for convenient use. + /// + public abstract partial class AdGroupCriterionServiceClient + { + /// + /// The default endpoint for the AdGroupCriterionService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupCriterionService scopes. + /// + /// + /// The default AdGroupCriterionService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupCriterionServiceClient client = await AdGroupCriterionServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupCriterionServiceClient.DefaultEndpoint.Host, AdGroupCriterionServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupCriterionServiceClient client = AdGroupCriterionServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupCriterionServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupCriterionServiceClient client = AdGroupCriterionServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupCriterionServiceClient.DefaultEndpoint.Host, AdGroupCriterionServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupCriterionServiceClient client = AdGroupCriterionServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupCriterionServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupCriterionServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupCriterionServiceClient Create(grpccore::Channel channel, AdGroupCriterionServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupCriterionServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupCriterionServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupCriterionService.AdGroupCriterionServiceClient grpcClient = new AdGroupCriterionService.AdGroupCriterionServiceClient(callInvoker); + return new AdGroupCriterionServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupCriterionService client. + /// + public virtual AdGroupCriterionService.AdGroupCriterionServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupCriterionAsync( + new GetAdGroupCriterionRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupCriterionAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupCriterion GetAdGroupCriterion( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupCriterion( + new GetAdGroupCriterionRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionAsync( + GetAdGroupCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionAsync( + GetAdGroupCriterionRequest request, + st::CancellationToken cancellationToken) => GetAdGroupCriterionAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupCriterion GetAdGroupCriterion( + GetAdGroupCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriteriaAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupCriteriaAsync( + new MutateAdGroupCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriteriaAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupCriteriaAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupCriteriaResponse MutateAdGroupCriteria( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupCriteria( + new MutateAdGroupCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriteriaAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupCriteriaAsync( + new MutateAdGroupCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriteriaAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupCriteriaAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupCriteriaResponse MutateAdGroupCriteria( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupCriteria( + new MutateAdGroupCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriteriaAsync( + MutateAdGroupCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupCriteriaAsync( + MutateAdGroupCriteriaRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupCriteriaAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupCriteriaResponse MutateAdGroupCriteria( + MutateAdGroupCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupCriterionService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupCriterionServiceClientImpl : AdGroupCriterionServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupCriterion; + private readonly gaxgrpc::ApiCall _callMutateAdGroupCriteria; + + /// + /// Constructs a client wrapper for the AdGroupCriterionService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupCriterionServiceClientImpl(AdGroupCriterionService.AdGroupCriterionServiceClient grpcClient, AdGroupCriterionServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupCriterionServiceSettings effectiveSettings = settings ?? AdGroupCriterionServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupCriterion = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupCriterionAsync, GrpcClient.GetAdGroupCriterion, effectiveSettings.GetAdGroupCriterionSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroupCriteria = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupCriteriaAsync, GrpcClient.MutateAdGroupCriteria, effectiveSettings.MutateAdGroupCriteriaSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroupCriterion); + Modify_GetAdGroupCriterionApiCall(ref _callGetAdGroupCriterion); + Modify_ApiCall(ref _callMutateAdGroupCriteria); + Modify_MutateAdGroupCriteriaApiCall(ref _callMutateAdGroupCriteria); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupCriterionApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupCriteriaApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupCriterionService.AdGroupCriterionServiceClient grpcClient, AdGroupCriterionServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupCriterionService client. + /// + public override AdGroupCriterionService.AdGroupCriterionServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupCriterionRequest(ref GetAdGroupCriterionRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupCriteriaRequest(ref MutateAdGroupCriteriaRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupCriterionAsync( + GetAdGroupCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupCriterionRequest(ref request, ref callSettings); + return _callGetAdGroupCriterion.Async(request, callSettings); + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupCriterion GetAdGroupCriterion( + GetAdGroupCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupCriterionRequest(ref request, ref callSettings); + return _callGetAdGroupCriterion.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupCriteriaAsync( + MutateAdGroupCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupCriteriaRequest(ref request, ref callSettings); + return _callMutateAdGroupCriteria.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupCriteriaResponse MutateAdGroupCriteria( + MutateAdGroupCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupCriteriaRequest(ref request, ref callSettings); + return _callMutateAdGroupCriteria.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupCriterionServiceGrpc.cs b/src/V3/Stubs/AdGroupCriterionServiceGrpc.cs new file mode 100644 index 000000000..0cc4dbda6 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_criterion_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ad group criteria. + /// + public static partial class AdGroupCriterionService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupCriterionService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupCriterionRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupCriterion = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupCriteriaRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupCriteriaResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupCriterion = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupCriterion", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupCriterionRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupCriterion); + + static readonly grpc::Method __Method_MutateAdGroupCriteria = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroupCriteria", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupCriteriaRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupCriteriaResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupCriterionService + public abstract partial class AdGroupCriterionServiceBase + { + /// + /// Returns the requested criterion in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupCriterion(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroupCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupCriterionService + public partial class AdGroupCriterionServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupCriterionService + /// The channel to use to make remote calls. + public AdGroupCriterionServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupCriterionService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupCriterionServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupCriterionServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupCriterionServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion GetAdGroupCriterion(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupCriterion(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion GetAdGroupCriterion(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupCriterion, null, options, request); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupCriterionAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupCriterionAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupCriterionAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupCriterion, null, options, request); + } + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaResponse MutateAdGroupCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupCriteria(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaResponse MutateAdGroupCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroupCriteria, null, options, request); + } + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupCriteriaAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupCriteriaAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupCriteriaAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriteriaRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroupCriteria, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupCriterionServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupCriterionServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupCriterionServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupCriterion, serviceImpl.GetAdGroupCriterion) + .AddMethod(__Method_MutateAdGroupCriteria, serviceImpl.MutateAdGroupCriteria).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupCriterionServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupCriterion, serviceImpl.GetAdGroupCriterion); + serviceBinder.AddMethod(__Method_MutateAdGroupCriteria, serviceImpl.MutateAdGroupCriteria); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupCriterionSimulation.cs b/src/V3/Stubs/AdGroupCriterionSimulation.cs new file mode 100644 index 000000000..4221b9991 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionSimulation.cs @@ -0,0 +1,495 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_criterion_simulation.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_criterion_simulation.proto + public static partial class AdGroupCriterionSimulationReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_criterion_simulation.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionSimulationReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "Y3JpdGVyaW9uX3NpbXVsYXRpb24ucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlcxovZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29t", + "bW9uL3NpbXVsYXRpb24ucHJvdG8aQmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL3NpbXVsYXRpb25fbW9kaWZpY2F0aW9uX21ldGhvZC5wcm90bxoz", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvc2ltdWxhdGlvbl90eXBl", + "LnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29n", + "bGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBl", + "cnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8imgYKGkFk", + "R3JvdXBDcml0ZXJpb25TaW11bGF0aW9uElIKDXJlc291cmNlX25hbWUYASAB", + "KAlCO+BBBfpBNQozZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0FkR3JvdXBD", + "cml0ZXJpb25TaW11bGF0aW9uEjUKC2FkX2dyb3VwX2lkGAIgASgLMhsuZ29v", + "Z2xlLnByb3RvYnVmLkludDY0VmFsdWVCA+BBAxI2Cgxjcml0ZXJpb25faWQY", + "AyABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDElMKBHR5", + "cGUYBCABKA4yQC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5TaW11", + "bGF0aW9uVHlwZUVudW0uU2ltdWxhdGlvblR5cGVCA+BBAxJ+ChNtb2RpZmlj", + "YXRpb25fbWV0aG9kGAUgASgOMlwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuU2ltdWxhdGlvbk1vZGlmaWNhdGlvbk1ldGhvZEVudW0uU2ltdWxh", + "dGlvbk1vZGlmaWNhdGlvbk1ldGhvZEID4EEDEjUKCnN0YXJ0X2RhdGUYBiAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxIzCghlbmRf", + "ZGF0ZRgHIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EED", + "ElwKEmNwY19iaWRfcG9pbnRfbGlzdBgIIAEoCzI5Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmNvbW1vbi5DcGNCaWRTaW11bGF0aW9uUG9pbnRMaXN0QgPg", + "QQNIADqLAepBhwEKM2dvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZEdyb3Vw", + "Q3JpdGVyaW9uU2ltdWxhdGlvbhJQY3VzdG9tZXJzL3tjdXN0b21lcn0vYWRH", + "cm91cENyaXRlcmlvblNpbXVsYXRpb25zL3thZF9ncm91cF9jcml0ZXJpb25f", + "c2ltdWxhdGlvbn1CDAoKcG9pbnRfbGlzdEKMAgolY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnJlc291cmNlc0IfQWRHcm91cENyaXRlcmlvblNpbXVs", + "YXRpb25Qcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29n", + "bGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6IC", + "A0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdv", + "b2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.SimulationReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation), global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation.Parser, new[]{ "ResourceName", "AdGroupId", "CriterionId", "Type", "ModificationMethod", "StartDate", "EndDate", "CpcBidPointList" }, new[]{ "PointList" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad group criterion simulation. Supported combinations of advertising + /// channel type, criterion type, simulation type, and simulation modification + /// method are detailed below respectively. + /// + /// 1. DISPLAY - KEYWORD - CPC_BID - UNIFORM + /// 2. SEARCH - KEYWORD - CPC_BID - UNIFORM + /// 3. SHOPPING - LISTING_GROUP - CPC_BID - UNIFORM + /// + public sealed partial class AdGroupCriterionSimulation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupCriterionSimulation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulationReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionSimulation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionSimulation(AdGroupCriterionSimulation other) : this() { + resourceName_ = other.resourceName_; + AdGroupId = other.AdGroupId; + CriterionId = other.CriterionId; + type_ = other.type_; + modificationMethod_ = other.modificationMethod_; + StartDate = other.StartDate; + EndDate = other.EndDate; + switch (other.PointListCase) { + case PointListOneofCase.CpcBidPointList: + CpcBidPointList = other.CpcBidPointList.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionSimulation Clone() { + return new AdGroupCriterionSimulation(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group criterion simulation. + /// Ad group criterion simulation resource names have the form: + /// + /// `customers/{customer_id}/adGroupCriterionSimulations/{ad_group_id}~{criterion_id}~{type}~{modification_method}~{start_date}~{end_date}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "ad_group_id" field. + public const int AdGroupIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_adGroupId_codec = pb::FieldCodec.ForStructWrapper(18); + private long? adGroupId_; + /// + /// Output only. AdGroup ID of the simulation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AdGroupId { + get { return adGroupId_; } + set { + adGroupId_ = value; + } + } + + + /// Field number for the "criterion_id" field. + public const int CriterionIdFieldNumber = 3; + private static readonly pb::FieldCodec _single_criterionId_codec = pb::FieldCodec.ForStructWrapper(26); + private long? criterionId_; + /// + /// Output only. Criterion ID of the simulation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CriterionId { + get { return criterionId_; } + set { + criterionId_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType type_ = 0; + /// + /// Output only. The field that the simulation modifies. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "modification_method" field. + public const int ModificationMethodFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod modificationMethod_ = 0; + /// + /// Output only. How the simulation modifies the field. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod ModificationMethod { + get { return modificationMethod_; } + set { + modificationMethod_ = value; + } + } + + /// Field number for the "start_date" field. + public const int StartDateFieldNumber = 6; + private static readonly pb::FieldCodec _single_startDate_codec = pb::FieldCodec.ForClassWrapper(50); + private string startDate_; + /// + /// Output only. First day on which the simulation is based, in YYYY-MM-DD format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDate { + get { return startDate_; } + set { + startDate_ = value; + } + } + + + /// Field number for the "end_date" field. + public const int EndDateFieldNumber = 7; + private static readonly pb::FieldCodec _single_endDate_codec = pb::FieldCodec.ForClassWrapper(58); + private string endDate_; + /// + /// Output only. Last day on which the simulation is based, in YYYY-MM-DD format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDate { + get { return endDate_; } + set { + endDate_ = value; + } + } + + + /// Field number for the "cpc_bid_point_list" field. + public const int CpcBidPointListFieldNumber = 8; + /// + /// Output only. Simulation points if the simulation type is CPC_BID. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList CpcBidPointList { + get { return pointListCase_ == PointListOneofCase.CpcBidPointList ? (global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList) pointList_ : null; } + set { + pointList_ = value; + pointListCase_ = value == null ? PointListOneofCase.None : PointListOneofCase.CpcBidPointList; + } + } + + private object pointList_; + /// Enum of possible cases for the "point_list" oneof. + public enum PointListOneofCase { + None = 0, + CpcBidPointList = 8, + } + private PointListOneofCase pointListCase_ = PointListOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PointListOneofCase PointListCase { + get { return pointListCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearPointList() { + pointListCase_ = PointListOneofCase.None; + pointList_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupCriterionSimulation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupCriterionSimulation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (AdGroupId != other.AdGroupId) return false; + if (CriterionId != other.CriterionId) return false; + if (Type != other.Type) return false; + if (ModificationMethod != other.ModificationMethod) return false; + if (StartDate != other.StartDate) return false; + if (EndDate != other.EndDate) return false; + if (!object.Equals(CpcBidPointList, other.CpcBidPointList)) return false; + if (PointListCase != other.PointListCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (adGroupId_ != null) hash ^= AdGroupId.GetHashCode(); + if (criterionId_ != null) hash ^= CriterionId.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (ModificationMethod != 0) hash ^= ModificationMethod.GetHashCode(); + if (startDate_ != null) hash ^= StartDate.GetHashCode(); + if (endDate_ != null) hash ^= EndDate.GetHashCode(); + if (pointListCase_ == PointListOneofCase.CpcBidPointList) hash ^= CpcBidPointList.GetHashCode(); + hash ^= (int) pointListCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (adGroupId_ != null) { + _single_adGroupId_codec.WriteTagAndValue(output, AdGroupId); + } + if (criterionId_ != null) { + _single_criterionId_codec.WriteTagAndValue(output, CriterionId); + } + if (Type != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) Type); + } + if (ModificationMethod != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) ModificationMethod); + } + if (startDate_ != null) { + _single_startDate_codec.WriteTagAndValue(output, StartDate); + } + if (endDate_ != null) { + _single_endDate_codec.WriteTagAndValue(output, EndDate); + } + if (pointListCase_ == PointListOneofCase.CpcBidPointList) { + output.WriteRawTag(66); + output.WriteMessage(CpcBidPointList); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (adGroupId_ != null) { + size += _single_adGroupId_codec.CalculateSizeWithTag(AdGroupId); + } + if (criterionId_ != null) { + size += _single_criterionId_codec.CalculateSizeWithTag(CriterionId); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (ModificationMethod != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ModificationMethod); + } + if (startDate_ != null) { + size += _single_startDate_codec.CalculateSizeWithTag(StartDate); + } + if (endDate_ != null) { + size += _single_endDate_codec.CalculateSizeWithTag(EndDate); + } + if (pointListCase_ == PointListOneofCase.CpcBidPointList) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CpcBidPointList); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupCriterionSimulation other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.adGroupId_ != null) { + if (adGroupId_ == null || other.AdGroupId != 0L) { + AdGroupId = other.AdGroupId; + } + } + if (other.criterionId_ != null) { + if (criterionId_ == null || other.CriterionId != 0L) { + CriterionId = other.CriterionId; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.ModificationMethod != 0) { + ModificationMethod = other.ModificationMethod; + } + if (other.startDate_ != null) { + if (startDate_ == null || other.StartDate != "") { + StartDate = other.StartDate; + } + } + if (other.endDate_ != null) { + if (endDate_ == null || other.EndDate != "") { + EndDate = other.EndDate; + } + } + switch (other.PointListCase) { + case PointListOneofCase.CpcBidPointList: + if (CpcBidPointList == null) { + CpcBidPointList = new global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList(); + } + CpcBidPointList.MergeFrom(other.CpcBidPointList); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_adGroupId_codec.Read(input); + if (adGroupId_ == null || value != 0L) { + AdGroupId = value; + } + break; + } + case 26: { + long? value = _single_criterionId_codec.Read(input); + if (criterionId_ == null || value != 0L) { + CriterionId = value; + } + break; + } + case 32: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType) input.ReadEnum(); + break; + } + case 40: { + ModificationMethod = (global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod) input.ReadEnum(); + break; + } + case 50: { + string value = _single_startDate_codec.Read(input); + if (startDate_ == null || value != "") { + StartDate = value; + } + break; + } + case 58: { + string value = _single_endDate_codec.Read(input); + if (endDate_ == null || value != "") { + EndDate = value; + } + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList(); + if (pointListCase_ == PointListOneofCase.CpcBidPointList) { + subBuilder.MergeFrom(CpcBidPointList); + } + input.ReadMessage(subBuilder); + CpcBidPointList = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupCriterionSimulationService.cs b/src/V3/Stubs/AdGroupCriterionSimulationService.cs new file mode 100644 index 000000000..d7c7e3a66 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionSimulationService.cs @@ -0,0 +1,198 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_criterion_simulation_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_criterion_simulation_service.proto + public static partial class AdGroupCriterionSimulationServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_criterion_simulation_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionSimulationServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9j", + "cml0ZXJpb25fc2ltdWxhdGlvbl9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlcxpFZ29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvcmVzb3VyY2VzL2FkX2dyb3VwX2NyaXRlcmlvbl9zaW11bGF0aW9uLnBy", + "b3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBp", + "L2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90", + "byJCCiRHZXRBZEdyb3VwQ3JpdGVyaW9uU2ltdWxhdGlvblJlcXVlc3QSGgoN", + "cmVzb3VyY2VfbmFtZRgBIAEoCUID4EECMsACCiFBZEdyb3VwQ3JpdGVyaW9u", + "U2ltdWxhdGlvblNlcnZpY2US/QEKHUdldEFkR3JvdXBDcml0ZXJpb25TaW11", + "bGF0aW9uEkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR2V0", + "QWRHcm91cENyaXRlcmlvblNpbXVsYXRpb25SZXF1ZXN0Gj0uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkFkR3JvdXBDcml0ZXJpb25TaW11", + "bGF0aW9uIlWC0+STAj8SPS92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMv", + "Ki9hZEdyb3VwQ3JpdGVyaW9uU2ltdWxhdGlvbnMvKn3aQQ1yZXNvdXJjZV9u", + "YW1lGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21CjQIKJGNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0ImQWRHcm91cENyaXRlcmlv", + "blNpbXVsYXRpb25TZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2Vz", + "O3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2Vy", + "dmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulationReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionSimulationRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionSimulationRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [AdGroupCriterionSimulationService.GetAdGroupCriterionSimulation][google.ads.googleads.v3.services.AdGroupCriterionSimulationService.GetAdGroupCriterionSimulation]. + /// + public sealed partial class GetAdGroupCriterionSimulationRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupCriterionSimulationRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionSimulationServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionSimulationRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionSimulationRequest(GetAdGroupCriterionSimulationRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupCriterionSimulationRequest Clone() { + return new GetAdGroupCriterionSimulationRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group criterion simulation to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupCriterionSimulationRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupCriterionSimulationRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupCriterionSimulationRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupCriterionSimulationServiceClient.cs b/src/V3/Stubs/AdGroupCriterionSimulationServiceClient.cs new file mode 100644 index 000000000..24060c73c --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionSimulationServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupCriterionSimulationServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupCriterionSimulationServiceSettings GetDefault() => new AdGroupCriterionSimulationServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupCriterionSimulationServiceSettings() { } + + private AdGroupCriterionSimulationServiceSettings(AdGroupCriterionSimulationServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupCriterionSimulationSettings = existing.GetAdGroupCriterionSimulationSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupCriterionSimulationServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupCriterionSimulationServiceClient.GetAdGroupCriterionSimulation and AdGroupCriterionSimulationServiceClient.GetAdGroupCriterionSimulationAsync. + /// + /// + /// The default AdGroupCriterionSimulationServiceClient.GetAdGroupCriterionSimulation and + /// AdGroupCriterionSimulationServiceClient.GetAdGroupCriterionSimulationAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupCriterionSimulationSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupCriterionSimulationServiceSettings Clone() => new AdGroupCriterionSimulationServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupCriterionSimulationServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupCriterionSimulationServiceSettings Settings { get; set; } + + /// + public override AdGroupCriterionSimulationServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupCriterionSimulationServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupCriterionSimulationServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupCriterionSimulationServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupCriterionSimulationServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupCriterionSimulationServiceClient.ChannelPool; + } + + /// + /// AdGroupCriterionSimulationService client wrapper, for convenient use. + /// + public abstract partial class AdGroupCriterionSimulationServiceClient + { + /// + /// The default endpoint for the AdGroupCriterionSimulationService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupCriterionSimulationService scopes. + /// + /// + /// The default AdGroupCriterionSimulationService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupCriterionSimulationServiceClient client = await AdGroupCriterionSimulationServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupCriterionSimulationServiceClient.DefaultEndpoint.Host, AdGroupCriterionSimulationServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupCriterionSimulationServiceClient client = AdGroupCriterionSimulationServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupCriterionSimulationServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupCriterionSimulationServiceClient client = AdGroupCriterionSimulationServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupCriterionSimulationServiceClient.DefaultEndpoint.Host, AdGroupCriterionSimulationServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupCriterionSimulationServiceClient client = AdGroupCriterionSimulationServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupCriterionSimulationServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupCriterionSimulationServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupCriterionSimulationServiceClient Create(grpccore::Channel channel, AdGroupCriterionSimulationServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupCriterionSimulationServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupCriterionSimulationServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupCriterionSimulationService.AdGroupCriterionSimulationServiceClient grpcClient = new AdGroupCriterionSimulationService.AdGroupCriterionSimulationServiceClient(callInvoker); + return new AdGroupCriterionSimulationServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupCriterionSimulationService client. + /// + public virtual AdGroupCriterionSimulationService.AdGroupCriterionSimulationServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// + /// Required. The resource name of the ad group criterion simulation to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionSimulationAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupCriterionSimulationAsync( + new GetAdGroupCriterionSimulationRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// + /// Required. The resource name of the ad group criterion simulation to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionSimulationAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupCriterionSimulationAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// + /// Required. The resource name of the ad group criterion simulation to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupCriterionSimulation GetAdGroupCriterionSimulation( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupCriterionSimulation( + new GetAdGroupCriterionSimulationRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionSimulationAsync( + GetAdGroupCriterionSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupCriterionSimulationAsync( + GetAdGroupCriterionSimulationRequest request, + st::CancellationToken cancellationToken) => GetAdGroupCriterionSimulationAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupCriterionSimulation GetAdGroupCriterionSimulation( + GetAdGroupCriterionSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupCriterionSimulationService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupCriterionSimulationServiceClientImpl : AdGroupCriterionSimulationServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupCriterionSimulation; + + /// + /// Constructs a client wrapper for the AdGroupCriterionSimulationService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupCriterionSimulationServiceClientImpl(AdGroupCriterionSimulationService.AdGroupCriterionSimulationServiceClient grpcClient, AdGroupCriterionSimulationServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupCriterionSimulationServiceSettings effectiveSettings = settings ?? AdGroupCriterionSimulationServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupCriterionSimulation = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupCriterionSimulationAsync, GrpcClient.GetAdGroupCriterionSimulation, effectiveSettings.GetAdGroupCriterionSimulationSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetAdGroupCriterionSimulation); + Modify_GetAdGroupCriterionSimulationApiCall(ref _callGetAdGroupCriterionSimulation); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupCriterionSimulationApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupCriterionSimulationService.AdGroupCriterionSimulationServiceClient grpcClient, AdGroupCriterionSimulationServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupCriterionSimulationService client. + /// + public override AdGroupCriterionSimulationService.AdGroupCriterionSimulationServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupCriterionSimulationRequest(ref GetAdGroupCriterionSimulationRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupCriterionSimulationAsync( + GetAdGroupCriterionSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupCriterionSimulationRequest(ref request, ref callSettings); + return _callGetAdGroupCriterionSimulation.Async(request, callSettings); + } + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupCriterionSimulation GetAdGroupCriterionSimulation( + GetAdGroupCriterionSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupCriterionSimulationRequest(ref request, ref callSettings); + return _callGetAdGroupCriterionSimulation.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupCriterionSimulationServiceGrpc.cs b/src/V3/Stubs/AdGroupCriterionSimulationServiceGrpc.cs new file mode 100644 index 000000000..d54f99b30 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionSimulationServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_criterion_simulation_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch ad group criterion simulations. + /// + public static partial class AdGroupCriterionSimulationService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupCriterionSimulationService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupCriterionSimulationRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionSimulationRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupCriterionSimulation = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupCriterionSimulation = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupCriterionSimulation", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupCriterionSimulationRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupCriterionSimulation); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionSimulationServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupCriterionSimulationService + public abstract partial class AdGroupCriterionSimulationServiceBase + { + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupCriterionSimulation(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionSimulationRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupCriterionSimulationService + public partial class AdGroupCriterionSimulationServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupCriterionSimulationService + /// The channel to use to make remote calls. + public AdGroupCriterionSimulationServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupCriterionSimulationService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupCriterionSimulationServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupCriterionSimulationServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupCriterionSimulationServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation GetAdGroupCriterionSimulation(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionSimulationRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupCriterionSimulation(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation GetAdGroupCriterionSimulation(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionSimulationRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupCriterionSimulation, null, options, request); + } + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupCriterionSimulationAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionSimulationRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupCriterionSimulationAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group criterion simulation in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupCriterionSimulationAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupCriterionSimulationRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupCriterionSimulation, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupCriterionSimulationServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupCriterionSimulationServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupCriterionSimulationServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupCriterionSimulation, serviceImpl.GetAdGroupCriterionSimulation).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupCriterionSimulationServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupCriterionSimulation, serviceImpl.GetAdGroupCriterionSimulation); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupCriterionStatus.cs b/src/V3/Stubs/AdGroupCriterionStatus.cs new file mode 100644 index 000000000..540dfd0b7 --- /dev/null +++ b/src/V3/Stubs/AdGroupCriterionStatus.cs @@ -0,0 +1,192 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_group_criterion_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_group_criterion_status.proto + public static partial class AdGroupCriterionStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_group_criterion_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupCriterionStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9ncm91cF9jcml0", + "ZXJpb25fc3RhdHVzLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJ6ChpBZEdyb3Vw", + "Q3JpdGVyaW9uU3RhdHVzRW51bSJcChZBZEdyb3VwQ3JpdGVyaW9uU3RhdHVz", + "Eg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB0VOQUJMRUQQAhIK", + "CgZQQVVTRUQQAxILCgdSRU1PVkVEEARC8AEKIWNvbS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtc0IbQWRHcm91cENyaXRlcmlvblN0YXR1c1Byb3Rv", + "UAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "RW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusEnum.Types.AdGroupCriterionStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing AdGroupCriterion statuses. + /// + public sealed partial class AdGroupCriterionStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupCriterionStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdGroupCriterionStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionStatusEnum(AdGroupCriterionStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupCriterionStatusEnum Clone() { + return new AdGroupCriterionStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupCriterionStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupCriterionStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupCriterionStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupCriterionStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of an AdGroupCriterion. + /// + public enum AdGroupCriterionStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The ad group criterion is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// The ad group criterion is paused. + /// + [pbr::OriginalName("PAUSED")] Paused = 3, + /// + /// The ad group criterion is removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupError.cs b/src/V3/Stubs/AdGroupError.cs new file mode 100644 index 000000000..d081ba902 --- /dev/null +++ b/src/V3/Stubs/AdGroupError.cs @@ -0,0 +1,238 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_group_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_group_error.proto + public static partial class AdGroupErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_group_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfZ3JvdXBfZXJy", + "b3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKgBAoQQWRHcm91cEVycm9yRW51", + "bSKLBAoMQWRHcm91cEVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9X", + "ThABEhoKFkRVUExJQ0FURV9BREdST1VQX05BTUUQAhIYChRJTlZBTElEX0FE", + "R1JPVVBfTkFNRRADEiUKIUFEVkVSVElTRVJfTk9UX09OX0NPTlRFTlRfTkVU", + "V09SSxAFEg8KC0JJRF9UT09fQklHEAYSKgomQklEX1RZUEVfQU5EX0JJRERJ", + "TkdfU1RSQVRFR1lfTUlTTUFUQ0gQBxIYChRNSVNTSU5HX0FER1JPVVBfTkFN", + "RRAIEiAKHEFER1JPVVBfTEFCRUxfRE9FU19OT1RfRVhJU1QQCRIgChxBREdS", + "T1VQX0xBQkVMX0FMUkVBRFlfRVhJU1RTEAoSLAooSU5WQUxJRF9DT05URU5U", + "X0JJRF9DUklURVJJT05fVFlQRV9HUk9VUBALEjgKNEFEX0dST1VQX1RZUEVf", + "Tk9UX1ZBTElEX0ZPUl9BRFZFUlRJU0lOR19DSEFOTkVMX1RZUEUQDBI5CjVB", + "REdST1VQX1RZUEVfTk9UX1NVUFBPUlRFRF9GT1JfQ0FNUEFJR05fU0FMRVNf", + "Q09VTlRSWRANEkIKPkNBTk5PVF9BRERfQURHUk9VUF9PRl9UWVBFX0RTQV9U", + "T19DQU1QQUlHTl9XSVRIT1VUX0RTQV9TRVRUSU5HEA5C7AEKImNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNCEUFkR3JvdXBFcnJvclByb3Rv", + "UAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9lcnJvcnM7ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFk", + "cy5Hb29nbGVBZHMuVjMuRXJyb3JzygIeR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVycm9y", + "c2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdGroupErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupErrorEnum.Types.AdGroupError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad group errors. + /// + public sealed partial class AdGroupErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdGroupErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupErrorEnum(AdGroupErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupErrorEnum Clone() { + return new AdGroupErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad group errors. + /// + public enum AdGroupError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// AdGroup with the same name already exists for the campaign. + /// + [pbr::OriginalName("DUPLICATE_ADGROUP_NAME")] DuplicateAdgroupName = 2, + /// + /// AdGroup name is not valid. + /// + [pbr::OriginalName("INVALID_ADGROUP_NAME")] InvalidAdgroupName = 3, + /// + /// Advertiser is not allowed to target sites or set site bids that are not + /// on the Google Search Network. + /// + [pbr::OriginalName("ADVERTISER_NOT_ON_CONTENT_NETWORK")] AdvertiserNotOnContentNetwork = 5, + /// + /// Bid amount is too big. + /// + [pbr::OriginalName("BID_TOO_BIG")] BidTooBig = 6, + /// + /// AdGroup bid does not match the campaign's bidding strategy. + /// + [pbr::OriginalName("BID_TYPE_AND_BIDDING_STRATEGY_MISMATCH")] BidTypeAndBiddingStrategyMismatch = 7, + /// + /// AdGroup name is required for Add. + /// + [pbr::OriginalName("MISSING_ADGROUP_NAME")] MissingAdgroupName = 8, + /// + /// No link found between the ad group and the label. + /// + [pbr::OriginalName("ADGROUP_LABEL_DOES_NOT_EXIST")] AdgroupLabelDoesNotExist = 9, + /// + /// The label has already been attached to the ad group. + /// + [pbr::OriginalName("ADGROUP_LABEL_ALREADY_EXISTS")] AdgroupLabelAlreadyExists = 10, + /// + /// The CriterionTypeGroup is not supported for the content bid dimension. + /// + [pbr::OriginalName("INVALID_CONTENT_BID_CRITERION_TYPE_GROUP")] InvalidContentBidCriterionTypeGroup = 11, + /// + /// The ad group type is not compatible with the campaign channel type. + /// + [pbr::OriginalName("AD_GROUP_TYPE_NOT_VALID_FOR_ADVERTISING_CHANNEL_TYPE")] AdGroupTypeNotValidForAdvertisingChannelType = 12, + /// + /// The ad group type is not supported in the country of sale of the + /// campaign. + /// + [pbr::OriginalName("ADGROUP_TYPE_NOT_SUPPORTED_FOR_CAMPAIGN_SALES_COUNTRY")] AdgroupTypeNotSupportedForCampaignSalesCountry = 13, + /// + /// Ad groups of AdGroupType.SEARCH_DYNAMIC_ADS can only be added to + /// campaigns that have DynamicSearchAdsSetting attached. + /// + [pbr::OriginalName("CANNOT_ADD_ADGROUP_OF_TYPE_DSA_TO_CAMPAIGN_WITHOUT_DSA_SETTING")] CannotAddAdgroupOfTypeDsaToCampaignWithoutDsaSetting = 14, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupExtensionSetting.cs b/src/V3/Stubs/AdGroupExtensionSetting.cs new file mode 100644 index 000000000..ce126500f --- /dev/null +++ b/src/V3/Stubs/AdGroupExtensionSetting.cs @@ -0,0 +1,336 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_extension_setting.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_extension_setting.proto + public static partial class AdGroupExtensionSettingReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_extension_setting.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupExtensionSettingReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "ZXh0ZW5zaW9uX3NldHRpbmcucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMv", + "ZXh0ZW5zaW9uX3NldHRpbmdfZGV2aWNlLnByb3RvGjJnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcy9leHRlbnNpb25fdHlwZS5wcm90bxofZ29vZ2xl", + "L2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJj", + "ZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvQEChdBZEdyb3VwRXh0ZW5zaW9u", + "U2V0dGluZxJPCg1yZXNvdXJjZV9uYW1lGAEgASgJQjjgQQX6QTIKMGdvb2ds", + "ZWFkcy5nb29nbGVhcGlzLmNvbS9BZEdyb3VwRXh0ZW5zaW9uU2V0dGluZxJb", + "Cg5leHRlbnNpb25fdHlwZRgCIAEoDjI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zLkV4dGVuc2lvblR5cGVFbnVtLkV4dGVuc2lvblR5cGVCA+BB", + "BRJYCghhZF9ncm91cBgDIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZUIo4EEF+kEiCiBnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91", + "cBJrChRleHRlbnNpb25fZmVlZF9pdGVtcxgEIAMoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZUIv+kEsCipnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b20vRXh0ZW5zaW9uRmVlZEl0ZW0SYAoGZGV2aWNlGAUgASgOMlAuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXMuRXh0ZW5zaW9uU2V0dGluZ0Rldmlj", + "ZUVudW0uRXh0ZW5zaW9uU2V0dGluZ0RldmljZTqBAepBfgowZ29vZ2xlYWRz", + "Lmdvb2dsZWFwaXMuY29tL0FkR3JvdXBFeHRlbnNpb25TZXR0aW5nEkpjdXN0", + "b21lcnMve2N1c3RvbWVyfS9hZEdyb3VwRXh0ZW5zaW9uU2V0dGluZ3Mve2Fk", + "X2dyb3VwX2V4dGVuc2lvbl9zZXR0aW5nfUKJAgolY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnJlc291cmNlc0IcQWRHcm91cEV4dGVuc2lvblNldHRp", + "bmdQcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dB", + "QaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2ds", + "ZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting), global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting.Parser, new[]{ "ResourceName", "ExtensionType", "AdGroup", "ExtensionFeedItems", "Device" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad group extension setting. + /// + public sealed partial class AdGroupExtensionSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupExtensionSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSettingReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupExtensionSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupExtensionSetting(AdGroupExtensionSetting other) : this() { + resourceName_ = other.resourceName_; + extensionType_ = other.extensionType_; + AdGroup = other.AdGroup; + extensionFeedItems_ = other.extensionFeedItems_.Clone(); + device_ = other.device_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupExtensionSetting Clone() { + return new AdGroupExtensionSetting(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group extension setting. + /// AdGroupExtensionSetting resource names have the form: + /// + /// `customers/{customer_id}/adGroupExtensionSettings/{ad_group_id}~{extension_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "extension_type" field. + public const int ExtensionTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType extensionType_ = 0; + /// + /// Immutable. The extension type of the ad group extension setting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType ExtensionType { + get { return extensionType_; } + set { + extensionType_ = value; + } + } + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 3; + private static readonly pb::FieldCodec _single_adGroup_codec = pb::FieldCodec.ForClassWrapper(26); + private string adGroup_; + /// + /// Immutable. The resource name of the ad group. The linked extension feed items will + /// serve under this ad group. + /// AdGroup resource names have the form: + /// + /// `customers/{customer_id}/adGroups/{ad_group_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroup { + get { return adGroup_; } + set { + adGroup_ = value; + } + } + + + /// Field number for the "extension_feed_items" field. + public const int ExtensionFeedItemsFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_extensionFeedItems_codec + = pb::FieldCodec.ForClassWrapper(34); + private readonly pbc::RepeatedField extensionFeedItems_ = new pbc::RepeatedField(); + /// + /// The resource names of the extension feed items to serve under the ad group. + /// ExtensionFeedItem resource names have the form: + /// + /// `customers/{customer_id}/extensionFeedItems/{feed_item_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ExtensionFeedItems { + get { return extensionFeedItems_; } + } + + /// Field number for the "device" field. + public const int DeviceFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice device_ = 0; + /// + /// The device for which the extensions will serve. Optional. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice Device { + get { return device_; } + set { + device_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupExtensionSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupExtensionSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (ExtensionType != other.ExtensionType) return false; + if (AdGroup != other.AdGroup) return false; + if(!extensionFeedItems_.Equals(other.extensionFeedItems_)) return false; + if (Device != other.Device) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (ExtensionType != 0) hash ^= ExtensionType.GetHashCode(); + if (adGroup_ != null) hash ^= AdGroup.GetHashCode(); + hash ^= extensionFeedItems_.GetHashCode(); + if (Device != 0) hash ^= Device.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (ExtensionType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) ExtensionType); + } + if (adGroup_ != null) { + _single_adGroup_codec.WriteTagAndValue(output, AdGroup); + } + extensionFeedItems_.WriteTo(output, _repeated_extensionFeedItems_codec); + if (Device != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Device); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (ExtensionType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ExtensionType); + } + if (adGroup_ != null) { + size += _single_adGroup_codec.CalculateSizeWithTag(AdGroup); + } + size += extensionFeedItems_.CalculateSize(_repeated_extensionFeedItems_codec); + if (Device != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Device); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupExtensionSetting other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.ExtensionType != 0) { + ExtensionType = other.ExtensionType; + } + if (other.adGroup_ != null) { + if (adGroup_ == null || other.AdGroup != "") { + AdGroup = other.AdGroup; + } + } + extensionFeedItems_.Add(other.extensionFeedItems_); + if (other.Device != 0) { + Device = other.Device; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 16: { + ExtensionType = (global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType) input.ReadEnum(); + break; + } + case 26: { + string value = _single_adGroup_codec.Read(input); + if (adGroup_ == null || value != "") { + AdGroup = value; + } + break; + } + case 34: { + extensionFeedItems_.AddEntriesFrom(input, _repeated_extensionFeedItems_codec); + break; + } + case 40: { + Device = (global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupExtensionSettingService.cs b/src/V3/Stubs/AdGroupExtensionSettingService.cs new file mode 100644 index 000000000..bd1feb039 --- /dev/null +++ b/src/V3/Stubs/AdGroupExtensionSettingService.cs @@ -0,0 +1,1044 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_extension_setting_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_extension_setting_service.proto + public static partial class AdGroupExtensionSettingServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_extension_setting_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupExtensionSettingServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cklnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9l", + "eHRlbnNpb25fc2V0dGluZ19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcxpCZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "cmVzb3VyY2VzL2FkX2dyb3VwX2V4dGVuc2lvbl9zZXR0aW5nLnByb3RvGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVu", + "dC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29v", + "Z2xlL3Byb3RvYnVmL2ZpZWxkX21hc2sucHJvdG8aF2dvb2dsZS9ycGMvc3Rh", + "dHVzLnByb3RvIj8KIUdldEFkR3JvdXBFeHRlbnNpb25TZXR0aW5nUmVxdWVz", + "dBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIizgEKJU11dGF0ZUFkR3Jv", + "dXBFeHRlbnNpb25TZXR0aW5nc1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASAB", + "KAlCA+BBAhJbCgpvcGVyYXRpb25zGAIgAygLMkIuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXMuQWRHcm91cEV4dGVuc2lvblNldHRpbmdPcGVy", + "YXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyABKAgSFQoNdmFsaWRh", + "dGVfb25seRgEIAEoCCKOAgogQWRHcm91cEV4dGVuc2lvblNldHRpbmdPcGVy", + "YXRpb24SLwoLdXBkYXRlX21hc2sYBCABKAsyGi5nb29nbGUucHJvdG9idWYu", + "RmllbGRNYXNrEkwKBmNyZWF0ZRgBIAEoCzI6Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlcy5BZEdyb3VwRXh0ZW5zaW9uU2V0dGluZ0gAEkwK", + "BnVwZGF0ZRgCIAEoCzI6Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291", + "cmNlcy5BZEdyb3VwRXh0ZW5zaW9uU2V0dGluZ0gAEhAKBnJlbW92ZRgDIAEo", + "CUgAQgsKCW9wZXJhdGlvbiKzAQomTXV0YXRlQWRHcm91cEV4dGVuc2lvblNl", + "dHRpbmdzUmVzcG9uc2USMQoVcGFydGlhbF9mYWlsdXJlX2Vycm9yGAMgASgL", + "MhIuZ29vZ2xlLnJwYy5TdGF0dXMSVgoHcmVzdWx0cxgCIAMoCzJFLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBFeHRl", + "bnNpb25TZXR0aW5nUmVzdWx0IjwKI011dGF0ZUFkR3JvdXBFeHRlbnNpb25T", + "ZXR0aW5nUmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAkyygQKHkFkR3Jv", + "dXBFeHRlbnNpb25TZXR0aW5nU2VydmljZRLxAQoaR2V0QWRHcm91cEV4dGVu", + "c2lvblNldHRpbmcSQy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5HZXRBZEdyb3VwRXh0ZW5zaW9uU2V0dGluZ1JlcXVlc3QaOi5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cEV4dGVuc2lvblNl", + "dHRpbmciUoLT5JMCPBI6L3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8q", + "L2FkR3JvdXBFeHRlbnNpb25TZXR0aW5ncy8qfdpBDXJlc291cmNlX25hbWUS", + "lgIKHk11dGF0ZUFkR3JvdXBFeHRlbnNpb25TZXR0aW5ncxJHLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBFeHRlbnNp", + "b25TZXR0aW5nc1JlcXVlc3QaSC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5NdXRhdGVBZEdyb3VwRXh0ZW5zaW9uU2V0dGluZ3NSZXNwb25z", + "ZSJhgtPkkwJCIj0vdjMvY3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfS9hZEdy", + "b3VwRXh0ZW5zaW9uU2V0dGluZ3M6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQs", + "b3BlcmF0aW9ucxobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQooCCiRj", + "b20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCI0FkR3JvdXBF", + "eHRlbnNpb25TZXR0aW5nU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcu", + "b3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2", + "aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPq", + "AiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3Rv", + "Mw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSettingReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupExtensionSettingRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupExtensionSettingRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [AdGroupExtensionSettingService.GetAdGroupExtensionSetting][google.ads.googleads.v3.services.AdGroupExtensionSettingService.GetAdGroupExtensionSetting]. + /// + public sealed partial class GetAdGroupExtensionSettingRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupExtensionSettingRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupExtensionSettingRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupExtensionSettingRequest(GetAdGroupExtensionSettingRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupExtensionSettingRequest Clone() { + return new GetAdGroupExtensionSettingRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group extension setting to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupExtensionSettingRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupExtensionSettingRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupExtensionSettingRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [AdGroupExtensionSettingService.MutateAdGroupExtensionSettings][google.ads.googleads.v3.services.AdGroupExtensionSettingService.MutateAdGroupExtensionSettings]. + /// + public sealed partial class MutateAdGroupExtensionSettingsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupExtensionSettingsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingsRequest(MutateAdGroupExtensionSettingsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingsRequest Clone() { + return new MutateAdGroupExtensionSettingsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose ad group extension settings are being + /// modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual ad group extension + /// settings. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupExtensionSettingsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupExtensionSettingsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupExtensionSettingsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on an ad group extension setting. + /// + public sealed partial class AdGroupExtensionSettingOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupExtensionSettingOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupExtensionSettingOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupExtensionSettingOperation(AdGroupExtensionSettingOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupExtensionSettingOperation Clone() { + return new AdGroupExtensionSettingOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad group + /// extension setting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The ad group extension setting is expected to have a + /// valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed ad group extension + /// setting is expected, in this format: + /// + /// `customers/{customer_id}/adGroupExtensionSettings/{ad_group_id}~{extension_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupExtensionSettingOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupExtensionSettingOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupExtensionSettingOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for an ad group extension setting mutate. + /// + public sealed partial class MutateAdGroupExtensionSettingsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupExtensionSettingsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingsResponse(MutateAdGroupExtensionSettingsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingsResponse Clone() { + return new MutateAdGroupExtensionSettingsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupExtensionSettingsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupExtensionSettingsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupExtensionSettingsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the ad group extension setting mutate. + /// + public sealed partial class MutateAdGroupExtensionSettingResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupExtensionSettingResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingResult(MutateAdGroupExtensionSettingResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupExtensionSettingResult Clone() { + return new MutateAdGroupExtensionSettingResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupExtensionSettingResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupExtensionSettingResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupExtensionSettingResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupExtensionSettingServiceClient.cs b/src/V3/Stubs/AdGroupExtensionSettingServiceClient.cs new file mode 100644 index 000000000..1d5dc10d5 --- /dev/null +++ b/src/V3/Stubs/AdGroupExtensionSettingServiceClient.cs @@ -0,0 +1,910 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupExtensionSettingServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupExtensionSettingServiceSettings GetDefault() => new AdGroupExtensionSettingServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupExtensionSettingServiceSettings() { } + + private AdGroupExtensionSettingServiceSettings(AdGroupExtensionSettingServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupExtensionSettingSettings = existing.GetAdGroupExtensionSettingSettings; + MutateAdGroupExtensionSettingsSettings = existing.MutateAdGroupExtensionSettingsSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupExtensionSettingServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupExtensionSettingServiceClient.GetAdGroupExtensionSetting and AdGroupExtensionSettingServiceClient.GetAdGroupExtensionSettingAsync. + /// + /// + /// The default AdGroupExtensionSettingServiceClient.GetAdGroupExtensionSetting and + /// AdGroupExtensionSettingServiceClient.GetAdGroupExtensionSettingAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupExtensionSettingSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupExtensionSettingServiceClient.MutateAdGroupExtensionSettings and AdGroupExtensionSettingServiceClient.MutateAdGroupExtensionSettingsAsync. + /// + /// + /// The default AdGroupExtensionSettingServiceClient.MutateAdGroupExtensionSettings and + /// AdGroupExtensionSettingServiceClient.MutateAdGroupExtensionSettingsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupExtensionSettingsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupExtensionSettingServiceSettings Clone() => new AdGroupExtensionSettingServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupExtensionSettingServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupExtensionSettingServiceSettings Settings { get; set; } + + /// + public override AdGroupExtensionSettingServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupExtensionSettingServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupExtensionSettingServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupExtensionSettingServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupExtensionSettingServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupExtensionSettingServiceClient.ChannelPool; + } + + /// + /// AdGroupExtensionSettingService client wrapper, for convenient use. + /// + public abstract partial class AdGroupExtensionSettingServiceClient + { + /// + /// The default endpoint for the AdGroupExtensionSettingService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupExtensionSettingService scopes. + /// + /// + /// The default AdGroupExtensionSettingService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupExtensionSettingServiceClient client = await AdGroupExtensionSettingServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupExtensionSettingServiceClient.DefaultEndpoint.Host, AdGroupExtensionSettingServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupExtensionSettingServiceClient client = AdGroupExtensionSettingServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupExtensionSettingServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupExtensionSettingServiceClient client = AdGroupExtensionSettingServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupExtensionSettingServiceClient.DefaultEndpoint.Host, AdGroupExtensionSettingServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupExtensionSettingServiceClient client = AdGroupExtensionSettingServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupExtensionSettingServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupExtensionSettingServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupExtensionSettingServiceClient Create(grpccore::Channel channel, AdGroupExtensionSettingServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupExtensionSettingServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupExtensionSettingServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupExtensionSettingService.AdGroupExtensionSettingServiceClient grpcClient = new AdGroupExtensionSettingService.AdGroupExtensionSettingServiceClient(callInvoker); + return new AdGroupExtensionSettingServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupExtensionSettingService client. + /// + public virtual AdGroupExtensionSettingService.AdGroupExtensionSettingServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// + /// Required. The resource name of the ad group extension setting to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupExtensionSettingAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupExtensionSettingAsync( + new GetAdGroupExtensionSettingRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// + /// Required. The resource name of the ad group extension setting to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupExtensionSettingAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupExtensionSettingAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// + /// Required. The resource name of the ad group extension setting to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupExtensionSetting GetAdGroupExtensionSetting( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupExtensionSetting( + new GetAdGroupExtensionSettingRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupExtensionSettingAsync( + GetAdGroupExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupExtensionSettingAsync( + GetAdGroupExtensionSettingRequest request, + st::CancellationToken cancellationToken) => GetAdGroupExtensionSettingAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupExtensionSetting GetAdGroupExtensionSetting( + GetAdGroupExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad group extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual ad group extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupExtensionSettingsAsync( + new MutateAdGroupExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad group extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual ad group extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupExtensionSettingsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad group extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual ad group extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupExtensionSettingsResponse MutateAdGroupExtensionSettings( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupExtensionSettings( + new MutateAdGroupExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad group extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual ad group extension + /// settings. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupExtensionSettingsAsync( + new MutateAdGroupExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad group extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual ad group extension + /// settings. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupExtensionSettingsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad group extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual ad group extension + /// settings. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupExtensionSettingsResponse MutateAdGroupExtensionSettings( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupExtensionSettings( + new MutateAdGroupExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupExtensionSettingsAsync( + MutateAdGroupExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupExtensionSettingsAsync( + MutateAdGroupExtensionSettingsRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupExtensionSettingsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupExtensionSettingsResponse MutateAdGroupExtensionSettings( + MutateAdGroupExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupExtensionSettingService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupExtensionSettingServiceClientImpl : AdGroupExtensionSettingServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupExtensionSetting; + private readonly gaxgrpc::ApiCall _callMutateAdGroupExtensionSettings; + + /// + /// Constructs a client wrapper for the AdGroupExtensionSettingService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupExtensionSettingServiceClientImpl(AdGroupExtensionSettingService.AdGroupExtensionSettingServiceClient grpcClient, AdGroupExtensionSettingServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupExtensionSettingServiceSettings effectiveSettings = settings ?? AdGroupExtensionSettingServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupExtensionSetting = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupExtensionSettingAsync, GrpcClient.GetAdGroupExtensionSetting, effectiveSettings.GetAdGroupExtensionSettingSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroupExtensionSettings = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupExtensionSettingsAsync, GrpcClient.MutateAdGroupExtensionSettings, effectiveSettings.MutateAdGroupExtensionSettingsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroupExtensionSetting); + Modify_GetAdGroupExtensionSettingApiCall(ref _callGetAdGroupExtensionSetting); + Modify_ApiCall(ref _callMutateAdGroupExtensionSettings); + Modify_MutateAdGroupExtensionSettingsApiCall(ref _callMutateAdGroupExtensionSettings); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupExtensionSettingApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupExtensionSettingsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupExtensionSettingService.AdGroupExtensionSettingServiceClient grpcClient, AdGroupExtensionSettingServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupExtensionSettingService client. + /// + public override AdGroupExtensionSettingService.AdGroupExtensionSettingServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupExtensionSettingRequest(ref GetAdGroupExtensionSettingRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupExtensionSettingsRequest(ref MutateAdGroupExtensionSettingsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupExtensionSettingAsync( + GetAdGroupExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupExtensionSettingRequest(ref request, ref callSettings); + return _callGetAdGroupExtensionSetting.Async(request, callSettings); + } + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupExtensionSetting GetAdGroupExtensionSetting( + GetAdGroupExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupExtensionSettingRequest(ref request, ref callSettings); + return _callGetAdGroupExtensionSetting.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupExtensionSettingsAsync( + MutateAdGroupExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupExtensionSettingsRequest(ref request, ref callSettings); + return _callMutateAdGroupExtensionSettings.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupExtensionSettingsResponse MutateAdGroupExtensionSettings( + MutateAdGroupExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupExtensionSettingsRequest(ref request, ref callSettings); + return _callMutateAdGroupExtensionSettings.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupExtensionSettingServiceGrpc.cs b/src/V3/Stubs/AdGroupExtensionSettingServiceGrpc.cs new file mode 100644 index 000000000..231e2dcd2 --- /dev/null +++ b/src/V3/Stubs/AdGroupExtensionSettingServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_extension_setting_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ad group extension settings. + /// + public static partial class AdGroupExtensionSettingService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupExtensionSettingService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupExtensionSettingRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupExtensionSettingRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupExtensionSetting = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupExtensionSettingsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupExtensionSettingsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupExtensionSetting = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupExtensionSetting", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupExtensionSettingRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupExtensionSetting); + + static readonly grpc::Method __Method_MutateAdGroupExtensionSettings = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroupExtensionSettings", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupExtensionSettingsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupExtensionSettingsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupExtensionSettingService + public abstract partial class AdGroupExtensionSettingServiceBase + { + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupExtensionSettingRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroupExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupExtensionSettingService + public partial class AdGroupExtensionSettingServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupExtensionSettingService + /// The channel to use to make remote calls. + public AdGroupExtensionSettingServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupExtensionSettingService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupExtensionSettingServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupExtensionSettingServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupExtensionSettingServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting GetAdGroupExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupExtensionSettingRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupExtensionSetting(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting GetAdGroupExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupExtensionSettingRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupExtensionSetting, null, options, request); + } + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupExtensionSettingAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupExtensionSettingRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupExtensionSettingAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group extension setting in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupExtensionSettingAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupExtensionSettingRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupExtensionSetting, null, options, request); + } + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsResponse MutateAdGroupExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupExtensionSettings(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsResponse MutateAdGroupExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroupExtensionSettings, null, options, request); + } + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupExtensionSettingsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupExtensionSettingsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad group extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupExtensionSettingsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroupExtensionSettings, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupExtensionSettingServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupExtensionSettingServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupExtensionSettingServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupExtensionSetting, serviceImpl.GetAdGroupExtensionSetting) + .AddMethod(__Method_MutateAdGroupExtensionSettings, serviceImpl.MutateAdGroupExtensionSettings).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupExtensionSettingServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupExtensionSetting, serviceImpl.GetAdGroupExtensionSetting); + serviceBinder.AddMethod(__Method_MutateAdGroupExtensionSettings, serviceImpl.MutateAdGroupExtensionSettings); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupFeed.cs b/src/V3/Stubs/AdGroupFeed.cs new file mode 100644 index 000000000..3affc569e --- /dev/null +++ b/src/V3/Stubs/AdGroupFeed.cs @@ -0,0 +1,377 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_feed.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_feed.proto + public static partial class AdGroupFeedReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_feed.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupFeedReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "ZmVlZC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "GjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vbWF0Y2hpbmdfZnVu", + "Y3Rpb24ucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2Zl", + "ZWRfbGlua19zdGF0dXMucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL3BsYWNlaG9sZGVyX3R5cGUucHJvdG8aH2dvb2dsZS9hcGkvZmll", + "bGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8a", + "Hmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9h", + "bm5vdGF0aW9ucy5wcm90byLgBAoLQWRHcm91cEZlZWQSQwoNcmVzb3VyY2Vf", + "bmFtZRgBIAEoCUIs4EEF+kEmCiRnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20v", + "QWRHcm91cEZlZWQSUQoEZmVlZBgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZUIl4EEF+kEfCh1nb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20v", + "RmVlZBJYCghhZF9ncm91cBgDIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZUIo4EEF+kEiCiBnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRH", + "cm91cBJdChFwbGFjZWhvbGRlcl90eXBlcxgEIAMoDjJCLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zLlBsYWNlaG9sZGVyVHlwZUVudW0uUGxhY2Vo", + "b2xkZXJUeXBlEksKEW1hdGNoaW5nX2Z1bmN0aW9uGAUgASgLMjAuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuY29tbW9uLk1hdGNoaW5nRnVuY3Rpb24SVQoG", + "c3RhdHVzGAYgASgOMkAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMu", + "RmVlZExpbmtTdGF0dXNFbnVtLkZlZWRMaW5rU3RhdHVzQgPgQQM6XOpBWQok", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0FkR3JvdXBGZWVkEjFjdXN0b21l", + "cnMve2N1c3RvbWVyfS9hZEdyb3VwRmVlZHMve2FkX2dyb3VwX2ZlZWR9Qv0B", + "CiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzQhBBZEdy", + "b3VwRmVlZFByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2Vz", + "ogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIh", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.MatchingFunctionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed), global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed.Parser, new[]{ "ResourceName", "Feed", "AdGroup", "PlaceholderTypes", "MatchingFunction", "Status" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad group feed. + /// + public sealed partial class AdGroupFeed : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupFeed()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeedReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeed() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeed(AdGroupFeed other) : this() { + resourceName_ = other.resourceName_; + Feed = other.Feed; + AdGroup = other.AdGroup; + placeholderTypes_ = other.placeholderTypes_.Clone(); + matchingFunction_ = other.matchingFunction_ != null ? other.matchingFunction_.Clone() : null; + status_ = other.status_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeed Clone() { + return new AdGroupFeed(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group feed. + /// Ad group feed resource names have the form: + /// + /// `customers/{customer_id}/adGroupFeeds/{ad_group_id}~{feed_id} + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "feed" field. + public const int FeedFieldNumber = 2; + private static readonly pb::FieldCodec _single_feed_codec = pb::FieldCodec.ForClassWrapper(18); + private string feed_; + /// + /// Immutable. The feed being linked to the ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Feed { + get { return feed_; } + set { + feed_ = value; + } + } + + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 3; + private static readonly pb::FieldCodec _single_adGroup_codec = pb::FieldCodec.ForClassWrapper(26); + private string adGroup_; + /// + /// Immutable. The ad group being linked to the feed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroup { + get { return adGroup_; } + set { + adGroup_ = value; + } + } + + + /// Field number for the "placeholder_types" field. + public const int PlaceholderTypesFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_placeholderTypes_codec + = pb::FieldCodec.ForEnum(34, x => (int) x, x => (global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType) x); + private readonly pbc::RepeatedField placeholderTypes_ = new pbc::RepeatedField(); + /// + /// Indicates which placeholder types the feed may populate under the connected + /// ad group. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PlaceholderTypes { + get { return placeholderTypes_; } + } + + /// Field number for the "matching_function" field. + public const int MatchingFunctionFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Common.MatchingFunction matchingFunction_; + /// + /// Matching function associated with the AdGroupFeed. + /// The matching function is used to filter the set of feed items selected. + /// Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MatchingFunction MatchingFunction { + get { return matchingFunction_; } + set { + matchingFunction_ = value; + } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus status_ = 0; + /// + /// Output only. Status of the ad group feed. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupFeed); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupFeed other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Feed != other.Feed) return false; + if (AdGroup != other.AdGroup) return false; + if(!placeholderTypes_.Equals(other.placeholderTypes_)) return false; + if (!object.Equals(MatchingFunction, other.MatchingFunction)) return false; + if (Status != other.Status) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (feed_ != null) hash ^= Feed.GetHashCode(); + if (adGroup_ != null) hash ^= AdGroup.GetHashCode(); + hash ^= placeholderTypes_.GetHashCode(); + if (matchingFunction_ != null) hash ^= MatchingFunction.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (feed_ != null) { + _single_feed_codec.WriteTagAndValue(output, Feed); + } + if (adGroup_ != null) { + _single_adGroup_codec.WriteTagAndValue(output, AdGroup); + } + placeholderTypes_.WriteTo(output, _repeated_placeholderTypes_codec); + if (matchingFunction_ != null) { + output.WriteRawTag(42); + output.WriteMessage(MatchingFunction); + } + if (Status != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) Status); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (feed_ != null) { + size += _single_feed_codec.CalculateSizeWithTag(Feed); + } + if (adGroup_ != null) { + size += _single_adGroup_codec.CalculateSizeWithTag(AdGroup); + } + size += placeholderTypes_.CalculateSize(_repeated_placeholderTypes_codec); + if (matchingFunction_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MatchingFunction); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupFeed other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.feed_ != null) { + if (feed_ == null || other.Feed != "") { + Feed = other.Feed; + } + } + if (other.adGroup_ != null) { + if (adGroup_ == null || other.AdGroup != "") { + AdGroup = other.AdGroup; + } + } + placeholderTypes_.Add(other.placeholderTypes_); + if (other.matchingFunction_ != null) { + if (matchingFunction_ == null) { + MatchingFunction = new global::Google.Ads.GoogleAds.V3.Common.MatchingFunction(); + } + MatchingFunction.MergeFrom(other.MatchingFunction); + } + if (other.Status != 0) { + Status = other.Status; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_feed_codec.Read(input); + if (feed_ == null || value != "") { + Feed = value; + } + break; + } + case 26: { + string value = _single_adGroup_codec.Read(input); + if (adGroup_ == null || value != "") { + AdGroup = value; + } + break; + } + case 34: + case 32: { + placeholderTypes_.AddEntriesFrom(input, _repeated_placeholderTypes_codec); + break; + } + case 42: { + if (matchingFunction_ == null) { + MatchingFunction = new global::Google.Ads.GoogleAds.V3.Common.MatchingFunction(); + } + input.ReadMessage(MatchingFunction); + break; + } + case 48: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupFeedError.cs b/src/V3/Stubs/AdGroupFeedError.cs new file mode 100644 index 000000000..4ba376332 --- /dev/null +++ b/src/V3/Stubs/AdGroupFeedError.cs @@ -0,0 +1,213 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_group_feed_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_group_feed_error.proto + public static partial class AdGroupFeedErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_group_feed_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupFeedErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfZ3JvdXBfZmVl", + "ZF9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvItwCChRBZEdyb3VwRmVl", + "ZEVycm9yRW51bSLDAgoQQWRHcm91cEZlZWRFcnJvchIPCgtVTlNQRUNJRklF", + "RBAAEgsKB1VOS05PV04QARIsCihGRUVEX0FMUkVBRFlfRVhJU1RTX0ZPUl9Q", + "TEFDRUhPTERFUl9UWVBFEAISIgoeQ0FOTk9UX0NSRUFURV9GT1JfUkVNT1ZF", + "RF9GRUVEEAMSHwobQURHUk9VUF9GRUVEX0FMUkVBRFlfRVhJU1RTEAQSKgom", + "Q0FOTk9UX09QRVJBVEVfT05fUkVNT1ZFRF9BREdST1VQX0ZFRUQQBRIcChhJ", + "TlZBTElEX1BMQUNFSE9MREVSX1RZUEUQBhIsCihNSVNTSU5HX0ZFRURNQVBQ", + "SU5HX0ZPUl9QTEFDRUhPTERFUl9UWVBFEAcSJgoiTk9fRVhJU1RJTkdfTE9D", + "QVRJT05fQ1VTVE9NRVJfRkVFRBAIQvABCiJjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZXJyb3JzQhVBZEdyb3VwRmVlZEVycm9yUHJvdG9QAVpEZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2ds", + "ZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJv", + "cnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupFeedErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdGroupFeedErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdGroupFeedErrorEnum.Types.AdGroupFeedError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad group feed errors. + /// + public sealed partial class AdGroupFeedErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupFeedErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdGroupFeedErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeedErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeedErrorEnum(AdGroupFeedErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeedErrorEnum Clone() { + return new AdGroupFeedErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupFeedErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupFeedErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupFeedErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupFeedErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad group feed errors. + /// + public enum AdGroupFeedError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// An active feed already exists for this ad group and place holder type. + /// + [pbr::OriginalName("FEED_ALREADY_EXISTS_FOR_PLACEHOLDER_TYPE")] FeedAlreadyExistsForPlaceholderType = 2, + /// + /// The specified feed is removed. + /// + [pbr::OriginalName("CANNOT_CREATE_FOR_REMOVED_FEED")] CannotCreateForRemovedFeed = 3, + /// + /// The AdGroupFeed already exists. UPDATE operation should be used to modify + /// the existing AdGroupFeed. + /// + [pbr::OriginalName("ADGROUP_FEED_ALREADY_EXISTS")] AdgroupFeedAlreadyExists = 4, + /// + /// Cannot operate on removed AdGroupFeed. + /// + [pbr::OriginalName("CANNOT_OPERATE_ON_REMOVED_ADGROUP_FEED")] CannotOperateOnRemovedAdgroupFeed = 5, + /// + /// Invalid placeholder type. + /// + [pbr::OriginalName("INVALID_PLACEHOLDER_TYPE")] InvalidPlaceholderType = 6, + /// + /// Feed mapping for this placeholder type does not exist. + /// + [pbr::OriginalName("MISSING_FEEDMAPPING_FOR_PLACEHOLDER_TYPE")] MissingFeedmappingForPlaceholderType = 7, + /// + /// Location AdGroupFeeds cannot be created unless there is a location + /// CustomerFeed for the specified feed. + /// + [pbr::OriginalName("NO_EXISTING_LOCATION_CUSTOMER_FEED")] NoExistingLocationCustomerFeed = 8, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupFeedService.cs b/src/V3/Stubs/AdGroupFeedService.cs new file mode 100644 index 000000000..0132d033d --- /dev/null +++ b/src/V3/Stubs/AdGroupFeedService.cs @@ -0,0 +1,1033 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_feed_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_feed_service.proto + public static partial class AdGroupFeedServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_feed_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupFeedServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9m", + "ZWVkX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzGjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRf", + "Z3JvdXBfZmVlZC5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRf", + "YmVoYXZpb3IucHJvdG8aIGdvb2dsZS9wcm90b2J1Zi9maWVsZF9tYXNrLnBy", + "b3RvGhdnb29nbGUvcnBjL3N0YXR1cy5wcm90byIzChVHZXRBZEdyb3VwRmVl", + "ZFJlcXVlc3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEoCUID4EECIrYBChlNdXRh", + "dGVBZEdyb3VwRmVlZHNSZXF1ZXN0EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPg", + "QQISTwoKb3BlcmF0aW9ucxgCIAMoCzI2Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLkFkR3JvdXBGZWVkT3BlcmF0aW9uQgPgQQISFwoPcGFy", + "dGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlkYXRlX29ubHkYBCABKAgi6gEK", + "FEFkR3JvdXBGZWVkT3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAQgASgLMhou", + "Z29vZ2xlLnByb3RvYnVmLkZpZWxkTWFzaxJACgZjcmVhdGUYASABKAsyLi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cEZlZWRI", + "ABJACgZ1cGRhdGUYAiABKAsyLi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMuQWRHcm91cEZlZWRIABIQCgZyZW1vdmUYAyABKAlIAEILCglv", + "cGVyYXRpb24imwEKGk11dGF0ZUFkR3JvdXBGZWVkc1Jlc3BvbnNlEjEKFXBh", + "cnRpYWxfZmFpbHVyZV9lcnJvchgDIAEoCzISLmdvb2dsZS5ycGMuU3RhdHVz", + "EkoKB3Jlc3VsdHMYAiADKAsyOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5NdXRhdGVBZEdyb3VwRmVlZFJlc3VsdCIwChdNdXRhdGVBZEdy", + "b3VwRmVlZFJlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJMt4DChJBZEdy", + "b3VwRmVlZFNlcnZpY2USwQEKDkdldEFkR3JvdXBGZWVkEjcuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuR2V0QWRHcm91cEZlZWRSZXF1ZXN0", + "Gi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkFkR3JvdXBG", + "ZWVkIkaC0+STAjASLi92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9h", + "ZEdyb3VwRmVlZHMvKn3aQQ1yZXNvdXJjZV9uYW1lEuYBChJNdXRhdGVBZEdy", + "b3VwRmVlZHMSOy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5N", + "dXRhdGVBZEdyb3VwRmVlZHNSZXF1ZXN0GjwuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuTXV0YXRlQWRHcm91cEZlZWRzUmVzcG9uc2UiVYLT", + "5JMCNiIxL3YzL2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn0vYWRHcm91cEZl", + "ZWRzOm11dGF0ZToBKtpBFmN1c3RvbWVyX2lkLG9wZXJhdGlvbnMaG8pBGGdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbUL+AQokY29tLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzQhdBZEdyb3VwRmVlZFNlcnZpY2VQcm90b1AB", + "Wkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xl", + "QWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6", + "OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeedReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupFeedRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupFeedRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupFeedService.GetAdGroupFeed][google.ads.googleads.v3.services.AdGroupFeedService.GetAdGroupFeed]. + /// + public sealed partial class GetAdGroupFeedRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupFeedRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupFeedRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupFeedRequest(GetAdGroupFeedRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupFeedRequest Clone() { + return new GetAdGroupFeedRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group feed to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupFeedRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupFeedRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupFeedRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdGroupFeedService.MutateAdGroupFeeds][google.ads.googleads.v3.services.AdGroupFeedService.MutateAdGroupFeeds]. + /// + public sealed partial class MutateAdGroupFeedsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupFeedsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedsRequest(MutateAdGroupFeedsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedsRequest Clone() { + return new MutateAdGroupFeedsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose ad group feeds are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual ad group feeds. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupFeedsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupFeedsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupFeedsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on an ad group feed. + /// + public sealed partial class AdGroupFeedOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupFeedOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeedOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeedOperation(AdGroupFeedOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupFeedOperation Clone() { + return new AdGroupFeedOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad group feed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The ad group feed is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed ad group feed is + /// expected, in this format: + /// + /// `customers/{customer_id}/adGroupFeeds/{ad_group_id}~{feed_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupFeedOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupFeedOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupFeedOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for an ad group feed mutate. + /// + public sealed partial class MutateAdGroupFeedsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupFeedsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedsResponse(MutateAdGroupFeedsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedsResponse Clone() { + return new MutateAdGroupFeedsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupFeedsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupFeedsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupFeedsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the ad group feed mutate. + /// + public sealed partial class MutateAdGroupFeedResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupFeedResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedResult(MutateAdGroupFeedResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupFeedResult Clone() { + return new MutateAdGroupFeedResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupFeedResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupFeedResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupFeedResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupFeedServiceClient.cs b/src/V3/Stubs/AdGroupFeedServiceClient.cs new file mode 100644 index 000000000..4d90a66b4 --- /dev/null +++ b/src/V3/Stubs/AdGroupFeedServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupFeedServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupFeedServiceSettings GetDefault() => new AdGroupFeedServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupFeedServiceSettings() { } + + private AdGroupFeedServiceSettings(AdGroupFeedServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupFeedSettings = existing.GetAdGroupFeedSettings; + MutateAdGroupFeedsSettings = existing.MutateAdGroupFeedsSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupFeedServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupFeedServiceClient.GetAdGroupFeed and AdGroupFeedServiceClient.GetAdGroupFeedAsync. + /// + /// + /// The default AdGroupFeedServiceClient.GetAdGroupFeed and + /// AdGroupFeedServiceClient.GetAdGroupFeedAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupFeedSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupFeedServiceClient.MutateAdGroupFeeds and AdGroupFeedServiceClient.MutateAdGroupFeedsAsync. + /// + /// + /// The default AdGroupFeedServiceClient.MutateAdGroupFeeds and + /// AdGroupFeedServiceClient.MutateAdGroupFeedsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupFeedsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupFeedServiceSettings Clone() => new AdGroupFeedServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupFeedServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupFeedServiceSettings Settings { get; set; } + + /// + public override AdGroupFeedServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupFeedServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupFeedServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupFeedServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupFeedServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupFeedServiceClient.ChannelPool; + } + + /// + /// AdGroupFeedService client wrapper, for convenient use. + /// + public abstract partial class AdGroupFeedServiceClient + { + /// + /// The default endpoint for the AdGroupFeedService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupFeedService scopes. + /// + /// + /// The default AdGroupFeedService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupFeedServiceClient client = await AdGroupFeedServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupFeedServiceClient.DefaultEndpoint.Host, AdGroupFeedServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupFeedServiceClient client = AdGroupFeedServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupFeedServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupFeedServiceClient client = AdGroupFeedServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupFeedServiceClient.DefaultEndpoint.Host, AdGroupFeedServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupFeedServiceClient client = AdGroupFeedServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupFeedServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupFeedServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupFeedServiceClient Create(grpccore::Channel channel, AdGroupFeedServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupFeedServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupFeedServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupFeedService.AdGroupFeedServiceClient grpcClient = new AdGroupFeedService.AdGroupFeedServiceClient(callInvoker); + return new AdGroupFeedServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupFeedService client. + /// + public virtual AdGroupFeedService.AdGroupFeedServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group feed in full detail. + /// + /// + /// Required. The resource name of the ad group feed to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupFeedAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupFeedAsync( + new GetAdGroupFeedRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group feed in full detail. + /// + /// + /// Required. The resource name of the ad group feed to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupFeedAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupFeedAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group feed in full detail. + /// + /// + /// Required. The resource name of the ad group feed to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupFeed GetAdGroupFeed( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupFeed( + new GetAdGroupFeedRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupFeedAsync( + GetAdGroupFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupFeedAsync( + GetAdGroupFeedRequest request, + st::CancellationToken cancellationToken) => GetAdGroupFeedAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupFeed GetAdGroupFeed( + GetAdGroupFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad group feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupFeedsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupFeedsAsync( + new MutateAdGroupFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad group feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupFeedsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupFeedsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad group feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupFeedsResponse MutateAdGroupFeeds( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupFeeds( + new MutateAdGroupFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad group feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group feeds. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupFeedsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupFeedsAsync( + new MutateAdGroupFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad group feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group feeds. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupFeedsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupFeedsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad group feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad group feeds. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupFeedsResponse MutateAdGroupFeeds( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupFeeds( + new MutateAdGroupFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupFeedsAsync( + MutateAdGroupFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupFeedsAsync( + MutateAdGroupFeedsRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupFeedsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupFeedsResponse MutateAdGroupFeeds( + MutateAdGroupFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupFeedService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupFeedServiceClientImpl : AdGroupFeedServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupFeed; + private readonly gaxgrpc::ApiCall _callMutateAdGroupFeeds; + + /// + /// Constructs a client wrapper for the AdGroupFeedService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupFeedServiceClientImpl(AdGroupFeedService.AdGroupFeedServiceClient grpcClient, AdGroupFeedServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupFeedServiceSettings effectiveSettings = settings ?? AdGroupFeedServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupFeed = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupFeedAsync, GrpcClient.GetAdGroupFeed, effectiveSettings.GetAdGroupFeedSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroupFeeds = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupFeedsAsync, GrpcClient.MutateAdGroupFeeds, effectiveSettings.MutateAdGroupFeedsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroupFeed); + Modify_GetAdGroupFeedApiCall(ref _callGetAdGroupFeed); + Modify_ApiCall(ref _callMutateAdGroupFeeds); + Modify_MutateAdGroupFeedsApiCall(ref _callMutateAdGroupFeeds); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupFeedApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupFeedsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupFeedService.AdGroupFeedServiceClient grpcClient, AdGroupFeedServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupFeedService client. + /// + public override AdGroupFeedService.AdGroupFeedServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupFeedRequest(ref GetAdGroupFeedRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupFeedsRequest(ref MutateAdGroupFeedsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupFeedAsync( + GetAdGroupFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupFeedRequest(ref request, ref callSettings); + return _callGetAdGroupFeed.Async(request, callSettings); + } + + /// + /// Returns the requested ad group feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupFeed GetAdGroupFeed( + GetAdGroupFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupFeedRequest(ref request, ref callSettings); + return _callGetAdGroupFeed.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupFeedsAsync( + MutateAdGroupFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupFeedsRequest(ref request, ref callSettings); + return _callMutateAdGroupFeeds.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupFeedsResponse MutateAdGroupFeeds( + MutateAdGroupFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupFeedsRequest(ref request, ref callSettings); + return _callMutateAdGroupFeeds.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupFeedServiceGrpc.cs b/src/V3/Stubs/AdGroupFeedServiceGrpc.cs new file mode 100644 index 000000000..40180b1ca --- /dev/null +++ b/src/V3/Stubs/AdGroupFeedServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_feed_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ad group feeds. + /// + public static partial class AdGroupFeedService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupFeedService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupFeedRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupFeedRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupFeed = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupFeedsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupFeedsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupFeed = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupFeed", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupFeedRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupFeed); + + static readonly grpc::Method __Method_MutateAdGroupFeeds = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroupFeeds", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupFeedsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupFeedsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupFeedService + public abstract partial class AdGroupFeedServiceBase + { + /// + /// Returns the requested ad group feed in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupFeed(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupFeedRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroupFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupFeedService + public partial class AdGroupFeedServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupFeedService + /// The channel to use to make remote calls. + public AdGroupFeedServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupFeedService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupFeedServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupFeedServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupFeedServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group feed in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed GetAdGroupFeed(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupFeedRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupFeed(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group feed in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed GetAdGroupFeed(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupFeedRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupFeed, null, options, request); + } + /// + /// Returns the requested ad group feed in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupFeedAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupFeedRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupFeedAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group feed in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupFeedAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupFeedRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupFeed, null, options, request); + } + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsResponse MutateAdGroupFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupFeeds(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsResponse MutateAdGroupFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroupFeeds, null, options, request); + } + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupFeedsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupFeedsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad group feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupFeedsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroupFeeds, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupFeedServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupFeedServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupFeedServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupFeed, serviceImpl.GetAdGroupFeed) + .AddMethod(__Method_MutateAdGroupFeeds, serviceImpl.MutateAdGroupFeeds).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupFeedServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupFeed, serviceImpl.GetAdGroupFeed); + serviceBinder.AddMethod(__Method_MutateAdGroupFeeds, serviceImpl.MutateAdGroupFeeds); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupLabel.cs b/src/V3/Stubs/AdGroupLabel.cs new file mode 100644 index 000000000..e3b3fe917 --- /dev/null +++ b/src/V3/Stubs/AdGroupLabel.cs @@ -0,0 +1,271 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_label.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_label.proto + public static partial class AdGroupLabelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_label.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupLabelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "bGFiZWwucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2Fw", + "aS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnBy", + "b3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIuQCCgxBZEdyb3Vw", + "TGFiZWwSRAoNcmVzb3VyY2VfbmFtZRgBIAEoCUIt4EEF+kEnCiVnb29nbGVh", + "ZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91cExhYmVsElgKCGFkX2dyb3VwGAIg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQijgQQX6QSIKIGdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZEdyb3VwElMKBWxhYmVsGAMgASgL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQibgQQX6QSAKHmdvb2ds", + "ZWFkcy5nb29nbGVhcGlzLmNvbS9MYWJlbDpf6kFcCiVnb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb20vQWRHcm91cExhYmVsEjNjdXN0b21lcnMve2N1c3RvbWVy", + "fS9hZEdyb3VwTGFiZWxzL3thZF9ncm91cF9sYWJlbH1C/gEKJWNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNCEUFkR3JvdXBMYWJlbFBy", + "b3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIh", + "R29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFk", + "c1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2ds", + "ZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel), global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel.Parser, new[]{ "ResourceName", "AdGroup", "Label" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A relationship between an ad group and a label. + /// + public sealed partial class AdGroupLabel : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupLabel()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupLabel() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupLabel(AdGroupLabel other) : this() { + resourceName_ = other.resourceName_; + AdGroup = other.AdGroup; + Label = other.Label; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupLabel Clone() { + return new AdGroupLabel(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group label. + /// Ad group label resource names have the form: + /// `customers/{customer_id}/adGroupLabels/{ad_group_id}~{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 2; + private static readonly pb::FieldCodec _single_adGroup_codec = pb::FieldCodec.ForClassWrapper(18); + private string adGroup_; + /// + /// Immutable. The ad group to which the label is attached. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroup { + get { return adGroup_; } + set { + adGroup_ = value; + } + } + + + /// Field number for the "label" field. + public const int LabelFieldNumber = 3; + private static readonly pb::FieldCodec _single_label_codec = pb::FieldCodec.ForClassWrapper(26); + private string label_; + /// + /// Immutable. The label assigned to the ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Label { + get { return label_; } + set { + label_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupLabel); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupLabel other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (AdGroup != other.AdGroup) return false; + if (Label != other.Label) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (adGroup_ != null) hash ^= AdGroup.GetHashCode(); + if (label_ != null) hash ^= Label.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (adGroup_ != null) { + _single_adGroup_codec.WriteTagAndValue(output, AdGroup); + } + if (label_ != null) { + _single_label_codec.WriteTagAndValue(output, Label); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (adGroup_ != null) { + size += _single_adGroup_codec.CalculateSizeWithTag(AdGroup); + } + if (label_ != null) { + size += _single_label_codec.CalculateSizeWithTag(Label); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupLabel other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.adGroup_ != null) { + if (adGroup_ == null || other.AdGroup != "") { + AdGroup = other.AdGroup; + } + } + if (other.label_ != null) { + if (label_ == null || other.Label != "") { + Label = other.Label; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_adGroup_codec.Read(input); + if (adGroup_ == null || value != "") { + AdGroup = value; + } + break; + } + case 26: { + string value = _single_label_codec.Read(input); + if (label_ == null || value != "") { + Label = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupLabelService.cs b/src/V3/Stubs/AdGroupLabelService.cs new file mode 100644 index 000000000..07abfe142 --- /dev/null +++ b/src/V3/Stubs/AdGroupLabelService.cs @@ -0,0 +1,951 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_label_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_label_service.proto + public static partial class AdGroupLabelServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_label_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupLabelServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9s", + "YWJlbF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2Fk", + "X2dyb3VwX2xhYmVsLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVs", + "ZF9iZWhhdmlvci5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8iNAoW", + "R2V0QWRHcm91cExhYmVsUmVxdWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJ", + "QgPgQQIiuAEKGk11dGF0ZUFkR3JvdXBMYWJlbHNSZXF1ZXN0EhgKC2N1c3Rv", + "bWVyX2lkGAEgASgJQgPgQQISUAoKb3BlcmF0aW9ucxgCIAMoCzI3Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkFkR3JvdXBMYWJlbE9wZXJh", + "dGlvbkID4EECEhcKD3BhcnRpYWxfZmFpbHVyZRgDIAEoCBIVCg12YWxpZGF0", + "ZV9vbmx5GAQgASgIInkKFUFkR3JvdXBMYWJlbE9wZXJhdGlvbhJBCgZjcmVh", + "dGUYASABKAsyLy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMu", + "QWRHcm91cExhYmVsSAASEAoGcmVtb3ZlGAIgASgJSABCCwoJb3BlcmF0aW9u", + "Ip0BChtNdXRhdGVBZEdyb3VwTGFiZWxzUmVzcG9uc2USMQoVcGFydGlhbF9m", + "YWlsdXJlX2Vycm9yGAMgASgLMhIuZ29vZ2xlLnJwYy5TdGF0dXMSSwoHcmVz", + "dWx0cxgCIAMoCzI6Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2Vz", + "Lk11dGF0ZUFkR3JvdXBMYWJlbFJlc3VsdCIxChhNdXRhdGVBZEdyb3VwTGFi", + "ZWxSZXN1bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTLnAwoTQWRHcm91cExh", + "YmVsU2VydmljZRLFAQoPR2V0QWRHcm91cExhYmVsEjguZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuR2V0QWRHcm91cExhYmVsUmVxdWVzdBov", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZEdyb3VwTGFi", + "ZWwiR4LT5JMCMRIvL3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2Fk", + "R3JvdXBMYWJlbHMvKn3aQQ1yZXNvdXJjZV9uYW1lEuoBChNNdXRhdGVBZEdy", + "b3VwTGFiZWxzEjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "TXV0YXRlQWRHcm91cExhYmVsc1JlcXVlc3QaPS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVBZEdyb3VwTGFiZWxzUmVzcG9uc2Ui", + "VoLT5JMCNyIyL3YzL2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn0vYWRHcm91", + "cExhYmVsczptdXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVyYXRpb25zGhvK", + "QRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21C/wEKJGNvbS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlc0IYQWRHcm91cExhYmVsU2VydmljZVBy", + "b3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabelReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupLabelRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupLabelRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupLabelService.GetAdGroupLabel][google.ads.googleads.v3.services.AdGroupLabelService.GetAdGroupLabel]. + /// + public sealed partial class GetAdGroupLabelRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupLabelRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupLabelRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupLabelRequest(GetAdGroupLabelRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupLabelRequest Clone() { + return new GetAdGroupLabelRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group label to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupLabelRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupLabelRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupLabelRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdGroupLabelService.MutateAdGroupLabels][google.ads.googleads.v3.services.AdGroupLabelService.MutateAdGroupLabels]. + /// + public sealed partial class MutateAdGroupLabelsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupLabelsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelsRequest(MutateAdGroupLabelsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelsRequest Clone() { + return new MutateAdGroupLabelsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. ID of the customer whose ad group labels are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on ad group labels. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupLabelsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupLabelsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupLabelsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove) on an ad group label. + /// + public sealed partial class AdGroupLabelOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupLabelOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupLabelOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupLabelOperation(AdGroupLabelOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupLabelOperation Clone() { + return new AdGroupLabelOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad group + /// label. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 2; + /// + /// Remove operation: A resource name for the ad group label + /// being removed, in this format: + /// + /// `customers/{customer_id}/adGroupLabels/{ad_group_id}~{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupLabelOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupLabelOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(18); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupLabelOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for an ad group labels mutate. + /// + public sealed partial class MutateAdGroupLabelsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupLabelsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelsResponse(MutateAdGroupLabelsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelsResponse Clone() { + return new MutateAdGroupLabelsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupLabelsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupLabelsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupLabelsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for an ad group label mutate. + /// + public sealed partial class MutateAdGroupLabelResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupLabelResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelResult(MutateAdGroupLabelResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupLabelResult Clone() { + return new MutateAdGroupLabelResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupLabelResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupLabelResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupLabelResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupLabelServiceClient.cs b/src/V3/Stubs/AdGroupLabelServiceClient.cs new file mode 100644 index 000000000..13a76df90 --- /dev/null +++ b/src/V3/Stubs/AdGroupLabelServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupLabelServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupLabelServiceSettings GetDefault() => new AdGroupLabelServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupLabelServiceSettings() { } + + private AdGroupLabelServiceSettings(AdGroupLabelServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupLabelSettings = existing.GetAdGroupLabelSettings; + MutateAdGroupLabelsSettings = existing.MutateAdGroupLabelsSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupLabelServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupLabelServiceClient.GetAdGroupLabel and AdGroupLabelServiceClient.GetAdGroupLabelAsync. + /// + /// + /// The default AdGroupLabelServiceClient.GetAdGroupLabel and + /// AdGroupLabelServiceClient.GetAdGroupLabelAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupLabelSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupLabelServiceClient.MutateAdGroupLabels and AdGroupLabelServiceClient.MutateAdGroupLabelsAsync. + /// + /// + /// The default AdGroupLabelServiceClient.MutateAdGroupLabels and + /// AdGroupLabelServiceClient.MutateAdGroupLabelsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupLabelsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupLabelServiceSettings Clone() => new AdGroupLabelServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupLabelServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupLabelServiceSettings Settings { get; set; } + + /// + public override AdGroupLabelServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupLabelServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupLabelServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupLabelServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupLabelServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupLabelServiceClient.ChannelPool; + } + + /// + /// AdGroupLabelService client wrapper, for convenient use. + /// + public abstract partial class AdGroupLabelServiceClient + { + /// + /// The default endpoint for the AdGroupLabelService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupLabelService scopes. + /// + /// + /// The default AdGroupLabelService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupLabelServiceClient client = await AdGroupLabelServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupLabelServiceClient.DefaultEndpoint.Host, AdGroupLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupLabelServiceClient client = AdGroupLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupLabelServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupLabelServiceClient client = AdGroupLabelServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupLabelServiceClient.DefaultEndpoint.Host, AdGroupLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupLabelServiceClient client = AdGroupLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupLabelServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupLabelServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupLabelServiceClient Create(grpccore::Channel channel, AdGroupLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupLabelServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupLabelService.AdGroupLabelServiceClient grpcClient = new AdGroupLabelService.AdGroupLabelServiceClient(callInvoker); + return new AdGroupLabelServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupLabelService client. + /// + public virtual AdGroupLabelService.AdGroupLabelServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group label in full detail. + /// + /// + /// Required. The resource name of the ad group label to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupLabelAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupLabelAsync( + new GetAdGroupLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group label in full detail. + /// + /// + /// Required. The resource name of the ad group label to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupLabelAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupLabelAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group label in full detail. + /// + /// + /// Required. The resource name of the ad group label to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupLabel GetAdGroupLabel( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupLabel( + new GetAdGroupLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupLabelAsync( + GetAdGroupLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupLabelAsync( + GetAdGroupLabelRequest request, + st::CancellationToken cancellationToken) => GetAdGroupLabelAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupLabel GetAdGroupLabel( + GetAdGroupLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupLabelsAsync( + new MutateAdGroupLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupLabelsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group labels. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupLabelsResponse MutateAdGroupLabels( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupLabels( + new MutateAdGroupLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group labels. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupLabelsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupLabelsAsync( + new MutateAdGroupLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group labels. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupLabelsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupLabelsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose ad group labels are being modified. + /// + /// + /// Required. The list of operations to perform on ad group labels. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupLabelsResponse MutateAdGroupLabels( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupLabels( + new MutateAdGroupLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupLabelsAsync( + MutateAdGroupLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupLabelsAsync( + MutateAdGroupLabelsRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupLabelsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupLabelsResponse MutateAdGroupLabels( + MutateAdGroupLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupLabelService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupLabelServiceClientImpl : AdGroupLabelServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupLabel; + private readonly gaxgrpc::ApiCall _callMutateAdGroupLabels; + + /// + /// Constructs a client wrapper for the AdGroupLabelService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupLabelServiceClientImpl(AdGroupLabelService.AdGroupLabelServiceClient grpcClient, AdGroupLabelServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupLabelServiceSettings effectiveSettings = settings ?? AdGroupLabelServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupLabel = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupLabelAsync, GrpcClient.GetAdGroupLabel, effectiveSettings.GetAdGroupLabelSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroupLabels = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupLabelsAsync, GrpcClient.MutateAdGroupLabels, effectiveSettings.MutateAdGroupLabelsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroupLabel); + Modify_GetAdGroupLabelApiCall(ref _callGetAdGroupLabel); + Modify_ApiCall(ref _callMutateAdGroupLabels); + Modify_MutateAdGroupLabelsApiCall(ref _callMutateAdGroupLabels); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupLabelApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupLabelsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupLabelService.AdGroupLabelServiceClient grpcClient, AdGroupLabelServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupLabelService client. + /// + public override AdGroupLabelService.AdGroupLabelServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupLabelRequest(ref GetAdGroupLabelRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupLabelsRequest(ref MutateAdGroupLabelsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupLabelAsync( + GetAdGroupLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupLabelRequest(ref request, ref callSettings); + return _callGetAdGroupLabel.Async(request, callSettings); + } + + /// + /// Returns the requested ad group label in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupLabel GetAdGroupLabel( + GetAdGroupLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupLabelRequest(ref request, ref callSettings); + return _callGetAdGroupLabel.Sync(request, callSettings); + } + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupLabelsAsync( + MutateAdGroupLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupLabelsRequest(ref request, ref callSettings); + return _callMutateAdGroupLabels.Async(request, callSettings); + } + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupLabelsResponse MutateAdGroupLabels( + MutateAdGroupLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupLabelsRequest(ref request, ref callSettings); + return _callMutateAdGroupLabels.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupLabelServiceGrpc.cs b/src/V3/Stubs/AdGroupLabelServiceGrpc.cs new file mode 100644 index 000000000..f7e48f10d --- /dev/null +++ b/src/V3/Stubs/AdGroupLabelServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_label_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage labels on ad groups. + /// + public static partial class AdGroupLabelService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupLabelService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupLabelRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupLabelRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupLabel = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupLabelsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupLabelsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupLabel = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupLabel", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupLabelRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupLabel); + + static readonly grpc::Method __Method_MutateAdGroupLabels = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroupLabels", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupLabelsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupLabelsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupLabelService + public abstract partial class AdGroupLabelServiceBase + { + /// + /// Returns the requested ad group label in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupLabelRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroupLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupLabelService + public partial class AdGroupLabelServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupLabelService + /// The channel to use to make remote calls. + public AdGroupLabelServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupLabelService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupLabelServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupLabelServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupLabelServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group label in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel GetAdGroupLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupLabel(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group label in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel GetAdGroupLabel(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupLabel, null, options, request); + } + /// + /// Returns the requested ad group label in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupLabelAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group label in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupLabel, null, options, request); + } + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsResponse MutateAdGroupLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupLabels(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsResponse MutateAdGroupLabels(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroupLabels, null, options, request); + } + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupLabelsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes ad group labels. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroupLabels, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupLabelServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupLabelServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupLabelServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupLabel, serviceImpl.GetAdGroupLabel) + .AddMethod(__Method_MutateAdGroupLabels, serviceImpl.MutateAdGroupLabels).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupLabelServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupLabel, serviceImpl.GetAdGroupLabel); + serviceBinder.AddMethod(__Method_MutateAdGroupLabels, serviceImpl.MutateAdGroupLabels); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupService.cs b/src/V3/Stubs/AdGroupService.cs new file mode 100644 index 000000000..421ff27aa --- /dev/null +++ b/src/V3/Stubs/AdGroupService.cs @@ -0,0 +1,1030 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_service.proto + public static partial class AdGroupServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9z", + "ZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cxowZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2FkX2dyb3Vw", + "LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUv", + "YXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5w", + "cm90bxogZ29vZ2xlL3Byb3RvYnVmL2ZpZWxkX21hc2sucHJvdG8aF2dvb2ds", + "ZS9ycGMvc3RhdHVzLnByb3RvIi8KEUdldEFkR3JvdXBSZXF1ZXN0EhoKDXJl", + "c291cmNlX25hbWUYASABKAlCA+BBAiKuAQoVTXV0YXRlQWRHcm91cHNSZXF1", + "ZXN0EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPgQQISSwoKb3BlcmF0aW9ucxgC", + "IAMoCzIyLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkFkR3Jv", + "dXBPcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyABKAgSFQoN", + "dmFsaWRhdGVfb25seRgEIAEoCCLeAQoQQWRHcm91cE9wZXJhdGlvbhIvCgt1", + "cGRhdGVfbWFzaxgEIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5GaWVsZE1hc2sS", + "PAoGY3JlYXRlGAEgASgLMiouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLkFkR3JvdXBIABI8CgZ1cGRhdGUYAiABKAsyKi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cEgAEhAKBnJlbW92ZRgD", + "IAEoCUgAQgsKCW9wZXJhdGlvbiKTAQoWTXV0YXRlQWRHcm91cHNSZXNwb25z", + "ZRIxChVwYXJ0aWFsX2ZhaWx1cmVfZXJyb3IYAyABKAsyEi5nb29nbGUucnBj", + "LlN0YXR1cxJGCgdyZXN1bHRzGAIgAygLMjUuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuTXV0YXRlQWRHcm91cFJlc3VsdCIsChNNdXRhdGVB", + "ZEdyb3VwUmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAkyugMKDkFkR3Jv", + "dXBTZXJ2aWNlErEBCgpHZXRBZEdyb3VwEjMuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuR2V0QWRHcm91cFJlcXVlc3QaKi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cCJCgtPkkwIsEiovdjMv", + "e3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovYWRHcm91cHMvKn3aQQ1yZXNv", + "dXJjZV9uYW1lEtYBCg5NdXRhdGVBZEdyb3VwcxI3Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBzUmVxdWVzdBo4Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkR3JvdXBz", + "UmVzcG9uc2UiUYLT5JMCMiItL3YzL2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9", + "Kn0vYWRHcm91cHM6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9u", + "cxobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQvoBCiRjb20uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCE0FkR3JvdXBTZXJ2aWNlUHJv", + "dG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9h", + "ZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29v", + "Z2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdGroupOperation), global::Google.Ads.GoogleAds.V3.Services.AdGroupOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupService.GetAdGroup][google.ads.googleads.v3.services.AdGroupService.GetAdGroup]. + /// + public sealed partial class GetAdGroupRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupRequest(GetAdGroupRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupRequest Clone() { + return new GetAdGroupRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdGroupService.MutateAdGroups][google.ads.googleads.v3.services.AdGroupService.MutateAdGroups]. + /// + public sealed partial class MutateAdGroupsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupsRequest(MutateAdGroupsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupsRequest Clone() { + return new MutateAdGroupsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose ad groups are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdGroupOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual ad groups. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on an ad group. + /// + public sealed partial class AdGroupOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupOperation(AdGroupOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupOperation Clone() { + return new AdGroupOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroup Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroup) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The ad group is expected to have a valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroup Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.AdGroup) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed ad group is expected, + /// in this format: + /// + /// `customers/{customer_id}/adGroups/{ad_group_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdGroup(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.AdGroup(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroup subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroup(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.AdGroup subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdGroup(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for an ad group mutate. + /// + public sealed partial class MutateAdGroupsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupsResponse(MutateAdGroupsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupsResponse Clone() { + return new MutateAdGroupsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the ad group mutate. + /// + public sealed partial class MutateAdGroupResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdGroupResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupResult(MutateAdGroupResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdGroupResult Clone() { + return new MutateAdGroupResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdGroupResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdGroupResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdGroupResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupServiceClient.cs b/src/V3/Stubs/AdGroupServiceClient.cs new file mode 100644 index 000000000..90e3a7cfb --- /dev/null +++ b/src/V3/Stubs/AdGroupServiceClient.cs @@ -0,0 +1,887 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupServiceSettings GetDefault() => new AdGroupServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupServiceSettings() { } + + private AdGroupServiceSettings(AdGroupServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupSettings = existing.GetAdGroupSettings; + MutateAdGroupsSettings = existing.MutateAdGroupsSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupServiceClient.GetAdGroup and AdGroupServiceClient.GetAdGroupAsync. + /// + /// + /// The default AdGroupServiceClient.GetAdGroup and + /// AdGroupServiceClient.GetAdGroupAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupServiceClient.MutateAdGroups and AdGroupServiceClient.MutateAdGroupsAsync. + /// + /// + /// The default AdGroupServiceClient.MutateAdGroups and + /// AdGroupServiceClient.MutateAdGroupsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdGroupsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupServiceSettings Clone() => new AdGroupServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupServiceSettings Settings { get; set; } + + /// + public override AdGroupServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupServiceClient.ChannelPool; + } + + /// + /// AdGroupService client wrapper, for convenient use. + /// + public abstract partial class AdGroupServiceClient + { + /// + /// The default endpoint for the AdGroupService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupService scopes. + /// + /// + /// The default AdGroupService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupServiceClient client = await AdGroupServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupServiceClient.DefaultEndpoint.Host, AdGroupServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupServiceClient client = AdGroupServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupServiceClient client = AdGroupServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupServiceClient.DefaultEndpoint.Host, AdGroupServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupServiceClient client = AdGroupServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupServiceClient Create(grpccore::Channel channel, AdGroupServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupService.AdGroupServiceClient grpcClient = new AdGroupService.AdGroupServiceClient(callInvoker); + return new AdGroupServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupService client. + /// + public virtual AdGroupService.AdGroupServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group in full detail. + /// + /// + /// Required. The resource name of the ad group to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupAsync( + new GetAdGroupRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group in full detail. + /// + /// + /// Required. The resource name of the ad group to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group in full detail. + /// + /// + /// Required. The resource name of the ad group to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroup GetAdGroup( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroup( + new GetAdGroupRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAsync( + GetAdGroupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupAsync( + GetAdGroupRequest request, + st::CancellationToken cancellationToken) => GetAdGroupAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroup GetAdGroup( + GetAdGroupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad groups. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupsAsync( + new MutateAdGroupsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad groups. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdGroupsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad groups. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupsResponse MutateAdGroups( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroups( + new MutateAdGroupsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad groups. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroupsAsync( + new MutateAdGroupsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad groups. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdGroupsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad groups. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupsResponse MutateAdGroups( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdGroups( + new MutateAdGroupsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupsAsync( + MutateAdGroupsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdGroupsAsync( + MutateAdGroupsRequest request, + st::CancellationToken cancellationToken) => MutateAdGroupsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdGroupsResponse MutateAdGroups( + MutateAdGroupsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupServiceClientImpl : AdGroupServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroup; + private readonly gaxgrpc::ApiCall _callMutateAdGroups; + + /// + /// Constructs a client wrapper for the AdGroupService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupServiceClientImpl(AdGroupService.AdGroupServiceClient grpcClient, AdGroupServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupServiceSettings effectiveSettings = settings ?? AdGroupServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroup = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupAsync, GrpcClient.GetAdGroup, effectiveSettings.GetAdGroupSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdGroups = clientHelper.BuildApiCall( + GrpcClient.MutateAdGroupsAsync, GrpcClient.MutateAdGroups, effectiveSettings.MutateAdGroupsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdGroup); + Modify_GetAdGroupApiCall(ref _callGetAdGroup); + Modify_ApiCall(ref _callMutateAdGroups); + Modify_MutateAdGroupsApiCall(ref _callMutateAdGroups); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdGroupsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupService.AdGroupServiceClient grpcClient, AdGroupServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupService client. + /// + public override AdGroupService.AdGroupServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupRequest(ref GetAdGroupRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdGroupsRequest(ref MutateAdGroupsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupAsync( + GetAdGroupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupRequest(ref request, ref callSettings); + return _callGetAdGroup.Async(request, callSettings); + } + + /// + /// Returns the requested ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroup GetAdGroup( + GetAdGroupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupRequest(ref request, ref callSettings); + return _callGetAdGroup.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdGroupsAsync( + MutateAdGroupsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupsRequest(ref request, ref callSettings); + return _callMutateAdGroups.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdGroupsResponse MutateAdGroups( + MutateAdGroupsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdGroupsRequest(ref request, ref callSettings); + return _callMutateAdGroups.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupServiceGrpc.cs b/src/V3/Stubs/AdGroupServiceGrpc.cs new file mode 100644 index 000000000..05408dfda --- /dev/null +++ b/src/V3/Stubs/AdGroupServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ad groups. + /// + public static partial class AdGroupService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroup = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroup.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdGroupsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroup = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroup", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroup); + + static readonly grpc::Method __Method_MutateAdGroups = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdGroups", + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdGroupsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupService + public abstract partial class AdGroupServiceBase + { + /// + /// Returns the requested ad group in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroup(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdGroups(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupService + public partial class AdGroupServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupService + /// The channel to use to make remote calls. + public AdGroupServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroup GetAdGroup(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroup(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroup GetAdGroup(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroup, null, options, request); + } + /// + /// Returns the requested ad group in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroup, null, options, request); + } + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsResponse MutateAdGroups(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroups(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsResponse MutateAdGroups(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdGroups, null, options, request); + } + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdGroupsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad groups. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdGroupsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdGroups, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroup, serviceImpl.GetAdGroup) + .AddMethod(__Method_MutateAdGroups, serviceImpl.MutateAdGroups).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroup, serviceImpl.GetAdGroup); + serviceBinder.AddMethod(__Method_MutateAdGroups, serviceImpl.MutateAdGroups); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupSimulation.cs b/src/V3/Stubs/AdGroupSimulation.cs new file mode 100644 index 000000000..2ec59b76b --- /dev/null +++ b/src/V3/Stubs/AdGroupSimulation.cs @@ -0,0 +1,549 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_group_simulation.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_group_simulation.proto + public static partial class AdGroupSimulationReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_group_simulation.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupSimulationReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBf", + "c2ltdWxhdGlvbi5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzGi9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vc2ltdWxh", + "dGlvbi5wcm90bxpCZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvc2lt", + "dWxhdGlvbl9tb2RpZmljYXRpb25fbWV0aG9kLnByb3RvGjNnb29nbGUvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcy9zaW11bGF0aW9uX3R5cGUucHJvdG8aH2dv", + "b2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVz", + "b3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxoc", + "Z29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byL0BgoRQWRHcm91cFNpbXVs", + "YXRpb24SSQoNcmVzb3VyY2VfbmFtZRgBIAEoCUIy4EEF+kEsCipnb29nbGVh", + "ZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91cFNpbXVsYXRpb24SNQoLYWRfZ3Jv", + "dXBfaWQYAiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EED", + "ElMKBHR5cGUYAyABKA4yQC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cy5TaW11bGF0aW9uVHlwZUVudW0uU2ltdWxhdGlvblR5cGVCA+BBAxJ+ChNt", + "b2RpZmljYXRpb25fbWV0aG9kGAQgASgOMlwuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZW51bXMuU2ltdWxhdGlvbk1vZGlmaWNhdGlvbk1ldGhvZEVudW0u", + "U2ltdWxhdGlvbk1vZGlmaWNhdGlvbk1ldGhvZEID4EEDEjUKCnN0YXJ0X2Rh", + "dGUYBSABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxIz", + "CghlbmRfZGF0ZRgGIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZUID4EEDElwKEmNwY19iaWRfcG9pbnRfbGlzdBgIIAEoCzI5Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5DcGNCaWRTaW11bGF0aW9uUG9pbnRM", + "aXN0QgPgQQNIABJcChJjcHZfYmlkX3BvaW50X2xpc3QYCiABKAsyOS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQ3B2QmlkU2ltdWxhdGlvblBv", + "aW50TGlzdEID4EEDSAASYgoVdGFyZ2V0X2NwYV9wb2ludF9saXN0GAkgASgL", + "MjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLlRhcmdldENwYVNp", + "bXVsYXRpb25Qb2ludExpc3RCA+BBA0gAOm7qQWsKKmdvb2dsZWFkcy5nb29n", + "bGVhcGlzLmNvbS9BZEdyb3VwU2ltdWxhdGlvbhI9Y3VzdG9tZXJzL3tjdXN0", + "b21lcn0vYWRHcm91cFNpbXVsYXRpb25zL3thZF9ncm91cF9zaW11bGF0aW9u", + "fUIMCgpwb2ludF9saXN0QoMCCiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzQhZBZEdyb3VwU2ltdWxhdGlvblByb3RvUAFaSmdvb2ds", + "ZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFk", + "cy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5H", + "b29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJl", + "c291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.SimulationReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation), global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation.Parser, new[]{ "ResourceName", "AdGroupId", "Type", "ModificationMethod", "StartDate", "EndDate", "CpcBidPointList", "CpvBidPointList", "TargetCpaPointList" }, new[]{ "PointList" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad group simulation. Supported combinations of advertising + /// channel type, simulation type and simulation modification method is + /// detailed below respectively. + /// + /// 1. SEARCH - CPC_BID - DEFAULT + /// 2. SEARCH - CPC_BID - UNIFORM + /// 3. SEARCH - TARGET_CPA - UNIFORM + /// 4. DISPLAY - CPC_BID - DEFAULT + /// 5. DISPLAY - CPC_BID - UNIFORM + /// 6. DISPLAY - TARGET_CPA - UNIFORM + /// 7. VIDEO - CPV_BID - DEFAULT + /// 8. VIDEO - CPV_BID - UNIFORM + /// + public sealed partial class AdGroupSimulation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupSimulation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulationReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupSimulation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupSimulation(AdGroupSimulation other) : this() { + resourceName_ = other.resourceName_; + AdGroupId = other.AdGroupId; + type_ = other.type_; + modificationMethod_ = other.modificationMethod_; + StartDate = other.StartDate; + EndDate = other.EndDate; + switch (other.PointListCase) { + case PointListOneofCase.CpcBidPointList: + CpcBidPointList = other.CpcBidPointList.Clone(); + break; + case PointListOneofCase.CpvBidPointList: + CpvBidPointList = other.CpvBidPointList.Clone(); + break; + case PointListOneofCase.TargetCpaPointList: + TargetCpaPointList = other.TargetCpaPointList.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupSimulation Clone() { + return new AdGroupSimulation(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad group simulation. + /// Ad group simulation resource names have the form: + /// + /// `customers/{customer_id}/adGroupSimulations/{ad_group_id}~{type}~{modification_method}~{start_date}~{end_date}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "ad_group_id" field. + public const int AdGroupIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_adGroupId_codec = pb::FieldCodec.ForStructWrapper(18); + private long? adGroupId_; + /// + /// Output only. Ad group id of the simulation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AdGroupId { + get { return adGroupId_; } + set { + adGroupId_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType type_ = 0; + /// + /// Output only. The field that the simulation modifies. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "modification_method" field. + public const int ModificationMethodFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod modificationMethod_ = 0; + /// + /// Output only. How the simulation modifies the field. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod ModificationMethod { + get { return modificationMethod_; } + set { + modificationMethod_ = value; + } + } + + /// Field number for the "start_date" field. + public const int StartDateFieldNumber = 5; + private static readonly pb::FieldCodec _single_startDate_codec = pb::FieldCodec.ForClassWrapper(42); + private string startDate_; + /// + /// Output only. First day on which the simulation is based, in YYYY-MM-DD format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDate { + get { return startDate_; } + set { + startDate_ = value; + } + } + + + /// Field number for the "end_date" field. + public const int EndDateFieldNumber = 6; + private static readonly pb::FieldCodec _single_endDate_codec = pb::FieldCodec.ForClassWrapper(50); + private string endDate_; + /// + /// Output only. Last day on which the simulation is based, in YYYY-MM-DD format + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDate { + get { return endDate_; } + set { + endDate_ = value; + } + } + + + /// Field number for the "cpc_bid_point_list" field. + public const int CpcBidPointListFieldNumber = 8; + /// + /// Output only. Simulation points if the simulation type is CPC_BID. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList CpcBidPointList { + get { return pointListCase_ == PointListOneofCase.CpcBidPointList ? (global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList) pointList_ : null; } + set { + pointList_ = value; + pointListCase_ = value == null ? PointListOneofCase.None : PointListOneofCase.CpcBidPointList; + } + } + + /// Field number for the "cpv_bid_point_list" field. + public const int CpvBidPointListFieldNumber = 10; + /// + /// Output only. Simulation points if the simulation type is CPV_BID. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CpvBidSimulationPointList CpvBidPointList { + get { return pointListCase_ == PointListOneofCase.CpvBidPointList ? (global::Google.Ads.GoogleAds.V3.Common.CpvBidSimulationPointList) pointList_ : null; } + set { + pointList_ = value; + pointListCase_ = value == null ? PointListOneofCase.None : PointListOneofCase.CpvBidPointList; + } + } + + /// Field number for the "target_cpa_point_list" field. + public const int TargetCpaPointListFieldNumber = 9; + /// + /// Output only. Simulation points if the simulation type is TARGET_CPA. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetCpaSimulationPointList TargetCpaPointList { + get { return pointListCase_ == PointListOneofCase.TargetCpaPointList ? (global::Google.Ads.GoogleAds.V3.Common.TargetCpaSimulationPointList) pointList_ : null; } + set { + pointList_ = value; + pointListCase_ = value == null ? PointListOneofCase.None : PointListOneofCase.TargetCpaPointList; + } + } + + private object pointList_; + /// Enum of possible cases for the "point_list" oneof. + public enum PointListOneofCase { + None = 0, + CpcBidPointList = 8, + CpvBidPointList = 10, + TargetCpaPointList = 9, + } + private PointListOneofCase pointListCase_ = PointListOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PointListOneofCase PointListCase { + get { return pointListCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearPointList() { + pointListCase_ = PointListOneofCase.None; + pointList_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupSimulation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupSimulation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (AdGroupId != other.AdGroupId) return false; + if (Type != other.Type) return false; + if (ModificationMethod != other.ModificationMethod) return false; + if (StartDate != other.StartDate) return false; + if (EndDate != other.EndDate) return false; + if (!object.Equals(CpcBidPointList, other.CpcBidPointList)) return false; + if (!object.Equals(CpvBidPointList, other.CpvBidPointList)) return false; + if (!object.Equals(TargetCpaPointList, other.TargetCpaPointList)) return false; + if (PointListCase != other.PointListCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (adGroupId_ != null) hash ^= AdGroupId.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (ModificationMethod != 0) hash ^= ModificationMethod.GetHashCode(); + if (startDate_ != null) hash ^= StartDate.GetHashCode(); + if (endDate_ != null) hash ^= EndDate.GetHashCode(); + if (pointListCase_ == PointListOneofCase.CpcBidPointList) hash ^= CpcBidPointList.GetHashCode(); + if (pointListCase_ == PointListOneofCase.CpvBidPointList) hash ^= CpvBidPointList.GetHashCode(); + if (pointListCase_ == PointListOneofCase.TargetCpaPointList) hash ^= TargetCpaPointList.GetHashCode(); + hash ^= (int) pointListCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (adGroupId_ != null) { + _single_adGroupId_codec.WriteTagAndValue(output, AdGroupId); + } + if (Type != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Type); + } + if (ModificationMethod != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) ModificationMethod); + } + if (startDate_ != null) { + _single_startDate_codec.WriteTagAndValue(output, StartDate); + } + if (endDate_ != null) { + _single_endDate_codec.WriteTagAndValue(output, EndDate); + } + if (pointListCase_ == PointListOneofCase.CpcBidPointList) { + output.WriteRawTag(66); + output.WriteMessage(CpcBidPointList); + } + if (pointListCase_ == PointListOneofCase.TargetCpaPointList) { + output.WriteRawTag(74); + output.WriteMessage(TargetCpaPointList); + } + if (pointListCase_ == PointListOneofCase.CpvBidPointList) { + output.WriteRawTag(82); + output.WriteMessage(CpvBidPointList); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (adGroupId_ != null) { + size += _single_adGroupId_codec.CalculateSizeWithTag(AdGroupId); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (ModificationMethod != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ModificationMethod); + } + if (startDate_ != null) { + size += _single_startDate_codec.CalculateSizeWithTag(StartDate); + } + if (endDate_ != null) { + size += _single_endDate_codec.CalculateSizeWithTag(EndDate); + } + if (pointListCase_ == PointListOneofCase.CpcBidPointList) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CpcBidPointList); + } + if (pointListCase_ == PointListOneofCase.CpvBidPointList) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CpvBidPointList); + } + if (pointListCase_ == PointListOneofCase.TargetCpaPointList) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(TargetCpaPointList); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupSimulation other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.adGroupId_ != null) { + if (adGroupId_ == null || other.AdGroupId != 0L) { + AdGroupId = other.AdGroupId; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.ModificationMethod != 0) { + ModificationMethod = other.ModificationMethod; + } + if (other.startDate_ != null) { + if (startDate_ == null || other.StartDate != "") { + StartDate = other.StartDate; + } + } + if (other.endDate_ != null) { + if (endDate_ == null || other.EndDate != "") { + EndDate = other.EndDate; + } + } + switch (other.PointListCase) { + case PointListOneofCase.CpcBidPointList: + if (CpcBidPointList == null) { + CpcBidPointList = new global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList(); + } + CpcBidPointList.MergeFrom(other.CpcBidPointList); + break; + case PointListOneofCase.CpvBidPointList: + if (CpvBidPointList == null) { + CpvBidPointList = new global::Google.Ads.GoogleAds.V3.Common.CpvBidSimulationPointList(); + } + CpvBidPointList.MergeFrom(other.CpvBidPointList); + break; + case PointListOneofCase.TargetCpaPointList: + if (TargetCpaPointList == null) { + TargetCpaPointList = new global::Google.Ads.GoogleAds.V3.Common.TargetCpaSimulationPointList(); + } + TargetCpaPointList.MergeFrom(other.TargetCpaPointList); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_adGroupId_codec.Read(input); + if (adGroupId_ == null || value != 0L) { + AdGroupId = value; + } + break; + } + case 24: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType) input.ReadEnum(); + break; + } + case 32: { + ModificationMethod = (global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod) input.ReadEnum(); + break; + } + case 42: { + string value = _single_startDate_codec.Read(input); + if (startDate_ == null || value != "") { + StartDate = value; + } + break; + } + case 50: { + string value = _single_endDate_codec.Read(input); + if (endDate_ == null || value != "") { + EndDate = value; + } + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CpcBidSimulationPointList(); + if (pointListCase_ == PointListOneofCase.CpcBidPointList) { + subBuilder.MergeFrom(CpcBidPointList); + } + input.ReadMessage(subBuilder); + CpcBidPointList = subBuilder; + break; + } + case 74: { + global::Google.Ads.GoogleAds.V3.Common.TargetCpaSimulationPointList subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetCpaSimulationPointList(); + if (pointListCase_ == PointListOneofCase.TargetCpaPointList) { + subBuilder.MergeFrom(TargetCpaPointList); + } + input.ReadMessage(subBuilder); + TargetCpaPointList = subBuilder; + break; + } + case 82: { + global::Google.Ads.GoogleAds.V3.Common.CpvBidSimulationPointList subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CpvBidSimulationPointList(); + if (pointListCase_ == PointListOneofCase.CpvBidPointList) { + subBuilder.MergeFrom(CpvBidPointList); + } + input.ReadMessage(subBuilder); + CpvBidPointList = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupSimulationService.cs b/src/V3/Stubs/AdGroupSimulationService.cs new file mode 100644 index 000000000..23dec3a4d --- /dev/null +++ b/src/V3/Stubs/AdGroupSimulationService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_simulation_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_group_simulation_service.proto + public static partial class AdGroupSimulationServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_group_simulation_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupSimulationServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9z", + "aW11bGF0aW9uX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvYWRfZ3JvdXBfc2ltdWxhdGlvbi5wcm90bxocZ29vZ2xlL2FwaS9hbm5v", + "dGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2ds", + "ZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8iOQobR2V0QWRHcm91cFNpbXVs", + "YXRpb25SZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAjKTAgoY", + "QWRHcm91cFNpbXVsYXRpb25TZXJ2aWNlEtkBChRHZXRBZEdyb3VwU2ltdWxh", + "dGlvbhI9Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEFk", + "R3JvdXBTaW11bGF0aW9uUmVxdWVzdBo0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5BZEdyb3VwU2ltdWxhdGlvbiJMgtPkkwI2EjQvdjMv", + "e3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovYWRHcm91cFNpbXVsYXRpb25z", + "Lyp92kENcmVzb3VyY2VfbmFtZRobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMu", + "Y29tQoQCCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNC", + "HUFkR3JvdXBTaW11bGF0aW9uU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9z", + "ZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2Vydmlj", + "ZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulationReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupSimulationRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupSimulationRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdGroupSimulationService.GetAdGroupSimulation][google.ads.googleads.v3.services.AdGroupSimulationService.GetAdGroupSimulation]. + /// + public sealed partial class GetAdGroupSimulationRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdGroupSimulationRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupSimulationServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupSimulationRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupSimulationRequest(GetAdGroupSimulationRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdGroupSimulationRequest Clone() { + return new GetAdGroupSimulationRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group simulation to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdGroupSimulationRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdGroupSimulationRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdGroupSimulationRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupSimulationServiceClient.cs b/src/V3/Stubs/AdGroupSimulationServiceClient.cs new file mode 100644 index 000000000..d08500ba8 --- /dev/null +++ b/src/V3/Stubs/AdGroupSimulationServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdGroupSimulationServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdGroupSimulationServiceSettings GetDefault() => new AdGroupSimulationServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdGroupSimulationServiceSettings() { } + + private AdGroupSimulationServiceSettings(AdGroupSimulationServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdGroupSimulationSettings = existing.GetAdGroupSimulationSettings; + OnCopy(existing); + } + + partial void OnCopy(AdGroupSimulationServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdGroupSimulationServiceClient.GetAdGroupSimulation and AdGroupSimulationServiceClient.GetAdGroupSimulationAsync. + /// + /// + /// The default AdGroupSimulationServiceClient.GetAdGroupSimulation and + /// AdGroupSimulationServiceClient.GetAdGroupSimulationAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdGroupSimulationSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdGroupSimulationServiceSettings Clone() => new AdGroupSimulationServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdGroupSimulationServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdGroupSimulationServiceSettings Settings { get; set; } + + /// + public override AdGroupSimulationServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdGroupSimulationServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdGroupSimulationServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdGroupSimulationServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdGroupSimulationServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdGroupSimulationServiceClient.ChannelPool; + } + + /// + /// AdGroupSimulationService client wrapper, for convenient use. + /// + public abstract partial class AdGroupSimulationServiceClient + { + /// + /// The default endpoint for the AdGroupSimulationService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdGroupSimulationService scopes. + /// + /// + /// The default AdGroupSimulationService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupSimulationServiceClient client = await AdGroupSimulationServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupSimulationServiceClient.DefaultEndpoint.Host, AdGroupSimulationServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupSimulationServiceClient client = AdGroupSimulationServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupSimulationServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdGroupSimulationServiceClient client = AdGroupSimulationServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdGroupSimulationServiceClient.DefaultEndpoint.Host, AdGroupSimulationServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdGroupSimulationServiceClient client = AdGroupSimulationServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdGroupSimulationServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdGroupSimulationServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupSimulationServiceClient Create(grpccore::Channel channel, AdGroupSimulationServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdGroupSimulationServiceClient Create(grpccore::CallInvoker callInvoker, AdGroupSimulationServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdGroupSimulationService.AdGroupSimulationServiceClient grpcClient = new AdGroupSimulationService.AdGroupSimulationServiceClient(callInvoker); + return new AdGroupSimulationServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdGroupSimulationService client. + /// + public virtual AdGroupSimulationService.AdGroupSimulationServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// + /// Required. The resource name of the ad group simulation to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupSimulationAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupSimulationAsync( + new GetAdGroupSimulationRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// + /// Required. The resource name of the ad group simulation to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupSimulationAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdGroupSimulationAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// + /// Required. The resource name of the ad group simulation to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupSimulation GetAdGroupSimulation( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdGroupSimulation( + new GetAdGroupSimulationRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupSimulationAsync( + GetAdGroupSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdGroupSimulationAsync( + GetAdGroupSimulationRequest request, + st::CancellationToken cancellationToken) => GetAdGroupSimulationAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdGroupSimulation GetAdGroupSimulation( + GetAdGroupSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdGroupSimulationService client wrapper implementation, for convenient use. + /// + public sealed partial class AdGroupSimulationServiceClientImpl : AdGroupSimulationServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdGroupSimulation; + + /// + /// Constructs a client wrapper for the AdGroupSimulationService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdGroupSimulationServiceClientImpl(AdGroupSimulationService.AdGroupSimulationServiceClient grpcClient, AdGroupSimulationServiceSettings settings) + { + GrpcClient = grpcClient; + AdGroupSimulationServiceSettings effectiveSettings = settings ?? AdGroupSimulationServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdGroupSimulation = clientHelper.BuildApiCall( + GrpcClient.GetAdGroupSimulationAsync, GrpcClient.GetAdGroupSimulation, effectiveSettings.GetAdGroupSimulationSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetAdGroupSimulation); + Modify_GetAdGroupSimulationApiCall(ref _callGetAdGroupSimulation); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdGroupSimulationApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdGroupSimulationService.AdGroupSimulationServiceClient grpcClient, AdGroupSimulationServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdGroupSimulationService client. + /// + public override AdGroupSimulationService.AdGroupSimulationServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdGroupSimulationRequest(ref GetAdGroupSimulationRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdGroupSimulationAsync( + GetAdGroupSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupSimulationRequest(ref request, ref callSettings); + return _callGetAdGroupSimulation.Async(request, callSettings); + } + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdGroupSimulation GetAdGroupSimulation( + GetAdGroupSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdGroupSimulationRequest(ref request, ref callSettings); + return _callGetAdGroupSimulation.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdGroupSimulationServiceGrpc.cs b/src/V3/Stubs/AdGroupSimulationServiceGrpc.cs new file mode 100644 index 000000000..5ab4921b4 --- /dev/null +++ b/src/V3/Stubs/AdGroupSimulationServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_group_simulation_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch ad group simulations. + /// + public static partial class AdGroupSimulationService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdGroupSimulationService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdGroupSimulationRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdGroupSimulationRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdGroupSimulation = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdGroupSimulation = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdGroupSimulation", + __Marshaller_google_ads_googleads_v3_services_GetAdGroupSimulationRequest, + __Marshaller_google_ads_googleads_v3_resources_AdGroupSimulation); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdGroupSimulationServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdGroupSimulationService + public abstract partial class AdGroupSimulationServiceBase + { + /// + /// Returns the requested ad group simulation in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdGroupSimulation(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupSimulationRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdGroupSimulationService + public partial class AdGroupSimulationServiceClient : grpc::ClientBase + { + /// Creates a new client for AdGroupSimulationService + /// The channel to use to make remote calls. + public AdGroupSimulationServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdGroupSimulationService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdGroupSimulationServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdGroupSimulationServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdGroupSimulationServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad group simulation in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation GetAdGroupSimulation(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupSimulationRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupSimulation(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group simulation in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation GetAdGroupSimulation(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupSimulationRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdGroupSimulation, null, options, request); + } + /// + /// Returns the requested ad group simulation in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupSimulationAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupSimulationRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdGroupSimulationAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad group simulation in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdGroupSimulationAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdGroupSimulationRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdGroupSimulation, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdGroupSimulationServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdGroupSimulationServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdGroupSimulationServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdGroupSimulation, serviceImpl.GetAdGroupSimulation).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdGroupSimulationServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdGroupSimulation, serviceImpl.GetAdGroupSimulation); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdGroupStatus.cs b/src/V3/Stubs/AdGroupStatus.cs new file mode 100644 index 000000000..db2ae5c8b --- /dev/null +++ b/src/V3/Stubs/AdGroupStatus.cs @@ -0,0 +1,191 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_group_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_group_status.proto + public static partial class AdGroupStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_group_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9ncm91cF9zdGF0", + "dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvImgKEUFkR3JvdXBTdGF0dXNFbnVt", + "IlMKDUFkR3JvdXBTdGF0dXMSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dO", + "EAESCwoHRU5BQkxFRBACEgoKBlBBVVNFRBADEgsKB1JFTU9WRUQQBELnAQoh", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhJBZEdyb3VwU3Rh", + "dHVzUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29v", + "Z2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2ds", + "ZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpF", + "bnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupStatusEnum.Types.AdGroupStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of an ad group. + /// + public sealed partial class AdGroupStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdGroupStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupStatusEnum(AdGroupStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupStatusEnum Clone() { + return new AdGroupStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of an ad group. + /// + public enum AdGroupStatus { + /// + /// The status has not been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The ad group is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// The ad group is paused. + /// + [pbr::OriginalName("PAUSED")] Paused = 3, + /// + /// The ad group is removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdGroupType.cs b/src/V3/Stubs/AdGroupType.cs new file mode 100644 index 000000000..236dbe671 --- /dev/null +++ b/src/V3/Stubs/AdGroupType.cs @@ -0,0 +1,239 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_group_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_group_type.proto + public static partial class AdGroupTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_group_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdGroupTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9ncm91cF90eXBl", + "LnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byKJAwoPQWRHcm91cFR5cGVFbnVtIvUC", + "CgtBZEdyb3VwVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIT", + "Cg9TRUFSQ0hfU1RBTkRBUkQQAhIUChBESVNQTEFZX1NUQU5EQVJEEAMSGAoU", + "U0hPUFBJTkdfUFJPRFVDVF9BRFMQBBINCglIT1RFTF9BRFMQBhIWChJTSE9Q", + "UElOR19TTUFSVF9BRFMQBxIQCgxWSURFT19CVU1QRVIQCBIdChlWSURFT19U", + "UlVFX1ZJRVdfSU5fU1RSRUFNEAkSHgoaVklERU9fVFJVRV9WSUVXX0lOX0RJ", + "U1BMQVkQChIhCh1WSURFT19OT05fU0tJUFBBQkxFX0lOX1NUUkVBTRALEhMK", + "D1ZJREVPX09VVFNUUkVBTRAMEhYKElNFQVJDSF9EWU5BTUlDX0FEUxANEiMK", + "H1NIT1BQSU5HX0NPTVBBUklTT05fTElTVElOR19BRFMQDhIWChJQUk9NT1RF", + "RF9IT1RFTF9BRFMQD0LlAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zQhBBZEdyb3VwVHlwZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztl", + "bnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygId", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdGroupTypeEnum.Types.AdGroupType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Defines types of an ad group, specific to a particular campaign channel + /// type. This type drives validations that restrict which entities can be + /// added to the ad group. + /// + public sealed partial class AdGroupTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdGroupTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdGroupTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupTypeEnum(AdGroupTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdGroupTypeEnum Clone() { + return new AdGroupTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdGroupTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdGroupTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdGroupTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdGroupTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum listing the possible types of an ad group. + /// + public enum AdGroupType { + /// + /// The type has not been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The default ad group type for Search campaigns. + /// + [pbr::OriginalName("SEARCH_STANDARD")] SearchStandard = 2, + /// + /// The default ad group type for Display campaigns. + /// + [pbr::OriginalName("DISPLAY_STANDARD")] DisplayStandard = 3, + /// + /// The ad group type for Shopping campaigns serving standard product ads. + /// + [pbr::OriginalName("SHOPPING_PRODUCT_ADS")] ShoppingProductAds = 4, + /// + /// The default ad group type for Hotel campaigns. + /// + [pbr::OriginalName("HOTEL_ADS")] HotelAds = 6, + /// + /// The type for ad groups in Smart Shopping campaigns. + /// + [pbr::OriginalName("SHOPPING_SMART_ADS")] ShoppingSmartAds = 7, + /// + /// Short unskippable in-stream video ads. + /// + [pbr::OriginalName("VIDEO_BUMPER")] VideoBumper = 8, + /// + /// TrueView (skippable) in-stream video ads. + /// + [pbr::OriginalName("VIDEO_TRUE_VIEW_IN_STREAM")] VideoTrueViewInStream = 9, + /// + /// TrueView in-display video ads. + /// + [pbr::OriginalName("VIDEO_TRUE_VIEW_IN_DISPLAY")] VideoTrueViewInDisplay = 10, + /// + /// Unskippable in-stream video ads. + /// + [pbr::OriginalName("VIDEO_NON_SKIPPABLE_IN_STREAM")] VideoNonSkippableInStream = 11, + /// + /// Outstream video ads. + /// + [pbr::OriginalName("VIDEO_OUTSTREAM")] VideoOutstream = 12, + /// + /// Ad group type for Dynamic Search Ads ad groups. + /// + [pbr::OriginalName("SEARCH_DYNAMIC_ADS")] SearchDynamicAds = 13, + /// + /// The type for ad groups in Shopping Comparison Listing campaigns. + /// + [pbr::OriginalName("SHOPPING_COMPARISON_LISTING_ADS")] ShoppingComparisonListingAds = 14, + /// + /// The ad group type for Promoted Hotel ad groups. + /// + [pbr::OriginalName("PROMOTED_HOTEL_ADS")] PromotedHotelAds = 15, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdNetworkType.cs b/src/V3/Stubs/AdNetworkType.cs new file mode 100644 index 000000000..0648dca12 --- /dev/null +++ b/src/V3/Stubs/AdNetworkType.cs @@ -0,0 +1,202 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_network_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_network_type.proto + public static partial class AdNetworkTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_network_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdNetworkTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9uZXR3b3JrX3R5", + "cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvIqMBChFBZE5ldHdvcmtUeXBlRW51", + "bSKNAQoNQWROZXR3b3JrVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05P", + "V04QARIKCgZTRUFSQ0gQAhITCg9TRUFSQ0hfUEFSVE5FUlMQAxILCgdDT05U", + "RU5UEAQSEgoOWU9VVFVCRV9TRUFSQ0gQBRIRCg1ZT1VUVUJFX1dBVENIEAYS", + "CQoFTUlYRUQQB0LnAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zQhJBZE5ldHdvcmtUeXBlUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2Vu", + "dW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1H", + "b29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdNetworkTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AdNetworkTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdNetworkTypeEnum.Types.AdNetworkType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enumeration of Google Ads network types. + /// + public sealed partial class AdNetworkTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdNetworkTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdNetworkTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdNetworkTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdNetworkTypeEnum(AdNetworkTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdNetworkTypeEnum Clone() { + return new AdNetworkTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdNetworkTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdNetworkTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdNetworkTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdNetworkTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates Google Ads network types. + /// + public enum AdNetworkType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Google search. + /// + [pbr::OriginalName("SEARCH")] Search = 2, + /// + /// Search partners. + /// + [pbr::OriginalName("SEARCH_PARTNERS")] SearchPartners = 3, + /// + /// Display Network. + /// + [pbr::OriginalName("CONTENT")] Content = 4, + /// + /// YouTube Search. + /// + [pbr::OriginalName("YOUTUBE_SEARCH")] YoutubeSearch = 5, + /// + /// YouTube Videos + /// + [pbr::OriginalName("YOUTUBE_WATCH")] YoutubeWatch = 6, + /// + /// Cross-network. + /// + [pbr::OriginalName("MIXED")] Mixed = 7, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdParameter.cs b/src/V3/Stubs/AdParameter.cs new file mode 100644 index 000000000..b45cb3233 --- /dev/null +++ b/src/V3/Stubs/AdParameter.cs @@ -0,0 +1,327 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_parameter.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_parameter.proto + public static partial class AdParameterReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_parameter.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdParameterReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfcGFyYW1l", + "dGVyLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMa", + "H2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkv", + "cmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90", + "bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKNAwoLQWRQYXJhbWV0", + "ZXISQwoNcmVzb3VyY2VfbmFtZRgBIAEoCUIs4EEF+kEmCiRnb29nbGVhZHMu", + "Z29vZ2xlYXBpcy5jb20vQWRQYXJhbWV0ZXISawoSYWRfZ3JvdXBfY3JpdGVy", + "aW9uGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQjHgQQX6", + "QSsKKWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZEdyb3VwQ3JpdGVyaW9u", + "EjkKD3BhcmFtZXRlcl9pbmRleBgDIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5J", + "bnQ2NFZhbHVlQgPgQQUSNAoOaW5zZXJ0aW9uX3RleHQYBCABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWU6W+pBWAokZ29vZ2xlYWRzLmdvb2ds", + "ZWFwaXMuY29tL0FkUGFyYW1ldGVyEjBjdXN0b21lcnMve2N1c3RvbWVyfS9h", + "ZFBhcmFtZXRlcnMve2FkX3BhcmFtZXRlcn1C/QEKJWNvbS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXNCEEFkUGFyYW1ldGVyUHJvdG9QAVpK", + "Z29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29v", + "Z2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2ds", + "ZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdParameter), global::Google.Ads.GoogleAds.V3.Resources.AdParameter.Parser, new[]{ "ResourceName", "AdGroupCriterion", "ParameterIndex", "InsertionText" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad parameter that is used to update numeric values (such as prices or + /// inventory levels) in any text line of an ad (including URLs). There can + /// be a maximum of two AdParameters per ad group criterion. (One with + /// parameter_index = 1 and one with parameter_index = 2.) + /// In the ad the parameters are referenced by a placeholder of the form + /// "{param#:value}". E.g. "{param1:$17}" + /// + public sealed partial class AdParameter : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdParameter()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdParameterReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameter() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameter(AdParameter other) : this() { + resourceName_ = other.resourceName_; + AdGroupCriterion = other.AdGroupCriterion; + ParameterIndex = other.ParameterIndex; + InsertionText = other.InsertionText; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameter Clone() { + return new AdParameter(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad parameter. + /// Ad parameter resource names have the form: + /// + /// `customers/{customer_id}/adParameters/{ad_group_id}~{criterion_id}~{parameter_index}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "ad_group_criterion" field. + public const int AdGroupCriterionFieldNumber = 2; + private static readonly pb::FieldCodec _single_adGroupCriterion_codec = pb::FieldCodec.ForClassWrapper(18); + private string adGroupCriterion_; + /// + /// Immutable. The ad group criterion that this ad parameter belongs to. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupCriterion { + get { return adGroupCriterion_; } + set { + adGroupCriterion_ = value; + } + } + + + /// Field number for the "parameter_index" field. + public const int ParameterIndexFieldNumber = 3; + private static readonly pb::FieldCodec _single_parameterIndex_codec = pb::FieldCodec.ForStructWrapper(26); + private long? parameterIndex_; + /// + /// Immutable. The unique index of this ad parameter. Must be either 1 or 2. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ParameterIndex { + get { return parameterIndex_; } + set { + parameterIndex_ = value; + } + } + + + /// Field number for the "insertion_text" field. + public const int InsertionTextFieldNumber = 4; + private static readonly pb::FieldCodec _single_insertionText_codec = pb::FieldCodec.ForClassWrapper(34); + private string insertionText_; + /// + /// Numeric value to insert into the ad text. The following restrictions + /// apply: + /// - Can use comma or period as a separator, with an optional period or + /// comma (respectively) for fractional values. For example, 1,000,000.00 + /// and 2.000.000,10 are valid. + /// - Can be prepended or appended with a currency symbol. For example, + /// $99.99 is valid. + /// - Can be prepended or appended with a currency code. For example, 99.99USD + /// and EUR200 are valid. + /// - Can use '%'. For example, 1.0% and 1,0% are valid. + /// - Can use plus or minus. For example, -10.99 and 25+ are valid. + /// - Can use '/' between two numbers. For example 4/1 and 0.95/0.45 are + /// valid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string InsertionText { + get { return insertionText_; } + set { + insertionText_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdParameter); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdParameter other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (AdGroupCriterion != other.AdGroupCriterion) return false; + if (ParameterIndex != other.ParameterIndex) return false; + if (InsertionText != other.InsertionText) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (adGroupCriterion_ != null) hash ^= AdGroupCriterion.GetHashCode(); + if (parameterIndex_ != null) hash ^= ParameterIndex.GetHashCode(); + if (insertionText_ != null) hash ^= InsertionText.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (adGroupCriterion_ != null) { + _single_adGroupCriterion_codec.WriteTagAndValue(output, AdGroupCriterion); + } + if (parameterIndex_ != null) { + _single_parameterIndex_codec.WriteTagAndValue(output, ParameterIndex); + } + if (insertionText_ != null) { + _single_insertionText_codec.WriteTagAndValue(output, InsertionText); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (adGroupCriterion_ != null) { + size += _single_adGroupCriterion_codec.CalculateSizeWithTag(AdGroupCriterion); + } + if (parameterIndex_ != null) { + size += _single_parameterIndex_codec.CalculateSizeWithTag(ParameterIndex); + } + if (insertionText_ != null) { + size += _single_insertionText_codec.CalculateSizeWithTag(InsertionText); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdParameter other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.adGroupCriterion_ != null) { + if (adGroupCriterion_ == null || other.AdGroupCriterion != "") { + AdGroupCriterion = other.AdGroupCriterion; + } + } + if (other.parameterIndex_ != null) { + if (parameterIndex_ == null || other.ParameterIndex != 0L) { + ParameterIndex = other.ParameterIndex; + } + } + if (other.insertionText_ != null) { + if (insertionText_ == null || other.InsertionText != "") { + InsertionText = other.InsertionText; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_adGroupCriterion_codec.Read(input); + if (adGroupCriterion_ == null || value != "") { + AdGroupCriterion = value; + } + break; + } + case 26: { + long? value = _single_parameterIndex_codec.Read(input); + if (parameterIndex_ == null || value != 0L) { + ParameterIndex = value; + } + break; + } + case 34: { + string value = _single_insertionText_codec.Read(input); + if (insertionText_ == null || value != "") { + InsertionText = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdParameterError.cs b/src/V3/Stubs/AdParameterError.cs new file mode 100644 index 000000000..7d74995a5 --- /dev/null +++ b/src/V3/Stubs/AdParameterError.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_parameter_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_parameter_error.proto + public static partial class AdParameterErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_parameter_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdParameterErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfcGFyYW1ldGVy", + "X2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMa", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ikwEKFEFkUGFyYW1ldGVy", + "RXJyb3JFbnVtInsKEEFkUGFyYW1ldGVyRXJyb3ISDwoLVU5TUEVDSUZJRUQQ", + "ABILCgdVTktOT1dOEAESJgoiQURfR1JPVVBfQ1JJVEVSSU9OX01VU1RfQkVf", + "S0VZV09SRBACEiEKHUlOVkFMSURfSU5TRVJUSU9OX1RFWFRfRk9STUFUEANC", + "8AEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNCFUFkUGFy", + "YW1ldGVyRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90", + "by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6IC", + "A0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2ds", + "ZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29n", + "bGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdParameterErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdParameterErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdParameterErrorEnum.Types.AdParameterError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad parameter errors. + /// + public sealed partial class AdParameterErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdParameterErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdParameterErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameterErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameterErrorEnum(AdParameterErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameterErrorEnum Clone() { + return new AdParameterErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdParameterErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdParameterErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdParameterErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdParameterErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad parameter errors. + /// + public enum AdParameterError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The ad group criterion must be a keyword criterion. + /// + [pbr::OriginalName("AD_GROUP_CRITERION_MUST_BE_KEYWORD")] AdGroupCriterionMustBeKeyword = 2, + /// + /// The insertion text is invalid. + /// + [pbr::OriginalName("INVALID_INSERTION_TEXT_FORMAT")] InvalidInsertionTextFormat = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdParameterService.cs b/src/V3/Stubs/AdParameterService.cs new file mode 100644 index 000000000..3e2a70822 --- /dev/null +++ b/src/V3/Stubs/AdParameterService.cs @@ -0,0 +1,1033 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_parameter_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_parameter_service.proto + public static partial class AdParameterServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_parameter_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdParameterServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9wYXJhbWV0", + "ZXJfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMaNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9hZF9w", + "YXJhbWV0ZXIucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8a", + "F2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2Jl", + "aGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9idWYvZmllbGRfbWFzay5wcm90", + "bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8iMwoVR2V0QWRQYXJhbWV0ZXJS", + "ZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiK2AQoZTXV0YXRl", + "QWRQYXJhbWV0ZXJzUmVxdWVzdBIYCgtjdXN0b21lcl9pZBgBIAEoCUID4EEC", + "Ek8KCm9wZXJhdGlvbnMYAiADKAsyNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5BZFBhcmFtZXRlck9wZXJhdGlvbkID4EECEhcKD3BhcnRp", + "YWxfZmFpbHVyZRgDIAEoCBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIuoBChRB", + "ZFBhcmFtZXRlck9wZXJhdGlvbhIvCgt1cGRhdGVfbWFzaxgEIAEoCzIaLmdv", + "b2dsZS5wcm90b2J1Zi5GaWVsZE1hc2sSQAoGY3JlYXRlGAEgASgLMi4uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkFkUGFyYW1ldGVySAAS", + "QAoGdXBkYXRlGAIgASgLMi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLkFkUGFyYW1ldGVySAASEAoGcmVtb3ZlGAMgASgJSABCCwoJb3Bl", + "cmF0aW9uIpsBChpNdXRhdGVBZFBhcmFtZXRlcnNSZXNwb25zZRIxChVwYXJ0", + "aWFsX2ZhaWx1cmVfZXJyb3IYAyABKAsyEi5nb29nbGUucnBjLlN0YXR1cxJK", + "CgdyZXN1bHRzGAIgAygLMjkuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuTXV0YXRlQWRQYXJhbWV0ZXJSZXN1bHQiMAoXTXV0YXRlQWRQYXJh", + "bWV0ZXJSZXN1bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTLeAwoSQWRQYXJh", + "bWV0ZXJTZXJ2aWNlEsEBCg5HZXRBZFBhcmFtZXRlchI3Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEFkUGFyYW1ldGVyUmVxdWVzdBou", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZFBhcmFtZXRl", + "ciJGgtPkkwIwEi4vdjMve3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovYWRQ", + "YXJhbWV0ZXJzLyp92kENcmVzb3VyY2VfbmFtZRLmAQoSTXV0YXRlQWRQYXJh", + "bWV0ZXJzEjsuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0", + "YXRlQWRQYXJhbWV0ZXJzUmVxdWVzdBo8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLk11dGF0ZUFkUGFyYW1ldGVyc1Jlc3BvbnNlIlWC0+ST", + "AjYiMS92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2FkUGFyYW1ldGVy", + "czptdXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVyYXRpb25zGhvKQRhnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb21C/gEKJGNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlc0IXQWRQYXJhbWV0ZXJTZXJ2aWNlUHJvdG9QAVpI", + "Z29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29v", + "Z2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFk", + "cy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFk", + "c1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpT", + "ZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdParameterReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdParameterRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdParameterRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdParameterOperation), global::Google.Ads.GoogleAds.V3.Services.AdParameterOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdParameterResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdParameterResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdParameterService.GetAdParameter][google.ads.googleads.v3.services.AdParameterService.GetAdParameter] + /// + public sealed partial class GetAdParameterRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdParameterRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdParameterServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdParameterRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdParameterRequest(GetAdParameterRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdParameterRequest Clone() { + return new GetAdParameterRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad parameter to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdParameterRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdParameterRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdParameterRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdParameterService.MutateAdParameters][google.ads.googleads.v3.services.AdParameterService.MutateAdParameters] + /// + public sealed partial class MutateAdParametersRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdParametersRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdParameterServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParametersRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParametersRequest(MutateAdParametersRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParametersRequest Clone() { + return new MutateAdParametersRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose ad parameters are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdParameterOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual ad parameters. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdParametersRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdParametersRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdParametersRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on ad parameter. + /// + public sealed partial class AdParameterOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdParameterOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdParameterServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameterOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameterOperation(AdParameterOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdParameterOperation Clone() { + return new AdParameterOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new ad parameter. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdParameter Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.AdParameter) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The ad parameter is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdParameter Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.AdParameter) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the ad parameter to remove is + /// expected in this format: + /// + /// `customers/{customer_id}/adParameters/{ad_group_id}~{criterion_id}~{parameter_index}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdParameterOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdParameterOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdParameterOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.AdParameter(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.AdParameter(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.AdParameter subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdParameter(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.AdParameter subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.AdParameter(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for an ad parameter mutate. + /// + public sealed partial class MutateAdParametersResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdParametersResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdParameterServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParametersResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParametersResponse(MutateAdParametersResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParametersResponse Clone() { + return new MutateAdParametersResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdParameterResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdParametersResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdParametersResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdParametersResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the ad parameter mutate. + /// + public sealed partial class MutateAdParameterResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdParameterResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdParameterServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParameterResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParameterResult(MutateAdParameterResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdParameterResult Clone() { + return new MutateAdParameterResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// The resource name returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdParameterResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdParameterResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdParameterResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdParameterServiceClient.cs b/src/V3/Stubs/AdParameterServiceClient.cs new file mode 100644 index 000000000..fa3245d20 --- /dev/null +++ b/src/V3/Stubs/AdParameterServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdParameterServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdParameterServiceSettings GetDefault() => new AdParameterServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdParameterServiceSettings() { } + + private AdParameterServiceSettings(AdParameterServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdParameterSettings = existing.GetAdParameterSettings; + MutateAdParametersSettings = existing.MutateAdParametersSettings; + OnCopy(existing); + } + + partial void OnCopy(AdParameterServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdParameterServiceClient.GetAdParameter and AdParameterServiceClient.GetAdParameterAsync. + /// + /// + /// The default AdParameterServiceClient.GetAdParameter and + /// AdParameterServiceClient.GetAdParameterAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdParameterSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdParameterServiceClient.MutateAdParameters and AdParameterServiceClient.MutateAdParametersAsync. + /// + /// + /// The default AdParameterServiceClient.MutateAdParameters and + /// AdParameterServiceClient.MutateAdParametersAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdParametersSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdParameterServiceSettings Clone() => new AdParameterServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdParameterServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdParameterServiceSettings Settings { get; set; } + + /// + public override AdParameterServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdParameterServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdParameterServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdParameterServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdParameterServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdParameterServiceClient.ChannelPool; + } + + /// + /// AdParameterService client wrapper, for convenient use. + /// + public abstract partial class AdParameterServiceClient + { + /// + /// The default endpoint for the AdParameterService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdParameterService scopes. + /// + /// + /// The default AdParameterService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdParameterServiceClient client = await AdParameterServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdParameterServiceClient.DefaultEndpoint.Host, AdParameterServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdParameterServiceClient client = AdParameterServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdParameterServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdParameterServiceClient client = AdParameterServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdParameterServiceClient.DefaultEndpoint.Host, AdParameterServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdParameterServiceClient client = AdParameterServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdParameterServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdParameterServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdParameterServiceClient Create(grpccore::Channel channel, AdParameterServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdParameterServiceClient Create(grpccore::CallInvoker callInvoker, AdParameterServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdParameterService.AdParameterServiceClient grpcClient = new AdParameterService.AdParameterServiceClient(callInvoker); + return new AdParameterServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdParameterService client. + /// + public virtual AdParameterService.AdParameterServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad parameter in full detail. + /// + /// + /// Required. The resource name of the ad parameter to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdParameterAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdParameterAsync( + new GetAdParameterRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad parameter in full detail. + /// + /// + /// Required. The resource name of the ad parameter to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdParameterAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdParameterAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad parameter in full detail. + /// + /// + /// Required. The resource name of the ad parameter to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdParameter GetAdParameter( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdParameter( + new GetAdParameterRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad parameter in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdParameterAsync( + GetAdParameterRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad parameter in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdParameterAsync( + GetAdParameterRequest request, + st::CancellationToken cancellationToken) => GetAdParameterAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad parameter in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdParameter GetAdParameter( + GetAdParameterRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad parameters are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad parameters. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdParametersAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdParametersAsync( + new MutateAdParametersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad parameters are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad parameters. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdParametersAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAdParametersAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad parameters are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad parameters. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdParametersResponse MutateAdParameters( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAdParameters( + new MutateAdParametersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad parameters are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad parameters. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdParametersAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdParametersAsync( + new MutateAdParametersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad parameters are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad parameters. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdParametersAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdParametersAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose ad parameters are being modified. + /// + /// + /// Required. The list of operations to perform on individual ad parameters. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdParametersResponse MutateAdParameters( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdParameters( + new MutateAdParametersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdParametersAsync( + MutateAdParametersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdParametersAsync( + MutateAdParametersRequest request, + st::CancellationToken cancellationToken) => MutateAdParametersAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdParametersResponse MutateAdParameters( + MutateAdParametersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdParameterService client wrapper implementation, for convenient use. + /// + public sealed partial class AdParameterServiceClientImpl : AdParameterServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdParameter; + private readonly gaxgrpc::ApiCall _callMutateAdParameters; + + /// + /// Constructs a client wrapper for the AdParameterService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdParameterServiceClientImpl(AdParameterService.AdParameterServiceClient grpcClient, AdParameterServiceSettings settings) + { + GrpcClient = grpcClient; + AdParameterServiceSettings effectiveSettings = settings ?? AdParameterServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdParameter = clientHelper.BuildApiCall( + GrpcClient.GetAdParameterAsync, GrpcClient.GetAdParameter, effectiveSettings.GetAdParameterSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAdParameters = clientHelper.BuildApiCall( + GrpcClient.MutateAdParametersAsync, GrpcClient.MutateAdParameters, effectiveSettings.MutateAdParametersSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAdParameter); + Modify_GetAdParameterApiCall(ref _callGetAdParameter); + Modify_ApiCall(ref _callMutateAdParameters); + Modify_MutateAdParametersApiCall(ref _callMutateAdParameters); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdParameterApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdParametersApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdParameterService.AdParameterServiceClient grpcClient, AdParameterServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdParameterService client. + /// + public override AdParameterService.AdParameterServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdParameterRequest(ref GetAdParameterRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdParametersRequest(ref MutateAdParametersRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad parameter in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdParameterAsync( + GetAdParameterRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdParameterRequest(ref request, ref callSettings); + return _callGetAdParameter.Async(request, callSettings); + } + + /// + /// Returns the requested ad parameter in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdParameter GetAdParameter( + GetAdParameterRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdParameterRequest(ref request, ref callSettings); + return _callGetAdParameter.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdParametersAsync( + MutateAdParametersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdParametersRequest(ref request, ref callSettings); + return _callMutateAdParameters.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdParametersResponse MutateAdParameters( + MutateAdParametersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdParametersRequest(ref request, ref callSettings); + return _callMutateAdParameters.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdParameterServiceGrpc.cs b/src/V3/Stubs/AdParameterServiceGrpc.cs new file mode 100644 index 000000000..f239562d5 --- /dev/null +++ b/src/V3/Stubs/AdParameterServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_parameter_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ad parameters. + /// + public static partial class AdParameterService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdParameterService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdParameterRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdParameterRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdParameter = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdParameter.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdParametersRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdParametersResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdParameter = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdParameter", + __Marshaller_google_ads_googleads_v3_services_GetAdParameterRequest, + __Marshaller_google_ads_googleads_v3_resources_AdParameter); + + static readonly grpc::Method __Method_MutateAdParameters = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAdParameters", + __Marshaller_google_ads_googleads_v3_services_MutateAdParametersRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdParametersResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdParameterServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdParameterService + public abstract partial class AdParameterServiceBase + { + /// + /// Returns the requested ad parameter in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdParameter(global::Google.Ads.GoogleAds.V3.Services.GetAdParameterRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAdParameters(global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdParameterService + public partial class AdParameterServiceClient : grpc::ClientBase + { + /// Creates a new client for AdParameterService + /// The channel to use to make remote calls. + public AdParameterServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdParameterService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdParameterServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdParameterServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdParameterServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad parameter in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdParameter GetAdParameter(global::Google.Ads.GoogleAds.V3.Services.GetAdParameterRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdParameter(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad parameter in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdParameter GetAdParameter(global::Google.Ads.GoogleAds.V3.Services.GetAdParameterRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdParameter, null, options, request); + } + /// + /// Returns the requested ad parameter in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdParameterAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdParameterRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdParameterAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad parameter in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdParameterAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdParameterRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdParameter, null, options, request); + } + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersResponse MutateAdParameters(global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdParameters(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersResponse MutateAdParameters(global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAdParameters, null, options, request); + } + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdParametersAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdParametersAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes ad parameters. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdParametersAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdParametersRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAdParameters, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdParameterServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdParameterServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdParameterServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdParameter, serviceImpl.GetAdParameter) + .AddMethod(__Method_MutateAdParameters, serviceImpl.MutateAdParameters).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdParameterServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdParameter, serviceImpl.GetAdParameter); + serviceBinder.AddMethod(__Method_MutateAdParameters, serviceImpl.MutateAdParameters); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdScheduleView.cs b/src/V3/Stubs/AdScheduleView.cs new file mode 100644 index 000000000..910933dbd --- /dev/null +++ b/src/V3/Stubs/AdScheduleView.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/ad_schedule_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/ad_schedule_view.proto + public static partial class AdScheduleViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/ad_schedule_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdScheduleViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfc2NoZWR1", + "bGVfdmlldy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29nbGUv", + "YXBpL3Jlc291cmNlLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvIr8BCg5BZFNjaGVkdWxlVmlldxJGCg1yZXNvdXJjZV9uYW1lGAEgASgJ", + "Qi/gQQX6QSkKJ2dvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZFNjaGVkdWxl", + "Vmlldzpl6kFiCidnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRTY2hlZHVs", + "ZVZpZXcSN2N1c3RvbWVycy97Y3VzdG9tZXJ9L2FkU2NoZWR1bGVWaWV3cy97", + "YWRfc2NoZWR1bGVfdmlld31CgAIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXNCE0FkU2NoZWR1bGVWaWV3UHJvdG9QAVpKZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xW", + "M1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVz", + "b3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView), global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An ad schedule view summarizes the performance of campaigns by + /// AdSchedule criteria. + /// + public sealed partial class AdScheduleView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdScheduleView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AdScheduleViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdScheduleView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdScheduleView(AdScheduleView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdScheduleView Clone() { + return new AdScheduleView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the ad schedule view. + /// AdSchedule view resource names have the form: + /// + /// `customers/{customer_id}/adScheduleViews/{campaign_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdScheduleView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdScheduleView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdScheduleView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdScheduleViewService.cs b/src/V3/Stubs/AdScheduleViewService.cs new file mode 100644 index 000000000..8136168a8 --- /dev/null +++ b/src/V3/Stubs/AdScheduleViewService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_schedule_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_schedule_view_service.proto + public static partial class AdScheduleViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_schedule_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdScheduleViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9zY2hlZHVs", + "ZV92aWV3X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "YWRfc2NoZWR1bGVfdmlldy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkv", + "ZmllbGRfYmVoYXZpb3IucHJvdG8iNgoYR2V0QWRTY2hlZHVsZVZpZXdSZXF1", + "ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAjKEAgoVQWRTY2hlZHVs", + "ZVZpZXdTZXJ2aWNlEs0BChFHZXRBZFNjaGVkdWxlVmlldxI6Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEFkU2NoZWR1bGVWaWV3UmVx", + "dWVzdBoxLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZFNj", + "aGVkdWxlVmlldyJJgtPkkwIzEjEvdjMve3Jlc291cmNlX25hbWU9Y3VzdG9t", + "ZXJzLyovYWRTY2hlZHVsZVZpZXdzLyp92kENcmVzb3VyY2VfbmFtZRobykEY", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQoECCiRjb20uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXNCGkFkU2NoZWR1bGVWaWV3U2VydmljZVBy", + "b3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdScheduleViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdScheduleViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdScheduleViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdScheduleViewService.GetAdScheduleView][google.ads.googleads.v3.services.AdScheduleViewService.GetAdScheduleView]. + /// + public sealed partial class GetAdScheduleViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdScheduleViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdScheduleViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdScheduleViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdScheduleViewRequest(GetAdScheduleViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdScheduleViewRequest Clone() { + return new GetAdScheduleViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad schedule view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdScheduleViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdScheduleViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdScheduleViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdScheduleViewServiceClient.cs b/src/V3/Stubs/AdScheduleViewServiceClient.cs new file mode 100644 index 000000000..9175d34c3 --- /dev/null +++ b/src/V3/Stubs/AdScheduleViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdScheduleViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdScheduleViewServiceSettings GetDefault() => new AdScheduleViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdScheduleViewServiceSettings() { } + + private AdScheduleViewServiceSettings(AdScheduleViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdScheduleViewSettings = existing.GetAdScheduleViewSettings; + OnCopy(existing); + } + + partial void OnCopy(AdScheduleViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdScheduleViewServiceClient.GetAdScheduleView and AdScheduleViewServiceClient.GetAdScheduleViewAsync. + /// + /// + /// The default AdScheduleViewServiceClient.GetAdScheduleView and + /// AdScheduleViewServiceClient.GetAdScheduleViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdScheduleViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdScheduleViewServiceSettings Clone() => new AdScheduleViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdScheduleViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdScheduleViewServiceSettings Settings { get; set; } + + /// + public override AdScheduleViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdScheduleViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdScheduleViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdScheduleViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdScheduleViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdScheduleViewServiceClient.ChannelPool; + } + + /// + /// AdScheduleViewService client wrapper, for convenient use. + /// + public abstract partial class AdScheduleViewServiceClient + { + /// + /// The default endpoint for the AdScheduleViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdScheduleViewService scopes. + /// + /// + /// The default AdScheduleViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdScheduleViewServiceClient client = await AdScheduleViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdScheduleViewServiceClient.DefaultEndpoint.Host, AdScheduleViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdScheduleViewServiceClient client = AdScheduleViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdScheduleViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdScheduleViewServiceClient client = AdScheduleViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdScheduleViewServiceClient.DefaultEndpoint.Host, AdScheduleViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdScheduleViewServiceClient client = AdScheduleViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdScheduleViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdScheduleViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdScheduleViewServiceClient Create(grpccore::Channel channel, AdScheduleViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdScheduleViewServiceClient Create(grpccore::CallInvoker callInvoker, AdScheduleViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdScheduleViewService.AdScheduleViewServiceClient grpcClient = new AdScheduleViewService.AdScheduleViewServiceClient(callInvoker); + return new AdScheduleViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdScheduleViewService client. + /// + public virtual AdScheduleViewService.AdScheduleViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// + /// Required. The resource name of the ad schedule view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdScheduleViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdScheduleViewAsync( + new GetAdScheduleViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// + /// Required. The resource name of the ad schedule view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdScheduleViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdScheduleViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// + /// Required. The resource name of the ad schedule view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdScheduleView GetAdScheduleView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdScheduleView( + new GetAdScheduleViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdScheduleViewAsync( + GetAdScheduleViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdScheduleViewAsync( + GetAdScheduleViewRequest request, + st::CancellationToken cancellationToken) => GetAdScheduleViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AdScheduleView GetAdScheduleView( + GetAdScheduleViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdScheduleViewService client wrapper implementation, for convenient use. + /// + public sealed partial class AdScheduleViewServiceClientImpl : AdScheduleViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAdScheduleView; + + /// + /// Constructs a client wrapper for the AdScheduleViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdScheduleViewServiceClientImpl(AdScheduleViewService.AdScheduleViewServiceClient grpcClient, AdScheduleViewServiceSettings settings) + { + GrpcClient = grpcClient; + AdScheduleViewServiceSettings effectiveSettings = settings ?? AdScheduleViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAdScheduleView = clientHelper.BuildApiCall( + GrpcClient.GetAdScheduleViewAsync, GrpcClient.GetAdScheduleView, effectiveSettings.GetAdScheduleViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetAdScheduleView); + Modify_GetAdScheduleViewApiCall(ref _callGetAdScheduleView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdScheduleViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdScheduleViewService.AdScheduleViewServiceClient grpcClient, AdScheduleViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdScheduleViewService client. + /// + public override AdScheduleViewService.AdScheduleViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdScheduleViewRequest(ref GetAdScheduleViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdScheduleViewAsync( + GetAdScheduleViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdScheduleViewRequest(ref request, ref callSettings); + return _callGetAdScheduleView.Async(request, callSettings); + } + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AdScheduleView GetAdScheduleView( + GetAdScheduleViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdScheduleViewRequest(ref request, ref callSettings); + return _callGetAdScheduleView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdScheduleViewServiceGrpc.cs b/src/V3/Stubs/AdScheduleViewServiceGrpc.cs new file mode 100644 index 000000000..6b51a2d5e --- /dev/null +++ b/src/V3/Stubs/AdScheduleViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_schedule_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch ad schedule views. + /// + public static partial class AdScheduleViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdScheduleViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdScheduleViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdScheduleViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AdScheduleView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAdScheduleView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAdScheduleView", + __Marshaller_google_ads_googleads_v3_services_GetAdScheduleViewRequest, + __Marshaller_google_ads_googleads_v3_resources_AdScheduleView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdScheduleViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdScheduleViewService + public abstract partial class AdScheduleViewServiceBase + { + /// + /// Returns the requested ad schedule view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAdScheduleView(global::Google.Ads.GoogleAds.V3.Services.GetAdScheduleViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdScheduleViewService + public partial class AdScheduleViewServiceClient : grpc::ClientBase + { + /// Creates a new client for AdScheduleViewService + /// The channel to use to make remote calls. + public AdScheduleViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdScheduleViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdScheduleViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdScheduleViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdScheduleViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad schedule view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView GetAdScheduleView(global::Google.Ads.GoogleAds.V3.Services.GetAdScheduleViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdScheduleView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad schedule view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView GetAdScheduleView(global::Google.Ads.GoogleAds.V3.Services.GetAdScheduleViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAdScheduleView, null, options, request); + } + /// + /// Returns the requested ad schedule view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdScheduleViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdScheduleViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdScheduleViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad schedule view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdScheduleViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdScheduleViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAdScheduleView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdScheduleViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdScheduleViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdScheduleViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAdScheduleView, serviceImpl.GetAdScheduleView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdScheduleViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAdScheduleView, serviceImpl.GetAdScheduleView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdService.cs b/src/V3/Stubs/AdService.cs new file mode 100644 index 000000000..63e206354 --- /dev/null +++ b/src/V3/Stubs/AdService.cs @@ -0,0 +1,841 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/ad_service.proto + public static partial class AdServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/ad_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9zZXJ2aWNl", + "LnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcxoqZ29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2FkLnByb3RvGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5w", + "cm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29vZ2xl", + "L3Byb3RvYnVmL2ZpZWxkX21hc2sucHJvdG8iKgoMR2V0QWRSZXF1ZXN0EhoK", + "DXJlc291cmNlX25hbWUYASABKAlCA+BBAiJ0ChBNdXRhdGVBZHNSZXF1ZXN0", + "EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPgQQISRgoKb3BlcmF0aW9ucxgCIAMo", + "CzItLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkFkT3BlcmF0", + "aW9uQgPgQQIihAEKC0FkT3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAIgASgL", + "MhouZ29vZ2xlLnByb3RvYnVmLkZpZWxkTWFzaxI3CgZ1cGRhdGUYASABKAsy", + "JS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRIAEILCglv", + "cGVyYXRpb24iVgoRTXV0YXRlQWRzUmVzcG9uc2USQQoHcmVzdWx0cxgCIAMo", + "CzIwLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFk", + "UmVzdWx0IicKDk11dGF0ZUFkUmVzdWx0EhUKDXJlc291cmNlX25hbWUYASAB", + "KAkyjQMKCUFkU2VydmljZRKdAQoFR2V0QWQSLi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5HZXRBZFJlcXVlc3QaJS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5yZXNvdXJjZXMuQWQiPYLT5JMCJxIlL3YzL3tyZXNvdXJj", + "ZV9uYW1lPWN1c3RvbWVycy8qL2Fkcy8qfdpBDXJlc291cmNlX25hbWUSwgEK", + "CU11dGF0ZUFkcxIyLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2Vz", + "Lk11dGF0ZUFkc1JlcXVlc3QaMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5NdXRhdGVBZHNSZXNwb25zZSJMgtPkkwItIigvdjMvY3VzdG9t", + "ZXJzL3tjdXN0b21lcl9pZD0qfS9hZHM6bXV0YXRlOgEq2kEWY3VzdG9tZXJf", + "aWQsb3BlcmF0aW9ucxobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQvUB", + "CiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCDkFkU2Vy", + "dmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dB", + "QaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xl", + "XEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AdReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAdRequest), global::Google.Ads.GoogleAds.V3.Services.GetAdRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAdsRequest.Parser, new[]{ "CustomerId", "Operations" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AdOperation), global::Google.Ads.GoogleAds.V3.Services.AdOperation.Parser, new[]{ "UpdateMask", "Update" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAdsResponse.Parser, new[]{ "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAdResult), global::Google.Ads.GoogleAds.V3.Services.MutateAdResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AdService.GetAd][google.ads.googleads.v3.services.AdService.GetAd]. + /// + public sealed partial class GetAdRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAdRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdRequest(GetAdRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAdRequest Clone() { + return new GetAdRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAdRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAdRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAdRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AdService.MutateAds][google.ads.googleads.v3.services.AdService.MutateAds]. + /// + public sealed partial class MutateAdsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdsRequest(MutateAdsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdsRequest Clone() { + return new MutateAdsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose ads are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AdOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual ads. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + } + } + } + + } + + /// + /// A single update operation on an ad. + /// + public sealed partial class AdOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdOperation(AdOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdOperation Clone() { + return new AdOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 2; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 1; + /// + /// Update operation: The ad is expected to have a valid resource name + /// in this format: + /// + /// `customers/{customer_id}/ads/{ad_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Ad Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.Ad) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Update = 1, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(10); + output.WriteMessage(Update); + } + if (updateMask_ != null) { + output.WriteRawTag(18); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.Ad(); + } + Update.MergeFrom(other.Update); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.Ad subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.Ad(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 18: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for an ad mutate. + /// + public sealed partial class MutateAdsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdsResponse(MutateAdsResponse other) : this() { + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdsResponse Clone() { + return new MutateAdsResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAdResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdsResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// The result for the ad mutate. + /// + public sealed partial class MutateAdResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAdResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AdServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdResult(MutateAdResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAdResult Clone() { + return new MutateAdResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// The resource name returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAdResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAdResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAdResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdServiceClient.cs b/src/V3/Stubs/AdServiceClient.cs new file mode 100644 index 000000000..211f2fdb3 --- /dev/null +++ b/src/V3/Stubs/AdServiceClient.cs @@ -0,0 +1,770 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AdServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AdServiceSettings GetDefault() => new AdServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AdServiceSettings() { } + + private AdServiceSettings(AdServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAdSettings = existing.GetAdSettings; + MutateAdsSettings = existing.MutateAdsSettings; + OnCopy(existing); + } + + partial void OnCopy(AdServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AdServiceClient.GetAd and AdServiceClient.GetAdAsync. + /// + /// + /// The default AdServiceClient.GetAd and + /// AdServiceClient.GetAdAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAdSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AdServiceClient.MutateAds and AdServiceClient.MutateAdsAsync. + /// + /// + /// The default AdServiceClient.MutateAds and + /// AdServiceClient.MutateAdsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAdsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AdServiceSettings Clone() => new AdServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AdServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AdServiceSettings Settings { get; set; } + + /// + public override AdServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AdServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AdServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AdServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AdServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AdServiceClient.ChannelPool; + } + + /// + /// AdService client wrapper, for convenient use. + /// + public abstract partial class AdServiceClient + { + /// + /// The default endpoint for the AdService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AdService scopes. + /// + /// + /// The default AdService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdServiceClient client = await AdServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdServiceClient.DefaultEndpoint.Host, AdServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdServiceClient client = AdServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AdServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AdServiceClient client = AdServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AdServiceClient.DefaultEndpoint.Host, AdServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AdServiceClient client = AdServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AdServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AdServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdServiceClient Create(grpccore::Channel channel, AdServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AdServiceClient Create(grpccore::CallInvoker callInvoker, AdServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AdService.AdServiceClient grpcClient = new AdService.AdServiceClient(callInvoker); + return new AdServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AdService client. + /// + public virtual AdService.AdServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested ad in full detail. + /// + /// + /// Required. The resource name of the ad to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAdAsync( + new GetAdRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// Required. The resource name of the ad to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAdAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// Required. The resource name of the ad to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Ad GetAd( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAd( + new GetAdRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdAsync( + GetAdRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAdAsync( + GetAdRequest request, + st::CancellationToken cancellationToken) => GetAdAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Ad GetAd( + GetAdRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Updates ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAdsAsync( + new MutateAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Updates ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAdsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Updates ads. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose ads are being modified. + /// + /// + /// Required. The list of operations to perform on individual ads. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdsResponse MutateAds( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAds( + new MutateAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Updates ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdsAsync( + MutateAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Updates ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAdsAsync( + MutateAdsRequest request, + st::CancellationToken cancellationToken) => MutateAdsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Updates ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAdsResponse MutateAds( + MutateAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AdService client wrapper implementation, for convenient use. + /// + public sealed partial class AdServiceClientImpl : AdServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAd; + private readonly gaxgrpc::ApiCall _callMutateAds; + + /// + /// Constructs a client wrapper for the AdService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AdServiceClientImpl(AdService.AdServiceClient grpcClient, AdServiceSettings settings) + { + GrpcClient = grpcClient; + AdServiceSettings effectiveSettings = settings ?? AdServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAd = clientHelper.BuildApiCall( + GrpcClient.GetAdAsync, GrpcClient.GetAd, effectiveSettings.GetAdSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAds = clientHelper.BuildApiCall( + GrpcClient.MutateAdsAsync, GrpcClient.MutateAds, effectiveSettings.MutateAdsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAd); + Modify_GetAdApiCall(ref _callGetAd); + Modify_ApiCall(ref _callMutateAds); + Modify_MutateAdsApiCall(ref _callMutateAds); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAdApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAdsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AdService.AdServiceClient grpcClient, AdServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AdService client. + /// + public override AdService.AdServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAdRequest(ref GetAdRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAdsRequest(ref MutateAdsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAdAsync( + GetAdRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdRequest(ref request, ref callSettings); + return _callGetAd.Async(request, callSettings); + } + + /// + /// Returns the requested ad in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::Ad GetAd( + GetAdRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAdRequest(ref request, ref callSettings); + return _callGetAd.Sync(request, callSettings); + } + + /// + /// Updates ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAdsAsync( + MutateAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdsRequest(ref request, ref callSettings); + return _callMutateAds.Async(request, callSettings); + } + + /// + /// Updates ads. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAdsResponse MutateAds( + MutateAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAdsRequest(ref request, ref callSettings); + return _callMutateAds.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AdServiceGrpc.cs b/src/V3/Stubs/AdServiceGrpc.cs new file mode 100644 index 000000000..e8fabe25b --- /dev/null +++ b/src/V3/Stubs/AdServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/ad_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage ads. + /// + public static partial class AdService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AdService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAdRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAdRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_Ad = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.Ad.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAdsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAdsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAd = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAd", + __Marshaller_google_ads_googleads_v3_services_GetAdRequest, + __Marshaller_google_ads_googleads_v3_resources_Ad); + + static readonly grpc::Method __Method_MutateAds = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAds", + __Marshaller_google_ads_googleads_v3_services_MutateAdsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAdsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AdServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AdService + public abstract partial class AdServiceBase + { + /// + /// Returns the requested ad in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAd(global::Google.Ads.GoogleAds.V3.Services.GetAdRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Updates ads. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAds(global::Google.Ads.GoogleAds.V3.Services.MutateAdsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AdService + public partial class AdServiceClient : grpc::ClientBase + { + /// Creates a new client for AdService + /// The channel to use to make remote calls. + public AdServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AdService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AdServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AdServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AdServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested ad in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Ad GetAd(global::Google.Ads.GoogleAds.V3.Services.GetAdRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAd(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Ad GetAd(global::Google.Ads.GoogleAds.V3.Services.GetAdRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAd, null, options, request); + } + /// + /// Returns the requested ad in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAdAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested ad in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAdAsync(global::Google.Ads.GoogleAds.V3.Services.GetAdRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAd, null, options, request); + } + /// + /// Updates ads. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdsResponse MutateAds(global::Google.Ads.GoogleAds.V3.Services.MutateAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAds(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Updates ads. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAdsResponse MutateAds(global::Google.Ads.GoogleAds.V3.Services.MutateAdsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAds, null, options, request); + } + /// + /// Updates ads. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAdsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Updates ads. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAdsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAdsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAds, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AdServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AdServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AdServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAd, serviceImpl.GetAd) + .AddMethod(__Method_MutateAds, serviceImpl.MutateAds).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AdServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAd, serviceImpl.GetAd); + serviceBinder.AddMethod(__Method_MutateAds, serviceImpl.MutateAds); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AdServingOptimizationStatus.cs b/src/V3/Stubs/AdServingOptimizationStatus.cs new file mode 100644 index 000000000..9a32190e1 --- /dev/null +++ b/src/V3/Stubs/AdServingOptimizationStatus.cs @@ -0,0 +1,204 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_serving_optimization_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_serving_optimization_status.proto + public static partial class AdServingOptimizationStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_serving_optimization_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdServingOptimizationStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9zZXJ2aW5nX29w", + "dGltaXphdGlvbl9zdGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIrwBCh9B", + "ZFNlcnZpbmdPcHRpbWl6YXRpb25TdGF0dXNFbnVtIpgBChtBZFNlcnZpbmdP", + "cHRpbWl6YXRpb25TdGF0dXMSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dO", + "EAESDAoIT1BUSU1JWkUQAhIXChNDT05WRVJTSU9OX09QVElNSVpFEAMSCgoG", + "Uk9UQVRFEAQSFwoTUk9UQVRFX0lOREVGSU5JVEVMWRAFEg8KC1VOQVZBSUxB", + "QkxFEAZC9QEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0Ig", + "QWRTZXJ2aW5nT3B0aW1pemF0aW9uU3RhdHVzUHJvdG9QAVpCZ29vZ2xlLmdv", + "bGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMu", + "RW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2ds", + "ZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdServingOptimizationStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.AdServingOptimizationStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdServingOptimizationStatusEnum.Types.AdServingOptimizationStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Possible ad serving statuses of a campaign. + /// + public sealed partial class AdServingOptimizationStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdServingOptimizationStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdServingOptimizationStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdServingOptimizationStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdServingOptimizationStatusEnum(AdServingOptimizationStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdServingOptimizationStatusEnum Clone() { + return new AdServingOptimizationStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdServingOptimizationStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdServingOptimizationStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdServingOptimizationStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdServingOptimizationStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible serving statuses. + /// + public enum AdServingOptimizationStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Ad serving is optimized based on CTR for the campaign. + /// + [pbr::OriginalName("OPTIMIZE")] Optimize = 2, + /// + /// Ad serving is optimized based on CTR * Conversion for the campaign. If + /// the campaign is not in the conversion optimizer bidding strategy, it will + /// default to OPTIMIZED. + /// + [pbr::OriginalName("CONVERSION_OPTIMIZE")] ConversionOptimize = 3, + /// + /// Ads are rotated evenly for 90 days, then optimized for clicks. + /// + [pbr::OriginalName("ROTATE")] Rotate = 4, + /// + /// Show lower performing ads more evenly with higher performing ads, and do + /// not optimize. + /// + [pbr::OriginalName("ROTATE_INDEFINITELY")] RotateIndefinitely = 5, + /// + /// Ad serving optimization status is not available. + /// + [pbr::OriginalName("UNAVAILABLE")] Unavailable = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdSharingError.cs b/src/V3/Stubs/AdSharingError.cs new file mode 100644 index 000000000..ef6ef2beb --- /dev/null +++ b/src/V3/Stubs/AdSharingError.cs @@ -0,0 +1,191 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/ad_sharing_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/ad_sharing_error.proto + public static partial class AdSharingErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/ad_sharing_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdSharingErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfc2hhcmluZ19l", + "cnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIqkBChJBZFNoYXJpbmdFcnJv", + "ckVudW0ikgEKDkFkU2hhcmluZ0Vycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoH", + "VU5LTk9XThABEiAKHEFEX0dST1VQX0FMUkVBRFlfQ09OVEFJTlNfQUQQAhIi", + "Ch5JTkNPTVBBVElCTEVfQURfVU5ERVJfQURfR1JPVVAQAxIcChhDQU5OT1Rf", + "U0hBUkVfSU5BQ1RJVkVfQUQQBELuAQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVycm9yc0ITQWRTaGFyaW5nRXJyb3JQcm90b1ABWkRnb29nbGUu", + "Z29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMv", + "djMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oC", + "Ikdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdSharingErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdSharingErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdSharingErrorEnum.Types.AdSharingError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad sharing errors. + /// + public sealed partial class AdSharingErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdSharingErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdSharingErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdSharingErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdSharingErrorEnum(AdSharingErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdSharingErrorEnum Clone() { + return new AdSharingErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdSharingErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdSharingErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdSharingErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdSharingErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible ad sharing errors. + /// + public enum AdSharingError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Error resulting in attempting to add an Ad to an AdGroup that already + /// contains the Ad. + /// + [pbr::OriginalName("AD_GROUP_ALREADY_CONTAINS_AD")] AdGroupAlreadyContainsAd = 2, + /// + /// Ad is not compatible with the AdGroup it is being shared with. + /// + [pbr::OriginalName("INCOMPATIBLE_AD_UNDER_AD_GROUP")] IncompatibleAdUnderAdGroup = 3, + /// + /// Cannot add AdGroupAd on inactive Ad. + /// + [pbr::OriginalName("CANNOT_SHARE_INACTIVE_AD")] CannotShareInactiveAd = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdStrength.cs b/src/V3/Stubs/AdStrength.cs new file mode 100644 index 000000000..c50a46ae9 --- /dev/null +++ b/src/V3/Stubs/AdStrength.cs @@ -0,0 +1,201 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_strength.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_strength.proto + public static partial class AdStrengthReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_strength.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdStrengthReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF9zdHJlbmd0aC5w", + "cm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8ihQEKDkFkU3RyZW5ndGhFbnVtInMKCkFk", + "U3RyZW5ndGgSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESCwoHUEVO", + "RElORxACEgoKBk5PX0FEUxADEggKBFBPT1IQBBILCgdBVkVSQUdFEAUSCAoE", + "R09PRBAGEg0KCUVYQ0VMTEVOVBAHQuQBCiFjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXNCD0FkU3RyZW5ndGhQcm90b1ABWkJnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "ZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5F", + "bnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xl", + "OjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdStrengthEnum), global::Google.Ads.GoogleAds.V3.Enums.AdStrengthEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdStrengthEnum.Types.AdStrength) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible ad strengths. + /// + public sealed partial class AdStrengthEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdStrengthEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdStrengthReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdStrengthEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdStrengthEnum(AdStrengthEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdStrengthEnum Clone() { + return new AdStrengthEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdStrengthEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdStrengthEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdStrengthEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdStrengthEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum listing the possible ad strengths. + /// + public enum AdStrength { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The ad strength is currently pending. + /// + [pbr::OriginalName("PENDING")] Pending = 2, + /// + /// No ads could be generated. + /// + [pbr::OriginalName("NO_ADS")] NoAds = 3, + /// + /// Poor strength. + /// + [pbr::OriginalName("POOR")] Poor = 4, + /// + /// Average strength. + /// + [pbr::OriginalName("AVERAGE")] Average = 5, + /// + /// Good strength. + /// + [pbr::OriginalName("GOOD")] Good = 6, + /// + /// Excellent strength. + /// + [pbr::OriginalName("EXCELLENT")] Excellent = 7, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdType.cs b/src/V3/Stubs/AdType.cs new file mode 100644 index 000000000..f1f118538 --- /dev/null +++ b/src/V3/Stubs/AdType.cs @@ -0,0 +1,264 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/ad_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/ad_type.proto + public static partial class AdTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/ad_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Citnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZF90eXBlLnByb3Rv", + "Eh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29vZ2xlL2FwaS9h", + "bm5vdGF0aW9ucy5wcm90byLWAwoKQWRUeXBlRW51bSLHAwoGQWRUeXBlEg8K", + "C1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB1RFWFRfQUQQAhIUChBF", + "WFBBTkRFRF9URVhUX0FEEAMSEAoMQ0FMTF9PTkxZX0FEEAYSHgoaRVhQQU5E", + "RURfRFlOQU1JQ19TRUFSQ0hfQUQQBxIMCghIT1RFTF9BRBAIEhUKEVNIT1BQ", + "SU5HX1NNQVJUX0FEEAkSFwoTU0hPUFBJTkdfUFJPRFVDVF9BRBAKEgwKCFZJ", + "REVPX0FEEAwSDAoIR01BSUxfQUQQDRIMCghJTUFHRV9BRBAOEhgKFFJFU1BP", + "TlNJVkVfU0VBUkNIX0FEEA8SIAocTEVHQUNZX1JFU1BPTlNJVkVfRElTUExB", + "WV9BRBAQEgoKBkFQUF9BRBAREhkKFUxFR0FDWV9BUFBfSU5TVEFMTF9BRBAS", + "EhkKFVJFU1BPTlNJVkVfRElTUExBWV9BRBATEhMKD0hUTUw1X1VQTE9BRF9B", + "RBAVEhQKEERZTkFNSUNfSFRNTDVfQUQQFhIVChFBUFBfRU5HQUdFTUVOVF9B", + "RBAXEiIKHlNIT1BQSU5HX0NPTVBBUklTT05fTElTVElOR19BRBAYQuABCiFj", + "b20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCC0FkVHlwZVByb3Rv", + "UAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "RW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AdTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdTypeEnum.Types.AdType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible types of an ad. + /// + public sealed partial class AdTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdTypeEnum(AdTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdTypeEnum Clone() { + return new AdTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible types of an ad. + /// + public enum AdType { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The ad is a text ad. + /// + [pbr::OriginalName("TEXT_AD")] TextAd = 2, + /// + /// The ad is an expanded text ad. + /// + [pbr::OriginalName("EXPANDED_TEXT_AD")] ExpandedTextAd = 3, + /// + /// The ad is a call only ad. + /// + [pbr::OriginalName("CALL_ONLY_AD")] CallOnlyAd = 6, + /// + /// The ad is an expanded dynamic search ad. + /// + [pbr::OriginalName("EXPANDED_DYNAMIC_SEARCH_AD")] ExpandedDynamicSearchAd = 7, + /// + /// The ad is a hotel ad. + /// + [pbr::OriginalName("HOTEL_AD")] HotelAd = 8, + /// + /// The ad is a Smart Shopping ad. + /// + [pbr::OriginalName("SHOPPING_SMART_AD")] ShoppingSmartAd = 9, + /// + /// The ad is a standard Shopping ad. + /// + [pbr::OriginalName("SHOPPING_PRODUCT_AD")] ShoppingProductAd = 10, + /// + /// The ad is a video ad. + /// + [pbr::OriginalName("VIDEO_AD")] VideoAd = 12, + /// + /// This ad is a Gmail ad. + /// + [pbr::OriginalName("GMAIL_AD")] GmailAd = 13, + /// + /// This ad is an Image ad. + /// + [pbr::OriginalName("IMAGE_AD")] ImageAd = 14, + /// + /// The ad is a responsive search ad. + /// + [pbr::OriginalName("RESPONSIVE_SEARCH_AD")] ResponsiveSearchAd = 15, + /// + /// The ad is a legacy responsive display ad. + /// + [pbr::OriginalName("LEGACY_RESPONSIVE_DISPLAY_AD")] LegacyResponsiveDisplayAd = 16, + /// + /// The ad is an app ad. + /// + [pbr::OriginalName("APP_AD")] AppAd = 17, + /// + /// The ad is a legacy app install ad. + /// + [pbr::OriginalName("LEGACY_APP_INSTALL_AD")] LegacyAppInstallAd = 18, + /// + /// The ad is a responsive display ad. + /// + [pbr::OriginalName("RESPONSIVE_DISPLAY_AD")] ResponsiveDisplayAd = 19, + /// + /// The ad is a display upload ad with the HTML5_UPLOAD_AD product type. + /// + [pbr::OriginalName("HTML5_UPLOAD_AD")] Html5UploadAd = 21, + /// + /// The ad is a display upload ad with one of the DYNAMIC_HTML5_* product + /// types. + /// + [pbr::OriginalName("DYNAMIC_HTML5_AD")] DynamicHtml5Ad = 22, + /// + /// The ad is an app engagement ad. + /// + [pbr::OriginalName("APP_ENGAGEMENT_AD")] AppEngagementAd = 23, + /// + /// The ad is a Shopping Comparison Listing ad. + /// + [pbr::OriginalName("SHOPPING_COMPARISON_LISTING_AD")] ShoppingComparisonListingAd = 24, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdTypeInfos.cs b/src/V3/Stubs/AdTypeInfos.cs new file mode 100644 index 000000000..c15193a47 --- /dev/null +++ b/src/V3/Stubs/AdTypeInfos.cs @@ -0,0 +1,7495 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/ad_type_infos.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/ad_type_infos.proto + public static partial class AdTypeInfosReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/ad_type_infos.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdTypeInfosReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vYWRfdHlwZV9pbmZv", + "cy5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uGi1nb29n", + "bGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vYWRfYXNzZXQucHJvdG8aQ2dv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2NhbGxfY29udmVyc2lvbl9y", + "ZXBvcnRpbmdfc3RhdGUucHJvdG8aPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL2Rpc3BsYXlfYWRfZm9ybWF0X3NldHRpbmcucHJvdG8aP2dvb2ds", + "ZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2Rpc3BsYXlfdXBsb2FkX3Byb2R1", + "Y3RfdHlwZS5wcm90bxpDZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMv", + "bGVnYWN5X2FwcF9pbnN0YWxsX2FkX2FwcF9zdG9yZS5wcm90bxotZ29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvbWltZV90eXBlLnByb3RvGh5nb29n", + "bGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3Rh", + "dGlvbnMucHJvdG8ipAEKClRleHRBZEluZm8SLgoIaGVhZGxpbmUYASABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMgoMZGVzY3JpcHRpb24x", + "GAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjIKDGRlc2Ny", + "aXB0aW9uMhgDIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSL3", + "AgoSRXhwYW5kZWRUZXh0QWRJbmZvEjQKDmhlYWRsaW5lX3BhcnQxGAEgASgL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjQKDmhlYWRsaW5lX3Bh", + "cnQyGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjQKDmhl", + "YWRsaW5lX3BhcnQzGAYgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1Zh", + "bHVlEjEKC2Rlc2NyaXB0aW9uGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlEjIKDGRlc2NyaXB0aW9uMhgHIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZRIrCgVwYXRoMRgEIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZRIrCgVwYXRoMhgFIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZSLnBQoOQ2FsbE9ubHlBZEluZm8SMgoMY291bnRy", + "eV9jb2RlGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjIK", + "DHBob25lX251bWJlchgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZRIzCg1idXNpbmVzc19uYW1lGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlEi8KCWhlYWRsaW5lMRgLIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZRIvCgloZWFkbGluZTIYDCABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWUSMgoMZGVzY3JpcHRpb24xGAQgASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjIKDGRlc2NyaXB0aW9uMhgF", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIwCgxjYWxsX3Ry", + "YWNrZWQYBiABKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlEjsKF2Rp", + "c2FibGVfY2FsbF9jb252ZXJzaW9uGAcgASgLMhouZ29vZ2xlLnByb3RvYnVm", + "LkJvb2xWYWx1ZRJDCh1waG9uZV9udW1iZXJfdmVyaWZpY2F0aW9uX3VybBgI", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI3ChFjb252ZXJz", + "aW9uX2FjdGlvbhgJIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZRKAAQoaY29udmVyc2lvbl9yZXBvcnRpbmdfc3RhdGUYCiABKA4yXC5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5DYWxsQ29udmVyc2lvblJlcG9y", + "dGluZ1N0YXRlRW51bS5DYWxsQ29udmVyc2lvblJlcG9ydGluZ1N0YXRlIoQB", + "ChtFeHBhbmRlZER5bmFtaWNTZWFyY2hBZEluZm8SMQoLZGVzY3JpcHRpb24Y", + "ASABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMgoMZGVzY3Jp", + "cHRpb24yGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlIg0K", + "C0hvdGVsQWRJbmZvIhUKE1Nob3BwaW5nU21hcnRBZEluZm8iFwoVU2hvcHBp", + "bmdQcm9kdWN0QWRJbmZvIlEKH1Nob3BwaW5nQ29tcGFyaXNvbkxpc3RpbmdB", + "ZEluZm8SLgoIaGVhZGxpbmUYASABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWUiqQQKC0dtYWlsQWRJbmZvEjsKBnRlYXNlchgBIAEoCzIrLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5HbWFpbFRlYXNlchIyCgxo", + "ZWFkZXJfaW1hZ2UYAiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFs", + "dWUSNQoPbWFya2V0aW5nX2ltYWdlGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlEj4KGG1hcmtldGluZ19pbWFnZV9oZWFkbGluZRgEIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJBChttYXJrZXRpbmdf", + "aW1hZ2VfZGVzY3JpcHRpb24YBSABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWUSYwombWFya2V0aW5nX2ltYWdlX2Rpc3BsYXlfY2FsbF90b19h", + "Y3Rpb24YBiABKAsyMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24u", + "RGlzcGxheUNhbGxUb0FjdGlvbhJECg5wcm9kdWN0X2ltYWdlcxgHIAMoCzIs", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Qcm9kdWN0SW1hZ2US", + "RAoOcHJvZHVjdF92aWRlb3MYCCADKAsyLC5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5jb21tb24uUHJvZHVjdFZpZGVvItcBCgtHbWFpbFRlYXNlchIuCgho", + "ZWFkbGluZRgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIx", + "CgtkZXNjcmlwdGlvbhgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZRIzCg1idXNpbmVzc19uYW1lGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlEjAKCmxvZ29faW1hZ2UYBCABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWUirAEKE0Rpc3BsYXlDYWxsVG9BY3Rpb24SKgoE", + "dGV4dBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIwCgp0", + "ZXh0X2NvbG9yGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVl", + "EjcKEXVybF9jb2xsZWN0aW9uX2lkGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlIssBCgxQcm9kdWN0SW1hZ2USMwoNcHJvZHVjdF9pbWFn", + "ZRgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIxCgtkZXNj", + "cmlwdGlvbhgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJT", + "ChZkaXNwbGF5X2NhbGxfdG9fYWN0aW9uGAMgASgLMjMuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuY29tbW9uLkRpc3BsYXlDYWxsVG9BY3Rpb24iQwoMUHJv", + "ZHVjdFZpZGVvEjMKDXByb2R1Y3RfdmlkZW8YASABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWUi8QQKC0ltYWdlQWRJbmZvEjAKC3BpeGVsX3dp", + "ZHRoGAQgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUSMQoMcGl4", + "ZWxfaGVpZ2h0GAUgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUS", + "LwoJaW1hZ2VfdXJsGAYgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1Zh", + "bHVlEjgKE3ByZXZpZXdfcGl4ZWxfd2lkdGgYByABKAsyGy5nb29nbGUucHJv", + "dG9idWYuSW50NjRWYWx1ZRI5ChRwcmV2aWV3X3BpeGVsX2hlaWdodBgIIAEo", + "CzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlEjcKEXByZXZpZXdfaW1h", + "Z2VfdXJsGAkgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEkcK", + "CW1pbWVfdHlwZRgKIAEoDjI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zLk1pbWVUeXBlRW51bS5NaW1lVHlwZRIqCgRuYW1lGAsgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjIKCm1lZGlhX2ZpbGUYASABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVIABIrCgRkYXRhGAIgASgL", + "MhsuZ29vZ2xlLnByb3RvYnVmLkJ5dGVzVmFsdWVIABI/ChhhZF9pZF90b19j", + "b3B5X2ltYWdlX2Zyb20YAyABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRW", + "YWx1ZUgAQgcKBWltYWdlIlMKGVZpZGVvQnVtcGVySW5TdHJlYW1BZEluZm8S", + "NgoQY29tcGFuaW9uX2Jhbm5lchgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZSJZCh9WaWRlb05vblNraXBwYWJsZUluU3RyZWFtQWRJbmZv", + "EjYKEGNvbXBhbmlvbl9iYW5uZXIYASABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWUixwEKG1ZpZGVvVHJ1ZVZpZXdJblN0cmVhbUFkSW5mbxI5", + "ChNhY3Rpb25fYnV0dG9uX2xhYmVsGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlEjUKD2FjdGlvbl9oZWFkbGluZRgCIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI2ChBjb21wYW5pb25fYmFubmVyGAMg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlInkKFFZpZGVvT3V0", + "c3RyZWFtQWRJbmZvEi4KCGhlYWRsaW5lGAEgASgLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlEjEKC2Rlc2NyaXB0aW9uGAIgASgLMhwuZ29vZ2xl", + "LnByb3RvYnVmLlN0cmluZ1ZhbHVlIrYBChxWaWRlb1RydWVWaWV3RGlzY292", + "ZXJ5QWRJbmZvEi4KCGhlYWRsaW5lGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlEjIKDGRlc2NyaXB0aW9uMRgCIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZRIyCgxkZXNjcmlwdGlvbjIYAyABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUi4QMKC1ZpZGVvQWRJbmZvEjAK", + "Cm1lZGlhX2ZpbGUYASABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFs", + "dWUSUAoJaW5fc3RyZWFtGAIgASgLMjsuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuY29tbW9uLlZpZGVvVHJ1ZVZpZXdJblN0cmVhbUFkSW5mb0gAEksKBmJ1", + "bXBlchgDIAEoCzI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5W", + "aWRlb0J1bXBlckluU3RyZWFtQWRJbmZvSAASSgoKb3V0X3N0cmVhbRgEIAEo", + "CzI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5WaWRlb091dHN0", + "cmVhbUFkSW5mb0gAElgKDW5vbl9za2lwcGFibGUYBSABKAsyPy5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5jb21tb24uVmlkZW9Ob25Ta2lwcGFibGVJblN0", + "cmVhbUFkSW5mb0gAElEKCWRpc2NvdmVyeRgGIAEoCzI8Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmNvbW1vbi5WaWRlb1RydWVWaWV3RGlzY292ZXJ5QWRJ", + "bmZvSABCCAoGZm9ybWF0IvUBChZSZXNwb25zaXZlU2VhcmNoQWRJbmZvEj4K", + "CWhlYWRsaW5lcxgBIAMoCzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNv", + "bW1vbi5BZFRleHRBc3NldBJBCgxkZXNjcmlwdGlvbnMYAiADKAsyKy5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQWRUZXh0QXNzZXQSKwoFcGF0", + "aDEYAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSKwoFcGF0", + "aDIYBCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUi/QYKHUxl", + "Z2FjeVJlc3BvbnNpdmVEaXNwbGF5QWRJbmZvEjQKDnNob3J0X2hlYWRsaW5l", + "GAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjMKDWxvbmdf", + "aGVhZGxpbmUYAiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUS", + "MQoLZGVzY3JpcHRpb24YAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5n", + "VmFsdWUSMwoNYnVzaW5lc3NfbmFtZRgEIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZRI4ChRhbGxvd19mbGV4aWJsZV9jb2xvchgFIAEoCzIa", + "Lmdvb2dsZS5wcm90b2J1Zi5Cb29sVmFsdWUSMgoMYWNjZW50X2NvbG9yGAYg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjAKCm1haW5fY29s", + "b3IYByABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSOQoTY2Fs", + "bF90b19hY3Rpb25fdGV4dBgIIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZRIwCgpsb2dvX2ltYWdlGAkgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlEjcKEXNxdWFyZV9sb2dvX2ltYWdlGAogASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjUKD21hcmtldGluZ19pbWFnZRgL", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI8ChZzcXVhcmVf", + "bWFya2V0aW5nX2ltYWdlGAwgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlEmgKDmZvcm1hdF9zZXR0aW5nGA0gASgOMlAuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuZW51bXMuRGlzcGxheUFkRm9ybWF0U2V0dGluZ0VudW0u", + "RGlzcGxheUFkRm9ybWF0U2V0dGluZxIyCgxwcmljZV9wcmVmaXgYDiABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMAoKcHJvbW9fdGV4dBgP", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSKrAwoJQXBwQWRJ", + "bmZvEkYKEW1hbmRhdG9yeV9hZF90ZXh0GAEgASgLMisuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuY29tbW9uLkFkVGV4dEFzc2V0Ej4KCWhlYWRsaW5lcxgC", + "IAMoCzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZFRleHRB", + "c3NldBJBCgxkZXNjcmlwdGlvbnMYAyADKAsyKy5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5jb21tb24uQWRUZXh0QXNzZXQSPAoGaW1hZ2VzGAQgAygLMiwu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkFkSW1hZ2VBc3NldBJE", + "Cg55b3V0dWJlX3ZpZGVvcxgFIAMoCzIsLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmNvbW1vbi5BZFZpZGVvQXNzZXQSTwoTaHRtbDVfbWVkaWFfYnVuZGxl", + "cxgGIAMoCzIyLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZE1l", + "ZGlhQnVuZGxlQXNzZXQilAIKE0FwcEVuZ2FnZW1lbnRBZEluZm8SPgoJaGVh", + "ZGxpbmVzGAEgAygLMisuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9u", + "LkFkVGV4dEFzc2V0EkEKDGRlc2NyaXB0aW9ucxgCIAMoCzIrLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZFRleHRBc3NldBI8CgZpbWFnZXMY", + "AyADKAsyLC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQWRJbWFn", + "ZUFzc2V0EjwKBnZpZGVvcxgEIAMoCzIsLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmNvbW1vbi5BZFZpZGVvQXNzZXQiywIKFkxlZ2FjeUFwcEluc3RhbGxB", + "ZEluZm8SLAoGYXBwX2lkGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlEmsKCWFwcF9zdG9yZRgCIAEoDjJYLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zLkxlZ2FjeUFwcEluc3RhbGxBZEFwcFN0b3JlRW51bS5M", + "ZWdhY3lBcHBJbnN0YWxsQWRBcHBTdG9yZRIuCghoZWFkbGluZRgDIAEoCzIc", + "Lmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIyCgxkZXNjcmlwdGlvbjEY", + "BCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMgoMZGVzY3Jp", + "cHRpb24yGAUgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlIqoI", + "ChdSZXNwb25zaXZlRGlzcGxheUFkSW5mbxJGChBtYXJrZXRpbmdfaW1hZ2Vz", + "GAEgAygLMiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkFkSW1h", + "Z2VBc3NldBJNChdzcXVhcmVfbWFya2V0aW5nX2ltYWdlcxgCIAMoCzIsLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZEltYWdlQXNzZXQSQQoL", + "bG9nb19pbWFnZXMYAyADKAsyLC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5j", + "b21tb24uQWRJbWFnZUFzc2V0EkgKEnNxdWFyZV9sb2dvX2ltYWdlcxgEIAMo", + "CzIsLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZEltYWdlQXNz", + "ZXQSPgoJaGVhZGxpbmVzGAUgAygLMisuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuY29tbW9uLkFkVGV4dEFzc2V0EkIKDWxvbmdfaGVhZGxpbmUYBiABKAsy", + "Ky5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQWRUZXh0QXNzZXQS", + "QQoMZGVzY3JpcHRpb25zGAcgAygLMisuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuY29tbW9uLkFkVGV4dEFzc2V0EkQKDnlvdXR1YmVfdmlkZW9zGAggAygL", + "MiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkFkVmlkZW9Bc3Nl", + "dBIzCg1idXNpbmVzc19uYW1lGAkgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlEjAKCm1haW5fY29sb3IYCiABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWUSMgoMYWNjZW50X2NvbG9yGAsgASgLMhwuZ29vZ2xl", + "LnByb3RvYnVmLlN0cmluZ1ZhbHVlEjgKFGFsbG93X2ZsZXhpYmxlX2NvbG9y", + "GAwgASgLMhouZ29vZ2xlLnByb3RvYnVmLkJvb2xWYWx1ZRI5ChNjYWxsX3Rv", + "X2FjdGlvbl90ZXh0GA0gASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1Zh", + "bHVlEjIKDHByaWNlX3ByZWZpeBgOIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZRIwCgpwcm9tb190ZXh0GA8gASgLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlEmgKDmZvcm1hdF9zZXR0aW5nGBAgASgOMlAuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuRGlzcGxheUFkRm9ybWF0U2V0", + "dGluZ0VudW0uRGlzcGxheUFkRm9ybWF0U2V0dGluZyLrAQoTRGlzcGxheVVw", + "bG9hZEFkSW5mbxJ5ChtkaXNwbGF5X3VwbG9hZF9wcm9kdWN0X3R5cGUYASAB", + "KA4yVC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5EaXNwbGF5VXBs", + "b2FkUHJvZHVjdFR5cGVFbnVtLkRpc3BsYXlVcGxvYWRQcm9kdWN0VHlwZRJK", + "CgxtZWRpYV9idW5kbGUYAiABKAsyMi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5jb21tb24uQWRNZWRpYUJ1bmRsZUFzc2V0SABCDQoLbWVkaWFfYXNzZXRC", + "6wEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb25CEEFkVHlw", + "ZUluZm9zUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbjtjb21tb26iAgNHQUGq", + "Ah5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5Db21tb27KAh5Hb29nbGVcQWRz", + "XEdvb2dsZUFkc1xWM1xDb21tb27qAiJHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6Q29tbW9uYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.AdAssetReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.DisplayUploadProductTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.LegacyAppInstallAdAppStoreReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.MimeTypeReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TextAdInfo), global::Google.Ads.GoogleAds.V3.Common.TextAdInfo.Parser, new[]{ "Headline", "Description1", "Description2" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ExpandedTextAdInfo), global::Google.Ads.GoogleAds.V3.Common.ExpandedTextAdInfo.Parser, new[]{ "HeadlinePart1", "HeadlinePart2", "HeadlinePart3", "Description", "Description2", "Path1", "Path2" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CallOnlyAdInfo), global::Google.Ads.GoogleAds.V3.Common.CallOnlyAdInfo.Parser, new[]{ "CountryCode", "PhoneNumber", "BusinessName", "Headline1", "Headline2", "Description1", "Description2", "CallTracked", "DisableCallConversion", "PhoneNumberVerificationUrl", "ConversionAction", "ConversionReportingState" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ExpandedDynamicSearchAdInfo), global::Google.Ads.GoogleAds.V3.Common.ExpandedDynamicSearchAdInfo.Parser, new[]{ "Description", "Description2" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelAdInfo), global::Google.Ads.GoogleAds.V3.Common.HotelAdInfo.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ShoppingSmartAdInfo), global::Google.Ads.GoogleAds.V3.Common.ShoppingSmartAdInfo.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ShoppingProductAdInfo), global::Google.Ads.GoogleAds.V3.Common.ShoppingProductAdInfo.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ShoppingComparisonListingAdInfo), global::Google.Ads.GoogleAds.V3.Common.ShoppingComparisonListingAdInfo.Parser, new[]{ "Headline" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.GmailAdInfo), global::Google.Ads.GoogleAds.V3.Common.GmailAdInfo.Parser, new[]{ "Teaser", "HeaderImage", "MarketingImage", "MarketingImageHeadline", "MarketingImageDescription", "MarketingImageDisplayCallToAction", "ProductImages", "ProductVideos" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.GmailTeaser), global::Google.Ads.GoogleAds.V3.Common.GmailTeaser.Parser, new[]{ "Headline", "Description", "BusinessName", "LogoImage" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction), global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction.Parser, new[]{ "Text", "TextColor", "UrlCollectionId" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductImage), global::Google.Ads.GoogleAds.V3.Common.ProductImage.Parser, new[]{ "ProductImage_", "Description", "DisplayCallToAction" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductVideo), global::Google.Ads.GoogleAds.V3.Common.ProductVideo.Parser, new[]{ "ProductVideo_" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ImageAdInfo), global::Google.Ads.GoogleAds.V3.Common.ImageAdInfo.Parser, new[]{ "PixelWidth", "PixelHeight", "ImageUrl", "PreviewPixelWidth", "PreviewPixelHeight", "PreviewImageUrl", "MimeType", "Name", "MediaFile", "Data", "AdIdToCopyImageFrom" }, new[]{ "Image" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.VideoBumperInStreamAdInfo), global::Google.Ads.GoogleAds.V3.Common.VideoBumperInStreamAdInfo.Parser, new[]{ "CompanionBanner" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.VideoNonSkippableInStreamAdInfo), global::Google.Ads.GoogleAds.V3.Common.VideoNonSkippableInStreamAdInfo.Parser, new[]{ "CompanionBanner" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewInStreamAdInfo), global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewInStreamAdInfo.Parser, new[]{ "ActionButtonLabel", "ActionHeadline", "CompanionBanner" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.VideoOutstreamAdInfo), global::Google.Ads.GoogleAds.V3.Common.VideoOutstreamAdInfo.Parser, new[]{ "Headline", "Description" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewDiscoveryAdInfo), global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewDiscoveryAdInfo.Parser, new[]{ "Headline", "Description1", "Description2" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.VideoAdInfo), global::Google.Ads.GoogleAds.V3.Common.VideoAdInfo.Parser, new[]{ "MediaFile", "InStream", "Bumper", "OutStream", "NonSkippable", "Discovery" }, new[]{ "Format" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ResponsiveSearchAdInfo), global::Google.Ads.GoogleAds.V3.Common.ResponsiveSearchAdInfo.Parser, new[]{ "Headlines", "Descriptions", "Path1", "Path2" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.LegacyResponsiveDisplayAdInfo), global::Google.Ads.GoogleAds.V3.Common.LegacyResponsiveDisplayAdInfo.Parser, new[]{ "ShortHeadline", "LongHeadline", "Description", "BusinessName", "AllowFlexibleColor", "AccentColor", "MainColor", "CallToActionText", "LogoImage", "SquareLogoImage", "MarketingImage", "SquareMarketingImage", "FormatSetting", "PricePrefix", "PromoText" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AppAdInfo), global::Google.Ads.GoogleAds.V3.Common.AppAdInfo.Parser, new[]{ "MandatoryAdText", "Headlines", "Descriptions", "Images", "YoutubeVideos", "Html5MediaBundles" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AppEngagementAdInfo), global::Google.Ads.GoogleAds.V3.Common.AppEngagementAdInfo.Parser, new[]{ "Headlines", "Descriptions", "Images", "Videos" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.LegacyAppInstallAdInfo), global::Google.Ads.GoogleAds.V3.Common.LegacyAppInstallAdInfo.Parser, new[]{ "AppId", "AppStore", "Headline", "Description1", "Description2" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ResponsiveDisplayAdInfo), global::Google.Ads.GoogleAds.V3.Common.ResponsiveDisplayAdInfo.Parser, new[]{ "MarketingImages", "SquareMarketingImages", "LogoImages", "SquareLogoImages", "Headlines", "LongHeadline", "Descriptions", "YoutubeVideos", "BusinessName", "MainColor", "AccentColor", "AllowFlexibleColor", "CallToActionText", "PricePrefix", "PromoText", "FormatSetting" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.DisplayUploadAdInfo), global::Google.Ads.GoogleAds.V3.Common.DisplayUploadAdInfo.Parser, new[]{ "DisplayUploadProductType", "MediaBundle" }, new[]{ "MediaAsset" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A text ad. + /// + public sealed partial class TextAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TextAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextAdInfo(TextAdInfo other) : this() { + Headline = other.Headline; + Description1 = other.Description1; + Description2 = other.Description2; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextAdInfo Clone() { + return new TextAdInfo(this); + } + + /// Field number for the "headline" field. + public const int HeadlineFieldNumber = 1; + private static readonly pb::FieldCodec _single_headline_codec = pb::FieldCodec.ForClassWrapper(10); + private string headline_; + /// + /// The headline of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline { + get { return headline_; } + set { + headline_ = value; + } + } + + + /// Field number for the "description1" field. + public const int Description1FieldNumber = 2; + private static readonly pb::FieldCodec _single_description1_codec = pb::FieldCodec.ForClassWrapper(18); + private string description1_; + /// + /// The first line of the ad's description. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description1 { + get { return description1_; } + set { + description1_ = value; + } + } + + + /// Field number for the "description2" field. + public const int Description2FieldNumber = 3; + private static readonly pb::FieldCodec _single_description2_codec = pb::FieldCodec.ForClassWrapper(26); + private string description2_; + /// + /// The second line of the ad's description. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description2 { + get { return description2_; } + set { + description2_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TextAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TextAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Headline != other.Headline) return false; + if (Description1 != other.Description1) return false; + if (Description2 != other.Description2) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (headline_ != null) hash ^= Headline.GetHashCode(); + if (description1_ != null) hash ^= Description1.GetHashCode(); + if (description2_ != null) hash ^= Description2.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (headline_ != null) { + _single_headline_codec.WriteTagAndValue(output, Headline); + } + if (description1_ != null) { + _single_description1_codec.WriteTagAndValue(output, Description1); + } + if (description2_ != null) { + _single_description2_codec.WriteTagAndValue(output, Description2); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (headline_ != null) { + size += _single_headline_codec.CalculateSizeWithTag(Headline); + } + if (description1_ != null) { + size += _single_description1_codec.CalculateSizeWithTag(Description1); + } + if (description2_ != null) { + size += _single_description2_codec.CalculateSizeWithTag(Description2); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TextAdInfo other) { + if (other == null) { + return; + } + if (other.headline_ != null) { + if (headline_ == null || other.Headline != "") { + Headline = other.Headline; + } + } + if (other.description1_ != null) { + if (description1_ == null || other.Description1 != "") { + Description1 = other.Description1; + } + } + if (other.description2_ != null) { + if (description2_ == null || other.Description2 != "") { + Description2 = other.Description2; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_headline_codec.Read(input); + if (headline_ == null || value != "") { + Headline = value; + } + break; + } + case 18: { + string value = _single_description1_codec.Read(input); + if (description1_ == null || value != "") { + Description1 = value; + } + break; + } + case 26: { + string value = _single_description2_codec.Read(input); + if (description2_ == null || value != "") { + Description2 = value; + } + break; + } + } + } + } + + } + + /// + /// An expanded text ad. + /// + public sealed partial class ExpandedTextAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExpandedTextAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedTextAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedTextAdInfo(ExpandedTextAdInfo other) : this() { + HeadlinePart1 = other.HeadlinePart1; + HeadlinePart2 = other.HeadlinePart2; + HeadlinePart3 = other.HeadlinePart3; + Description = other.Description; + Description2 = other.Description2; + Path1 = other.Path1; + Path2 = other.Path2; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedTextAdInfo Clone() { + return new ExpandedTextAdInfo(this); + } + + /// Field number for the "headline_part1" field. + public const int HeadlinePart1FieldNumber = 1; + private static readonly pb::FieldCodec _single_headlinePart1_codec = pb::FieldCodec.ForClassWrapper(10); + private string headlinePart1_; + /// + /// The first part of the ad's headline. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string HeadlinePart1 { + get { return headlinePart1_; } + set { + headlinePart1_ = value; + } + } + + + /// Field number for the "headline_part2" field. + public const int HeadlinePart2FieldNumber = 2; + private static readonly pb::FieldCodec _single_headlinePart2_codec = pb::FieldCodec.ForClassWrapper(18); + private string headlinePart2_; + /// + /// The second part of the ad's headline. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string HeadlinePart2 { + get { return headlinePart2_; } + set { + headlinePart2_ = value; + } + } + + + /// Field number for the "headline_part3" field. + public const int HeadlinePart3FieldNumber = 6; + private static readonly pb::FieldCodec _single_headlinePart3_codec = pb::FieldCodec.ForClassWrapper(50); + private string headlinePart3_; + /// + /// The third part of the ad's headline. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string HeadlinePart3 { + get { return headlinePart3_; } + set { + headlinePart3_ = value; + } + } + + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 3; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(26); + private string description_; + /// + /// The description of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "description2" field. + public const int Description2FieldNumber = 7; + private static readonly pb::FieldCodec _single_description2_codec = pb::FieldCodec.ForClassWrapper(58); + private string description2_; + /// + /// The second description of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description2 { + get { return description2_; } + set { + description2_ = value; + } + } + + + /// Field number for the "path1" field. + public const int Path1FieldNumber = 4; + private static readonly pb::FieldCodec _single_path1_codec = pb::FieldCodec.ForClassWrapper(34); + private string path1_; + /// + /// The text that can appear alongside the ad's displayed URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Path1 { + get { return path1_; } + set { + path1_ = value; + } + } + + + /// Field number for the "path2" field. + public const int Path2FieldNumber = 5; + private static readonly pb::FieldCodec _single_path2_codec = pb::FieldCodec.ForClassWrapper(42); + private string path2_; + /// + /// Additional text that can appear alongside the ad's displayed URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Path2 { + get { return path2_; } + set { + path2_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExpandedTextAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExpandedTextAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (HeadlinePart1 != other.HeadlinePart1) return false; + if (HeadlinePart2 != other.HeadlinePart2) return false; + if (HeadlinePart3 != other.HeadlinePart3) return false; + if (Description != other.Description) return false; + if (Description2 != other.Description2) return false; + if (Path1 != other.Path1) return false; + if (Path2 != other.Path2) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (headlinePart1_ != null) hash ^= HeadlinePart1.GetHashCode(); + if (headlinePart2_ != null) hash ^= HeadlinePart2.GetHashCode(); + if (headlinePart3_ != null) hash ^= HeadlinePart3.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + if (description2_ != null) hash ^= Description2.GetHashCode(); + if (path1_ != null) hash ^= Path1.GetHashCode(); + if (path2_ != null) hash ^= Path2.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (headlinePart1_ != null) { + _single_headlinePart1_codec.WriteTagAndValue(output, HeadlinePart1); + } + if (headlinePart2_ != null) { + _single_headlinePart2_codec.WriteTagAndValue(output, HeadlinePart2); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + if (path1_ != null) { + _single_path1_codec.WriteTagAndValue(output, Path1); + } + if (path2_ != null) { + _single_path2_codec.WriteTagAndValue(output, Path2); + } + if (headlinePart3_ != null) { + _single_headlinePart3_codec.WriteTagAndValue(output, HeadlinePart3); + } + if (description2_ != null) { + _single_description2_codec.WriteTagAndValue(output, Description2); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (headlinePart1_ != null) { + size += _single_headlinePart1_codec.CalculateSizeWithTag(HeadlinePart1); + } + if (headlinePart2_ != null) { + size += _single_headlinePart2_codec.CalculateSizeWithTag(HeadlinePart2); + } + if (headlinePart3_ != null) { + size += _single_headlinePart3_codec.CalculateSizeWithTag(HeadlinePart3); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + if (description2_ != null) { + size += _single_description2_codec.CalculateSizeWithTag(Description2); + } + if (path1_ != null) { + size += _single_path1_codec.CalculateSizeWithTag(Path1); + } + if (path2_ != null) { + size += _single_path2_codec.CalculateSizeWithTag(Path2); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExpandedTextAdInfo other) { + if (other == null) { + return; + } + if (other.headlinePart1_ != null) { + if (headlinePart1_ == null || other.HeadlinePart1 != "") { + HeadlinePart1 = other.HeadlinePart1; + } + } + if (other.headlinePart2_ != null) { + if (headlinePart2_ == null || other.HeadlinePart2 != "") { + HeadlinePart2 = other.HeadlinePart2; + } + } + if (other.headlinePart3_ != null) { + if (headlinePart3_ == null || other.HeadlinePart3 != "") { + HeadlinePart3 = other.HeadlinePart3; + } + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + if (other.description2_ != null) { + if (description2_ == null || other.Description2 != "") { + Description2 = other.Description2; + } + } + if (other.path1_ != null) { + if (path1_ == null || other.Path1 != "") { + Path1 = other.Path1; + } + } + if (other.path2_ != null) { + if (path2_ == null || other.Path2 != "") { + Path2 = other.Path2; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_headlinePart1_codec.Read(input); + if (headlinePart1_ == null || value != "") { + HeadlinePart1 = value; + } + break; + } + case 18: { + string value = _single_headlinePart2_codec.Read(input); + if (headlinePart2_ == null || value != "") { + HeadlinePart2 = value; + } + break; + } + case 26: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 34: { + string value = _single_path1_codec.Read(input); + if (path1_ == null || value != "") { + Path1 = value; + } + break; + } + case 42: { + string value = _single_path2_codec.Read(input); + if (path2_ == null || value != "") { + Path2 = value; + } + break; + } + case 50: { + string value = _single_headlinePart3_codec.Read(input); + if (headlinePart3_ == null || value != "") { + HeadlinePart3 = value; + } + break; + } + case 58: { + string value = _single_description2_codec.Read(input); + if (description2_ == null || value != "") { + Description2 = value; + } + break; + } + } + } + } + + } + + /// + /// A call-only ad. + /// + public sealed partial class CallOnlyAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CallOnlyAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallOnlyAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallOnlyAdInfo(CallOnlyAdInfo other) : this() { + CountryCode = other.CountryCode; + PhoneNumber = other.PhoneNumber; + BusinessName = other.BusinessName; + Headline1 = other.Headline1; + Headline2 = other.Headline2; + Description1 = other.Description1; + Description2 = other.Description2; + CallTracked = other.CallTracked; + DisableCallConversion = other.DisableCallConversion; + PhoneNumberVerificationUrl = other.PhoneNumberVerificationUrl; + ConversionAction = other.ConversionAction; + conversionReportingState_ = other.conversionReportingState_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallOnlyAdInfo Clone() { + return new CallOnlyAdInfo(this); + } + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 1; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(10); + private string countryCode_; + /// + /// The country code in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "phone_number" field. + public const int PhoneNumberFieldNumber = 2; + private static readonly pb::FieldCodec _single_phoneNumber_codec = pb::FieldCodec.ForClassWrapper(18); + private string phoneNumber_; + /// + /// The phone number in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PhoneNumber { + get { return phoneNumber_; } + set { + phoneNumber_ = value; + } + } + + + /// Field number for the "business_name" field. + public const int BusinessNameFieldNumber = 3; + private static readonly pb::FieldCodec _single_businessName_codec = pb::FieldCodec.ForClassWrapper(26); + private string businessName_; + /// + /// The business name in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessName { + get { return businessName_; } + set { + businessName_ = value; + } + } + + + /// Field number for the "headline1" field. + public const int Headline1FieldNumber = 11; + private static readonly pb::FieldCodec _single_headline1_codec = pb::FieldCodec.ForClassWrapper(90); + private string headline1_; + /// + /// First headline in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline1 { + get { return headline1_; } + set { + headline1_ = value; + } + } + + + /// Field number for the "headline2" field. + public const int Headline2FieldNumber = 12; + private static readonly pb::FieldCodec _single_headline2_codec = pb::FieldCodec.ForClassWrapper(98); + private string headline2_; + /// + /// Second headline in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline2 { + get { return headline2_; } + set { + headline2_ = value; + } + } + + + /// Field number for the "description1" field. + public const int Description1FieldNumber = 4; + private static readonly pb::FieldCodec _single_description1_codec = pb::FieldCodec.ForClassWrapper(34); + private string description1_; + /// + /// The first line of the ad's description. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description1 { + get { return description1_; } + set { + description1_ = value; + } + } + + + /// Field number for the "description2" field. + public const int Description2FieldNumber = 5; + private static readonly pb::FieldCodec _single_description2_codec = pb::FieldCodec.ForClassWrapper(42); + private string description2_; + /// + /// The second line of the ad's description. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description2 { + get { return description2_; } + set { + description2_ = value; + } + } + + + /// Field number for the "call_tracked" field. + public const int CallTrackedFieldNumber = 6; + private static readonly pb::FieldCodec _single_callTracked_codec = pb::FieldCodec.ForStructWrapper(50); + private bool? callTracked_; + /// + /// Whether to enable call tracking for the creative. Enabling call + /// tracking also enables call conversions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? CallTracked { + get { return callTracked_; } + set { + callTracked_ = value; + } + } + + + /// Field number for the "disable_call_conversion" field. + public const int DisableCallConversionFieldNumber = 7; + private static readonly pb::FieldCodec _single_disableCallConversion_codec = pb::FieldCodec.ForStructWrapper(58); + private bool? disableCallConversion_; + /// + /// Whether to disable call conversion for the creative. + /// If set to `true`, disables call conversions even when `call_tracked` is + /// `true`. + /// If `call_tracked` is `false`, this field is ignored. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? DisableCallConversion { + get { return disableCallConversion_; } + set { + disableCallConversion_ = value; + } + } + + + /// Field number for the "phone_number_verification_url" field. + public const int PhoneNumberVerificationUrlFieldNumber = 8; + private static readonly pb::FieldCodec _single_phoneNumberVerificationUrl_codec = pb::FieldCodec.ForClassWrapper(66); + private string phoneNumberVerificationUrl_; + /// + /// The URL to be used for phone number verification. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PhoneNumberVerificationUrl { + get { return phoneNumberVerificationUrl_; } + set { + phoneNumberVerificationUrl_ = value; + } + } + + + /// Field number for the "conversion_action" field. + public const int ConversionActionFieldNumber = 9; + private static readonly pb::FieldCodec _single_conversionAction_codec = pb::FieldCodec.ForClassWrapper(74); + private string conversionAction_; + /// + /// The conversion action to attribute a call conversion to. If not set a + /// default conversion action is used. This field only has effect if + /// call_tracked is set to true. Otherwise this field is ignored. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionAction { + get { return conversionAction_; } + set { + conversionAction_ = value; + } + } + + + /// Field number for the "conversion_reporting_state" field. + public const int ConversionReportingStateFieldNumber = 10; + private global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum.Types.CallConversionReportingState conversionReportingState_ = 0; + /// + /// The call conversion behavior of this call only ad. It can use its own call + /// conversion setting, inherit the account level setting, or be disabled. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum.Types.CallConversionReportingState ConversionReportingState { + get { return conversionReportingState_; } + set { + conversionReportingState_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CallOnlyAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CallOnlyAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CountryCode != other.CountryCode) return false; + if (PhoneNumber != other.PhoneNumber) return false; + if (BusinessName != other.BusinessName) return false; + if (Headline1 != other.Headline1) return false; + if (Headline2 != other.Headline2) return false; + if (Description1 != other.Description1) return false; + if (Description2 != other.Description2) return false; + if (CallTracked != other.CallTracked) return false; + if (DisableCallConversion != other.DisableCallConversion) return false; + if (PhoneNumberVerificationUrl != other.PhoneNumberVerificationUrl) return false; + if (ConversionAction != other.ConversionAction) return false; + if (ConversionReportingState != other.ConversionReportingState) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (phoneNumber_ != null) hash ^= PhoneNumber.GetHashCode(); + if (businessName_ != null) hash ^= BusinessName.GetHashCode(); + if (headline1_ != null) hash ^= Headline1.GetHashCode(); + if (headline2_ != null) hash ^= Headline2.GetHashCode(); + if (description1_ != null) hash ^= Description1.GetHashCode(); + if (description2_ != null) hash ^= Description2.GetHashCode(); + if (callTracked_ != null) hash ^= CallTracked.GetHashCode(); + if (disableCallConversion_ != null) hash ^= DisableCallConversion.GetHashCode(); + if (phoneNumberVerificationUrl_ != null) hash ^= PhoneNumberVerificationUrl.GetHashCode(); + if (conversionAction_ != null) hash ^= ConversionAction.GetHashCode(); + if (ConversionReportingState != 0) hash ^= ConversionReportingState.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (phoneNumber_ != null) { + _single_phoneNumber_codec.WriteTagAndValue(output, PhoneNumber); + } + if (businessName_ != null) { + _single_businessName_codec.WriteTagAndValue(output, BusinessName); + } + if (description1_ != null) { + _single_description1_codec.WriteTagAndValue(output, Description1); + } + if (description2_ != null) { + _single_description2_codec.WriteTagAndValue(output, Description2); + } + if (callTracked_ != null) { + _single_callTracked_codec.WriteTagAndValue(output, CallTracked); + } + if (disableCallConversion_ != null) { + _single_disableCallConversion_codec.WriteTagAndValue(output, DisableCallConversion); + } + if (phoneNumberVerificationUrl_ != null) { + _single_phoneNumberVerificationUrl_codec.WriteTagAndValue(output, PhoneNumberVerificationUrl); + } + if (conversionAction_ != null) { + _single_conversionAction_codec.WriteTagAndValue(output, ConversionAction); + } + if (ConversionReportingState != 0) { + output.WriteRawTag(80); + output.WriteEnum((int) ConversionReportingState); + } + if (headline1_ != null) { + _single_headline1_codec.WriteTagAndValue(output, Headline1); + } + if (headline2_ != null) { + _single_headline2_codec.WriteTagAndValue(output, Headline2); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (phoneNumber_ != null) { + size += _single_phoneNumber_codec.CalculateSizeWithTag(PhoneNumber); + } + if (businessName_ != null) { + size += _single_businessName_codec.CalculateSizeWithTag(BusinessName); + } + if (headline1_ != null) { + size += _single_headline1_codec.CalculateSizeWithTag(Headline1); + } + if (headline2_ != null) { + size += _single_headline2_codec.CalculateSizeWithTag(Headline2); + } + if (description1_ != null) { + size += _single_description1_codec.CalculateSizeWithTag(Description1); + } + if (description2_ != null) { + size += _single_description2_codec.CalculateSizeWithTag(Description2); + } + if (callTracked_ != null) { + size += _single_callTracked_codec.CalculateSizeWithTag(CallTracked); + } + if (disableCallConversion_ != null) { + size += _single_disableCallConversion_codec.CalculateSizeWithTag(DisableCallConversion); + } + if (phoneNumberVerificationUrl_ != null) { + size += _single_phoneNumberVerificationUrl_codec.CalculateSizeWithTag(PhoneNumberVerificationUrl); + } + if (conversionAction_ != null) { + size += _single_conversionAction_codec.CalculateSizeWithTag(ConversionAction); + } + if (ConversionReportingState != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ConversionReportingState); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CallOnlyAdInfo other) { + if (other == null) { + return; + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.phoneNumber_ != null) { + if (phoneNumber_ == null || other.PhoneNumber != "") { + PhoneNumber = other.PhoneNumber; + } + } + if (other.businessName_ != null) { + if (businessName_ == null || other.BusinessName != "") { + BusinessName = other.BusinessName; + } + } + if (other.headline1_ != null) { + if (headline1_ == null || other.Headline1 != "") { + Headline1 = other.Headline1; + } + } + if (other.headline2_ != null) { + if (headline2_ == null || other.Headline2 != "") { + Headline2 = other.Headline2; + } + } + if (other.description1_ != null) { + if (description1_ == null || other.Description1 != "") { + Description1 = other.Description1; + } + } + if (other.description2_ != null) { + if (description2_ == null || other.Description2 != "") { + Description2 = other.Description2; + } + } + if (other.callTracked_ != null) { + if (callTracked_ == null || other.CallTracked != false) { + CallTracked = other.CallTracked; + } + } + if (other.disableCallConversion_ != null) { + if (disableCallConversion_ == null || other.DisableCallConversion != false) { + DisableCallConversion = other.DisableCallConversion; + } + } + if (other.phoneNumberVerificationUrl_ != null) { + if (phoneNumberVerificationUrl_ == null || other.PhoneNumberVerificationUrl != "") { + PhoneNumberVerificationUrl = other.PhoneNumberVerificationUrl; + } + } + if (other.conversionAction_ != null) { + if (conversionAction_ == null || other.ConversionAction != "") { + ConversionAction = other.ConversionAction; + } + } + if (other.ConversionReportingState != 0) { + ConversionReportingState = other.ConversionReportingState; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 18: { + string value = _single_phoneNumber_codec.Read(input); + if (phoneNumber_ == null || value != "") { + PhoneNumber = value; + } + break; + } + case 26: { + string value = _single_businessName_codec.Read(input); + if (businessName_ == null || value != "") { + BusinessName = value; + } + break; + } + case 34: { + string value = _single_description1_codec.Read(input); + if (description1_ == null || value != "") { + Description1 = value; + } + break; + } + case 42: { + string value = _single_description2_codec.Read(input); + if (description2_ == null || value != "") { + Description2 = value; + } + break; + } + case 50: { + bool? value = _single_callTracked_codec.Read(input); + if (callTracked_ == null || value != false) { + CallTracked = value; + } + break; + } + case 58: { + bool? value = _single_disableCallConversion_codec.Read(input); + if (disableCallConversion_ == null || value != false) { + DisableCallConversion = value; + } + break; + } + case 66: { + string value = _single_phoneNumberVerificationUrl_codec.Read(input); + if (phoneNumberVerificationUrl_ == null || value != "") { + PhoneNumberVerificationUrl = value; + } + break; + } + case 74: { + string value = _single_conversionAction_codec.Read(input); + if (conversionAction_ == null || value != "") { + ConversionAction = value; + } + break; + } + case 80: { + ConversionReportingState = (global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum.Types.CallConversionReportingState) input.ReadEnum(); + break; + } + case 90: { + string value = _single_headline1_codec.Read(input); + if (headline1_ == null || value != "") { + Headline1 = value; + } + break; + } + case 98: { + string value = _single_headline2_codec.Read(input); + if (headline2_ == null || value != "") { + Headline2 = value; + } + break; + } + } + } + } + + } + + /// + /// An expanded dynamic search ad. + /// + public sealed partial class ExpandedDynamicSearchAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExpandedDynamicSearchAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedDynamicSearchAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedDynamicSearchAdInfo(ExpandedDynamicSearchAdInfo other) : this() { + Description = other.Description; + Description2 = other.Description2; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedDynamicSearchAdInfo Clone() { + return new ExpandedDynamicSearchAdInfo(this); + } + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 1; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(10); + private string description_; + /// + /// The description of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "description2" field. + public const int Description2FieldNumber = 2; + private static readonly pb::FieldCodec _single_description2_codec = pb::FieldCodec.ForClassWrapper(18); + private string description2_; + /// + /// The second description of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description2 { + get { return description2_; } + set { + description2_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExpandedDynamicSearchAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExpandedDynamicSearchAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Description != other.Description) return false; + if (Description2 != other.Description2) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (description_ != null) hash ^= Description.GetHashCode(); + if (description2_ != null) hash ^= Description2.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + if (description2_ != null) { + _single_description2_codec.WriteTagAndValue(output, Description2); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + if (description2_ != null) { + size += _single_description2_codec.CalculateSizeWithTag(Description2); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExpandedDynamicSearchAdInfo other) { + if (other == null) { + return; + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + if (other.description2_ != null) { + if (description2_ == null || other.Description2 != "") { + Description2 = other.Description2; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 18: { + string value = _single_description2_codec.Read(input); + if (description2_ == null || value != "") { + Description2 = value; + } + break; + } + } + } + } + + } + + /// + /// A hotel ad. + /// + public sealed partial class HotelAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelAdInfo(HotelAdInfo other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelAdInfo Clone() { + return new HotelAdInfo(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelAdInfo other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// A Smart Shopping ad. + /// + public sealed partial class ShoppingSmartAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ShoppingSmartAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingSmartAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingSmartAdInfo(ShoppingSmartAdInfo other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingSmartAdInfo Clone() { + return new ShoppingSmartAdInfo(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ShoppingSmartAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ShoppingSmartAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ShoppingSmartAdInfo other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// A standard Shopping ad. + /// + public sealed partial class ShoppingProductAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ShoppingProductAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingProductAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingProductAdInfo(ShoppingProductAdInfo other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingProductAdInfo Clone() { + return new ShoppingProductAdInfo(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ShoppingProductAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ShoppingProductAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ShoppingProductAdInfo other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// A Shopping Comparison Listing ad. + /// + public sealed partial class ShoppingComparisonListingAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ShoppingComparisonListingAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingComparisonListingAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingComparisonListingAdInfo(ShoppingComparisonListingAdInfo other) : this() { + Headline = other.Headline; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingComparisonListingAdInfo Clone() { + return new ShoppingComparisonListingAdInfo(this); + } + + /// Field number for the "headline" field. + public const int HeadlineFieldNumber = 1; + private static readonly pb::FieldCodec _single_headline_codec = pb::FieldCodec.ForClassWrapper(10); + private string headline_; + /// + /// Headline of the ad. This field is required. Allowed length is between 25 + /// and 45 characters. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline { + get { return headline_; } + set { + headline_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ShoppingComparisonListingAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ShoppingComparisonListingAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Headline != other.Headline) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (headline_ != null) hash ^= Headline.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (headline_ != null) { + _single_headline_codec.WriteTagAndValue(output, Headline); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (headline_ != null) { + size += _single_headline_codec.CalculateSizeWithTag(Headline); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ShoppingComparisonListingAdInfo other) { + if (other == null) { + return; + } + if (other.headline_ != null) { + if (headline_ == null || other.Headline != "") { + Headline = other.Headline; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_headline_codec.Read(input); + if (headline_ == null || value != "") { + Headline = value; + } + break; + } + } + } + } + + } + + /// + /// A Gmail ad. + /// + public sealed partial class GmailAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GmailAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GmailAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GmailAdInfo(GmailAdInfo other) : this() { + teaser_ = other.teaser_ != null ? other.teaser_.Clone() : null; + HeaderImage = other.HeaderImage; + MarketingImage = other.MarketingImage; + MarketingImageHeadline = other.MarketingImageHeadline; + MarketingImageDescription = other.MarketingImageDescription; + marketingImageDisplayCallToAction_ = other.marketingImageDisplayCallToAction_ != null ? other.marketingImageDisplayCallToAction_.Clone() : null; + productImages_ = other.productImages_.Clone(); + productVideos_ = other.productVideos_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GmailAdInfo Clone() { + return new GmailAdInfo(this); + } + + /// Field number for the "teaser" field. + public const int TeaserFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Common.GmailTeaser teaser_; + /// + /// The Gmail teaser. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.GmailTeaser Teaser { + get { return teaser_; } + set { + teaser_ = value; + } + } + + /// Field number for the "header_image" field. + public const int HeaderImageFieldNumber = 2; + private static readonly pb::FieldCodec _single_headerImage_codec = pb::FieldCodec.ForClassWrapper(18); + private string headerImage_; + /// + /// The MediaFile resource name of the header image. Valid image types are GIF, + /// JPEG and PNG. The minimum size is 300x100 pixels and the aspect ratio must + /// be between 3:1 and 5:1 (+-1%). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string HeaderImage { + get { return headerImage_; } + set { + headerImage_ = value; + } + } + + + /// Field number for the "marketing_image" field. + public const int MarketingImageFieldNumber = 3; + private static readonly pb::FieldCodec _single_marketingImage_codec = pb::FieldCodec.ForClassWrapper(26); + private string marketingImage_; + /// + /// The MediaFile resource name of the marketing image. Valid image types are + /// GIF, JPEG and PNG. The image must either be landscape with a minimum size + /// of 600x314 pixels and aspect ratio of 600:314 (+-1%) or square with a + /// minimum size of 300x300 pixels and aspect ratio of 1:1 (+-1%) + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MarketingImage { + get { return marketingImage_; } + set { + marketingImage_ = value; + } + } + + + /// Field number for the "marketing_image_headline" field. + public const int MarketingImageHeadlineFieldNumber = 4; + private static readonly pb::FieldCodec _single_marketingImageHeadline_codec = pb::FieldCodec.ForClassWrapper(34); + private string marketingImageHeadline_; + /// + /// Headline of the marketing image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MarketingImageHeadline { + get { return marketingImageHeadline_; } + set { + marketingImageHeadline_ = value; + } + } + + + /// Field number for the "marketing_image_description" field. + public const int MarketingImageDescriptionFieldNumber = 5; + private static readonly pb::FieldCodec _single_marketingImageDescription_codec = pb::FieldCodec.ForClassWrapper(42); + private string marketingImageDescription_; + /// + /// Description of the marketing image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MarketingImageDescription { + get { return marketingImageDescription_; } + set { + marketingImageDescription_ = value; + } + } + + + /// Field number for the "marketing_image_display_call_to_action" field. + public const int MarketingImageDisplayCallToActionFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction marketingImageDisplayCallToAction_; + /// + /// Display-call-to-action of the marketing image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction MarketingImageDisplayCallToAction { + get { return marketingImageDisplayCallToAction_; } + set { + marketingImageDisplayCallToAction_ = value; + } + } + + /// Field number for the "product_images" field. + public const int ProductImagesFieldNumber = 7; + private static readonly pb::FieldCodec _repeated_productImages_codec + = pb::FieldCodec.ForMessage(58, global::Google.Ads.GoogleAds.V3.Common.ProductImage.Parser); + private readonly pbc::RepeatedField productImages_ = new pbc::RepeatedField(); + /// + /// Product images. Up to 15 images are supported. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ProductImages { + get { return productImages_; } + } + + /// Field number for the "product_videos" field. + public const int ProductVideosFieldNumber = 8; + private static readonly pb::FieldCodec _repeated_productVideos_codec + = pb::FieldCodec.ForMessage(66, global::Google.Ads.GoogleAds.V3.Common.ProductVideo.Parser); + private readonly pbc::RepeatedField productVideos_ = new pbc::RepeatedField(); + /// + /// Product videos. Up to 7 videos are supported. At least one product video + /// or a marketing image must be specified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ProductVideos { + get { return productVideos_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GmailAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GmailAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Teaser, other.Teaser)) return false; + if (HeaderImage != other.HeaderImage) return false; + if (MarketingImage != other.MarketingImage) return false; + if (MarketingImageHeadline != other.MarketingImageHeadline) return false; + if (MarketingImageDescription != other.MarketingImageDescription) return false; + if (!object.Equals(MarketingImageDisplayCallToAction, other.MarketingImageDisplayCallToAction)) return false; + if(!productImages_.Equals(other.productImages_)) return false; + if(!productVideos_.Equals(other.productVideos_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (teaser_ != null) hash ^= Teaser.GetHashCode(); + if (headerImage_ != null) hash ^= HeaderImage.GetHashCode(); + if (marketingImage_ != null) hash ^= MarketingImage.GetHashCode(); + if (marketingImageHeadline_ != null) hash ^= MarketingImageHeadline.GetHashCode(); + if (marketingImageDescription_ != null) hash ^= MarketingImageDescription.GetHashCode(); + if (marketingImageDisplayCallToAction_ != null) hash ^= MarketingImageDisplayCallToAction.GetHashCode(); + hash ^= productImages_.GetHashCode(); + hash ^= productVideos_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (teaser_ != null) { + output.WriteRawTag(10); + output.WriteMessage(Teaser); + } + if (headerImage_ != null) { + _single_headerImage_codec.WriteTagAndValue(output, HeaderImage); + } + if (marketingImage_ != null) { + _single_marketingImage_codec.WriteTagAndValue(output, MarketingImage); + } + if (marketingImageHeadline_ != null) { + _single_marketingImageHeadline_codec.WriteTagAndValue(output, MarketingImageHeadline); + } + if (marketingImageDescription_ != null) { + _single_marketingImageDescription_codec.WriteTagAndValue(output, MarketingImageDescription); + } + if (marketingImageDisplayCallToAction_ != null) { + output.WriteRawTag(50); + output.WriteMessage(MarketingImageDisplayCallToAction); + } + productImages_.WriteTo(output, _repeated_productImages_codec); + productVideos_.WriteTo(output, _repeated_productVideos_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (teaser_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Teaser); + } + if (headerImage_ != null) { + size += _single_headerImage_codec.CalculateSizeWithTag(HeaderImage); + } + if (marketingImage_ != null) { + size += _single_marketingImage_codec.CalculateSizeWithTag(MarketingImage); + } + if (marketingImageHeadline_ != null) { + size += _single_marketingImageHeadline_codec.CalculateSizeWithTag(MarketingImageHeadline); + } + if (marketingImageDescription_ != null) { + size += _single_marketingImageDescription_codec.CalculateSizeWithTag(MarketingImageDescription); + } + if (marketingImageDisplayCallToAction_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MarketingImageDisplayCallToAction); + } + size += productImages_.CalculateSize(_repeated_productImages_codec); + size += productVideos_.CalculateSize(_repeated_productVideos_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GmailAdInfo other) { + if (other == null) { + return; + } + if (other.teaser_ != null) { + if (teaser_ == null) { + Teaser = new global::Google.Ads.GoogleAds.V3.Common.GmailTeaser(); + } + Teaser.MergeFrom(other.Teaser); + } + if (other.headerImage_ != null) { + if (headerImage_ == null || other.HeaderImage != "") { + HeaderImage = other.HeaderImage; + } + } + if (other.marketingImage_ != null) { + if (marketingImage_ == null || other.MarketingImage != "") { + MarketingImage = other.MarketingImage; + } + } + if (other.marketingImageHeadline_ != null) { + if (marketingImageHeadline_ == null || other.MarketingImageHeadline != "") { + MarketingImageHeadline = other.MarketingImageHeadline; + } + } + if (other.marketingImageDescription_ != null) { + if (marketingImageDescription_ == null || other.MarketingImageDescription != "") { + MarketingImageDescription = other.MarketingImageDescription; + } + } + if (other.marketingImageDisplayCallToAction_ != null) { + if (marketingImageDisplayCallToAction_ == null) { + MarketingImageDisplayCallToAction = new global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction(); + } + MarketingImageDisplayCallToAction.MergeFrom(other.MarketingImageDisplayCallToAction); + } + productImages_.Add(other.productImages_); + productVideos_.Add(other.productVideos_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (teaser_ == null) { + Teaser = new global::Google.Ads.GoogleAds.V3.Common.GmailTeaser(); + } + input.ReadMessage(Teaser); + break; + } + case 18: { + string value = _single_headerImage_codec.Read(input); + if (headerImage_ == null || value != "") { + HeaderImage = value; + } + break; + } + case 26: { + string value = _single_marketingImage_codec.Read(input); + if (marketingImage_ == null || value != "") { + MarketingImage = value; + } + break; + } + case 34: { + string value = _single_marketingImageHeadline_codec.Read(input); + if (marketingImageHeadline_ == null || value != "") { + MarketingImageHeadline = value; + } + break; + } + case 42: { + string value = _single_marketingImageDescription_codec.Read(input); + if (marketingImageDescription_ == null || value != "") { + MarketingImageDescription = value; + } + break; + } + case 50: { + if (marketingImageDisplayCallToAction_ == null) { + MarketingImageDisplayCallToAction = new global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction(); + } + input.ReadMessage(MarketingImageDisplayCallToAction); + break; + } + case 58: { + productImages_.AddEntriesFrom(input, _repeated_productImages_codec); + break; + } + case 66: { + productVideos_.AddEntriesFrom(input, _repeated_productVideos_codec); + break; + } + } + } + } + + } + + /// + /// Gmail teaser data. The teaser is a small header that acts as an invitation + /// to view the rest of the ad (the body). + /// + public sealed partial class GmailTeaser : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GmailTeaser()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[9]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GmailTeaser() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GmailTeaser(GmailTeaser other) : this() { + Headline = other.Headline; + Description = other.Description; + BusinessName = other.BusinessName; + LogoImage = other.LogoImage; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GmailTeaser Clone() { + return new GmailTeaser(this); + } + + /// Field number for the "headline" field. + public const int HeadlineFieldNumber = 1; + private static readonly pb::FieldCodec _single_headline_codec = pb::FieldCodec.ForClassWrapper(10); + private string headline_; + /// + /// Headline of the teaser. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline { + get { return headline_; } + set { + headline_ = value; + } + } + + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 2; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(18); + private string description_; + /// + /// Description of the teaser. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "business_name" field. + public const int BusinessNameFieldNumber = 3; + private static readonly pb::FieldCodec _single_businessName_codec = pb::FieldCodec.ForClassWrapper(26); + private string businessName_; + /// + /// Business name of the advertiser. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessName { + get { return businessName_; } + set { + businessName_ = value; + } + } + + + /// Field number for the "logo_image" field. + public const int LogoImageFieldNumber = 4; + private static readonly pb::FieldCodec _single_logoImage_codec = pb::FieldCodec.ForClassWrapper(34); + private string logoImage_; + /// + /// The MediaFile resource name of the logo image. Valid image types are GIF, + /// JPEG and PNG. The minimum size is 144x144 pixels and the aspect ratio must + /// be 1:1 (+-1%). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LogoImage { + get { return logoImage_; } + set { + logoImage_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GmailTeaser); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GmailTeaser other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Headline != other.Headline) return false; + if (Description != other.Description) return false; + if (BusinessName != other.BusinessName) return false; + if (LogoImage != other.LogoImage) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (headline_ != null) hash ^= Headline.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + if (businessName_ != null) hash ^= BusinessName.GetHashCode(); + if (logoImage_ != null) hash ^= LogoImage.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (headline_ != null) { + _single_headline_codec.WriteTagAndValue(output, Headline); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + if (businessName_ != null) { + _single_businessName_codec.WriteTagAndValue(output, BusinessName); + } + if (logoImage_ != null) { + _single_logoImage_codec.WriteTagAndValue(output, LogoImage); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (headline_ != null) { + size += _single_headline_codec.CalculateSizeWithTag(Headline); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + if (businessName_ != null) { + size += _single_businessName_codec.CalculateSizeWithTag(BusinessName); + } + if (logoImage_ != null) { + size += _single_logoImage_codec.CalculateSizeWithTag(LogoImage); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GmailTeaser other) { + if (other == null) { + return; + } + if (other.headline_ != null) { + if (headline_ == null || other.Headline != "") { + Headline = other.Headline; + } + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + if (other.businessName_ != null) { + if (businessName_ == null || other.BusinessName != "") { + BusinessName = other.BusinessName; + } + } + if (other.logoImage_ != null) { + if (logoImage_ == null || other.LogoImage != "") { + LogoImage = other.LogoImage; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_headline_codec.Read(input); + if (headline_ == null || value != "") { + Headline = value; + } + break; + } + case 18: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 26: { + string value = _single_businessName_codec.Read(input); + if (businessName_ == null || value != "") { + BusinessName = value; + } + break; + } + case 34: { + string value = _single_logoImage_codec.Read(input); + if (logoImage_ == null || value != "") { + LogoImage = value; + } + break; + } + } + } + } + + } + + /// + /// Data for display call to action. The call to action is a piece of the ad + /// that prompts the user to do something. Like clicking a link or making a phone + /// call. + /// + public sealed partial class DisplayCallToAction : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DisplayCallToAction()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[10]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayCallToAction() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayCallToAction(DisplayCallToAction other) : this() { + Text = other.Text; + TextColor = other.TextColor; + UrlCollectionId = other.UrlCollectionId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayCallToAction Clone() { + return new DisplayCallToAction(this); + } + + /// Field number for the "text" field. + public const int TextFieldNumber = 1; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(10); + private string text_; + /// + /// Text for the display-call-to-action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + /// Field number for the "text_color" field. + public const int TextColorFieldNumber = 2; + private static readonly pb::FieldCodec _single_textColor_codec = pb::FieldCodec.ForClassWrapper(18); + private string textColor_; + /// + /// Text color for the display-call-to-action in hexadecimal, e.g. #ffffff for + /// white. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TextColor { + get { return textColor_; } + set { + textColor_ = value; + } + } + + + /// Field number for the "url_collection_id" field. + public const int UrlCollectionIdFieldNumber = 3; + private static readonly pb::FieldCodec _single_urlCollectionId_codec = pb::FieldCodec.ForClassWrapper(26); + private string urlCollectionId_; + /// + /// Identifies the url collection in the ad.url_collections field. If not set + /// the url defaults to final_url. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string UrlCollectionId { + get { return urlCollectionId_; } + set { + urlCollectionId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DisplayCallToAction); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DisplayCallToAction other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Text != other.Text) return false; + if (TextColor != other.TextColor) return false; + if (UrlCollectionId != other.UrlCollectionId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (text_ != null) hash ^= Text.GetHashCode(); + if (textColor_ != null) hash ^= TextColor.GetHashCode(); + if (urlCollectionId_ != null) hash ^= UrlCollectionId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (textColor_ != null) { + _single_textColor_codec.WriteTagAndValue(output, TextColor); + } + if (urlCollectionId_ != null) { + _single_urlCollectionId_codec.WriteTagAndValue(output, UrlCollectionId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (textColor_ != null) { + size += _single_textColor_codec.CalculateSizeWithTag(TextColor); + } + if (urlCollectionId_ != null) { + size += _single_urlCollectionId_codec.CalculateSizeWithTag(UrlCollectionId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DisplayCallToAction other) { + if (other == null) { + return; + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + if (other.textColor_ != null) { + if (textColor_ == null || other.TextColor != "") { + TextColor = other.TextColor; + } + } + if (other.urlCollectionId_ != null) { + if (urlCollectionId_ == null || other.UrlCollectionId != "") { + UrlCollectionId = other.UrlCollectionId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + case 18: { + string value = _single_textColor_codec.Read(input); + if (textColor_ == null || value != "") { + TextColor = value; + } + break; + } + case 26: { + string value = _single_urlCollectionId_codec.Read(input); + if (urlCollectionId_ == null || value != "") { + UrlCollectionId = value; + } + break; + } + } + } + } + + } + + /// + /// Product image specific data. + /// + public sealed partial class ProductImage : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductImage()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[11]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductImage() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductImage(ProductImage other) : this() { + ProductImage_ = other.ProductImage_; + Description = other.Description; + displayCallToAction_ = other.displayCallToAction_ != null ? other.displayCallToAction_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductImage Clone() { + return new ProductImage(this); + } + + /// Field number for the "product_image" field. + public const int ProductImage_FieldNumber = 1; + private static readonly pb::FieldCodec _single_productImage_codec = pb::FieldCodec.ForClassWrapper(10); + private string productImage_; + /// + /// The MediaFile resource name of the product image. Valid image types are + /// GIF, JPEG and PNG. The minimum size is 300x300 pixels and the aspect ratio + /// must be 1:1 (+-1%). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProductImage_ { + get { return productImage_; } + set { + productImage_ = value; + } + } + + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 2; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(18); + private string description_; + /// + /// Description of the product. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "display_call_to_action" field. + public const int DisplayCallToActionFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction displayCallToAction_; + /// + /// Display-call-to-action of the product image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction DisplayCallToAction { + get { return displayCallToAction_; } + set { + displayCallToAction_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductImage); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductImage other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ProductImage_ != other.ProductImage_) return false; + if (Description != other.Description) return false; + if (!object.Equals(DisplayCallToAction, other.DisplayCallToAction)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (productImage_ != null) hash ^= ProductImage_.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + if (displayCallToAction_ != null) hash ^= DisplayCallToAction.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (productImage_ != null) { + _single_productImage_codec.WriteTagAndValue(output, ProductImage_); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + if (displayCallToAction_ != null) { + output.WriteRawTag(26); + output.WriteMessage(DisplayCallToAction); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (productImage_ != null) { + size += _single_productImage_codec.CalculateSizeWithTag(ProductImage_); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + if (displayCallToAction_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(DisplayCallToAction); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductImage other) { + if (other == null) { + return; + } + if (other.productImage_ != null) { + if (productImage_ == null || other.ProductImage_ != "") { + ProductImage_ = other.ProductImage_; + } + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + if (other.displayCallToAction_ != null) { + if (displayCallToAction_ == null) { + DisplayCallToAction = new global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction(); + } + DisplayCallToAction.MergeFrom(other.DisplayCallToAction); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_productImage_codec.Read(input); + if (productImage_ == null || value != "") { + ProductImage_ = value; + } + break; + } + case 18: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 26: { + if (displayCallToAction_ == null) { + DisplayCallToAction = new global::Google.Ads.GoogleAds.V3.Common.DisplayCallToAction(); + } + input.ReadMessage(DisplayCallToAction); + break; + } + } + } + } + + } + + /// + /// Product video specific data. + /// + public sealed partial class ProductVideo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductVideo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[12]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductVideo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductVideo(ProductVideo other) : this() { + ProductVideo_ = other.ProductVideo_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductVideo Clone() { + return new ProductVideo(this); + } + + /// Field number for the "product_video" field. + public const int ProductVideo_FieldNumber = 1; + private static readonly pb::FieldCodec _single_productVideo_codec = pb::FieldCodec.ForClassWrapper(10); + private string productVideo_; + /// + /// The MediaFile resource name of a video which must be hosted on YouTube. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProductVideo_ { + get { return productVideo_; } + set { + productVideo_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductVideo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductVideo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ProductVideo_ != other.ProductVideo_) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (productVideo_ != null) hash ^= ProductVideo_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (productVideo_ != null) { + _single_productVideo_codec.WriteTagAndValue(output, ProductVideo_); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (productVideo_ != null) { + size += _single_productVideo_codec.CalculateSizeWithTag(ProductVideo_); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductVideo other) { + if (other == null) { + return; + } + if (other.productVideo_ != null) { + if (productVideo_ == null || other.ProductVideo_ != "") { + ProductVideo_ = other.ProductVideo_; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_productVideo_codec.Read(input); + if (productVideo_ == null || value != "") { + ProductVideo_ = value; + } + break; + } + } + } + } + + } + + /// + /// An image ad. + /// + public sealed partial class ImageAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ImageAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[13]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageAdInfo(ImageAdInfo other) : this() { + PixelWidth = other.PixelWidth; + PixelHeight = other.PixelHeight; + ImageUrl = other.ImageUrl; + PreviewPixelWidth = other.PreviewPixelWidth; + PreviewPixelHeight = other.PreviewPixelHeight; + PreviewImageUrl = other.PreviewImageUrl; + mimeType_ = other.mimeType_; + Name = other.Name; + switch (other.ImageCase) { + case ImageOneofCase.MediaFile: + MediaFile = other.MediaFile; + break; + case ImageOneofCase.Data: + Data = other.Data; + break; + case ImageOneofCase.AdIdToCopyImageFrom: + AdIdToCopyImageFrom = other.AdIdToCopyImageFrom; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageAdInfo Clone() { + return new ImageAdInfo(this); + } + + /// Field number for the "pixel_width" field. + public const int PixelWidthFieldNumber = 4; + private static readonly pb::FieldCodec _single_pixelWidth_codec = pb::FieldCodec.ForStructWrapper(34); + private long? pixelWidth_; + /// + /// Width in pixels of the full size image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PixelWidth { + get { return pixelWidth_; } + set { + pixelWidth_ = value; + } + } + + + /// Field number for the "pixel_height" field. + public const int PixelHeightFieldNumber = 5; + private static readonly pb::FieldCodec _single_pixelHeight_codec = pb::FieldCodec.ForStructWrapper(42); + private long? pixelHeight_; + /// + /// Height in pixels of the full size image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PixelHeight { + get { return pixelHeight_; } + set { + pixelHeight_ = value; + } + } + + + /// Field number for the "image_url" field. + public const int ImageUrlFieldNumber = 6; + private static readonly pb::FieldCodec _single_imageUrl_codec = pb::FieldCodec.ForClassWrapper(50); + private string imageUrl_; + /// + /// URL of the full size image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ImageUrl { + get { return imageUrl_; } + set { + imageUrl_ = value; + } + } + + + /// Field number for the "preview_pixel_width" field. + public const int PreviewPixelWidthFieldNumber = 7; + private static readonly pb::FieldCodec _single_previewPixelWidth_codec = pb::FieldCodec.ForStructWrapper(58); + private long? previewPixelWidth_; + /// + /// Width in pixels of the preview size image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PreviewPixelWidth { + get { return previewPixelWidth_; } + set { + previewPixelWidth_ = value; + } + } + + + /// Field number for the "preview_pixel_height" field. + public const int PreviewPixelHeightFieldNumber = 8; + private static readonly pb::FieldCodec _single_previewPixelHeight_codec = pb::FieldCodec.ForStructWrapper(66); + private long? previewPixelHeight_; + /// + /// Height in pixels of the preview size image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PreviewPixelHeight { + get { return previewPixelHeight_; } + set { + previewPixelHeight_ = value; + } + } + + + /// Field number for the "preview_image_url" field. + public const int PreviewImageUrlFieldNumber = 9; + private static readonly pb::FieldCodec _single_previewImageUrl_codec = pb::FieldCodec.ForClassWrapper(74); + private string previewImageUrl_; + /// + /// URL of the preview size image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PreviewImageUrl { + get { return previewImageUrl_; } + set { + previewImageUrl_ = value; + } + } + + + /// Field number for the "mime_type" field. + public const int MimeTypeFieldNumber = 10; + private global::Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types.MimeType mimeType_ = 0; + /// + /// The mime type of the image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types.MimeType MimeType { + get { return mimeType_; } + set { + mimeType_ = value; + } + } + + /// Field number for the "name" field. + public const int NameFieldNumber = 11; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(90); + private string name_; + /// + /// The name of the image. If the image was created from a MediaFile, this is + /// the MediaFile's name. If the image was created from bytes, this is empty. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "media_file" field. + public const int MediaFileFieldNumber = 1; + private static readonly pb::FieldCodec _oneof_mediaFile_codec = pb::FieldCodec.ForClassWrapper(10); + /// + /// The MediaFile resource to use for the image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MediaFile { + get { return imageCase_ == ImageOneofCase.MediaFile ? (string) image_ : (string) null; } + set { + image_ = value; + imageCase_ = value == null ? ImageOneofCase.None : ImageOneofCase.MediaFile; + } + } + + /// Field number for the "data" field. + public const int DataFieldNumber = 2; + private static readonly pb::FieldCodec _oneof_data_codec = pb::FieldCodec.ForClassWrapper(18); + /// + /// Raw image data as bytes. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pb::ByteString Data { + get { return imageCase_ == ImageOneofCase.Data ? (pb::ByteString) image_ : (pb::ByteString) null; } + set { + image_ = value; + imageCase_ = value == null ? ImageOneofCase.None : ImageOneofCase.Data; + } + } + + /// Field number for the "ad_id_to_copy_image_from" field. + public const int AdIdToCopyImageFromFieldNumber = 3; + private static readonly pb::FieldCodec _oneof_adIdToCopyImageFrom_codec = pb::FieldCodec.ForStructWrapper(26); + /// + /// An ad ID to copy the image from. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AdIdToCopyImageFrom { + get { return imageCase_ == ImageOneofCase.AdIdToCopyImageFrom ? (long?) image_ : (long?) null; } + set { + image_ = value; + imageCase_ = value == null ? ImageOneofCase.None : ImageOneofCase.AdIdToCopyImageFrom; + } + } + + private object image_; + /// Enum of possible cases for the "image" oneof. + public enum ImageOneofCase { + None = 0, + MediaFile = 1, + Data = 2, + AdIdToCopyImageFrom = 3, + } + private ImageOneofCase imageCase_ = ImageOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageOneofCase ImageCase { + get { return imageCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearImage() { + imageCase_ = ImageOneofCase.None; + image_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ImageAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ImageAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (PixelWidth != other.PixelWidth) return false; + if (PixelHeight != other.PixelHeight) return false; + if (ImageUrl != other.ImageUrl) return false; + if (PreviewPixelWidth != other.PreviewPixelWidth) return false; + if (PreviewPixelHeight != other.PreviewPixelHeight) return false; + if (PreviewImageUrl != other.PreviewImageUrl) return false; + if (MimeType != other.MimeType) return false; + if (Name != other.Name) return false; + if (MediaFile != other.MediaFile) return false; + if (Data != other.Data) return false; + if (AdIdToCopyImageFrom != other.AdIdToCopyImageFrom) return false; + if (ImageCase != other.ImageCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (pixelWidth_ != null) hash ^= PixelWidth.GetHashCode(); + if (pixelHeight_ != null) hash ^= PixelHeight.GetHashCode(); + if (imageUrl_ != null) hash ^= ImageUrl.GetHashCode(); + if (previewPixelWidth_ != null) hash ^= PreviewPixelWidth.GetHashCode(); + if (previewPixelHeight_ != null) hash ^= PreviewPixelHeight.GetHashCode(); + if (previewImageUrl_ != null) hash ^= PreviewImageUrl.GetHashCode(); + if (MimeType != 0) hash ^= MimeType.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (imageCase_ == ImageOneofCase.MediaFile) hash ^= MediaFile.GetHashCode(); + if (imageCase_ == ImageOneofCase.Data) hash ^= Data.GetHashCode(); + if (imageCase_ == ImageOneofCase.AdIdToCopyImageFrom) hash ^= AdIdToCopyImageFrom.GetHashCode(); + hash ^= (int) imageCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (imageCase_ == ImageOneofCase.MediaFile) { + _oneof_mediaFile_codec.WriteTagAndValue(output, (string) image_); + } + if (imageCase_ == ImageOneofCase.Data) { + _oneof_data_codec.WriteTagAndValue(output, (pb::ByteString) image_); + } + if (imageCase_ == ImageOneofCase.AdIdToCopyImageFrom) { + _oneof_adIdToCopyImageFrom_codec.WriteTagAndValue(output, (long?) image_); + } + if (pixelWidth_ != null) { + _single_pixelWidth_codec.WriteTagAndValue(output, PixelWidth); + } + if (pixelHeight_ != null) { + _single_pixelHeight_codec.WriteTagAndValue(output, PixelHeight); + } + if (imageUrl_ != null) { + _single_imageUrl_codec.WriteTagAndValue(output, ImageUrl); + } + if (previewPixelWidth_ != null) { + _single_previewPixelWidth_codec.WriteTagAndValue(output, PreviewPixelWidth); + } + if (previewPixelHeight_ != null) { + _single_previewPixelHeight_codec.WriteTagAndValue(output, PreviewPixelHeight); + } + if (previewImageUrl_ != null) { + _single_previewImageUrl_codec.WriteTagAndValue(output, PreviewImageUrl); + } + if (MimeType != 0) { + output.WriteRawTag(80); + output.WriteEnum((int) MimeType); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (pixelWidth_ != null) { + size += _single_pixelWidth_codec.CalculateSizeWithTag(PixelWidth); + } + if (pixelHeight_ != null) { + size += _single_pixelHeight_codec.CalculateSizeWithTag(PixelHeight); + } + if (imageUrl_ != null) { + size += _single_imageUrl_codec.CalculateSizeWithTag(ImageUrl); + } + if (previewPixelWidth_ != null) { + size += _single_previewPixelWidth_codec.CalculateSizeWithTag(PreviewPixelWidth); + } + if (previewPixelHeight_ != null) { + size += _single_previewPixelHeight_codec.CalculateSizeWithTag(PreviewPixelHeight); + } + if (previewImageUrl_ != null) { + size += _single_previewImageUrl_codec.CalculateSizeWithTag(PreviewImageUrl); + } + if (MimeType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MimeType); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (imageCase_ == ImageOneofCase.MediaFile) { + size += _oneof_mediaFile_codec.CalculateSizeWithTag(MediaFile); + } + if (imageCase_ == ImageOneofCase.Data) { + size += _oneof_data_codec.CalculateSizeWithTag(Data); + } + if (imageCase_ == ImageOneofCase.AdIdToCopyImageFrom) { + size += _oneof_adIdToCopyImageFrom_codec.CalculateSizeWithTag(AdIdToCopyImageFrom); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ImageAdInfo other) { + if (other == null) { + return; + } + if (other.pixelWidth_ != null) { + if (pixelWidth_ == null || other.PixelWidth != 0L) { + PixelWidth = other.PixelWidth; + } + } + if (other.pixelHeight_ != null) { + if (pixelHeight_ == null || other.PixelHeight != 0L) { + PixelHeight = other.PixelHeight; + } + } + if (other.imageUrl_ != null) { + if (imageUrl_ == null || other.ImageUrl != "") { + ImageUrl = other.ImageUrl; + } + } + if (other.previewPixelWidth_ != null) { + if (previewPixelWidth_ == null || other.PreviewPixelWidth != 0L) { + PreviewPixelWidth = other.PreviewPixelWidth; + } + } + if (other.previewPixelHeight_ != null) { + if (previewPixelHeight_ == null || other.PreviewPixelHeight != 0L) { + PreviewPixelHeight = other.PreviewPixelHeight; + } + } + if (other.previewImageUrl_ != null) { + if (previewImageUrl_ == null || other.PreviewImageUrl != "") { + PreviewImageUrl = other.PreviewImageUrl; + } + } + if (other.MimeType != 0) { + MimeType = other.MimeType; + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + switch (other.ImageCase) { + case ImageOneofCase.MediaFile: + MediaFile = other.MediaFile; + break; + case ImageOneofCase.Data: + Data = other.Data; + break; + case ImageOneofCase.AdIdToCopyImageFrom: + AdIdToCopyImageFrom = other.AdIdToCopyImageFrom; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + MediaFile = _oneof_mediaFile_codec.Read(input); + break; + } + case 18: { + Data = _oneof_data_codec.Read(input); + break; + } + case 26: { + AdIdToCopyImageFrom = _oneof_adIdToCopyImageFrom_codec.Read(input); + break; + } + case 34: { + long? value = _single_pixelWidth_codec.Read(input); + if (pixelWidth_ == null || value != 0L) { + PixelWidth = value; + } + break; + } + case 42: { + long? value = _single_pixelHeight_codec.Read(input); + if (pixelHeight_ == null || value != 0L) { + PixelHeight = value; + } + break; + } + case 50: { + string value = _single_imageUrl_codec.Read(input); + if (imageUrl_ == null || value != "") { + ImageUrl = value; + } + break; + } + case 58: { + long? value = _single_previewPixelWidth_codec.Read(input); + if (previewPixelWidth_ == null || value != 0L) { + PreviewPixelWidth = value; + } + break; + } + case 66: { + long? value = _single_previewPixelHeight_codec.Read(input); + if (previewPixelHeight_ == null || value != 0L) { + PreviewPixelHeight = value; + } + break; + } + case 74: { + string value = _single_previewImageUrl_codec.Read(input); + if (previewImageUrl_ == null || value != "") { + PreviewImageUrl = value; + } + break; + } + case 80: { + MimeType = (global::Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types.MimeType) input.ReadEnum(); + break; + } + case 90: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + } + } + } + + } + + /// + /// Representation of video bumper in-stream ad format (very short in-stream + /// non-skippable video ad). + /// + public sealed partial class VideoBumperInStreamAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new VideoBumperInStreamAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[14]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoBumperInStreamAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoBumperInStreamAdInfo(VideoBumperInStreamAdInfo other) : this() { + CompanionBanner = other.CompanionBanner; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoBumperInStreamAdInfo Clone() { + return new VideoBumperInStreamAdInfo(this); + } + + /// Field number for the "companion_banner" field. + public const int CompanionBannerFieldNumber = 1; + private static readonly pb::FieldCodec _single_companionBanner_codec = pb::FieldCodec.ForClassWrapper(10); + private string companionBanner_; + /// + /// The MediaFile resource name of the companion banner used with the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CompanionBanner { + get { return companionBanner_; } + set { + companionBanner_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as VideoBumperInStreamAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(VideoBumperInStreamAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CompanionBanner != other.CompanionBanner) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (companionBanner_ != null) hash ^= CompanionBanner.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (companionBanner_ != null) { + _single_companionBanner_codec.WriteTagAndValue(output, CompanionBanner); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (companionBanner_ != null) { + size += _single_companionBanner_codec.CalculateSizeWithTag(CompanionBanner); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(VideoBumperInStreamAdInfo other) { + if (other == null) { + return; + } + if (other.companionBanner_ != null) { + if (companionBanner_ == null || other.CompanionBanner != "") { + CompanionBanner = other.CompanionBanner; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_companionBanner_codec.Read(input); + if (companionBanner_ == null || value != "") { + CompanionBanner = value; + } + break; + } + } + } + } + + } + + /// + /// Representation of video non-skippable in-stream ad format (15 second + /// in-stream non-skippable video ad). + /// + public sealed partial class VideoNonSkippableInStreamAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new VideoNonSkippableInStreamAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[15]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoNonSkippableInStreamAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoNonSkippableInStreamAdInfo(VideoNonSkippableInStreamAdInfo other) : this() { + CompanionBanner = other.CompanionBanner; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoNonSkippableInStreamAdInfo Clone() { + return new VideoNonSkippableInStreamAdInfo(this); + } + + /// Field number for the "companion_banner" field. + public const int CompanionBannerFieldNumber = 1; + private static readonly pb::FieldCodec _single_companionBanner_codec = pb::FieldCodec.ForClassWrapper(10); + private string companionBanner_; + /// + /// The MediaFile resource name of the companion banner used with the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CompanionBanner { + get { return companionBanner_; } + set { + companionBanner_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as VideoNonSkippableInStreamAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(VideoNonSkippableInStreamAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CompanionBanner != other.CompanionBanner) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (companionBanner_ != null) hash ^= CompanionBanner.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (companionBanner_ != null) { + _single_companionBanner_codec.WriteTagAndValue(output, CompanionBanner); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (companionBanner_ != null) { + size += _single_companionBanner_codec.CalculateSizeWithTag(CompanionBanner); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(VideoNonSkippableInStreamAdInfo other) { + if (other == null) { + return; + } + if (other.companionBanner_ != null) { + if (companionBanner_ == null || other.CompanionBanner != "") { + CompanionBanner = other.CompanionBanner; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_companionBanner_codec.Read(input); + if (companionBanner_ == null || value != "") { + CompanionBanner = value; + } + break; + } + } + } + } + + } + + /// + /// Representation of video TrueView in-stream ad format (ad shown during video + /// playback, often at beginning, which displays a skip button a few seconds into + /// the video). + /// + public sealed partial class VideoTrueViewInStreamAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new VideoTrueViewInStreamAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[16]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoTrueViewInStreamAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoTrueViewInStreamAdInfo(VideoTrueViewInStreamAdInfo other) : this() { + ActionButtonLabel = other.ActionButtonLabel; + ActionHeadline = other.ActionHeadline; + CompanionBanner = other.CompanionBanner; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoTrueViewInStreamAdInfo Clone() { + return new VideoTrueViewInStreamAdInfo(this); + } + + /// Field number for the "action_button_label" field. + public const int ActionButtonLabelFieldNumber = 1; + private static readonly pb::FieldCodec _single_actionButtonLabel_codec = pb::FieldCodec.ForClassWrapper(10); + private string actionButtonLabel_; + /// + /// Label on the CTA (call-to-action) button taking the user to the video ad's + /// final URL. + /// Required for TrueView for action campaigns, optional otherwise. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ActionButtonLabel { + get { return actionButtonLabel_; } + set { + actionButtonLabel_ = value; + } + } + + + /// Field number for the "action_headline" field. + public const int ActionHeadlineFieldNumber = 2; + private static readonly pb::FieldCodec _single_actionHeadline_codec = pb::FieldCodec.ForClassWrapper(18); + private string actionHeadline_; + /// + /// Additional text displayed with the CTA (call-to-action) button to give + /// context and encourage clicking on the button. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ActionHeadline { + get { return actionHeadline_; } + set { + actionHeadline_ = value; + } + } + + + /// Field number for the "companion_banner" field. + public const int CompanionBannerFieldNumber = 3; + private static readonly pb::FieldCodec _single_companionBanner_codec = pb::FieldCodec.ForClassWrapper(26); + private string companionBanner_; + /// + /// The MediaFile resource name of the companion banner used with the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CompanionBanner { + get { return companionBanner_; } + set { + companionBanner_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as VideoTrueViewInStreamAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(VideoTrueViewInStreamAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ActionButtonLabel != other.ActionButtonLabel) return false; + if (ActionHeadline != other.ActionHeadline) return false; + if (CompanionBanner != other.CompanionBanner) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (actionButtonLabel_ != null) hash ^= ActionButtonLabel.GetHashCode(); + if (actionHeadline_ != null) hash ^= ActionHeadline.GetHashCode(); + if (companionBanner_ != null) hash ^= CompanionBanner.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (actionButtonLabel_ != null) { + _single_actionButtonLabel_codec.WriteTagAndValue(output, ActionButtonLabel); + } + if (actionHeadline_ != null) { + _single_actionHeadline_codec.WriteTagAndValue(output, ActionHeadline); + } + if (companionBanner_ != null) { + _single_companionBanner_codec.WriteTagAndValue(output, CompanionBanner); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (actionButtonLabel_ != null) { + size += _single_actionButtonLabel_codec.CalculateSizeWithTag(ActionButtonLabel); + } + if (actionHeadline_ != null) { + size += _single_actionHeadline_codec.CalculateSizeWithTag(ActionHeadline); + } + if (companionBanner_ != null) { + size += _single_companionBanner_codec.CalculateSizeWithTag(CompanionBanner); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(VideoTrueViewInStreamAdInfo other) { + if (other == null) { + return; + } + if (other.actionButtonLabel_ != null) { + if (actionButtonLabel_ == null || other.ActionButtonLabel != "") { + ActionButtonLabel = other.ActionButtonLabel; + } + } + if (other.actionHeadline_ != null) { + if (actionHeadline_ == null || other.ActionHeadline != "") { + ActionHeadline = other.ActionHeadline; + } + } + if (other.companionBanner_ != null) { + if (companionBanner_ == null || other.CompanionBanner != "") { + CompanionBanner = other.CompanionBanner; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_actionButtonLabel_codec.Read(input); + if (actionButtonLabel_ == null || value != "") { + ActionButtonLabel = value; + } + break; + } + case 18: { + string value = _single_actionHeadline_codec.Read(input); + if (actionHeadline_ == null || value != "") { + ActionHeadline = value; + } + break; + } + case 26: { + string value = _single_companionBanner_codec.Read(input); + if (companionBanner_ == null || value != "") { + CompanionBanner = value; + } + break; + } + } + } + } + + } + + /// + /// Representation of video out-stream ad format (ad shown alongside a feed + /// with automatic playback, without sound). + /// + public sealed partial class VideoOutstreamAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new VideoOutstreamAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[17]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoOutstreamAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoOutstreamAdInfo(VideoOutstreamAdInfo other) : this() { + Headline = other.Headline; + Description = other.Description; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoOutstreamAdInfo Clone() { + return new VideoOutstreamAdInfo(this); + } + + /// Field number for the "headline" field. + public const int HeadlineFieldNumber = 1; + private static readonly pb::FieldCodec _single_headline_codec = pb::FieldCodec.ForClassWrapper(10); + private string headline_; + /// + /// The headline of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline { + get { return headline_; } + set { + headline_ = value; + } + } + + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 2; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(18); + private string description_; + /// + /// The description line. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as VideoOutstreamAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(VideoOutstreamAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Headline != other.Headline) return false; + if (Description != other.Description) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (headline_ != null) hash ^= Headline.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (headline_ != null) { + _single_headline_codec.WriteTagAndValue(output, Headline); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (headline_ != null) { + size += _single_headline_codec.CalculateSizeWithTag(Headline); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(VideoOutstreamAdInfo other) { + if (other == null) { + return; + } + if (other.headline_ != null) { + if (headline_ == null || other.Headline != "") { + Headline = other.Headline; + } + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_headline_codec.Read(input); + if (headline_ == null || value != "") { + Headline = value; + } + break; + } + case 18: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + } + } + } + + } + + /// + /// Representation of video TrueView discovery ad format. + /// + public sealed partial class VideoTrueViewDiscoveryAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new VideoTrueViewDiscoveryAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[18]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoTrueViewDiscoveryAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoTrueViewDiscoveryAdInfo(VideoTrueViewDiscoveryAdInfo other) : this() { + Headline = other.Headline; + Description1 = other.Description1; + Description2 = other.Description2; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoTrueViewDiscoveryAdInfo Clone() { + return new VideoTrueViewDiscoveryAdInfo(this); + } + + /// Field number for the "headline" field. + public const int HeadlineFieldNumber = 1; + private static readonly pb::FieldCodec _single_headline_codec = pb::FieldCodec.ForClassWrapper(10); + private string headline_; + /// + /// The headline of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline { + get { return headline_; } + set { + headline_ = value; + } + } + + + /// Field number for the "description1" field. + public const int Description1FieldNumber = 2; + private static readonly pb::FieldCodec _single_description1_codec = pb::FieldCodec.ForClassWrapper(18); + private string description1_; + /// + /// First text line for a TrueView video discovery ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description1 { + get { return description1_; } + set { + description1_ = value; + } + } + + + /// Field number for the "description2" field. + public const int Description2FieldNumber = 3; + private static readonly pb::FieldCodec _single_description2_codec = pb::FieldCodec.ForClassWrapper(26); + private string description2_; + /// + /// Second text line for a TrueView video discovery ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description2 { + get { return description2_; } + set { + description2_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as VideoTrueViewDiscoveryAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(VideoTrueViewDiscoveryAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Headline != other.Headline) return false; + if (Description1 != other.Description1) return false; + if (Description2 != other.Description2) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (headline_ != null) hash ^= Headline.GetHashCode(); + if (description1_ != null) hash ^= Description1.GetHashCode(); + if (description2_ != null) hash ^= Description2.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (headline_ != null) { + _single_headline_codec.WriteTagAndValue(output, Headline); + } + if (description1_ != null) { + _single_description1_codec.WriteTagAndValue(output, Description1); + } + if (description2_ != null) { + _single_description2_codec.WriteTagAndValue(output, Description2); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (headline_ != null) { + size += _single_headline_codec.CalculateSizeWithTag(Headline); + } + if (description1_ != null) { + size += _single_description1_codec.CalculateSizeWithTag(Description1); + } + if (description2_ != null) { + size += _single_description2_codec.CalculateSizeWithTag(Description2); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(VideoTrueViewDiscoveryAdInfo other) { + if (other == null) { + return; + } + if (other.headline_ != null) { + if (headline_ == null || other.Headline != "") { + Headline = other.Headline; + } + } + if (other.description1_ != null) { + if (description1_ == null || other.Description1 != "") { + Description1 = other.Description1; + } + } + if (other.description2_ != null) { + if (description2_ == null || other.Description2 != "") { + Description2 = other.Description2; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_headline_codec.Read(input); + if (headline_ == null || value != "") { + Headline = value; + } + break; + } + case 18: { + string value = _single_description1_codec.Read(input); + if (description1_ == null || value != "") { + Description1 = value; + } + break; + } + case 26: { + string value = _single_description2_codec.Read(input); + if (description2_ == null || value != "") { + Description2 = value; + } + break; + } + } + } + } + + } + + /// + /// A video ad. + /// + public sealed partial class VideoAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new VideoAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[19]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoAdInfo(VideoAdInfo other) : this() { + MediaFile = other.MediaFile; + switch (other.FormatCase) { + case FormatOneofCase.InStream: + InStream = other.InStream.Clone(); + break; + case FormatOneofCase.Bumper: + Bumper = other.Bumper.Clone(); + break; + case FormatOneofCase.OutStream: + OutStream = other.OutStream.Clone(); + break; + case FormatOneofCase.NonSkippable: + NonSkippable = other.NonSkippable.Clone(); + break; + case FormatOneofCase.Discovery: + Discovery = other.Discovery.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VideoAdInfo Clone() { + return new VideoAdInfo(this); + } + + /// Field number for the "media_file" field. + public const int MediaFileFieldNumber = 1; + private static readonly pb::FieldCodec _single_mediaFile_codec = pb::FieldCodec.ForClassWrapper(10); + private string mediaFile_; + /// + /// The MediaFile resource to use for the video. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MediaFile { + get { return mediaFile_; } + set { + mediaFile_ = value; + } + } + + + /// Field number for the "in_stream" field. + public const int InStreamFieldNumber = 2; + /// + /// Video TrueView in-stream ad format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewInStreamAdInfo InStream { + get { return formatCase_ == FormatOneofCase.InStream ? (global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewInStreamAdInfo) format_ : null; } + set { + format_ = value; + formatCase_ = value == null ? FormatOneofCase.None : FormatOneofCase.InStream; + } + } + + /// Field number for the "bumper" field. + public const int BumperFieldNumber = 3; + /// + /// Video bumper in-stream ad format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.VideoBumperInStreamAdInfo Bumper { + get { return formatCase_ == FormatOneofCase.Bumper ? (global::Google.Ads.GoogleAds.V3.Common.VideoBumperInStreamAdInfo) format_ : null; } + set { + format_ = value; + formatCase_ = value == null ? FormatOneofCase.None : FormatOneofCase.Bumper; + } + } + + /// Field number for the "out_stream" field. + public const int OutStreamFieldNumber = 4; + /// + /// Video out-stream ad format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.VideoOutstreamAdInfo OutStream { + get { return formatCase_ == FormatOneofCase.OutStream ? (global::Google.Ads.GoogleAds.V3.Common.VideoOutstreamAdInfo) format_ : null; } + set { + format_ = value; + formatCase_ = value == null ? FormatOneofCase.None : FormatOneofCase.OutStream; + } + } + + /// Field number for the "non_skippable" field. + public const int NonSkippableFieldNumber = 5; + /// + /// Video non-skippable in-stream ad format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.VideoNonSkippableInStreamAdInfo NonSkippable { + get { return formatCase_ == FormatOneofCase.NonSkippable ? (global::Google.Ads.GoogleAds.V3.Common.VideoNonSkippableInStreamAdInfo) format_ : null; } + set { + format_ = value; + formatCase_ = value == null ? FormatOneofCase.None : FormatOneofCase.NonSkippable; + } + } + + /// Field number for the "discovery" field. + public const int DiscoveryFieldNumber = 6; + /// + /// Video TrueView discovery ad format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewDiscoveryAdInfo Discovery { + get { return formatCase_ == FormatOneofCase.Discovery ? (global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewDiscoveryAdInfo) format_ : null; } + set { + format_ = value; + formatCase_ = value == null ? FormatOneofCase.None : FormatOneofCase.Discovery; + } + } + + private object format_; + /// Enum of possible cases for the "format" oneof. + public enum FormatOneofCase { + None = 0, + InStream = 2, + Bumper = 3, + OutStream = 4, + NonSkippable = 5, + Discovery = 6, + } + private FormatOneofCase formatCase_ = FormatOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FormatOneofCase FormatCase { + get { return formatCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearFormat() { + formatCase_ = FormatOneofCase.None; + format_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as VideoAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(VideoAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (MediaFile != other.MediaFile) return false; + if (!object.Equals(InStream, other.InStream)) return false; + if (!object.Equals(Bumper, other.Bumper)) return false; + if (!object.Equals(OutStream, other.OutStream)) return false; + if (!object.Equals(NonSkippable, other.NonSkippable)) return false; + if (!object.Equals(Discovery, other.Discovery)) return false; + if (FormatCase != other.FormatCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (mediaFile_ != null) hash ^= MediaFile.GetHashCode(); + if (formatCase_ == FormatOneofCase.InStream) hash ^= InStream.GetHashCode(); + if (formatCase_ == FormatOneofCase.Bumper) hash ^= Bumper.GetHashCode(); + if (formatCase_ == FormatOneofCase.OutStream) hash ^= OutStream.GetHashCode(); + if (formatCase_ == FormatOneofCase.NonSkippable) hash ^= NonSkippable.GetHashCode(); + if (formatCase_ == FormatOneofCase.Discovery) hash ^= Discovery.GetHashCode(); + hash ^= (int) formatCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (mediaFile_ != null) { + _single_mediaFile_codec.WriteTagAndValue(output, MediaFile); + } + if (formatCase_ == FormatOneofCase.InStream) { + output.WriteRawTag(18); + output.WriteMessage(InStream); + } + if (formatCase_ == FormatOneofCase.Bumper) { + output.WriteRawTag(26); + output.WriteMessage(Bumper); + } + if (formatCase_ == FormatOneofCase.OutStream) { + output.WriteRawTag(34); + output.WriteMessage(OutStream); + } + if (formatCase_ == FormatOneofCase.NonSkippable) { + output.WriteRawTag(42); + output.WriteMessage(NonSkippable); + } + if (formatCase_ == FormatOneofCase.Discovery) { + output.WriteRawTag(50); + output.WriteMessage(Discovery); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (mediaFile_ != null) { + size += _single_mediaFile_codec.CalculateSizeWithTag(MediaFile); + } + if (formatCase_ == FormatOneofCase.InStream) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(InStream); + } + if (formatCase_ == FormatOneofCase.Bumper) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Bumper); + } + if (formatCase_ == FormatOneofCase.OutStream) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(OutStream); + } + if (formatCase_ == FormatOneofCase.NonSkippable) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(NonSkippable); + } + if (formatCase_ == FormatOneofCase.Discovery) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Discovery); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(VideoAdInfo other) { + if (other == null) { + return; + } + if (other.mediaFile_ != null) { + if (mediaFile_ == null || other.MediaFile != "") { + MediaFile = other.MediaFile; + } + } + switch (other.FormatCase) { + case FormatOneofCase.InStream: + if (InStream == null) { + InStream = new global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewInStreamAdInfo(); + } + InStream.MergeFrom(other.InStream); + break; + case FormatOneofCase.Bumper: + if (Bumper == null) { + Bumper = new global::Google.Ads.GoogleAds.V3.Common.VideoBumperInStreamAdInfo(); + } + Bumper.MergeFrom(other.Bumper); + break; + case FormatOneofCase.OutStream: + if (OutStream == null) { + OutStream = new global::Google.Ads.GoogleAds.V3.Common.VideoOutstreamAdInfo(); + } + OutStream.MergeFrom(other.OutStream); + break; + case FormatOneofCase.NonSkippable: + if (NonSkippable == null) { + NonSkippable = new global::Google.Ads.GoogleAds.V3.Common.VideoNonSkippableInStreamAdInfo(); + } + NonSkippable.MergeFrom(other.NonSkippable); + break; + case FormatOneofCase.Discovery: + if (Discovery == null) { + Discovery = new global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewDiscoveryAdInfo(); + } + Discovery.MergeFrom(other.Discovery); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_mediaFile_codec.Read(input); + if (mediaFile_ == null || value != "") { + MediaFile = value; + } + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewInStreamAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewInStreamAdInfo(); + if (formatCase_ == FormatOneofCase.InStream) { + subBuilder.MergeFrom(InStream); + } + input.ReadMessage(subBuilder); + InStream = subBuilder; + break; + } + case 26: { + global::Google.Ads.GoogleAds.V3.Common.VideoBumperInStreamAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.VideoBumperInStreamAdInfo(); + if (formatCase_ == FormatOneofCase.Bumper) { + subBuilder.MergeFrom(Bumper); + } + input.ReadMessage(subBuilder); + Bumper = subBuilder; + break; + } + case 34: { + global::Google.Ads.GoogleAds.V3.Common.VideoOutstreamAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.VideoOutstreamAdInfo(); + if (formatCase_ == FormatOneofCase.OutStream) { + subBuilder.MergeFrom(OutStream); + } + input.ReadMessage(subBuilder); + OutStream = subBuilder; + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Common.VideoNonSkippableInStreamAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.VideoNonSkippableInStreamAdInfo(); + if (formatCase_ == FormatOneofCase.NonSkippable) { + subBuilder.MergeFrom(NonSkippable); + } + input.ReadMessage(subBuilder); + NonSkippable = subBuilder; + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewDiscoveryAdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.VideoTrueViewDiscoveryAdInfo(); + if (formatCase_ == FormatOneofCase.Discovery) { + subBuilder.MergeFrom(Discovery); + } + input.ReadMessage(subBuilder); + Discovery = subBuilder; + break; + } + } + } + } + + } + + /// + /// A responsive search ad. + /// + /// Responsive search ads let you create an ad that adapts to show more text, and + /// more relevant messages, to your customers. Enter multiple headlines and + /// descriptions when creating a responsive search ad, and over time, Google Ads + /// will automatically test different combinations and learn which combinations + /// perform best. By adapting your ad's content to more closely match potential + /// customers' search terms, responsive search ads may improve your campaign's + /// performance. + /// + /// More information at https://support.google.com/google-ads/answer/7684791 + /// + public sealed partial class ResponsiveSearchAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ResponsiveSearchAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[20]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ResponsiveSearchAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ResponsiveSearchAdInfo(ResponsiveSearchAdInfo other) : this() { + headlines_ = other.headlines_.Clone(); + descriptions_ = other.descriptions_.Clone(); + Path1 = other.Path1; + Path2 = other.Path2; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ResponsiveSearchAdInfo Clone() { + return new ResponsiveSearchAdInfo(this); + } + + /// Field number for the "headlines" field. + public const int HeadlinesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_headlines_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser); + private readonly pbc::RepeatedField headlines_ = new pbc::RepeatedField(); + /// + /// List of text assets for headlines. When the ad serves the headlines will + /// be selected from this list. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Headlines { + get { return headlines_; } + } + + /// Field number for the "descriptions" field. + public const int DescriptionsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_descriptions_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser); + private readonly pbc::RepeatedField descriptions_ = new pbc::RepeatedField(); + /// + /// List of text assets for descriptions. When the ad serves the descriptions + /// will be selected from this list. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Descriptions { + get { return descriptions_; } + } + + /// Field number for the "path1" field. + public const int Path1FieldNumber = 3; + private static readonly pb::FieldCodec _single_path1_codec = pb::FieldCodec.ForClassWrapper(26); + private string path1_; + /// + /// First part of text that may appear appended to the url displayed in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Path1 { + get { return path1_; } + set { + path1_ = value; + } + } + + + /// Field number for the "path2" field. + public const int Path2FieldNumber = 4; + private static readonly pb::FieldCodec _single_path2_codec = pb::FieldCodec.ForClassWrapper(34); + private string path2_; + /// + /// Second part of text that may appear appended to the url displayed in the + /// ad. This field can only be set when path1 is also set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Path2 { + get { return path2_; } + set { + path2_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ResponsiveSearchAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ResponsiveSearchAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!headlines_.Equals(other.headlines_)) return false; + if(!descriptions_.Equals(other.descriptions_)) return false; + if (Path1 != other.Path1) return false; + if (Path2 != other.Path2) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= headlines_.GetHashCode(); + hash ^= descriptions_.GetHashCode(); + if (path1_ != null) hash ^= Path1.GetHashCode(); + if (path2_ != null) hash ^= Path2.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + headlines_.WriteTo(output, _repeated_headlines_codec); + descriptions_.WriteTo(output, _repeated_descriptions_codec); + if (path1_ != null) { + _single_path1_codec.WriteTagAndValue(output, Path1); + } + if (path2_ != null) { + _single_path2_codec.WriteTagAndValue(output, Path2); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += headlines_.CalculateSize(_repeated_headlines_codec); + size += descriptions_.CalculateSize(_repeated_descriptions_codec); + if (path1_ != null) { + size += _single_path1_codec.CalculateSizeWithTag(Path1); + } + if (path2_ != null) { + size += _single_path2_codec.CalculateSizeWithTag(Path2); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ResponsiveSearchAdInfo other) { + if (other == null) { + return; + } + headlines_.Add(other.headlines_); + descriptions_.Add(other.descriptions_); + if (other.path1_ != null) { + if (path1_ == null || other.Path1 != "") { + Path1 = other.Path1; + } + } + if (other.path2_ != null) { + if (path2_ == null || other.Path2 != "") { + Path2 = other.Path2; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + headlines_.AddEntriesFrom(input, _repeated_headlines_codec); + break; + } + case 18: { + descriptions_.AddEntriesFrom(input, _repeated_descriptions_codec); + break; + } + case 26: { + string value = _single_path1_codec.Read(input); + if (path1_ == null || value != "") { + Path1 = value; + } + break; + } + case 34: { + string value = _single_path2_codec.Read(input); + if (path2_ == null || value != "") { + Path2 = value; + } + break; + } + } + } + } + + } + + /// + /// A legacy responsive display ad. Ads of this type are labeled 'Responsive ads' + /// in the Google Ads UI. + /// + public sealed partial class LegacyResponsiveDisplayAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new LegacyResponsiveDisplayAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[21]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LegacyResponsiveDisplayAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LegacyResponsiveDisplayAdInfo(LegacyResponsiveDisplayAdInfo other) : this() { + ShortHeadline = other.ShortHeadline; + LongHeadline = other.LongHeadline; + Description = other.Description; + BusinessName = other.BusinessName; + AllowFlexibleColor = other.AllowFlexibleColor; + AccentColor = other.AccentColor; + MainColor = other.MainColor; + CallToActionText = other.CallToActionText; + LogoImage = other.LogoImage; + SquareLogoImage = other.SquareLogoImage; + MarketingImage = other.MarketingImage; + SquareMarketingImage = other.SquareMarketingImage; + formatSetting_ = other.formatSetting_; + PricePrefix = other.PricePrefix; + PromoText = other.PromoText; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LegacyResponsiveDisplayAdInfo Clone() { + return new LegacyResponsiveDisplayAdInfo(this); + } + + /// Field number for the "short_headline" field. + public const int ShortHeadlineFieldNumber = 1; + private static readonly pb::FieldCodec _single_shortHeadline_codec = pb::FieldCodec.ForClassWrapper(10); + private string shortHeadline_; + /// + /// The short version of the ad's headline. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ShortHeadline { + get { return shortHeadline_; } + set { + shortHeadline_ = value; + } + } + + + /// Field number for the "long_headline" field. + public const int LongHeadlineFieldNumber = 2; + private static readonly pb::FieldCodec _single_longHeadline_codec = pb::FieldCodec.ForClassWrapper(18); + private string longHeadline_; + /// + /// The long version of the ad's headline. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LongHeadline { + get { return longHeadline_; } + set { + longHeadline_ = value; + } + } + + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 3; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(26); + private string description_; + /// + /// The description of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "business_name" field. + public const int BusinessNameFieldNumber = 4; + private static readonly pb::FieldCodec _single_businessName_codec = pb::FieldCodec.ForClassWrapper(34); + private string businessName_; + /// + /// The business name in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessName { + get { return businessName_; } + set { + businessName_ = value; + } + } + + + /// Field number for the "allow_flexible_color" field. + public const int AllowFlexibleColorFieldNumber = 5; + private static readonly pb::FieldCodec _single_allowFlexibleColor_codec = pb::FieldCodec.ForStructWrapper(42); + private bool? allowFlexibleColor_; + /// + /// Advertiser's consent to allow flexible color. When true, the ad may be + /// served with different color if necessary. When false, the ad will be served + /// with the specified colors or a neutral color. + /// The default value is true. + /// Must be true if main_color and accent_color are not set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? AllowFlexibleColor { + get { return allowFlexibleColor_; } + set { + allowFlexibleColor_ = value; + } + } + + + /// Field number for the "accent_color" field. + public const int AccentColorFieldNumber = 6; + private static readonly pb::FieldCodec _single_accentColor_codec = pb::FieldCodec.ForClassWrapper(50); + private string accentColor_; + /// + /// The accent color of the ad in hexadecimal, e.g. #ffffff for white. + /// If one of main_color and accent_color is set, the other is required as + /// well. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AccentColor { + get { return accentColor_; } + set { + accentColor_ = value; + } + } + + + /// Field number for the "main_color" field. + public const int MainColorFieldNumber = 7; + private static readonly pb::FieldCodec _single_mainColor_codec = pb::FieldCodec.ForClassWrapper(58); + private string mainColor_; + /// + /// The main color of the ad in hexadecimal, e.g. #ffffff for white. + /// If one of main_color and accent_color is set, the other is required as + /// well. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MainColor { + get { return mainColor_; } + set { + mainColor_ = value; + } + } + + + /// Field number for the "call_to_action_text" field. + public const int CallToActionTextFieldNumber = 8; + private static readonly pb::FieldCodec _single_callToActionText_codec = pb::FieldCodec.ForClassWrapper(66); + private string callToActionText_; + /// + /// The call-to-action text for the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CallToActionText { + get { return callToActionText_; } + set { + callToActionText_ = value; + } + } + + + /// Field number for the "logo_image" field. + public const int LogoImageFieldNumber = 9; + private static readonly pb::FieldCodec _single_logoImage_codec = pb::FieldCodec.ForClassWrapper(74); + private string logoImage_; + /// + /// The MediaFile resource name of the logo image used in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LogoImage { + get { return logoImage_; } + set { + logoImage_ = value; + } + } + + + /// Field number for the "square_logo_image" field. + public const int SquareLogoImageFieldNumber = 10; + private static readonly pb::FieldCodec _single_squareLogoImage_codec = pb::FieldCodec.ForClassWrapper(82); + private string squareLogoImage_; + /// + /// The MediaFile resource name of the square logo image used in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string SquareLogoImage { + get { return squareLogoImage_; } + set { + squareLogoImage_ = value; + } + } + + + /// Field number for the "marketing_image" field. + public const int MarketingImageFieldNumber = 11; + private static readonly pb::FieldCodec _single_marketingImage_codec = pb::FieldCodec.ForClassWrapper(90); + private string marketingImage_; + /// + /// The MediaFile resource name of the marketing image used in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MarketingImage { + get { return marketingImage_; } + set { + marketingImage_ = value; + } + } + + + /// Field number for the "square_marketing_image" field. + public const int SquareMarketingImageFieldNumber = 12; + private static readonly pb::FieldCodec _single_squareMarketingImage_codec = pb::FieldCodec.ForClassWrapper(98); + private string squareMarketingImage_; + /// + /// The MediaFile resource name of the square marketing image used in the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string SquareMarketingImage { + get { return squareMarketingImage_; } + set { + squareMarketingImage_ = value; + } + } + + + /// Field number for the "format_setting" field. + public const int FormatSettingFieldNumber = 13; + private global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum.Types.DisplayAdFormatSetting formatSetting_ = 0; + /// + /// Specifies which format the ad will be served in. Default is ALL_FORMATS. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum.Types.DisplayAdFormatSetting FormatSetting { + get { return formatSetting_; } + set { + formatSetting_ = value; + } + } + + /// Field number for the "price_prefix" field. + public const int PricePrefixFieldNumber = 14; + private static readonly pb::FieldCodec _single_pricePrefix_codec = pb::FieldCodec.ForClassWrapper(114); + private string pricePrefix_; + /// + /// Prefix before price. E.g. 'as low as'. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PricePrefix { + get { return pricePrefix_; } + set { + pricePrefix_ = value; + } + } + + + /// Field number for the "promo_text" field. + public const int PromoTextFieldNumber = 15; + private static readonly pb::FieldCodec _single_promoText_codec = pb::FieldCodec.ForClassWrapper(122); + private string promoText_; + /// + /// Promotion text used for dyanmic formats of responsive ads. For example + /// 'Free two-day shipping'. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PromoText { + get { return promoText_; } + set { + promoText_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as LegacyResponsiveDisplayAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(LegacyResponsiveDisplayAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ShortHeadline != other.ShortHeadline) return false; + if (LongHeadline != other.LongHeadline) return false; + if (Description != other.Description) return false; + if (BusinessName != other.BusinessName) return false; + if (AllowFlexibleColor != other.AllowFlexibleColor) return false; + if (AccentColor != other.AccentColor) return false; + if (MainColor != other.MainColor) return false; + if (CallToActionText != other.CallToActionText) return false; + if (LogoImage != other.LogoImage) return false; + if (SquareLogoImage != other.SquareLogoImage) return false; + if (MarketingImage != other.MarketingImage) return false; + if (SquareMarketingImage != other.SquareMarketingImage) return false; + if (FormatSetting != other.FormatSetting) return false; + if (PricePrefix != other.PricePrefix) return false; + if (PromoText != other.PromoText) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (shortHeadline_ != null) hash ^= ShortHeadline.GetHashCode(); + if (longHeadline_ != null) hash ^= LongHeadline.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + if (businessName_ != null) hash ^= BusinessName.GetHashCode(); + if (allowFlexibleColor_ != null) hash ^= AllowFlexibleColor.GetHashCode(); + if (accentColor_ != null) hash ^= AccentColor.GetHashCode(); + if (mainColor_ != null) hash ^= MainColor.GetHashCode(); + if (callToActionText_ != null) hash ^= CallToActionText.GetHashCode(); + if (logoImage_ != null) hash ^= LogoImage.GetHashCode(); + if (squareLogoImage_ != null) hash ^= SquareLogoImage.GetHashCode(); + if (marketingImage_ != null) hash ^= MarketingImage.GetHashCode(); + if (squareMarketingImage_ != null) hash ^= SquareMarketingImage.GetHashCode(); + if (FormatSetting != 0) hash ^= FormatSetting.GetHashCode(); + if (pricePrefix_ != null) hash ^= PricePrefix.GetHashCode(); + if (promoText_ != null) hash ^= PromoText.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (shortHeadline_ != null) { + _single_shortHeadline_codec.WriteTagAndValue(output, ShortHeadline); + } + if (longHeadline_ != null) { + _single_longHeadline_codec.WriteTagAndValue(output, LongHeadline); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + if (businessName_ != null) { + _single_businessName_codec.WriteTagAndValue(output, BusinessName); + } + if (allowFlexibleColor_ != null) { + _single_allowFlexibleColor_codec.WriteTagAndValue(output, AllowFlexibleColor); + } + if (accentColor_ != null) { + _single_accentColor_codec.WriteTagAndValue(output, AccentColor); + } + if (mainColor_ != null) { + _single_mainColor_codec.WriteTagAndValue(output, MainColor); + } + if (callToActionText_ != null) { + _single_callToActionText_codec.WriteTagAndValue(output, CallToActionText); + } + if (logoImage_ != null) { + _single_logoImage_codec.WriteTagAndValue(output, LogoImage); + } + if (squareLogoImage_ != null) { + _single_squareLogoImage_codec.WriteTagAndValue(output, SquareLogoImage); + } + if (marketingImage_ != null) { + _single_marketingImage_codec.WriteTagAndValue(output, MarketingImage); + } + if (squareMarketingImage_ != null) { + _single_squareMarketingImage_codec.WriteTagAndValue(output, SquareMarketingImage); + } + if (FormatSetting != 0) { + output.WriteRawTag(104); + output.WriteEnum((int) FormatSetting); + } + if (pricePrefix_ != null) { + _single_pricePrefix_codec.WriteTagAndValue(output, PricePrefix); + } + if (promoText_ != null) { + _single_promoText_codec.WriteTagAndValue(output, PromoText); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (shortHeadline_ != null) { + size += _single_shortHeadline_codec.CalculateSizeWithTag(ShortHeadline); + } + if (longHeadline_ != null) { + size += _single_longHeadline_codec.CalculateSizeWithTag(LongHeadline); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + if (businessName_ != null) { + size += _single_businessName_codec.CalculateSizeWithTag(BusinessName); + } + if (allowFlexibleColor_ != null) { + size += _single_allowFlexibleColor_codec.CalculateSizeWithTag(AllowFlexibleColor); + } + if (accentColor_ != null) { + size += _single_accentColor_codec.CalculateSizeWithTag(AccentColor); + } + if (mainColor_ != null) { + size += _single_mainColor_codec.CalculateSizeWithTag(MainColor); + } + if (callToActionText_ != null) { + size += _single_callToActionText_codec.CalculateSizeWithTag(CallToActionText); + } + if (logoImage_ != null) { + size += _single_logoImage_codec.CalculateSizeWithTag(LogoImage); + } + if (squareLogoImage_ != null) { + size += _single_squareLogoImage_codec.CalculateSizeWithTag(SquareLogoImage); + } + if (marketingImage_ != null) { + size += _single_marketingImage_codec.CalculateSizeWithTag(MarketingImage); + } + if (squareMarketingImage_ != null) { + size += _single_squareMarketingImage_codec.CalculateSizeWithTag(SquareMarketingImage); + } + if (FormatSetting != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) FormatSetting); + } + if (pricePrefix_ != null) { + size += _single_pricePrefix_codec.CalculateSizeWithTag(PricePrefix); + } + if (promoText_ != null) { + size += _single_promoText_codec.CalculateSizeWithTag(PromoText); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(LegacyResponsiveDisplayAdInfo other) { + if (other == null) { + return; + } + if (other.shortHeadline_ != null) { + if (shortHeadline_ == null || other.ShortHeadline != "") { + ShortHeadline = other.ShortHeadline; + } + } + if (other.longHeadline_ != null) { + if (longHeadline_ == null || other.LongHeadline != "") { + LongHeadline = other.LongHeadline; + } + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + if (other.businessName_ != null) { + if (businessName_ == null || other.BusinessName != "") { + BusinessName = other.BusinessName; + } + } + if (other.allowFlexibleColor_ != null) { + if (allowFlexibleColor_ == null || other.AllowFlexibleColor != false) { + AllowFlexibleColor = other.AllowFlexibleColor; + } + } + if (other.accentColor_ != null) { + if (accentColor_ == null || other.AccentColor != "") { + AccentColor = other.AccentColor; + } + } + if (other.mainColor_ != null) { + if (mainColor_ == null || other.MainColor != "") { + MainColor = other.MainColor; + } + } + if (other.callToActionText_ != null) { + if (callToActionText_ == null || other.CallToActionText != "") { + CallToActionText = other.CallToActionText; + } + } + if (other.logoImage_ != null) { + if (logoImage_ == null || other.LogoImage != "") { + LogoImage = other.LogoImage; + } + } + if (other.squareLogoImage_ != null) { + if (squareLogoImage_ == null || other.SquareLogoImage != "") { + SquareLogoImage = other.SquareLogoImage; + } + } + if (other.marketingImage_ != null) { + if (marketingImage_ == null || other.MarketingImage != "") { + MarketingImage = other.MarketingImage; + } + } + if (other.squareMarketingImage_ != null) { + if (squareMarketingImage_ == null || other.SquareMarketingImage != "") { + SquareMarketingImage = other.SquareMarketingImage; + } + } + if (other.FormatSetting != 0) { + FormatSetting = other.FormatSetting; + } + if (other.pricePrefix_ != null) { + if (pricePrefix_ == null || other.PricePrefix != "") { + PricePrefix = other.PricePrefix; + } + } + if (other.promoText_ != null) { + if (promoText_ == null || other.PromoText != "") { + PromoText = other.PromoText; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_shortHeadline_codec.Read(input); + if (shortHeadline_ == null || value != "") { + ShortHeadline = value; + } + break; + } + case 18: { + string value = _single_longHeadline_codec.Read(input); + if (longHeadline_ == null || value != "") { + LongHeadline = value; + } + break; + } + case 26: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 34: { + string value = _single_businessName_codec.Read(input); + if (businessName_ == null || value != "") { + BusinessName = value; + } + break; + } + case 42: { + bool? value = _single_allowFlexibleColor_codec.Read(input); + if (allowFlexibleColor_ == null || value != false) { + AllowFlexibleColor = value; + } + break; + } + case 50: { + string value = _single_accentColor_codec.Read(input); + if (accentColor_ == null || value != "") { + AccentColor = value; + } + break; + } + case 58: { + string value = _single_mainColor_codec.Read(input); + if (mainColor_ == null || value != "") { + MainColor = value; + } + break; + } + case 66: { + string value = _single_callToActionText_codec.Read(input); + if (callToActionText_ == null || value != "") { + CallToActionText = value; + } + break; + } + case 74: { + string value = _single_logoImage_codec.Read(input); + if (logoImage_ == null || value != "") { + LogoImage = value; + } + break; + } + case 82: { + string value = _single_squareLogoImage_codec.Read(input); + if (squareLogoImage_ == null || value != "") { + SquareLogoImage = value; + } + break; + } + case 90: { + string value = _single_marketingImage_codec.Read(input); + if (marketingImage_ == null || value != "") { + MarketingImage = value; + } + break; + } + case 98: { + string value = _single_squareMarketingImage_codec.Read(input); + if (squareMarketingImage_ == null || value != "") { + SquareMarketingImage = value; + } + break; + } + case 104: { + FormatSetting = (global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum.Types.DisplayAdFormatSetting) input.ReadEnum(); + break; + } + case 114: { + string value = _single_pricePrefix_codec.Read(input); + if (pricePrefix_ == null || value != "") { + PricePrefix = value; + } + break; + } + case 122: { + string value = _single_promoText_codec.Read(input); + if (promoText_ == null || value != "") { + PromoText = value; + } + break; + } + } + } + } + + } + + /// + /// An app ad. + /// + public sealed partial class AppAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[22]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppAdInfo(AppAdInfo other) : this() { + mandatoryAdText_ = other.mandatoryAdText_ != null ? other.mandatoryAdText_.Clone() : null; + headlines_ = other.headlines_.Clone(); + descriptions_ = other.descriptions_.Clone(); + images_ = other.images_.Clone(); + youtubeVideos_ = other.youtubeVideos_.Clone(); + html5MediaBundles_ = other.html5MediaBundles_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppAdInfo Clone() { + return new AppAdInfo(this); + } + + /// Field number for the "mandatory_ad_text" field. + public const int MandatoryAdTextFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Common.AdTextAsset mandatoryAdText_; + /// + /// An optional text asset that, if specified, must always be displayed when + /// the ad is served. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AdTextAsset MandatoryAdText { + get { return mandatoryAdText_; } + set { + mandatoryAdText_ = value; + } + } + + /// Field number for the "headlines" field. + public const int HeadlinesFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_headlines_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser); + private readonly pbc::RepeatedField headlines_ = new pbc::RepeatedField(); + /// + /// List of text assets for headlines. When the ad serves the headlines will + /// be selected from this list. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Headlines { + get { return headlines_; } + } + + /// Field number for the "descriptions" field. + public const int DescriptionsFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_descriptions_codec + = pb::FieldCodec.ForMessage(26, global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser); + private readonly pbc::RepeatedField descriptions_ = new pbc::RepeatedField(); + /// + /// List of text assets for descriptions. When the ad serves the descriptions + /// will be selected from this list. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Descriptions { + get { return descriptions_; } + } + + /// Field number for the "images" field. + public const int ImagesFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_images_codec + = pb::FieldCodec.ForMessage(34, global::Google.Ads.GoogleAds.V3.Common.AdImageAsset.Parser); + private readonly pbc::RepeatedField images_ = new pbc::RepeatedField(); + /// + /// List of image assets that may be displayed with the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Images { + get { return images_; } + } + + /// Field number for the "youtube_videos" field. + public const int YoutubeVideosFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_youtubeVideos_codec + = pb::FieldCodec.ForMessage(42, global::Google.Ads.GoogleAds.V3.Common.AdVideoAsset.Parser); + private readonly pbc::RepeatedField youtubeVideos_ = new pbc::RepeatedField(); + /// + /// List of YouTube video assets that may be displayed with the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField YoutubeVideos { + get { return youtubeVideos_; } + } + + /// Field number for the "html5_media_bundles" field. + public const int Html5MediaBundlesFieldNumber = 6; + private static readonly pb::FieldCodec _repeated_html5MediaBundles_codec + = pb::FieldCodec.ForMessage(50, global::Google.Ads.GoogleAds.V3.Common.AdMediaBundleAsset.Parser); + private readonly pbc::RepeatedField html5MediaBundles_ = new pbc::RepeatedField(); + /// + /// List of media bundle assets that may be used with the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Html5MediaBundles { + get { return html5MediaBundles_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(MandatoryAdText, other.MandatoryAdText)) return false; + if(!headlines_.Equals(other.headlines_)) return false; + if(!descriptions_.Equals(other.descriptions_)) return false; + if(!images_.Equals(other.images_)) return false; + if(!youtubeVideos_.Equals(other.youtubeVideos_)) return false; + if(!html5MediaBundles_.Equals(other.html5MediaBundles_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (mandatoryAdText_ != null) hash ^= MandatoryAdText.GetHashCode(); + hash ^= headlines_.GetHashCode(); + hash ^= descriptions_.GetHashCode(); + hash ^= images_.GetHashCode(); + hash ^= youtubeVideos_.GetHashCode(); + hash ^= html5MediaBundles_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (mandatoryAdText_ != null) { + output.WriteRawTag(10); + output.WriteMessage(MandatoryAdText); + } + headlines_.WriteTo(output, _repeated_headlines_codec); + descriptions_.WriteTo(output, _repeated_descriptions_codec); + images_.WriteTo(output, _repeated_images_codec); + youtubeVideos_.WriteTo(output, _repeated_youtubeVideos_codec); + html5MediaBundles_.WriteTo(output, _repeated_html5MediaBundles_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (mandatoryAdText_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MandatoryAdText); + } + size += headlines_.CalculateSize(_repeated_headlines_codec); + size += descriptions_.CalculateSize(_repeated_descriptions_codec); + size += images_.CalculateSize(_repeated_images_codec); + size += youtubeVideos_.CalculateSize(_repeated_youtubeVideos_codec); + size += html5MediaBundles_.CalculateSize(_repeated_html5MediaBundles_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppAdInfo other) { + if (other == null) { + return; + } + if (other.mandatoryAdText_ != null) { + if (mandatoryAdText_ == null) { + MandatoryAdText = new global::Google.Ads.GoogleAds.V3.Common.AdTextAsset(); + } + MandatoryAdText.MergeFrom(other.MandatoryAdText); + } + headlines_.Add(other.headlines_); + descriptions_.Add(other.descriptions_); + images_.Add(other.images_); + youtubeVideos_.Add(other.youtubeVideos_); + html5MediaBundles_.Add(other.html5MediaBundles_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (mandatoryAdText_ == null) { + MandatoryAdText = new global::Google.Ads.GoogleAds.V3.Common.AdTextAsset(); + } + input.ReadMessage(MandatoryAdText); + break; + } + case 18: { + headlines_.AddEntriesFrom(input, _repeated_headlines_codec); + break; + } + case 26: { + descriptions_.AddEntriesFrom(input, _repeated_descriptions_codec); + break; + } + case 34: { + images_.AddEntriesFrom(input, _repeated_images_codec); + break; + } + case 42: { + youtubeVideos_.AddEntriesFrom(input, _repeated_youtubeVideos_codec); + break; + } + case 50: { + html5MediaBundles_.AddEntriesFrom(input, _repeated_html5MediaBundles_codec); + break; + } + } + } + } + + } + + /// + /// App engagement ads allow you to write text encouraging a specific action in + /// the app, like checking in, making a purchase, or booking a flight. + /// They allow you to send users to a specific part of your app where they can + /// find what they're looking for easier and faster. + /// + public sealed partial class AppEngagementAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppEngagementAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[23]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppEngagementAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppEngagementAdInfo(AppEngagementAdInfo other) : this() { + headlines_ = other.headlines_.Clone(); + descriptions_ = other.descriptions_.Clone(); + images_ = other.images_.Clone(); + videos_ = other.videos_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppEngagementAdInfo Clone() { + return new AppEngagementAdInfo(this); + } + + /// Field number for the "headlines" field. + public const int HeadlinesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_headlines_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser); + private readonly pbc::RepeatedField headlines_ = new pbc::RepeatedField(); + /// + /// List of text assets for headlines. When the ad serves the headlines will + /// be selected from this list. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Headlines { + get { return headlines_; } + } + + /// Field number for the "descriptions" field. + public const int DescriptionsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_descriptions_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser); + private readonly pbc::RepeatedField descriptions_ = new pbc::RepeatedField(); + /// + /// List of text assets for descriptions. When the ad serves the descriptions + /// will be selected from this list. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Descriptions { + get { return descriptions_; } + } + + /// Field number for the "images" field. + public const int ImagesFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_images_codec + = pb::FieldCodec.ForMessage(26, global::Google.Ads.GoogleAds.V3.Common.AdImageAsset.Parser); + private readonly pbc::RepeatedField images_ = new pbc::RepeatedField(); + /// + /// List of image assets that may be displayed with the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Images { + get { return images_; } + } + + /// Field number for the "videos" field. + public const int VideosFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_videos_codec + = pb::FieldCodec.ForMessage(34, global::Google.Ads.GoogleAds.V3.Common.AdVideoAsset.Parser); + private readonly pbc::RepeatedField videos_ = new pbc::RepeatedField(); + /// + /// List of video assets that may be displayed with the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Videos { + get { return videos_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppEngagementAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppEngagementAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!headlines_.Equals(other.headlines_)) return false; + if(!descriptions_.Equals(other.descriptions_)) return false; + if(!images_.Equals(other.images_)) return false; + if(!videos_.Equals(other.videos_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= headlines_.GetHashCode(); + hash ^= descriptions_.GetHashCode(); + hash ^= images_.GetHashCode(); + hash ^= videos_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + headlines_.WriteTo(output, _repeated_headlines_codec); + descriptions_.WriteTo(output, _repeated_descriptions_codec); + images_.WriteTo(output, _repeated_images_codec); + videos_.WriteTo(output, _repeated_videos_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += headlines_.CalculateSize(_repeated_headlines_codec); + size += descriptions_.CalculateSize(_repeated_descriptions_codec); + size += images_.CalculateSize(_repeated_images_codec); + size += videos_.CalculateSize(_repeated_videos_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppEngagementAdInfo other) { + if (other == null) { + return; + } + headlines_.Add(other.headlines_); + descriptions_.Add(other.descriptions_); + images_.Add(other.images_); + videos_.Add(other.videos_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + headlines_.AddEntriesFrom(input, _repeated_headlines_codec); + break; + } + case 18: { + descriptions_.AddEntriesFrom(input, _repeated_descriptions_codec); + break; + } + case 26: { + images_.AddEntriesFrom(input, _repeated_images_codec); + break; + } + case 34: { + videos_.AddEntriesFrom(input, _repeated_videos_codec); + break; + } + } + } + } + + } + + /// + /// A legacy app install ad that only can be used by a few select customers. + /// + public sealed partial class LegacyAppInstallAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new LegacyAppInstallAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[24]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LegacyAppInstallAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LegacyAppInstallAdInfo(LegacyAppInstallAdInfo other) : this() { + AppId = other.AppId; + appStore_ = other.appStore_; + Headline = other.Headline; + Description1 = other.Description1; + Description2 = other.Description2; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LegacyAppInstallAdInfo Clone() { + return new LegacyAppInstallAdInfo(this); + } + + /// Field number for the "app_id" field. + public const int AppIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_appId_codec = pb::FieldCodec.ForClassWrapper(10); + private string appId_; + /// + /// The id of the mobile app. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AppId { + get { return appId_; } + set { + appId_ = value; + } + } + + + /// Field number for the "app_store" field. + public const int AppStoreFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.LegacyAppInstallAdAppStoreEnum.Types.LegacyAppInstallAdAppStore appStore_ = 0; + /// + /// The app store the mobile app is available in. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.LegacyAppInstallAdAppStoreEnum.Types.LegacyAppInstallAdAppStore AppStore { + get { return appStore_; } + set { + appStore_ = value; + } + } + + /// Field number for the "headline" field. + public const int HeadlineFieldNumber = 3; + private static readonly pb::FieldCodec _single_headline_codec = pb::FieldCodec.ForClassWrapper(26); + private string headline_; + /// + /// The headline of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline { + get { return headline_; } + set { + headline_ = value; + } + } + + + /// Field number for the "description1" field. + public const int Description1FieldNumber = 4; + private static readonly pb::FieldCodec _single_description1_codec = pb::FieldCodec.ForClassWrapper(34); + private string description1_; + /// + /// The first description line of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description1 { + get { return description1_; } + set { + description1_ = value; + } + } + + + /// Field number for the "description2" field. + public const int Description2FieldNumber = 5; + private static readonly pb::FieldCodec _single_description2_codec = pb::FieldCodec.ForClassWrapper(42); + private string description2_; + /// + /// The second description line of the ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description2 { + get { return description2_; } + set { + description2_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as LegacyAppInstallAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(LegacyAppInstallAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (AppId != other.AppId) return false; + if (AppStore != other.AppStore) return false; + if (Headline != other.Headline) return false; + if (Description1 != other.Description1) return false; + if (Description2 != other.Description2) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (appId_ != null) hash ^= AppId.GetHashCode(); + if (AppStore != 0) hash ^= AppStore.GetHashCode(); + if (headline_ != null) hash ^= Headline.GetHashCode(); + if (description1_ != null) hash ^= Description1.GetHashCode(); + if (description2_ != null) hash ^= Description2.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (appId_ != null) { + _single_appId_codec.WriteTagAndValue(output, AppId); + } + if (AppStore != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) AppStore); + } + if (headline_ != null) { + _single_headline_codec.WriteTagAndValue(output, Headline); + } + if (description1_ != null) { + _single_description1_codec.WriteTagAndValue(output, Description1); + } + if (description2_ != null) { + _single_description2_codec.WriteTagAndValue(output, Description2); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (appId_ != null) { + size += _single_appId_codec.CalculateSizeWithTag(AppId); + } + if (AppStore != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AppStore); + } + if (headline_ != null) { + size += _single_headline_codec.CalculateSizeWithTag(Headline); + } + if (description1_ != null) { + size += _single_description1_codec.CalculateSizeWithTag(Description1); + } + if (description2_ != null) { + size += _single_description2_codec.CalculateSizeWithTag(Description2); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(LegacyAppInstallAdInfo other) { + if (other == null) { + return; + } + if (other.appId_ != null) { + if (appId_ == null || other.AppId != "") { + AppId = other.AppId; + } + } + if (other.AppStore != 0) { + AppStore = other.AppStore; + } + if (other.headline_ != null) { + if (headline_ == null || other.Headline != "") { + Headline = other.Headline; + } + } + if (other.description1_ != null) { + if (description1_ == null || other.Description1 != "") { + Description1 = other.Description1; + } + } + if (other.description2_ != null) { + if (description2_ == null || other.Description2 != "") { + Description2 = other.Description2; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_appId_codec.Read(input); + if (appId_ == null || value != "") { + AppId = value; + } + break; + } + case 16: { + AppStore = (global::Google.Ads.GoogleAds.V3.Enums.LegacyAppInstallAdAppStoreEnum.Types.LegacyAppInstallAdAppStore) input.ReadEnum(); + break; + } + case 26: { + string value = _single_headline_codec.Read(input); + if (headline_ == null || value != "") { + Headline = value; + } + break; + } + case 34: { + string value = _single_description1_codec.Read(input); + if (description1_ == null || value != "") { + Description1 = value; + } + break; + } + case 42: { + string value = _single_description2_codec.Read(input); + if (description2_ == null || value != "") { + Description2 = value; + } + break; + } + } + } + } + + } + + /// + /// A responsive display ad. + /// + public sealed partial class ResponsiveDisplayAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ResponsiveDisplayAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[25]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ResponsiveDisplayAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ResponsiveDisplayAdInfo(ResponsiveDisplayAdInfo other) : this() { + marketingImages_ = other.marketingImages_.Clone(); + squareMarketingImages_ = other.squareMarketingImages_.Clone(); + logoImages_ = other.logoImages_.Clone(); + squareLogoImages_ = other.squareLogoImages_.Clone(); + headlines_ = other.headlines_.Clone(); + longHeadline_ = other.longHeadline_ != null ? other.longHeadline_.Clone() : null; + descriptions_ = other.descriptions_.Clone(); + youtubeVideos_ = other.youtubeVideos_.Clone(); + BusinessName = other.BusinessName; + MainColor = other.MainColor; + AccentColor = other.AccentColor; + AllowFlexibleColor = other.AllowFlexibleColor; + CallToActionText = other.CallToActionText; + PricePrefix = other.PricePrefix; + PromoText = other.PromoText; + formatSetting_ = other.formatSetting_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ResponsiveDisplayAdInfo Clone() { + return new ResponsiveDisplayAdInfo(this); + } + + /// Field number for the "marketing_images" field. + public const int MarketingImagesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_marketingImages_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Common.AdImageAsset.Parser); + private readonly pbc::RepeatedField marketingImages_ = new pbc::RepeatedField(); + /// + /// Marketing images to be used in the ad. Valid image types are GIF, + /// JPEG, and PNG. The minimum size is 600x314 and the aspect ratio must + /// be 1.91:1 (+-1%). At least one marketing_image is required. Combined with + /// square_marketing_images the maximum is 15. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField MarketingImages { + get { return marketingImages_; } + } + + /// Field number for the "square_marketing_images" field. + public const int SquareMarketingImagesFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_squareMarketingImages_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Common.AdImageAsset.Parser); + private readonly pbc::RepeatedField squareMarketingImages_ = new pbc::RepeatedField(); + /// + /// Square marketing images to be used in the ad. Valid image types are GIF, + /// JPEG, and PNG. The minimum size is 300x300 and the aspect ratio must + /// be 1:1 (+-1%). At least one square marketing_image is required. Combined + /// with marketing_images the maximum is 15. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField SquareMarketingImages { + get { return squareMarketingImages_; } + } + + /// Field number for the "logo_images" field. + public const int LogoImagesFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_logoImages_codec + = pb::FieldCodec.ForMessage(26, global::Google.Ads.GoogleAds.V3.Common.AdImageAsset.Parser); + private readonly pbc::RepeatedField logoImages_ = new pbc::RepeatedField(); + /// + /// Logo images to be used in the ad. Valid image types are GIF, + /// JPEG, and PNG. The minimum size is 512x128 and the aspect ratio must + /// be 4:1 (+-1%). Combined with square_logo_images the maximum is 5. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField LogoImages { + get { return logoImages_; } + } + + /// Field number for the "square_logo_images" field. + public const int SquareLogoImagesFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_squareLogoImages_codec + = pb::FieldCodec.ForMessage(34, global::Google.Ads.GoogleAds.V3.Common.AdImageAsset.Parser); + private readonly pbc::RepeatedField squareLogoImages_ = new pbc::RepeatedField(); + /// + /// Square logo images to be used in the ad. Valid image types are GIF, + /// JPEG, and PNG. The minimum size is 128x128 and the aspect ratio must + /// be 1:1 (+-1%). Combined with square_logo_images the maximum is 5. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField SquareLogoImages { + get { return squareLogoImages_; } + } + + /// Field number for the "headlines" field. + public const int HeadlinesFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_headlines_codec + = pb::FieldCodec.ForMessage(42, global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser); + private readonly pbc::RepeatedField headlines_ = new pbc::RepeatedField(); + /// + /// Short format headlines for the ad. The maximum length is 30 characters. + /// At least 1 and max 5 headlines can be specified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Headlines { + get { return headlines_; } + } + + /// Field number for the "long_headline" field. + public const int LongHeadlineFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Common.AdTextAsset longHeadline_; + /// + /// A required long format headline. The maximum length is 90 characters. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AdTextAsset LongHeadline { + get { return longHeadline_; } + set { + longHeadline_ = value; + } + } + + /// Field number for the "descriptions" field. + public const int DescriptionsFieldNumber = 7; + private static readonly pb::FieldCodec _repeated_descriptions_codec + = pb::FieldCodec.ForMessage(58, global::Google.Ads.GoogleAds.V3.Common.AdTextAsset.Parser); + private readonly pbc::RepeatedField descriptions_ = new pbc::RepeatedField(); + /// + /// Descriptive texts for the ad. The maximum length is 90 characters. At + /// least 1 and max 5 headlines can be specified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Descriptions { + get { return descriptions_; } + } + + /// Field number for the "youtube_videos" field. + public const int YoutubeVideosFieldNumber = 8; + private static readonly pb::FieldCodec _repeated_youtubeVideos_codec + = pb::FieldCodec.ForMessage(66, global::Google.Ads.GoogleAds.V3.Common.AdVideoAsset.Parser); + private readonly pbc::RepeatedField youtubeVideos_ = new pbc::RepeatedField(); + /// + /// Optional YouTube videos for the ad. A maximum of 5 videos can be specified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField YoutubeVideos { + get { return youtubeVideos_; } + } + + /// Field number for the "business_name" field. + public const int BusinessNameFieldNumber = 9; + private static readonly pb::FieldCodec _single_businessName_codec = pb::FieldCodec.ForClassWrapper(74); + private string businessName_; + /// + /// The advertiser/brand name. Maximum display width is 25. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessName { + get { return businessName_; } + set { + businessName_ = value; + } + } + + + /// Field number for the "main_color" field. + public const int MainColorFieldNumber = 10; + private static readonly pb::FieldCodec _single_mainColor_codec = pb::FieldCodec.ForClassWrapper(82); + private string mainColor_; + /// + /// The main color of the ad in hexadecimal, e.g. #ffffff for white. + /// If one of main_color and accent_color is set, the other is required as + /// well. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MainColor { + get { return mainColor_; } + set { + mainColor_ = value; + } + } + + + /// Field number for the "accent_color" field. + public const int AccentColorFieldNumber = 11; + private static readonly pb::FieldCodec _single_accentColor_codec = pb::FieldCodec.ForClassWrapper(90); + private string accentColor_; + /// + /// The accent color of the ad in hexadecimal, e.g. #ffffff for white. + /// If one of main_color and accent_color is set, the other is required as + /// well. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AccentColor { + get { return accentColor_; } + set { + accentColor_ = value; + } + } + + + /// Field number for the "allow_flexible_color" field. + public const int AllowFlexibleColorFieldNumber = 12; + private static readonly pb::FieldCodec _single_allowFlexibleColor_codec = pb::FieldCodec.ForStructWrapper(98); + private bool? allowFlexibleColor_; + /// + /// Advertiser's consent to allow flexible color. When true, the ad may be + /// served with different color if necessary. When false, the ad will be served + /// with the specified colors or a neutral color. + /// The default value is true. + /// Must be true if main_color and accent_color are not set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? AllowFlexibleColor { + get { return allowFlexibleColor_; } + set { + allowFlexibleColor_ = value; + } + } + + + /// Field number for the "call_to_action_text" field. + public const int CallToActionTextFieldNumber = 13; + private static readonly pb::FieldCodec _single_callToActionText_codec = pb::FieldCodec.ForClassWrapper(106); + private string callToActionText_; + /// + /// The call-to-action text for the ad. Maximum display width is 30. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CallToActionText { + get { return callToActionText_; } + set { + callToActionText_ = value; + } + } + + + /// Field number for the "price_prefix" field. + public const int PricePrefixFieldNumber = 14; + private static readonly pb::FieldCodec _single_pricePrefix_codec = pb::FieldCodec.ForClassWrapper(114); + private string pricePrefix_; + /// + /// Prefix before price. E.g. 'as low as'. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PricePrefix { + get { return pricePrefix_; } + set { + pricePrefix_ = value; + } + } + + + /// Field number for the "promo_text" field. + public const int PromoTextFieldNumber = 15; + private static readonly pb::FieldCodec _single_promoText_codec = pb::FieldCodec.ForClassWrapper(122); + private string promoText_; + /// + /// Promotion text used for dyanmic formats of responsive ads. For example + /// 'Free two-day shipping'. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PromoText { + get { return promoText_; } + set { + promoText_ = value; + } + } + + + /// Field number for the "format_setting" field. + public const int FormatSettingFieldNumber = 16; + private global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum.Types.DisplayAdFormatSetting formatSetting_ = 0; + /// + /// Specifies which format the ad will be served in. Default is ALL_FORMATS. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum.Types.DisplayAdFormatSetting FormatSetting { + get { return formatSetting_; } + set { + formatSetting_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ResponsiveDisplayAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ResponsiveDisplayAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!marketingImages_.Equals(other.marketingImages_)) return false; + if(!squareMarketingImages_.Equals(other.squareMarketingImages_)) return false; + if(!logoImages_.Equals(other.logoImages_)) return false; + if(!squareLogoImages_.Equals(other.squareLogoImages_)) return false; + if(!headlines_.Equals(other.headlines_)) return false; + if (!object.Equals(LongHeadline, other.LongHeadline)) return false; + if(!descriptions_.Equals(other.descriptions_)) return false; + if(!youtubeVideos_.Equals(other.youtubeVideos_)) return false; + if (BusinessName != other.BusinessName) return false; + if (MainColor != other.MainColor) return false; + if (AccentColor != other.AccentColor) return false; + if (AllowFlexibleColor != other.AllowFlexibleColor) return false; + if (CallToActionText != other.CallToActionText) return false; + if (PricePrefix != other.PricePrefix) return false; + if (PromoText != other.PromoText) return false; + if (FormatSetting != other.FormatSetting) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= marketingImages_.GetHashCode(); + hash ^= squareMarketingImages_.GetHashCode(); + hash ^= logoImages_.GetHashCode(); + hash ^= squareLogoImages_.GetHashCode(); + hash ^= headlines_.GetHashCode(); + if (longHeadline_ != null) hash ^= LongHeadline.GetHashCode(); + hash ^= descriptions_.GetHashCode(); + hash ^= youtubeVideos_.GetHashCode(); + if (businessName_ != null) hash ^= BusinessName.GetHashCode(); + if (mainColor_ != null) hash ^= MainColor.GetHashCode(); + if (accentColor_ != null) hash ^= AccentColor.GetHashCode(); + if (allowFlexibleColor_ != null) hash ^= AllowFlexibleColor.GetHashCode(); + if (callToActionText_ != null) hash ^= CallToActionText.GetHashCode(); + if (pricePrefix_ != null) hash ^= PricePrefix.GetHashCode(); + if (promoText_ != null) hash ^= PromoText.GetHashCode(); + if (FormatSetting != 0) hash ^= FormatSetting.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + marketingImages_.WriteTo(output, _repeated_marketingImages_codec); + squareMarketingImages_.WriteTo(output, _repeated_squareMarketingImages_codec); + logoImages_.WriteTo(output, _repeated_logoImages_codec); + squareLogoImages_.WriteTo(output, _repeated_squareLogoImages_codec); + headlines_.WriteTo(output, _repeated_headlines_codec); + if (longHeadline_ != null) { + output.WriteRawTag(50); + output.WriteMessage(LongHeadline); + } + descriptions_.WriteTo(output, _repeated_descriptions_codec); + youtubeVideos_.WriteTo(output, _repeated_youtubeVideos_codec); + if (businessName_ != null) { + _single_businessName_codec.WriteTagAndValue(output, BusinessName); + } + if (mainColor_ != null) { + _single_mainColor_codec.WriteTagAndValue(output, MainColor); + } + if (accentColor_ != null) { + _single_accentColor_codec.WriteTagAndValue(output, AccentColor); + } + if (allowFlexibleColor_ != null) { + _single_allowFlexibleColor_codec.WriteTagAndValue(output, AllowFlexibleColor); + } + if (callToActionText_ != null) { + _single_callToActionText_codec.WriteTagAndValue(output, CallToActionText); + } + if (pricePrefix_ != null) { + _single_pricePrefix_codec.WriteTagAndValue(output, PricePrefix); + } + if (promoText_ != null) { + _single_promoText_codec.WriteTagAndValue(output, PromoText); + } + if (FormatSetting != 0) { + output.WriteRawTag(128, 1); + output.WriteEnum((int) FormatSetting); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += marketingImages_.CalculateSize(_repeated_marketingImages_codec); + size += squareMarketingImages_.CalculateSize(_repeated_squareMarketingImages_codec); + size += logoImages_.CalculateSize(_repeated_logoImages_codec); + size += squareLogoImages_.CalculateSize(_repeated_squareLogoImages_codec); + size += headlines_.CalculateSize(_repeated_headlines_codec); + if (longHeadline_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(LongHeadline); + } + size += descriptions_.CalculateSize(_repeated_descriptions_codec); + size += youtubeVideos_.CalculateSize(_repeated_youtubeVideos_codec); + if (businessName_ != null) { + size += _single_businessName_codec.CalculateSizeWithTag(BusinessName); + } + if (mainColor_ != null) { + size += _single_mainColor_codec.CalculateSizeWithTag(MainColor); + } + if (accentColor_ != null) { + size += _single_accentColor_codec.CalculateSizeWithTag(AccentColor); + } + if (allowFlexibleColor_ != null) { + size += _single_allowFlexibleColor_codec.CalculateSizeWithTag(AllowFlexibleColor); + } + if (callToActionText_ != null) { + size += _single_callToActionText_codec.CalculateSizeWithTag(CallToActionText); + } + if (pricePrefix_ != null) { + size += _single_pricePrefix_codec.CalculateSizeWithTag(PricePrefix); + } + if (promoText_ != null) { + size += _single_promoText_codec.CalculateSizeWithTag(PromoText); + } + if (FormatSetting != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FormatSetting); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ResponsiveDisplayAdInfo other) { + if (other == null) { + return; + } + marketingImages_.Add(other.marketingImages_); + squareMarketingImages_.Add(other.squareMarketingImages_); + logoImages_.Add(other.logoImages_); + squareLogoImages_.Add(other.squareLogoImages_); + headlines_.Add(other.headlines_); + if (other.longHeadline_ != null) { + if (longHeadline_ == null) { + LongHeadline = new global::Google.Ads.GoogleAds.V3.Common.AdTextAsset(); + } + LongHeadline.MergeFrom(other.LongHeadline); + } + descriptions_.Add(other.descriptions_); + youtubeVideos_.Add(other.youtubeVideos_); + if (other.businessName_ != null) { + if (businessName_ == null || other.BusinessName != "") { + BusinessName = other.BusinessName; + } + } + if (other.mainColor_ != null) { + if (mainColor_ == null || other.MainColor != "") { + MainColor = other.MainColor; + } + } + if (other.accentColor_ != null) { + if (accentColor_ == null || other.AccentColor != "") { + AccentColor = other.AccentColor; + } + } + if (other.allowFlexibleColor_ != null) { + if (allowFlexibleColor_ == null || other.AllowFlexibleColor != false) { + AllowFlexibleColor = other.AllowFlexibleColor; + } + } + if (other.callToActionText_ != null) { + if (callToActionText_ == null || other.CallToActionText != "") { + CallToActionText = other.CallToActionText; + } + } + if (other.pricePrefix_ != null) { + if (pricePrefix_ == null || other.PricePrefix != "") { + PricePrefix = other.PricePrefix; + } + } + if (other.promoText_ != null) { + if (promoText_ == null || other.PromoText != "") { + PromoText = other.PromoText; + } + } + if (other.FormatSetting != 0) { + FormatSetting = other.FormatSetting; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + marketingImages_.AddEntriesFrom(input, _repeated_marketingImages_codec); + break; + } + case 18: { + squareMarketingImages_.AddEntriesFrom(input, _repeated_squareMarketingImages_codec); + break; + } + case 26: { + logoImages_.AddEntriesFrom(input, _repeated_logoImages_codec); + break; + } + case 34: { + squareLogoImages_.AddEntriesFrom(input, _repeated_squareLogoImages_codec); + break; + } + case 42: { + headlines_.AddEntriesFrom(input, _repeated_headlines_codec); + break; + } + case 50: { + if (longHeadline_ == null) { + LongHeadline = new global::Google.Ads.GoogleAds.V3.Common.AdTextAsset(); + } + input.ReadMessage(LongHeadline); + break; + } + case 58: { + descriptions_.AddEntriesFrom(input, _repeated_descriptions_codec); + break; + } + case 66: { + youtubeVideos_.AddEntriesFrom(input, _repeated_youtubeVideos_codec); + break; + } + case 74: { + string value = _single_businessName_codec.Read(input); + if (businessName_ == null || value != "") { + BusinessName = value; + } + break; + } + case 82: { + string value = _single_mainColor_codec.Read(input); + if (mainColor_ == null || value != "") { + MainColor = value; + } + break; + } + case 90: { + string value = _single_accentColor_codec.Read(input); + if (accentColor_ == null || value != "") { + AccentColor = value; + } + break; + } + case 98: { + bool? value = _single_allowFlexibleColor_codec.Read(input); + if (allowFlexibleColor_ == null || value != false) { + AllowFlexibleColor = value; + } + break; + } + case 106: { + string value = _single_callToActionText_codec.Read(input); + if (callToActionText_ == null || value != "") { + CallToActionText = value; + } + break; + } + case 114: { + string value = _single_pricePrefix_codec.Read(input); + if (pricePrefix_ == null || value != "") { + PricePrefix = value; + } + break; + } + case 122: { + string value = _single_promoText_codec.Read(input); + if (promoText_ == null || value != "") { + PromoText = value; + } + break; + } + case 128: { + FormatSetting = (global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum.Types.DisplayAdFormatSetting) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A generic type of display ad. The exact ad format is controlled by the + /// display_upload_product_type field, which determines what kinds of data + /// need to be included with the ad. + /// + public sealed partial class DisplayUploadAdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DisplayUploadAdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AdTypeInfosReflection.Descriptor.MessageTypes[26]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayUploadAdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayUploadAdInfo(DisplayUploadAdInfo other) : this() { + displayUploadProductType_ = other.displayUploadProductType_; + switch (other.MediaAssetCase) { + case MediaAssetOneofCase.MediaBundle: + MediaBundle = other.MediaBundle.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayUploadAdInfo Clone() { + return new DisplayUploadAdInfo(this); + } + + /// Field number for the "display_upload_product_type" field. + public const int DisplayUploadProductTypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.DisplayUploadProductTypeEnum.Types.DisplayUploadProductType displayUploadProductType_ = 0; + /// + /// The product type of this ad. See comments on the enum for details. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DisplayUploadProductTypeEnum.Types.DisplayUploadProductType DisplayUploadProductType { + get { return displayUploadProductType_; } + set { + displayUploadProductType_ = value; + } + } + + /// Field number for the "media_bundle" field. + public const int MediaBundleFieldNumber = 2; + /// + /// A media bundle asset to be used in the ad. For information about the + /// media bundle for HTML5_UPLOAD_AD see + /// https://support.google.com/google-ads/answer/1722096 + /// Media bundles that are part of dynamic product types use a special format + /// that needs to be created through the Google Web Designer. See + /// https://support.google.com/webdesigner/answer/7543898 for more + /// information. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AdMediaBundleAsset MediaBundle { + get { return mediaAssetCase_ == MediaAssetOneofCase.MediaBundle ? (global::Google.Ads.GoogleAds.V3.Common.AdMediaBundleAsset) mediaAsset_ : null; } + set { + mediaAsset_ = value; + mediaAssetCase_ = value == null ? MediaAssetOneofCase.None : MediaAssetOneofCase.MediaBundle; + } + } + + private object mediaAsset_; + /// Enum of possible cases for the "media_asset" oneof. + public enum MediaAssetOneofCase { + None = 0, + MediaBundle = 2, + } + private MediaAssetOneofCase mediaAssetCase_ = MediaAssetOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MediaAssetOneofCase MediaAssetCase { + get { return mediaAssetCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearMediaAsset() { + mediaAssetCase_ = MediaAssetOneofCase.None; + mediaAsset_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DisplayUploadAdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DisplayUploadAdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (DisplayUploadProductType != other.DisplayUploadProductType) return false; + if (!object.Equals(MediaBundle, other.MediaBundle)) return false; + if (MediaAssetCase != other.MediaAssetCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (DisplayUploadProductType != 0) hash ^= DisplayUploadProductType.GetHashCode(); + if (mediaAssetCase_ == MediaAssetOneofCase.MediaBundle) hash ^= MediaBundle.GetHashCode(); + hash ^= (int) mediaAssetCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (DisplayUploadProductType != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) DisplayUploadProductType); + } + if (mediaAssetCase_ == MediaAssetOneofCase.MediaBundle) { + output.WriteRawTag(18); + output.WriteMessage(MediaBundle); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (DisplayUploadProductType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DisplayUploadProductType); + } + if (mediaAssetCase_ == MediaAssetOneofCase.MediaBundle) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MediaBundle); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DisplayUploadAdInfo other) { + if (other == null) { + return; + } + if (other.DisplayUploadProductType != 0) { + DisplayUploadProductType = other.DisplayUploadProductType; + } + switch (other.MediaAssetCase) { + case MediaAssetOneofCase.MediaBundle: + if (MediaBundle == null) { + MediaBundle = new global::Google.Ads.GoogleAds.V3.Common.AdMediaBundleAsset(); + } + MediaBundle.MergeFrom(other.MediaBundle); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + DisplayUploadProductType = (global::Google.Ads.GoogleAds.V3.Enums.DisplayUploadProductTypeEnum.Types.DisplayUploadProductType) input.ReadEnum(); + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Common.AdMediaBundleAsset subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AdMediaBundleAsset(); + if (mediaAssetCase_ == MediaAssetOneofCase.MediaBundle) { + subBuilder.MergeFrom(MediaBundle); + } + input.ReadMessage(subBuilder); + MediaBundle = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdvertisingChannelSubType.cs b/src/V3/Stubs/AdvertisingChannelSubType.cs new file mode 100644 index 000000000..9cb99285f --- /dev/null +++ b/src/V3/Stubs/AdvertisingChannelSubType.cs @@ -0,0 +1,240 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/advertising_channel_sub_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/advertising_channel_sub_type.proto + public static partial class AdvertisingChannelSubTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/advertising_channel_sub_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdvertisingChannelSubTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZHZlcnRpc2luZ19j", + "aGFubmVsX3N1Yl90eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKVAwodQWR2", + "ZXJ0aXNpbmdDaGFubmVsU3ViVHlwZUVudW0i8wIKGUFkdmVydGlzaW5nQ2hh", + "bm5lbFN1YlR5cGUSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESFQoR", + "U0VBUkNIX01PQklMRV9BUFAQAhIWChJESVNQTEFZX01PQklMRV9BUFAQAxIS", + "Cg5TRUFSQ0hfRVhQUkVTUxAEEhMKD0RJU1BMQVlfRVhQUkVTUxAFEhYKElNI", + "T1BQSU5HX1NNQVJUX0FEUxAGEhQKEERJU1BMQVlfR01BSUxfQUQQBxIaChZE", + "SVNQTEFZX1NNQVJUX0NBTVBBSUdOEAgSEwoPVklERU9fT1VUU1RSRUFNEAkS", + "EAoMVklERU9fQUNUSU9OEAoSFwoTVklERU9fTk9OX1NLSVBQQUJMRRALEhAK", + "DEFQUF9DQU1QQUlHThAMEh8KG0FQUF9DQU1QQUlHTl9GT1JfRU5HQUdFTUVO", + "VBANEiMKH1NIT1BQSU5HX0NPTVBBUklTT05fTElTVElOR19BRFMQD0LzAQoh", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQh5BZHZlcnRpc2lu", + "Z0NoYW5uZWxTdWJUeXBlUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2Vu", + "cHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1z", + "ogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29n", + "bGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Types.AdvertisingChannelSubType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// An immutable specialization of an Advertising Channel. + /// + public sealed partial class AdvertisingChannelSubTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdvertisingChannelSubTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdvertisingChannelSubTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdvertisingChannelSubTypeEnum(AdvertisingChannelSubTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdvertisingChannelSubTypeEnum Clone() { + return new AdvertisingChannelSubTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdvertisingChannelSubTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdvertisingChannelSubTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdvertisingChannelSubTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdvertisingChannelSubTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing the different channel subtypes. + /// + public enum AdvertisingChannelSubType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used as a return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Mobile app campaigns for Search. + /// + [pbr::OriginalName("SEARCH_MOBILE_APP")] SearchMobileApp = 2, + /// + /// Mobile app campaigns for Display. + /// + [pbr::OriginalName("DISPLAY_MOBILE_APP")] DisplayMobileApp = 3, + /// + /// AdWords express campaigns for search. + /// + [pbr::OriginalName("SEARCH_EXPRESS")] SearchExpress = 4, + /// + /// AdWords Express campaigns for display. + /// + [pbr::OriginalName("DISPLAY_EXPRESS")] DisplayExpress = 5, + /// + /// Smart Shopping campaigns. + /// + [pbr::OriginalName("SHOPPING_SMART_ADS")] ShoppingSmartAds = 6, + /// + /// Gmail Ad campaigns. + /// + [pbr::OriginalName("DISPLAY_GMAIL_AD")] DisplayGmailAd = 7, + /// + /// Smart display campaigns. + /// + [pbr::OriginalName("DISPLAY_SMART_CAMPAIGN")] DisplaySmartCampaign = 8, + /// + /// Video Outstream campaigns. + /// + [pbr::OriginalName("VIDEO_OUTSTREAM")] VideoOutstream = 9, + /// + /// Video TrueView for Action campaigns. + /// + [pbr::OriginalName("VIDEO_ACTION")] VideoAction = 10, + /// + /// Video campaigns with non-skippable video ads. + /// + [pbr::OriginalName("VIDEO_NON_SKIPPABLE")] VideoNonSkippable = 11, + /// + /// App Campaign that allows you to easily promote your Android or iOS app + /// across Google's top properties including Search, Play, YouTube, and the + /// Google Display Network. + /// + [pbr::OriginalName("APP_CAMPAIGN")] AppCampaign = 12, + /// + /// App Campaign for engagement, focused on driving re-engagement with the + /// app across several of Google’s top properties including Search, YouTube, + /// and the Google Display Network. + /// + [pbr::OriginalName("APP_CAMPAIGN_FOR_ENGAGEMENT")] AppCampaignForEngagement = 13, + /// + /// Shopping Comparison Listing campaigns. + /// + [pbr::OriginalName("SHOPPING_COMPARISON_LISTING_ADS")] ShoppingComparisonListingAds = 15, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdvertisingChannelType.cs b/src/V3/Stubs/AdvertisingChannelType.cs new file mode 100644 index 000000000..5705e6e5d --- /dev/null +++ b/src/V3/Stubs/AdvertisingChannelType.cs @@ -0,0 +1,205 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/advertising_channel_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/advertising_channel_type.proto + public static partial class AdvertisingChannelTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/advertising_channel_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdvertisingChannelTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZHZlcnRpc2luZ19j", + "aGFubmVsX3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIqUBChpBZHZlcnRp", + "c2luZ0NoYW5uZWxUeXBlRW51bSKGAQoWQWR2ZXJ0aXNpbmdDaGFubmVsVHlw", + "ZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIKCgZTRUFSQ0gQAhIL", + "CgdESVNQTEFZEAMSDAoIU0hPUFBJTkcQBBIJCgVIT1RFTBAFEgkKBVZJREVP", + "EAYSEQoNTVVMVElfQ0hBTk5FTBAHQvABCiFjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXNCG0FkdmVydGlzaW5nQ2hhbm5lbFR5cGVQcm90b1AB", + "WkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVu", + "dW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// The channel type a campaign may target to serve on. + /// + public sealed partial class AdvertisingChannelTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdvertisingChannelTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdvertisingChannelTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdvertisingChannelTypeEnum(AdvertisingChannelTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdvertisingChannelTypeEnum Clone() { + return new AdvertisingChannelTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdvertisingChannelTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdvertisingChannelTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdvertisingChannelTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdvertisingChannelTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing the various advertising channel types. + /// + public enum AdvertisingChannelType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Search Network. Includes display bundled, and Search+ campaigns. + /// + [pbr::OriginalName("SEARCH")] Search = 2, + /// + /// Google Display Network only. + /// + [pbr::OriginalName("DISPLAY")] Display = 3, + /// + /// Shopping campaigns serve on the shopping property + /// and on google.com search results. + /// + [pbr::OriginalName("SHOPPING")] Shopping = 4, + /// + /// Hotel Ads campaigns. + /// + [pbr::OriginalName("HOTEL")] Hotel = 5, + /// + /// Video campaigns. + /// + [pbr::OriginalName("VIDEO")] Video = 6, + /// + /// App Campaigns, and App Campaigns for Engagement, that run + /// across multiple channels. + /// + [pbr::OriginalName("MULTI_CHANNEL")] MultiChannel = 7, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AdxError.cs b/src/V3/Stubs/AdxError.cs new file mode 100644 index 000000000..d101a387d --- /dev/null +++ b/src/V3/Stubs/AdxError.cs @@ -0,0 +1,180 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/adx_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/adx_error.proto + public static partial class AdxErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/adx_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AdxErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWR4X2Vycm9yLnBy", + "b3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMaHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8iUQoMQWR4RXJyb3JFbnVtIkEKCEFkeEVy", + "cm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhcKE1VOU1VQUE9S", + "VEVEX0ZFQVRVUkUQAkLoAQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9yc0INQWR4RXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9n", + "ZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vy", + "cm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oC", + "Hkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AdxErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AdxErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AdxErrorEnum.Types.AdxError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible adx errors. + /// + public sealed partial class AdxErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdxErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AdxErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdxErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdxErrorEnum(AdxErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdxErrorEnum Clone() { + return new AdxErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdxErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdxErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdxErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AdxErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible adx errors. + /// + public enum AdxError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Attempt to use non-AdX feature by AdX customer. + /// + [pbr::OriginalName("UNSUPPORTED_FEATURE")] UnsupportedFeature = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AffiliateLocationFeedRelationshipType.cs b/src/V3/Stubs/AffiliateLocationFeedRelationshipType.cs new file mode 100644 index 000000000..46a30779f --- /dev/null +++ b/src/V3/Stubs/AffiliateLocationFeedRelationshipType.cs @@ -0,0 +1,184 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/affiliate_location_feed_relationship_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/affiliate_location_feed_relationship_type.proto + public static partial class AffiliateLocationFeedRelationshipTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/affiliate_location_feed_relationship_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AffiliateLocationFeedRelationshipTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ck1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZmZpbGlhdGVfbG9j", + "YXRpb25fZmVlZF9yZWxhdGlvbnNoaXBfdHlwZS5wcm90bxIdZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMu", + "cHJvdG8iiAEKKUFmZmlsaWF0ZUxvY2F0aW9uRmVlZFJlbGF0aW9uc2hpcFR5", + "cGVFbnVtIlsKJUFmZmlsaWF0ZUxvY2F0aW9uRmVlZFJlbGF0aW9uc2hpcFR5", + "cGUSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESFAoQR0VORVJBTF9S", + "RVRBSUxFUhACQv8BCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXNCKkFmZmlsaWF0ZUxvY2F0aW9uRmVlZFJlbGF0aW9uc2hpcFR5cGVQcm90", + "b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRz", + "Lkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYz", + "XEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZw", + "cm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationFeedRelationshipTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationFeedRelationshipTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationFeedRelationshipTypeEnum.Types.AffiliateLocationFeedRelationshipType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible values for a relationship type for + /// an affiliate location feed. + /// + public sealed partial class AffiliateLocationFeedRelationshipTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AffiliateLocationFeedRelationshipTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationFeedRelationshipTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedRelationshipTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedRelationshipTypeEnum(AffiliateLocationFeedRelationshipTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedRelationshipTypeEnum Clone() { + return new AffiliateLocationFeedRelationshipTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AffiliateLocationFeedRelationshipTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AffiliateLocationFeedRelationshipTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AffiliateLocationFeedRelationshipTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AffiliateLocationFeedRelationshipTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for a relationship type for an affiliate location feed. + /// + public enum AffiliateLocationFeedRelationshipType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// General retailer relationship. + /// + [pbr::OriginalName("GENERAL_RETAILER")] GeneralRetailer = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AffiliateLocationPlaceholderField.cs b/src/V3/Stubs/AffiliateLocationPlaceholderField.cs new file mode 100644 index 000000000..49ca498f7 --- /dev/null +++ b/src/V3/Stubs/AffiliateLocationPlaceholderField.cs @@ -0,0 +1,226 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/affiliate_location_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/affiliate_location_placeholder_field.proto + public static partial class AffiliateLocationPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/affiliate_location_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AffiliateLocationPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZmZpbGlhdGVfbG9j", + "YXRpb25fcGxhY2Vob2xkZXJfZmllbGQucHJvdG8SHWdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3Rv", + "IqQCCiVBZmZpbGlhdGVMb2NhdGlvblBsYWNlaG9sZGVyRmllbGRFbnVtIvoB", + "CiFBZmZpbGlhdGVMb2NhdGlvblBsYWNlaG9sZGVyRmllbGQSDwoLVU5TUEVD", + "SUZJRUQQABILCgdVTktOT1dOEAESEQoNQlVTSU5FU1NfTkFNRRACEhIKDkFE", + "RFJFU1NfTElORV8xEAMSEgoOQUREUkVTU19MSU5FXzIQBBIICgRDSVRZEAUS", + "DAoIUFJPVklOQ0UQBhIPCgtQT1NUQUxfQ09ERRAHEhAKDENPVU5UUllfQ09E", + "RRAIEhAKDFBIT05FX05VTUJFUhAJEhEKDUxBTkdVQUdFX0NPREUQChIMCghD", + "SEFJTl9JRBALEg4KCkNIQUlOX05BTUUQDEL7AQohY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zQiZBZmZpbGlhdGVMb2NhdGlvblBsYWNlaG9s", + "ZGVyRmllbGRQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9n", + "b29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGq", + "Ah1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNc", + "R29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationPlaceholderFieldEnum.Types.AffiliateLocationPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Affiliate Location placeholder fields. + /// + public sealed partial class AffiliateLocationPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AffiliateLocationPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationPlaceholderFieldEnum(AffiliateLocationPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationPlaceholderFieldEnum Clone() { + return new AffiliateLocationPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AffiliateLocationPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AffiliateLocationPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AffiliateLocationPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AffiliateLocationPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Affiliate Location placeholder fields. + /// + public enum AffiliateLocationPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: STRING. The name of the business. + /// + [pbr::OriginalName("BUSINESS_NAME")] BusinessName = 2, + /// + /// Data Type: STRING. Line 1 of the business address. + /// + [pbr::OriginalName("ADDRESS_LINE_1")] AddressLine1 = 3, + /// + /// Data Type: STRING. Line 2 of the business address. + /// + [pbr::OriginalName("ADDRESS_LINE_2")] AddressLine2 = 4, + /// + /// Data Type: STRING. City of the business address. + /// + [pbr::OriginalName("CITY")] City = 5, + /// + /// Data Type: STRING. Province of the business address. + /// + [pbr::OriginalName("PROVINCE")] Province = 6, + /// + /// Data Type: STRING. Postal code of the business address. + /// + [pbr::OriginalName("POSTAL_CODE")] PostalCode = 7, + /// + /// Data Type: STRING. Country code of the business address. + /// + [pbr::OriginalName("COUNTRY_CODE")] CountryCode = 8, + /// + /// Data Type: STRING. Phone number of the business. + /// + [pbr::OriginalName("PHONE_NUMBER")] PhoneNumber = 9, + /// + /// Data Type: STRING. Language code of the business. + /// + [pbr::OriginalName("LANGUAGE_CODE")] LanguageCode = 10, + /// + /// Data Type: INT64. ID of the chain. + /// + [pbr::OriginalName("CHAIN_ID")] ChainId = 11, + /// + /// Data Type: STRING. Name of the chain. + /// + [pbr::OriginalName("CHAIN_NAME")] ChainName = 12, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AgeRangeType.cs b/src/V3/Stubs/AgeRangeType.cs new file mode 100644 index 000000000..6c38abc89 --- /dev/null +++ b/src/V3/Stubs/AgeRangeType.cs @@ -0,0 +1,208 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/age_range_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/age_range_type.proto + public static partial class AgeRangeTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/age_range_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AgeRangeTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZ2VfcmFuZ2VfdHlw", + "ZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2ds", + "ZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i6QEKEEFnZVJhbmdlVHlwZUVudW0i", + "1AEKDEFnZVJhbmdlVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04Q", + "ARIVCg9BR0VfUkFOR0VfMThfMjQQ2dkeEhUKD0FHRV9SQU5HRV8yNV8zNBDa", + "2R4SFQoPQUdFX1JBTkdFXzM1XzQ0ENvZHhIVCg9BR0VfUkFOR0VfNDVfNTQQ", + "3NkeEhUKD0FHRV9SQU5HRV81NV82NBDd2R4SFQoPQUdFX1JBTkdFXzY1X1VQ", + "EN7ZHhIcChZBR0VfUkFOR0VfVU5ERVRFUk1JTkVEEL/hHkLmAQohY29tLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhFBZ2VSYW5nZVR5cGVQcm90", + "b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRz", + "Lkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYz", + "XEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZw", + "cm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeEnum.Types.AgeRangeType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the type of demographic age ranges. + /// + public sealed partial class AgeRangeTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AgeRangeTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeTypeEnum(AgeRangeTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeTypeEnum Clone() { + return new AgeRangeTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AgeRangeTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AgeRangeTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AgeRangeTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AgeRangeTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The type of demographic age ranges (e.g. between 18 and 24 years old). + /// + public enum AgeRangeType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Between 18 and 24 years old. + /// + [pbr::OriginalName("AGE_RANGE_18_24")] AgeRange1824 = 503001, + /// + /// Between 25 and 34 years old. + /// + [pbr::OriginalName("AGE_RANGE_25_34")] AgeRange2534 = 503002, + /// + /// Between 35 and 44 years old. + /// + [pbr::OriginalName("AGE_RANGE_35_44")] AgeRange3544 = 503003, + /// + /// Between 45 and 54 years old. + /// + [pbr::OriginalName("AGE_RANGE_45_54")] AgeRange4554 = 503004, + /// + /// Between 55 and 64 years old. + /// + [pbr::OriginalName("AGE_RANGE_55_64")] AgeRange5564 = 503005, + /// + /// 65 years old and beyond. + /// + [pbr::OriginalName("AGE_RANGE_65_UP")] AgeRange65Up = 503006, + /// + /// Undetermined age range. + /// + [pbr::OriginalName("AGE_RANGE_UNDETERMINED")] AgeRangeUndetermined = 503999, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AgeRangeView.cs b/src/V3/Stubs/AgeRangeView.cs new file mode 100644 index 000000000..665595be0 --- /dev/null +++ b/src/V3/Stubs/AgeRangeView.cs @@ -0,0 +1,193 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/age_range_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/age_range_view.proto + public static partial class AgeRangeViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/age_range_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AgeRangeViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWdlX3Jhbmdl", + "X3ZpZXcucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2Fw", + "aS9yZXNvdXJjZS5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "byK1AQoMQWdlUmFuZ2VWaWV3EkQKDXJlc291cmNlX25hbWUYASABKAlCLeBB", + "BfpBJwolZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0FnZVJhbmdlVmlldzpf", + "6kFcCiVnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWdlUmFuZ2VWaWV3EjNj", + "dXN0b21lcnMve2N1c3RvbWVyfS9hZ2VSYW5nZVZpZXdzL3thZ2VfcmFuZ2Vf", + "dmlld31C/gEKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXNCEUFnZVJhbmdlVmlld1Byb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7", + "cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVz", + "b3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIl", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView), global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An age range view. + /// + public sealed partial class AgeRangeView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AgeRangeView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AgeRangeViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeView(AgeRangeView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeView Clone() { + return new AgeRangeView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the age range view. + /// Age range view resource names have the form: + /// + /// `customers/{customer_id}/ageRangeViews/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AgeRangeView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AgeRangeView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AgeRangeView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AgeRangeViewService.cs b/src/V3/Stubs/AgeRangeViewService.cs new file mode 100644 index 000000000..6e71efc48 --- /dev/null +++ b/src/V3/Stubs/AgeRangeViewService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/age_range_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/age_range_view_service.proto + public static partial class AgeRangeViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/age_range_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AgeRangeViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZ2VfcmFuZ2Vf", + "dmlld19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2Fn", + "ZV9yYW5nZV92aWV3LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVs", + "ZF9iZWhhdmlvci5wcm90byI0ChZHZXRBZ2VSYW5nZVZpZXdSZXF1ZXN0EhoK", + "DXJlc291cmNlX25hbWUYASABKAlCA+BBAjL6AQoTQWdlUmFuZ2VWaWV3U2Vy", + "dmljZRLFAQoPR2V0QWdlUmFuZ2VWaWV3EjguZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuR2V0QWdlUmFuZ2VWaWV3UmVxdWVzdBovLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZ2VSYW5nZVZpZXciR4LT", + "5JMCMRIvL3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2FnZVJhbmdl", + "Vmlld3MvKn3aQQ1yZXNvdXJjZV9uYW1lGhvKQRhnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb21C/wEKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlc0IYQWdlUmFuZ2VWaWV3U2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9z", + "ZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2Vydmlj", + "ZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AgeRangeViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAgeRangeViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetAgeRangeViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AgeRangeViewService.GetAgeRangeView][google.ads.googleads.v3.services.AgeRangeViewService.GetAgeRangeView]. + /// + public sealed partial class GetAgeRangeViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAgeRangeViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AgeRangeViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAgeRangeViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAgeRangeViewRequest(GetAgeRangeViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAgeRangeViewRequest Clone() { + return new GetAgeRangeViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the age range view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAgeRangeViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAgeRangeViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAgeRangeViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AgeRangeViewServiceClient.cs b/src/V3/Stubs/AgeRangeViewServiceClient.cs new file mode 100644 index 000000000..3c71369ac --- /dev/null +++ b/src/V3/Stubs/AgeRangeViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AgeRangeViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AgeRangeViewServiceSettings GetDefault() => new AgeRangeViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AgeRangeViewServiceSettings() { } + + private AgeRangeViewServiceSettings(AgeRangeViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAgeRangeViewSettings = existing.GetAgeRangeViewSettings; + OnCopy(existing); + } + + partial void OnCopy(AgeRangeViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AgeRangeViewServiceClient.GetAgeRangeView and AgeRangeViewServiceClient.GetAgeRangeViewAsync. + /// + /// + /// The default AgeRangeViewServiceClient.GetAgeRangeView and + /// AgeRangeViewServiceClient.GetAgeRangeViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAgeRangeViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AgeRangeViewServiceSettings Clone() => new AgeRangeViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AgeRangeViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AgeRangeViewServiceSettings Settings { get; set; } + + /// + public override AgeRangeViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AgeRangeViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AgeRangeViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AgeRangeViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AgeRangeViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AgeRangeViewServiceClient.ChannelPool; + } + + /// + /// AgeRangeViewService client wrapper, for convenient use. + /// + public abstract partial class AgeRangeViewServiceClient + { + /// + /// The default endpoint for the AgeRangeViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AgeRangeViewService scopes. + /// + /// + /// The default AgeRangeViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AgeRangeViewServiceClient client = await AgeRangeViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AgeRangeViewServiceClient.DefaultEndpoint.Host, AgeRangeViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AgeRangeViewServiceClient client = AgeRangeViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AgeRangeViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AgeRangeViewServiceClient client = AgeRangeViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AgeRangeViewServiceClient.DefaultEndpoint.Host, AgeRangeViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AgeRangeViewServiceClient client = AgeRangeViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AgeRangeViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AgeRangeViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AgeRangeViewServiceClient Create(grpccore::Channel channel, AgeRangeViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AgeRangeViewServiceClient Create(grpccore::CallInvoker callInvoker, AgeRangeViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AgeRangeViewService.AgeRangeViewServiceClient grpcClient = new AgeRangeViewService.AgeRangeViewServiceClient(callInvoker); + return new AgeRangeViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AgeRangeViewService client. + /// + public virtual AgeRangeViewService.AgeRangeViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested age range view in full detail. + /// + /// + /// Required. The resource name of the age range view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAgeRangeViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAgeRangeViewAsync( + new GetAgeRangeViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested age range view in full detail. + /// + /// + /// Required. The resource name of the age range view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAgeRangeViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAgeRangeViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested age range view in full detail. + /// + /// + /// Required. The resource name of the age range view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AgeRangeView GetAgeRangeView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAgeRangeView( + new GetAgeRangeViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested age range view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAgeRangeViewAsync( + GetAgeRangeViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested age range view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAgeRangeViewAsync( + GetAgeRangeViewRequest request, + st::CancellationToken cancellationToken) => GetAgeRangeViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested age range view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::AgeRangeView GetAgeRangeView( + GetAgeRangeViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AgeRangeViewService client wrapper implementation, for convenient use. + /// + public sealed partial class AgeRangeViewServiceClientImpl : AgeRangeViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAgeRangeView; + + /// + /// Constructs a client wrapper for the AgeRangeViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AgeRangeViewServiceClientImpl(AgeRangeViewService.AgeRangeViewServiceClient grpcClient, AgeRangeViewServiceSettings settings) + { + GrpcClient = grpcClient; + AgeRangeViewServiceSettings effectiveSettings = settings ?? AgeRangeViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAgeRangeView = clientHelper.BuildApiCall( + GrpcClient.GetAgeRangeViewAsync, GrpcClient.GetAgeRangeView, effectiveSettings.GetAgeRangeViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetAgeRangeView); + Modify_GetAgeRangeViewApiCall(ref _callGetAgeRangeView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAgeRangeViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AgeRangeViewService.AgeRangeViewServiceClient grpcClient, AgeRangeViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AgeRangeViewService client. + /// + public override AgeRangeViewService.AgeRangeViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAgeRangeViewRequest(ref GetAgeRangeViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested age range view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAgeRangeViewAsync( + GetAgeRangeViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAgeRangeViewRequest(ref request, ref callSettings); + return _callGetAgeRangeView.Async(request, callSettings); + } + + /// + /// Returns the requested age range view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::AgeRangeView GetAgeRangeView( + GetAgeRangeViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAgeRangeViewRequest(ref request, ref callSettings); + return _callGetAgeRangeView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AgeRangeViewServiceGrpc.cs b/src/V3/Stubs/AgeRangeViewServiceGrpc.cs new file mode 100644 index 000000000..2095f55fb --- /dev/null +++ b/src/V3/Stubs/AgeRangeViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/age_range_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage age range views. + /// + public static partial class AgeRangeViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AgeRangeViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAgeRangeViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAgeRangeViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_AgeRangeView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAgeRangeView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAgeRangeView", + __Marshaller_google_ads_googleads_v3_services_GetAgeRangeViewRequest, + __Marshaller_google_ads_googleads_v3_resources_AgeRangeView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AgeRangeViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AgeRangeViewService + public abstract partial class AgeRangeViewServiceBase + { + /// + /// Returns the requested age range view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAgeRangeView(global::Google.Ads.GoogleAds.V3.Services.GetAgeRangeViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AgeRangeViewService + public partial class AgeRangeViewServiceClient : grpc::ClientBase + { + /// Creates a new client for AgeRangeViewService + /// The channel to use to make remote calls. + public AgeRangeViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AgeRangeViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AgeRangeViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AgeRangeViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AgeRangeViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested age range view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView GetAgeRangeView(global::Google.Ads.GoogleAds.V3.Services.GetAgeRangeViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAgeRangeView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested age range view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView GetAgeRangeView(global::Google.Ads.GoogleAds.V3.Services.GetAgeRangeViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAgeRangeView, null, options, request); + } + /// + /// Returns the requested age range view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAgeRangeViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetAgeRangeViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAgeRangeViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested age range view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAgeRangeViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetAgeRangeViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAgeRangeView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AgeRangeViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AgeRangeViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AgeRangeViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAgeRangeView, serviceImpl.GetAgeRangeView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AgeRangeViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAgeRangeView, serviceImpl.GetAgeRangeView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AppCampaignAppStore.cs b/src/V3/Stubs/AppCampaignAppStore.cs new file mode 100644 index 000000000..b3cc91a34 --- /dev/null +++ b/src/V3/Stubs/AppCampaignAppStore.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/app_campaign_app_store.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/app_campaign_app_store.proto + public static partial class AppCampaignAppStoreReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/app_campaign_app_store.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AppCampaignAppStoreReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hcHBfY2FtcGFpZ25f", + "YXBwX3N0b3JlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJ5ChdBcHBDYW1wYWln", + "bkFwcFN0b3JlRW51bSJeChNBcHBDYW1wYWlnbkFwcFN0b3JlEg8KC1VOU1BF", + "Q0lGSUVEEAASCwoHVU5LTk9XThABEhMKD0FQUExFX0FQUF9TVE9SRRACEhQK", + "EEdPT0dMRV9BUFBfU1RPUkUQA0LtAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zQhhBcHBDYW1wYWlnbkFwcFN0b3JlUHJvdG9QAVpCZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVB", + "ZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oC", + "IUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreEnum), global::Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreEnum.Types.AppCampaignAppStore) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// The application store that distributes mobile applications. + /// + public sealed partial class AppCampaignAppStoreEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppCampaignAppStoreEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignAppStoreEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignAppStoreEnum(AppCampaignAppStoreEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignAppStoreEnum Clone() { + return new AppCampaignAppStoreEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppCampaignAppStoreEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppCampaignAppStoreEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppCampaignAppStoreEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AppCampaignAppStoreEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing app campaign app store. + /// + public enum AppCampaignAppStore { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Apple app store. + /// + [pbr::OriginalName("APPLE_APP_STORE")] AppleAppStore = 2, + /// + /// Google play. + /// + [pbr::OriginalName("GOOGLE_APP_STORE")] GoogleAppStore = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AppCampaignBiddingStrategyGoalType.cs b/src/V3/Stubs/AppCampaignBiddingStrategyGoalType.cs new file mode 100644 index 000000000..89ce504f5 --- /dev/null +++ b/src/V3/Stubs/AppCampaignBiddingStrategyGoalType.cs @@ -0,0 +1,206 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/app_campaign_bidding_strategy_goal_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/app_campaign_bidding_strategy_goal_type.proto + public static partial class AppCampaignBiddingStrategyGoalTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/app_campaign_bidding_strategy_goal_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AppCampaignBiddingStrategyGoalTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cktnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hcHBfY2FtcGFpZ25f", + "YmlkZGluZ19zdHJhdGVneV9nb2FsX3R5cGUucHJvdG8SHWdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvIq8CCiZBcHBDYW1wYWlnbkJpZGRpbmdTdHJhdGVneUdvYWxUeXBlRW51", + "bSKEAgoiQXBwQ2FtcGFpZ25CaWRkaW5nU3RyYXRlZ3lHb2FsVHlwZRIPCgtV", + "TlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIpCiVPUFRJTUlaRV9JTlNUQUxM", + "U19UQVJHRVRfSU5TVEFMTF9DT1NUEAISMwovT1BUSU1JWkVfSU5fQVBQX0NP", + "TlZFUlNJT05TX1RBUkdFVF9JTlNUQUxMX0NPU1QQAxI2CjJPUFRJTUlaRV9J", + "Tl9BUFBfQ09OVkVSU0lPTlNfVEFSR0VUX0NPTlZFUlNJT05fQ09TVBAEEigK", + "JE9QVElNSVpFX1JFVFVSTl9PTl9BRFZFUlRJU0lOR19TUEVORBAFQvwBCiFj", + "b20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCJ0FwcENhbXBhaWdu", + "QmlkZGluZ1N0cmF0ZWd5R29hbFR5cGVQcm90b1ABWkJnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVt", + "c8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeEnum.Types.AppCampaignBiddingStrategyGoalType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing goal towards which the bidding strategy of an + /// app campaign should optimize for. + /// + public sealed partial class AppCampaignBiddingStrategyGoalTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppCampaignBiddingStrategyGoalTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignBiddingStrategyGoalTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignBiddingStrategyGoalTypeEnum(AppCampaignBiddingStrategyGoalTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignBiddingStrategyGoalTypeEnum Clone() { + return new AppCampaignBiddingStrategyGoalTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppCampaignBiddingStrategyGoalTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppCampaignBiddingStrategyGoalTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppCampaignBiddingStrategyGoalTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AppCampaignBiddingStrategyGoalTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Goal type of App campaign BiddingStrategy. + /// + public enum AppCampaignBiddingStrategyGoalType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Aim to maximize the number of app installs. The cpa bid is the + /// target cost per install. + /// + [pbr::OriginalName("OPTIMIZE_INSTALLS_TARGET_INSTALL_COST")] OptimizeInstallsTargetInstallCost = 2, + /// + /// Aim to maximize the long term number of selected in-app conversions from + /// app installs. The cpa bid is the target cost per install. + /// + [pbr::OriginalName("OPTIMIZE_IN_APP_CONVERSIONS_TARGET_INSTALL_COST")] OptimizeInAppConversionsTargetInstallCost = 3, + /// + /// Aim to maximize the long term number of selected in-app conversions from + /// app installs. The cpa bid is the target cost per in-app conversion. Note + /// that the actual cpa may seem higher than the target cpa at first, since + /// the long term conversions haven’t happened yet. + /// + [pbr::OriginalName("OPTIMIZE_IN_APP_CONVERSIONS_TARGET_CONVERSION_COST")] OptimizeInAppConversionsTargetConversionCost = 4, + /// + /// Aim to maximize all conversions' value, i.e. install + selected in-app + /// conversions while achieving or exceeding target return on advertising + /// spend. + /// + [pbr::OriginalName("OPTIMIZE_RETURN_ON_ADVERTISING_SPEND")] OptimizeReturnOnAdvertisingSpend = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AppPaymentModelType.cs b/src/V3/Stubs/AppPaymentModelType.cs new file mode 100644 index 000000000..fb57b04ee --- /dev/null +++ b/src/V3/Stubs/AppPaymentModelType.cs @@ -0,0 +1,181 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/app_payment_model_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/app_payment_model_type.proto + public static partial class AppPaymentModelTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/app_payment_model_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AppPaymentModelTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hcHBfcGF5bWVudF9t", + "b2RlbF90eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJYChdBcHBQYXltZW50", + "TW9kZWxUeXBlRW51bSI9ChNBcHBQYXltZW50TW9kZWxUeXBlEg8KC1VOU1BF", + "Q0lGSUVEEAASCwoHVU5LTk9XThABEggKBFBBSUQQHkLtAQohY29tLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhhBcHBQYXltZW50TW9kZWxUeXBl", + "UHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBp", + "cy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xl", + "LkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFk", + "c1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVt", + "c2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AppPaymentModelTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AppPaymentModelTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AppPaymentModelTypeEnum.Types.AppPaymentModelType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents a criterion for targeting paid apps. + /// + public sealed partial class AppPaymentModelTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppPaymentModelTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AppPaymentModelTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPaymentModelTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPaymentModelTypeEnum(AppPaymentModelTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPaymentModelTypeEnum Clone() { + return new AppPaymentModelTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppPaymentModelTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppPaymentModelTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppPaymentModelTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AppPaymentModelTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible app payment models. + /// + public enum AppPaymentModelType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Represents paid-for apps. + /// + [pbr::OriginalName("PAID")] Paid = 30, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AppPlaceholderField.cs b/src/V3/Stubs/AppPlaceholderField.cs new file mode 100644 index 000000000..509dfd219 --- /dev/null +++ b/src/V3/Stubs/AppPlaceholderField.cs @@ -0,0 +1,218 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/app_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/app_placeholder_field.proto + public static partial class AppPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/app_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AppPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hcHBfcGxhY2Vob2xk", + "ZXJfZmllbGQucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIskBChdBcHBQbGFjZWhv", + "bGRlckZpZWxkRW51bSKtAQoTQXBwUGxhY2Vob2xkZXJGaWVsZBIPCgtVTlNQ", + "RUNJRklFRBAAEgsKB1VOS05PV04QARIJCgVTVE9SRRACEgYKAklEEAMSDQoJ", + "TElOS19URVhUEAQSBwoDVVJMEAUSDgoKRklOQUxfVVJMUxAGEhUKEUZJTkFM", + "X01PQklMRV9VUkxTEAcSEAoMVFJBQ0tJTkdfVVJMEAgSFAoQRklOQUxfVVJM", + "X1NVRkZJWBAJQu0BCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXNCGEFwcFBsYWNlaG9sZGVyRmllbGRQcm90b1ABWkJnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVt", + "c8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AppPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.AppPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AppPlaceholderFieldEnum.Types.AppPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for App placeholder fields. + /// + public sealed partial class AppPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AppPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPlaceholderFieldEnum(AppPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPlaceholderFieldEnum Clone() { + return new AppPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AppPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for App placeholder fields. + /// + public enum AppPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: INT64. The application store that the target application + /// belongs to. Valid values are: 1 = Apple iTunes Store; 2 = Google Play + /// Store. + /// + [pbr::OriginalName("STORE")] Store = 2, + /// + /// Data Type: STRING. The store-specific ID for the target application. + /// + [pbr::OriginalName("ID")] Id = 3, + /// + /// Data Type: STRING. The visible text displayed when the link is rendered + /// in an ad. + /// + [pbr::OriginalName("LINK_TEXT")] LinkText = 4, + /// + /// Data Type: STRING. The destination URL of the in-app link. + /// + [pbr::OriginalName("URL")] Url = 5, + /// + /// Data Type: URL_LIST. Final URLs for the in-app link when using Upgraded + /// URLs. + /// + [pbr::OriginalName("FINAL_URLS")] FinalUrls = 6, + /// + /// Data Type: URL_LIST. Final Mobile URLs for the in-app link when using + /// Upgraded URLs. + /// + [pbr::OriginalName("FINAL_MOBILE_URLS")] FinalMobileUrls = 7, + /// + /// Data Type: URL. Tracking template for the in-app link when using Upgraded + /// URLs. + /// + [pbr::OriginalName("TRACKING_URL")] TrackingUrl = 8, + /// + /// Data Type: STRING. Final URL suffix for the in-app link when using + /// parallel tracking. + /// + [pbr::OriginalName("FINAL_URL_SUFFIX")] FinalUrlSuffix = 9, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AppStore.cs b/src/V3/Stubs/AppStore.cs new file mode 100644 index 000000000..54801b933 --- /dev/null +++ b/src/V3/Stubs/AppStore.cs @@ -0,0 +1,184 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/app_store.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/app_store.proto + public static partial class AppStoreReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/app_store.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AppStoreReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hcHBfc3RvcmUucHJv", + "dG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29nbGUvYXBp", + "L2Fubm90YXRpb25zLnByb3RvIlsKDEFwcFN0b3JlRW51bSJLCghBcHBTdG9y", + "ZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIQCgxBUFBMRV9JVFVO", + "RVMQAhIPCgtHT09HTEVfUExBWRADQuIBCiFjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXNCDUFwcFN0b3JlUHJvdG9QAVpCZ29vZ2xlLmdvbGFu", + "Zy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vu", + "dW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51", + "bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AppStoreEnum), global::Google.Ads.GoogleAds.V3.Enums.AppStoreEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AppStoreEnum.Types.AppStore) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing app store type in an app extension. + /// + public sealed partial class AppStoreEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppStoreEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AppStoreReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppStoreEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppStoreEnum(AppStoreEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppStoreEnum Clone() { + return new AppStoreEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppStoreEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppStoreEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppStoreEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AppStoreEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// App store type in an app extension. + /// + public enum AppStore { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Apple iTunes. + /// + [pbr::OriginalName("APPLE_ITUNES")] AppleItunes = 2, + /// + /// Google Play. + /// + [pbr::OriginalName("GOOGLE_PLAY")] GooglePlay = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AppUrlOperatingSystemType.cs b/src/V3/Stubs/AppUrlOperatingSystemType.cs new file mode 100644 index 000000000..620c03a77 --- /dev/null +++ b/src/V3/Stubs/AppUrlOperatingSystemType.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/app_url_operating_system_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/app_url_operating_system_type.proto + public static partial class AppUrlOperatingSystemTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/app_url_operating_system_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AppUrlOperatingSystemTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hcHBfdXJsX29wZXJh", + "dGluZ19zeXN0ZW1fdHlwZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8icAodQXBw", + "VXJsT3BlcmF0aW5nU3lzdGVtVHlwZUVudW0iTwoZQXBwVXJsT3BlcmF0aW5n", + "U3lzdGVtVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIHCgNJ", + "T1MQAhILCgdBTkRST0lEEANC8wEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtc0IeQXBwVXJsT3BlcmF0aW5nU3lzdGVtVHlwZVByb3RvUAFa", + "Qmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51", + "bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3Rv", + "Mw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AppUrlOperatingSystemTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AppUrlOperatingSystemTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AppUrlOperatingSystemTypeEnum.Types.AppUrlOperatingSystemType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// The possible OS types for a deeplink AppUrl. + /// + public sealed partial class AppUrlOperatingSystemTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppUrlOperatingSystemTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AppUrlOperatingSystemTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppUrlOperatingSystemTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppUrlOperatingSystemTypeEnum(AppUrlOperatingSystemTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppUrlOperatingSystemTypeEnum Clone() { + return new AppUrlOperatingSystemTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppUrlOperatingSystemTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppUrlOperatingSystemTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppUrlOperatingSystemTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AppUrlOperatingSystemTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Operating System + /// + public enum AppUrlOperatingSystemType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The Apple IOS operating system. + /// + [pbr::OriginalName("IOS")] Ios = 2, + /// + /// The Android operating system. + /// + [pbr::OriginalName("ANDROID")] Android = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ApplyRecommendationResponsePartialFailureSupport.cs b/src/V3/Stubs/ApplyRecommendationResponsePartialFailureSupport.cs new file mode 100644 index 000000000..c272efe32 --- /dev/null +++ b/src/V3/Stubs/ApplyRecommendationResponsePartialFailureSupport.cs @@ -0,0 +1,46 @@ +// Copyright 2020 Google LLC. All Rights Reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// Generated code - do not edit + +using Google.Ads.GoogleAds.V3.Errors; +using System.Collections.Generic; +using Google.Protobuf.WellKnownTypes; + +namespace Google.Ads.GoogleAds.V3.Services +{ + public sealed partial class ApplyRecommendationResponse + { + /// + /// Gets a GoogleAdsFailure instance that combines all the errors + /// from a failed API call. + /// + public GoogleAdsFailure PartialFailure + { + get + { + if (this.PartialFailureError == null) + { + return null; + } + GoogleAdsFailure retval = new GoogleAdsFailure(); + foreach (Any any in this.PartialFailureError.Details) + { + GoogleAdsFailure failure = any.Unpack(); + retval.Errors.AddRange(failure.Errors); + } + return retval; + } + } + } +} diff --git a/src/V3/Stubs/Asset.cs b/src/V3/Stubs/Asset.cs new file mode 100644 index 000000000..7b8757f4b --- /dev/null +++ b/src/V3/Stubs/Asset.cs @@ -0,0 +1,505 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/asset.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/asset.proto + public static partial class AssetReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/asset.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AssetReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYXNzZXQucHJv", + "dG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcxowZ29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL2Fzc2V0X3R5cGVzLnByb3RvGi5n", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hc3NldF90eXBlLnByb3Rv", + "Gh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29nbGUvYXBp", + "L3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJv", + "dG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iggUKBUFzc2V0Ej0K", + "DXJlc291cmNlX25hbWUYASABKAlCJuBBBfpBIAoeZ29vZ2xlYWRzLmdvb2ds", + "ZWFwaXMuY29tL0Fzc2V0EiwKAmlkGAIgASgLMhsuZ29vZ2xlLnByb3RvYnVm", + "LkludDY0VmFsdWVCA+BBAxIvCgRuYW1lGAMgASgLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlQgPgQQUSSQoEdHlwZRgEIAEoDjI2Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkFzc2V0VHlwZUVudW0uQXNzZXRUeXBl", + "QgPgQQMSVQoTeW91dHViZV92aWRlb19hc3NldBgFIAEoCzIxLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Zb3V0dWJlVmlkZW9Bc3NldEID4EEF", + "SAASUwoSbWVkaWFfYnVuZGxlX2Fzc2V0GAYgASgLMjAuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuY29tbW9uLk1lZGlhQnVuZGxlQXNzZXRCA+BBBUgAEkYK", + "C2ltYWdlX2Fzc2V0GAcgASgLMiouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "Y29tbW9uLkltYWdlQXNzZXRCA+BBA0gAEkQKCnRleHRfYXNzZXQYCCABKAsy", + "KS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uVGV4dEFzc2V0QgPg", + "QQNIADpI6kFFCh5nb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQXNzZXQSI2N1", + "c3RvbWVycy97Y3VzdG9tZXJ9L2Fzc2V0cy97YXNzZXR9QgwKCmFzc2V0X2Rh", + "dGFC9wEKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNC", + "CkFzc2V0UHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJjZXOi", + "AgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFH", + "b29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6OkFk", + "czo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.AssetTypesReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AssetTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Asset), global::Google.Ads.GoogleAds.V3.Resources.Asset.Parser, new[]{ "ResourceName", "Id", "Name", "Type", "YoutubeVideoAsset", "MediaBundleAsset", "ImageAsset", "TextAsset" }, new[]{ "AssetData" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Asset is a part of an ad which can be shared across multiple ads. + /// It can be an image (ImageAsset), a video (YoutubeVideoAsset), etc. + /// + public sealed partial class Asset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Asset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.AssetReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Asset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Asset(Asset other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + type_ = other.type_; + switch (other.AssetDataCase) { + case AssetDataOneofCase.YoutubeVideoAsset: + YoutubeVideoAsset = other.YoutubeVideoAsset.Clone(); + break; + case AssetDataOneofCase.MediaBundleAsset: + MediaBundleAsset = other.MediaBundleAsset.Clone(); + break; + case AssetDataOneofCase.ImageAsset: + ImageAsset = other.ImageAsset.Clone(); + break; + case AssetDataOneofCase.TextAsset: + TextAsset = other.TextAsset.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Asset Clone() { + return new Asset(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the asset. + /// Asset resource names have the form: + /// + /// `customers/{customer_id}/assets/{asset_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 3; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(26); + private string name_; + /// + /// Immutable. Optional name of the asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.AssetTypeEnum.Types.AssetType type_ = 0; + /// + /// Output only. Type of the asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AssetTypeEnum.Types.AssetType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "youtube_video_asset" field. + public const int YoutubeVideoAssetFieldNumber = 5; + /// + /// Immutable. A YouTube video asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.YoutubeVideoAsset YoutubeVideoAsset { + get { return assetDataCase_ == AssetDataOneofCase.YoutubeVideoAsset ? (global::Google.Ads.GoogleAds.V3.Common.YoutubeVideoAsset) assetData_ : null; } + set { + assetData_ = value; + assetDataCase_ = value == null ? AssetDataOneofCase.None : AssetDataOneofCase.YoutubeVideoAsset; + } + } + + /// Field number for the "media_bundle_asset" field. + public const int MediaBundleAssetFieldNumber = 6; + /// + /// Immutable. A media bundle asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MediaBundleAsset MediaBundleAsset { + get { return assetDataCase_ == AssetDataOneofCase.MediaBundleAsset ? (global::Google.Ads.GoogleAds.V3.Common.MediaBundleAsset) assetData_ : null; } + set { + assetData_ = value; + assetDataCase_ = value == null ? AssetDataOneofCase.None : AssetDataOneofCase.MediaBundleAsset; + } + } + + /// Field number for the "image_asset" field. + public const int ImageAssetFieldNumber = 7; + /// + /// Output only. An image asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ImageAsset ImageAsset { + get { return assetDataCase_ == AssetDataOneofCase.ImageAsset ? (global::Google.Ads.GoogleAds.V3.Common.ImageAsset) assetData_ : null; } + set { + assetData_ = value; + assetDataCase_ = value == null ? AssetDataOneofCase.None : AssetDataOneofCase.ImageAsset; + } + } + + /// Field number for the "text_asset" field. + public const int TextAssetFieldNumber = 8; + /// + /// Output only. A text asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TextAsset TextAsset { + get { return assetDataCase_ == AssetDataOneofCase.TextAsset ? (global::Google.Ads.GoogleAds.V3.Common.TextAsset) assetData_ : null; } + set { + assetData_ = value; + assetDataCase_ = value == null ? AssetDataOneofCase.None : AssetDataOneofCase.TextAsset; + } + } + + private object assetData_; + /// Enum of possible cases for the "asset_data" oneof. + public enum AssetDataOneofCase { + None = 0, + YoutubeVideoAsset = 5, + MediaBundleAsset = 6, + ImageAsset = 7, + TextAsset = 8, + } + private AssetDataOneofCase assetDataCase_ = AssetDataOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetDataOneofCase AssetDataCase { + get { return assetDataCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearAssetData() { + assetDataCase_ = AssetDataOneofCase.None; + assetData_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as Asset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(Asset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (Type != other.Type) return false; + if (!object.Equals(YoutubeVideoAsset, other.YoutubeVideoAsset)) return false; + if (!object.Equals(MediaBundleAsset, other.MediaBundleAsset)) return false; + if (!object.Equals(ImageAsset, other.ImageAsset)) return false; + if (!object.Equals(TextAsset, other.TextAsset)) return false; + if (AssetDataCase != other.AssetDataCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (assetDataCase_ == AssetDataOneofCase.YoutubeVideoAsset) hash ^= YoutubeVideoAsset.GetHashCode(); + if (assetDataCase_ == AssetDataOneofCase.MediaBundleAsset) hash ^= MediaBundleAsset.GetHashCode(); + if (assetDataCase_ == AssetDataOneofCase.ImageAsset) hash ^= ImageAsset.GetHashCode(); + if (assetDataCase_ == AssetDataOneofCase.TextAsset) hash ^= TextAsset.GetHashCode(); + hash ^= (int) assetDataCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (Type != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) Type); + } + if (assetDataCase_ == AssetDataOneofCase.YoutubeVideoAsset) { + output.WriteRawTag(42); + output.WriteMessage(YoutubeVideoAsset); + } + if (assetDataCase_ == AssetDataOneofCase.MediaBundleAsset) { + output.WriteRawTag(50); + output.WriteMessage(MediaBundleAsset); + } + if (assetDataCase_ == AssetDataOneofCase.ImageAsset) { + output.WriteRawTag(58); + output.WriteMessage(ImageAsset); + } + if (assetDataCase_ == AssetDataOneofCase.TextAsset) { + output.WriteRawTag(66); + output.WriteMessage(TextAsset); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (assetDataCase_ == AssetDataOneofCase.YoutubeVideoAsset) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(YoutubeVideoAsset); + } + if (assetDataCase_ == AssetDataOneofCase.MediaBundleAsset) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MediaBundleAsset); + } + if (assetDataCase_ == AssetDataOneofCase.ImageAsset) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ImageAsset); + } + if (assetDataCase_ == AssetDataOneofCase.TextAsset) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(TextAsset); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(Asset other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.Type != 0) { + Type = other.Type; + } + switch (other.AssetDataCase) { + case AssetDataOneofCase.YoutubeVideoAsset: + if (YoutubeVideoAsset == null) { + YoutubeVideoAsset = new global::Google.Ads.GoogleAds.V3.Common.YoutubeVideoAsset(); + } + YoutubeVideoAsset.MergeFrom(other.YoutubeVideoAsset); + break; + case AssetDataOneofCase.MediaBundleAsset: + if (MediaBundleAsset == null) { + MediaBundleAsset = new global::Google.Ads.GoogleAds.V3.Common.MediaBundleAsset(); + } + MediaBundleAsset.MergeFrom(other.MediaBundleAsset); + break; + case AssetDataOneofCase.ImageAsset: + if (ImageAsset == null) { + ImageAsset = new global::Google.Ads.GoogleAds.V3.Common.ImageAsset(); + } + ImageAsset.MergeFrom(other.ImageAsset); + break; + case AssetDataOneofCase.TextAsset: + if (TextAsset == null) { + TextAsset = new global::Google.Ads.GoogleAds.V3.Common.TextAsset(); + } + TextAsset.MergeFrom(other.TextAsset); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 26: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 32: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.AssetTypeEnum.Types.AssetType) input.ReadEnum(); + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Common.YoutubeVideoAsset subBuilder = new global::Google.Ads.GoogleAds.V3.Common.YoutubeVideoAsset(); + if (assetDataCase_ == AssetDataOneofCase.YoutubeVideoAsset) { + subBuilder.MergeFrom(YoutubeVideoAsset); + } + input.ReadMessage(subBuilder); + YoutubeVideoAsset = subBuilder; + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Common.MediaBundleAsset subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MediaBundleAsset(); + if (assetDataCase_ == AssetDataOneofCase.MediaBundleAsset) { + subBuilder.MergeFrom(MediaBundleAsset); + } + input.ReadMessage(subBuilder); + MediaBundleAsset = subBuilder; + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Common.ImageAsset subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ImageAsset(); + if (assetDataCase_ == AssetDataOneofCase.ImageAsset) { + subBuilder.MergeFrom(ImageAsset); + } + input.ReadMessage(subBuilder); + ImageAsset = subBuilder; + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.TextAsset subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TextAsset(); + if (assetDataCase_ == AssetDataOneofCase.TextAsset) { + subBuilder.MergeFrom(TextAsset); + } + input.ReadMessage(subBuilder); + TextAsset = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AssetError.cs b/src/V3/Stubs/AssetError.cs new file mode 100644 index 000000000..e4cb9c562 --- /dev/null +++ b/src/V3/Stubs/AssetError.cs @@ -0,0 +1,201 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/asset_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/asset_error.proto + public static partial class AssetErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/asset_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AssetErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYXNzZXRfZXJyb3Iu", + "cHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byLSAQoOQXNzZXRFcnJvckVudW0ivwEK", + "CkFzc2V0RXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESKwon", + "Q1VTVE9NRVJfTk9UX1dISVRFTElTVEVEX0ZPUl9BU1NFVF9UWVBFEAISEwoP", + "RFVQTElDQVRFX0FTU0VUEAMSGAoURFVQTElDQVRFX0FTU0VUX05BTUUQBBIZ", + "ChVBU1NFVF9EQVRBX0lTX01JU1NJTkcQBRIcChhDQU5OT1RfTU9ESUZZX0FT", + "U0VUX05BTUUQBkLqAQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9yc0IPQXNzZXRFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJy", + "b3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIe", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AssetErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AssetErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AssetErrorEnum.Types.AssetError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible asset errors. + /// + public sealed partial class AssetErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AssetErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AssetErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetErrorEnum(AssetErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetErrorEnum Clone() { + return new AssetErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AssetErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AssetErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AssetErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AssetErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible asset errors. + /// + public enum AssetError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The customer is not whitelisted for this asset type. + /// + [pbr::OriginalName("CUSTOMER_NOT_WHITELISTED_FOR_ASSET_TYPE")] CustomerNotWhitelistedForAssetType = 2, + /// + /// Assets are duplicated across operations. + /// + [pbr::OriginalName("DUPLICATE_ASSET")] DuplicateAsset = 3, + /// + /// The asset name is duplicated, either across operations or with an + /// existing asset. + /// + [pbr::OriginalName("DUPLICATE_ASSET_NAME")] DuplicateAssetName = 4, + /// + /// The Asset.asset_data oneof is empty. + /// + [pbr::OriginalName("ASSET_DATA_IS_MISSING")] AssetDataIsMissing = 5, + /// + /// The asset has a name which is different from an existing duplicate that + /// represents the same content. + /// + [pbr::OriginalName("CANNOT_MODIFY_ASSET_NAME")] CannotModifyAssetName = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AssetFieldType.cs b/src/V3/Stubs/AssetFieldType.cs new file mode 100644 index 000000000..aaa089167 --- /dev/null +++ b/src/V3/Stubs/AssetFieldType.cs @@ -0,0 +1,203 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/asset_field_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/asset_field_type.proto + public static partial class AssetFieldTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/asset_field_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AssetFieldTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hc3NldF9maWVsZF90", + "eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byK1AQoSQXNzZXRGaWVsZFR5cGVF", + "bnVtIp4BCg5Bc3NldEZpZWxkVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VO", + "S05PV04QARIMCghIRUFETElORRACEg8KC0RFU0NSSVBUSU9OEAMSFQoRTUFO", + "REFUT1JZX0FEX1RFWFQQBBITCg9NQVJLRVRJTkdfSU1BR0UQBRIQCgxNRURJ", + "QV9CVU5ETEUQBhIRCg1ZT1VUVUJFX1ZJREVPEAdC6AEKIWNvbS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtc0ITQXNzZXRGaWVsZFR5cGVQcm90b1AB", + "WkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVu", + "dW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AssetFieldTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AssetFieldTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AssetFieldTypeEnum.Types.AssetFieldType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the possible placements of an asset. + /// + public sealed partial class AssetFieldTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AssetFieldTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AssetFieldTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetFieldTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetFieldTypeEnum(AssetFieldTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetFieldTypeEnum Clone() { + return new AssetFieldTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AssetFieldTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AssetFieldTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AssetFieldTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AssetFieldTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing the possible placements of an asset. + /// + public enum AssetFieldType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The asset is linked for use as a headline. + /// + [pbr::OriginalName("HEADLINE")] Headline = 2, + /// + /// The asset is linked for use as a description. + /// + [pbr::OriginalName("DESCRIPTION")] Description = 3, + /// + /// The asset is linked for use as mandatory ad text. + /// + [pbr::OriginalName("MANDATORY_AD_TEXT")] MandatoryAdText = 4, + /// + /// The asset is linked for use as a marketing image. + /// + [pbr::OriginalName("MARKETING_IMAGE")] MarketingImage = 5, + /// + /// The asset is linked for use as a media bundle. + /// + [pbr::OriginalName("MEDIA_BUNDLE")] MediaBundle = 6, + /// + /// The asset is linked for use as a YouTube video. + /// + [pbr::OriginalName("YOUTUBE_VIDEO")] YoutubeVideo = 7, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AssetPerformanceLabel.cs b/src/V3/Stubs/AssetPerformanceLabel.cs new file mode 100644 index 000000000..a42bbe73a --- /dev/null +++ b/src/V3/Stubs/AssetPerformanceLabel.cs @@ -0,0 +1,201 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/asset_performance_label.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/asset_performance_label.proto + public static partial class AssetPerformanceLabelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/asset_performance_label.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AssetPerformanceLabelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hc3NldF9wZXJmb3Jt", + "YW5jZV9sYWJlbC5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iigEKGUFzc2V0UGVy", + "Zm9ybWFuY2VMYWJlbEVudW0ibQoVQXNzZXRQZXJmb3JtYW5jZUxhYmVsEg8K", + "C1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB1BFTkRJTkcQAhIMCghM", + "RUFSTklORxADEgcKA0xPVxAEEggKBEdPT0QQBRIICgRCRVNUEAZC7wEKIWNv", + "bS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IaQXNzZXRQZXJmb3Jt", + "YW5jZUxhYmVsUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8v", + "Z29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FB", + "qgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRz", + "XEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AssetPerformanceLabelEnum), global::Google.Ads.GoogleAds.V3.Enums.AssetPerformanceLabelEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AssetPerformanceLabelEnum.Types.AssetPerformanceLabel) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the performance label of an asset. + /// + public sealed partial class AssetPerformanceLabelEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AssetPerformanceLabelEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AssetPerformanceLabelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetPerformanceLabelEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetPerformanceLabelEnum(AssetPerformanceLabelEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetPerformanceLabelEnum Clone() { + return new AssetPerformanceLabelEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AssetPerformanceLabelEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AssetPerformanceLabelEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AssetPerformanceLabelEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AssetPerformanceLabelEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing the possible performance labels of an asset, usually + /// computed in the context of a linkage. + /// + public enum AssetPerformanceLabel { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// This asset does not yet have any performance informantion. This may be + /// because it is still under review. + /// + [pbr::OriginalName("PENDING")] Pending = 2, + /// + /// The asset has started getting impressions but the stats are not + /// statistically significant enough to get an asset performance label. + /// + [pbr::OriginalName("LEARNING")] Learning = 3, + /// + /// Worst performing assets. + /// + [pbr::OriginalName("LOW")] Low = 4, + /// + /// Good performing assets. + /// + [pbr::OriginalName("GOOD")] Good = 5, + /// + /// Best performing assets. + /// + [pbr::OriginalName("BEST")] Best = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AssetService.cs b/src/V3/Stubs/AssetService.cs new file mode 100644 index 000000000..80024a19e --- /dev/null +++ b/src/V3/Stubs/AssetService.cs @@ -0,0 +1,803 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/asset_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/asset_service.proto + public static partial class AssetServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/asset_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AssetServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hc3NldF9zZXJ2", + "aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcxot", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2Fzc2V0LnByb3Rv", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2Ns", + "aWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90byIt", + "Cg9HZXRBc3NldFJlcXVlc3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEoCUID4EEC", + "InoKE011dGF0ZUFzc2V0c1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlC", + "A+BBAhJJCgpvcGVyYXRpb25zGAIgAygLMjAuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuQXNzZXRPcGVyYXRpb25CA+BBAiJZCg5Bc3NldE9w", + "ZXJhdGlvbhI6CgZjcmVhdGUYASABKAsyKC5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXMuQXNzZXRIAEILCglvcGVyYXRpb24iXAoUTXV0YXRl", + "QXNzZXRzUmVzcG9uc2USRAoHcmVzdWx0cxgCIAMoCzIzLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFzc2V0UmVzdWx0IioKEU11", + "dGF0ZUFzc2V0UmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAkyqAMKDEFz", + "c2V0U2VydmljZRKpAQoIR2V0QXNzZXQSMS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5HZXRBc3NldFJlcXVlc3QaKC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5yZXNvdXJjZXMuQXNzZXQiQILT5JMCKhIoL3YzL3tyZXNv", + "dXJjZV9uYW1lPWN1c3RvbWVycy8qL2Fzc2V0cy8qfdpBDXJlc291cmNlX25h", + "bWUSzgEKDE11dGF0ZUFzc2V0cxI1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLk11dGF0ZUFzc2V0c1JlcXVlc3QaNi5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVBc3NldHNSZXNwb25zZSJPgtPk", + "kwIwIisvdjMvY3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfS9hc3NldHM6bXV0", + "YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9ucxobykEYZ29vZ2xlYWRz", + "Lmdvb2dsZWFwaXMuY29tQvgBCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXNCEUFzc2V0U2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9z", + "ZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2Vydmlj", + "ZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.AssetReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetAssetRequest), global::Google.Ads.GoogleAds.V3.Services.GetAssetRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAssetsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateAssetsRequest.Parser, new[]{ "CustomerId", "Operations" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.AssetOperation), global::Google.Ads.GoogleAds.V3.Services.AssetOperation.Parser, new[]{ "Create" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAssetsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateAssetsResponse.Parser, new[]{ "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateAssetResult), global::Google.Ads.GoogleAds.V3.Services.MutateAssetResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [AssetService.GetAsset][google.ads.googleads.v3.services.AssetService.GetAsset] + /// + public sealed partial class GetAssetRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetAssetRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AssetServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAssetRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAssetRequest(GetAssetRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetAssetRequest Clone() { + return new GetAssetRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the asset to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetAssetRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetAssetRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetAssetRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [AssetService.MutateAssets][google.ads.googleads.v3.services.AssetService.MutateAssets] + /// + public sealed partial class MutateAssetsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAssetsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AssetServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetsRequest(MutateAssetsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetsRequest Clone() { + return new MutateAssetsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose assets are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.AssetOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual assets. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAssetsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAssetsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAssetsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + } + } + } + + } + + /// + /// A single operation to create an asset. Supported asset types are + /// YoutubeVideoAsset, MediaBundleAsset and ImageAsset. TextAsset should be + /// created with Ad inline. + /// + public sealed partial class AssetOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AssetOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AssetServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetOperation(AssetOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetOperation Clone() { + return new AssetOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Asset Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.Asset) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AssetOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AssetOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AssetOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.Asset(); + } + Create.MergeFrom(other.Create); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.Asset subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.Asset(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + } + } + } + + } + + /// + /// Response message for an asset mutate. + /// + public sealed partial class MutateAssetsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAssetsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AssetServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetsResponse(MutateAssetsResponse other) : this() { + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetsResponse Clone() { + return new MutateAssetsResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateAssetResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAssetsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAssetsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAssetsResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// The result for the asset mutate. + /// + public sealed partial class MutateAssetResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateAssetResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.AssetServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetResult(MutateAssetResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateAssetResult Clone() { + return new MutateAssetResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// The resource name returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateAssetResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateAssetResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateAssetResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AssetServiceClient.cs b/src/V3/Stubs/AssetServiceClient.cs new file mode 100644 index 000000000..77e7bbce8 --- /dev/null +++ b/src/V3/Stubs/AssetServiceClient.cs @@ -0,0 +1,770 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class AssetServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static AssetServiceSettings GetDefault() => new AssetServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public AssetServiceSettings() { } + + private AssetServiceSettings(AssetServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetAssetSettings = existing.GetAssetSettings; + MutateAssetsSettings = existing.MutateAssetsSettings; + OnCopy(existing); + } + + partial void OnCopy(AssetServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// AssetServiceClient.GetAsset and AssetServiceClient.GetAssetAsync. + /// + /// + /// The default AssetServiceClient.GetAsset and + /// AssetServiceClient.GetAssetAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetAssetSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// AssetServiceClient.MutateAssets and AssetServiceClient.MutateAssetsAsync. + /// + /// + /// The default AssetServiceClient.MutateAssets and + /// AssetServiceClient.MutateAssetsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateAssetsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public AssetServiceSettings Clone() => new AssetServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class AssetServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public AssetServiceSettings Settings { get; set; } + + /// + public override AssetServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return AssetServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return AssetServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => AssetServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => AssetServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => AssetServiceClient.ChannelPool; + } + + /// + /// AssetService client wrapper, for convenient use. + /// + public abstract partial class AssetServiceClient + { + /// + /// The default endpoint for the AssetService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default AssetService scopes. + /// + /// + /// The default AssetService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AssetServiceClient client = await AssetServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AssetServiceClient.DefaultEndpoint.Host, AssetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AssetServiceClient client = AssetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, AssetServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// AssetServiceClient client = AssetServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// AssetServiceClient.DefaultEndpoint.Host, AssetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// AssetServiceClient client = AssetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static AssetServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, AssetServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AssetServiceClient Create(grpccore::Channel channel, AssetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static AssetServiceClient Create(grpccore::CallInvoker callInvoker, AssetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + AssetService.AssetServiceClient grpcClient = new AssetService.AssetServiceClient(callInvoker); + return new AssetServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC AssetService client. + /// + public virtual AssetService.AssetServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested asset in full detail. + /// + /// + /// Required. The resource name of the asset to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAssetAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAssetAsync( + new GetAssetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested asset in full detail. + /// + /// + /// Required. The resource name of the asset to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAssetAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetAssetAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested asset in full detail. + /// + /// + /// Required. The resource name of the asset to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Asset GetAsset( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetAsset( + new GetAssetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested asset in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAssetAsync( + GetAssetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested asset in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetAssetAsync( + GetAssetRequest request, + st::CancellationToken cancellationToken) => GetAssetAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested asset in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Asset GetAsset( + GetAssetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates assets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose assets are being modified. + /// + /// + /// Required. The list of operations to perform on individual assets. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAssetsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAssetsAsync( + new MutateAssetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates assets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose assets are being modified. + /// + /// + /// Required. The list of operations to perform on individual assets. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAssetsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateAssetsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates assets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose assets are being modified. + /// + /// + /// Required. The list of operations to perform on individual assets. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAssetsResponse MutateAssets( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateAssets( + new MutateAssetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates assets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAssetsAsync( + MutateAssetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates assets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAssetsAsync( + MutateAssetsRequest request, + st::CancellationToken cancellationToken) => MutateAssetsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates assets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateAssetsResponse MutateAssets( + MutateAssetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// AssetService client wrapper implementation, for convenient use. + /// + public sealed partial class AssetServiceClientImpl : AssetServiceClient + { + private readonly gaxgrpc::ApiCall _callGetAsset; + private readonly gaxgrpc::ApiCall _callMutateAssets; + + /// + /// Constructs a client wrapper for the AssetService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public AssetServiceClientImpl(AssetService.AssetServiceClient grpcClient, AssetServiceSettings settings) + { + GrpcClient = grpcClient; + AssetServiceSettings effectiveSettings = settings ?? AssetServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetAsset = clientHelper.BuildApiCall( + GrpcClient.GetAssetAsync, GrpcClient.GetAsset, effectiveSettings.GetAssetSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateAssets = clientHelper.BuildApiCall( + GrpcClient.MutateAssetsAsync, GrpcClient.MutateAssets, effectiveSettings.MutateAssetsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetAsset); + Modify_GetAssetApiCall(ref _callGetAsset); + Modify_ApiCall(ref _callMutateAssets); + Modify_MutateAssetsApiCall(ref _callMutateAssets); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetAssetApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateAssetsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(AssetService.AssetServiceClient grpcClient, AssetServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC AssetService client. + /// + public override AssetService.AssetServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetAssetRequest(ref GetAssetRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateAssetsRequest(ref MutateAssetsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested asset in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetAssetAsync( + GetAssetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAssetRequest(ref request, ref callSettings); + return _callGetAsset.Async(request, callSettings); + } + + /// + /// Returns the requested asset in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::Asset GetAsset( + GetAssetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetAssetRequest(ref request, ref callSettings); + return _callGetAsset.Sync(request, callSettings); + } + + /// + /// Creates assets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAssetsAsync( + MutateAssetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAssetsRequest(ref request, ref callSettings); + return _callMutateAssets.Async(request, callSettings); + } + + /// + /// Creates assets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateAssetsResponse MutateAssets( + MutateAssetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateAssetsRequest(ref request, ref callSettings); + return _callMutateAssets.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/AssetServiceGrpc.cs b/src/V3/Stubs/AssetServiceGrpc.cs new file mode 100644 index 000000000..ed3d374a6 --- /dev/null +++ b/src/V3/Stubs/AssetServiceGrpc.cs @@ -0,0 +1,226 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/asset_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage assets. Asset types can be created with AssetService are + /// YoutubeVideoAsset, MediaBundleAsset and ImageAsset. TextAsset should be + /// created with Ad inline. + /// + public static partial class AssetService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.AssetService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetAssetRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetAssetRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_Asset = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.Asset.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAssetsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAssetsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateAssetsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateAssetsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetAsset = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetAsset", + __Marshaller_google_ads_googleads_v3_services_GetAssetRequest, + __Marshaller_google_ads_googleads_v3_resources_Asset); + + static readonly grpc::Method __Method_MutateAssets = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateAssets", + __Marshaller_google_ads_googleads_v3_services_MutateAssetsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateAssetsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.AssetServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of AssetService + public abstract partial class AssetServiceBase + { + /// + /// Returns the requested asset in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetAsset(global::Google.Ads.GoogleAds.V3.Services.GetAssetRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates assets. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateAssets(global::Google.Ads.GoogleAds.V3.Services.MutateAssetsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for AssetService + public partial class AssetServiceClient : grpc::ClientBase + { + /// Creates a new client for AssetService + /// The channel to use to make remote calls. + public AssetServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for AssetService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public AssetServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected AssetServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected AssetServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested asset in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Asset GetAsset(global::Google.Ads.GoogleAds.V3.Services.GetAssetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAsset(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested asset in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Asset GetAsset(global::Google.Ads.GoogleAds.V3.Services.GetAssetRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetAsset, null, options, request); + } + /// + /// Returns the requested asset in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAssetAsync(global::Google.Ads.GoogleAds.V3.Services.GetAssetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetAssetAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested asset in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetAssetAsync(global::Google.Ads.GoogleAds.V3.Services.GetAssetRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetAsset, null, options, request); + } + /// + /// Creates assets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAssetsResponse MutateAssets(global::Google.Ads.GoogleAds.V3.Services.MutateAssetsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAssets(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates assets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateAssetsResponse MutateAssets(global::Google.Ads.GoogleAds.V3.Services.MutateAssetsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateAssets, null, options, request); + } + /// + /// Creates assets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAssetsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAssetsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAssetsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates assets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAssetsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateAssetsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateAssets, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override AssetServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new AssetServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(AssetServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetAsset, serviceImpl.GetAsset) + .AddMethod(__Method_MutateAssets, serviceImpl.MutateAssets).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, AssetServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetAsset, serviceImpl.GetAsset); + serviceBinder.AddMethod(__Method_MutateAssets, serviceImpl.MutateAssets); + } + + } +} +#endregion diff --git a/src/V3/Stubs/AssetType.cs b/src/V3/Stubs/AssetType.cs new file mode 100644 index 000000000..70f7da161 --- /dev/null +++ b/src/V3/Stubs/AssetType.cs @@ -0,0 +1,193 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/asset_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/asset_type.proto + public static partial class AssetTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/asset_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AssetTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hc3NldF90eXBlLnBy", + "b3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90byJ0Cg1Bc3NldFR5cGVFbnVtImMKCUFzc2V0", + "VHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIRCg1ZT1VUVUJF", + "X1ZJREVPEAISEAoMTUVESUFfQlVORExFEAMSCQoFSU1BR0UQBBIICgRURVhU", + "EAVC4wEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IOQXNz", + "ZXRUeXBlUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgId", + "R29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYz", + "OjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AssetTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.AssetTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AssetTypeEnum.Types.AssetType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the types of asset. + /// + public sealed partial class AssetTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AssetTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AssetTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetTypeEnum(AssetTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AssetTypeEnum Clone() { + return new AssetTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AssetTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AssetTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AssetTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AssetTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible types of asset. + /// + public enum AssetType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// YouTube video asset. + /// + [pbr::OriginalName("YOUTUBE_VIDEO")] YoutubeVideo = 2, + /// + /// Media bundle asset. + /// + [pbr::OriginalName("MEDIA_BUNDLE")] MediaBundle = 3, + /// + /// Image asset. + /// + [pbr::OriginalName("IMAGE")] Image = 4, + /// + /// Text asset. + /// + [pbr::OriginalName("TEXT")] Text = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AssetTypes.cs b/src/V3/Stubs/AssetTypes.cs new file mode 100644 index 000000000..d95dc6de0 --- /dev/null +++ b/src/V3/Stubs/AssetTypes.cs @@ -0,0 +1,957 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/asset_types.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/asset_types.proto + public static partial class AssetTypesReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/asset_types.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AssetTypesReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vYXNzZXRfdHlwZXMu", + "cHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbhotZ29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvbWltZV90eXBlLnByb3RvGh5nb29n", + "bGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3Rh", + "dGlvbnMucHJvdG8iSwoRWW91dHViZVZpZGVvQXNzZXQSNgoQeW91dHViZV92", + "aWRlb19pZBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSI9", + "ChBNZWRpYUJ1bmRsZUFzc2V0EikKBGRhdGEYASABKAsyGy5nb29nbGUucHJv", + "dG9idWYuQnl0ZXNWYWx1ZSLzAQoKSW1hZ2VBc3NldBIpCgRkYXRhGAEgASgL", + "MhsuZ29vZ2xlLnByb3RvYnVmLkJ5dGVzVmFsdWUSLgoJZmlsZV9zaXplGAIg", + "ASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUSRwoJbWltZV90eXBl", + "GAMgASgOMjQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuTWltZVR5", + "cGVFbnVtLk1pbWVUeXBlEkEKCWZ1bGxfc2l6ZRgEIAEoCzIuLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5JbWFnZURpbWVuc2lvbiKiAQoOSW1h", + "Z2VEaW1lbnNpb24SMgoNaGVpZ2h0X3BpeGVscxgBIAEoCzIbLmdvb2dsZS5w", + "cm90b2J1Zi5JbnQ2NFZhbHVlEjEKDHdpZHRoX3BpeGVscxgCIAEoCzIbLmdv", + "b2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlEikKA3VybBgDIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSI3CglUZXh0QXNzZXQSKgoEdGV4dBgB", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZULqAQoiY29tLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbkIPQXNzZXRUeXBlc1Byb3Rv", + "UAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9jb21tb247Y29tbW9uogIDR0FBqgIeR29vZ2xlLkFk", + "cy5Hb29nbGVBZHMuVjMuQ29tbW9uygIeR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcQ29tbW9u6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkNvbW1v", + "bmIGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.MimeTypeReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.YoutubeVideoAsset), global::Google.Ads.GoogleAds.V3.Common.YoutubeVideoAsset.Parser, new[]{ "YoutubeVideoId" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.MediaBundleAsset), global::Google.Ads.GoogleAds.V3.Common.MediaBundleAsset.Parser, new[]{ "Data" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ImageAsset), global::Google.Ads.GoogleAds.V3.Common.ImageAsset.Parser, new[]{ "Data", "FileSize", "MimeType", "FullSize" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ImageDimension), global::Google.Ads.GoogleAds.V3.Common.ImageDimension.Parser, new[]{ "HeightPixels", "WidthPixels", "Url" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TextAsset), global::Google.Ads.GoogleAds.V3.Common.TextAsset.Parser, new[]{ "Text" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A YouTube asset. + /// + public sealed partial class YoutubeVideoAsset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new YoutubeVideoAsset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AssetTypesReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YoutubeVideoAsset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YoutubeVideoAsset(YoutubeVideoAsset other) : this() { + YoutubeVideoId = other.YoutubeVideoId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YoutubeVideoAsset Clone() { + return new YoutubeVideoAsset(this); + } + + /// Field number for the "youtube_video_id" field. + public const int YoutubeVideoIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_youtubeVideoId_codec = pb::FieldCodec.ForClassWrapper(10); + private string youtubeVideoId_; + /// + /// YouTube video id. This is the 11 character string value used in the + /// YouTube video URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string YoutubeVideoId { + get { return youtubeVideoId_; } + set { + youtubeVideoId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as YoutubeVideoAsset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(YoutubeVideoAsset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (YoutubeVideoId != other.YoutubeVideoId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (youtubeVideoId_ != null) hash ^= YoutubeVideoId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (youtubeVideoId_ != null) { + _single_youtubeVideoId_codec.WriteTagAndValue(output, YoutubeVideoId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (youtubeVideoId_ != null) { + size += _single_youtubeVideoId_codec.CalculateSizeWithTag(YoutubeVideoId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(YoutubeVideoAsset other) { + if (other == null) { + return; + } + if (other.youtubeVideoId_ != null) { + if (youtubeVideoId_ == null || other.YoutubeVideoId != "") { + YoutubeVideoId = other.YoutubeVideoId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_youtubeVideoId_codec.Read(input); + if (youtubeVideoId_ == null || value != "") { + YoutubeVideoId = value; + } + break; + } + } + } + } + + } + + /// + /// A MediaBundle asset. + /// + public sealed partial class MediaBundleAsset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MediaBundleAsset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AssetTypesReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MediaBundleAsset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MediaBundleAsset(MediaBundleAsset other) : this() { + Data = other.Data; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MediaBundleAsset Clone() { + return new MediaBundleAsset(this); + } + + /// Field number for the "data" field. + public const int DataFieldNumber = 1; + private static readonly pb::FieldCodec _single_data_codec = pb::FieldCodec.ForClassWrapper(10); + private pb::ByteString data_; + /// + /// Media bundle (ZIP file) asset data. The format of the uploaded ZIP file + /// depends on the ad field where it will be used. For more information on the + /// format, see the documentation of the ad field where you plan on using the + /// MediaBundleAsset. This field is mutate only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pb::ByteString Data { + get { return data_; } + set { + data_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MediaBundleAsset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MediaBundleAsset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Data != other.Data) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (data_ != null) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (data_ != null) { + _single_data_codec.WriteTagAndValue(output, Data); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (data_ != null) { + size += _single_data_codec.CalculateSizeWithTag(Data); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MediaBundleAsset other) { + if (other == null) { + return; + } + if (other.data_ != null) { + if (data_ == null || other.Data != pb::ByteString.Empty) { + Data = other.Data; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + pb::ByteString value = _single_data_codec.Read(input); + if (data_ == null || value != pb::ByteString.Empty) { + Data = value; + } + break; + } + } + } + } + + } + + /// + /// An Image asset. + /// + public sealed partial class ImageAsset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ImageAsset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AssetTypesReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageAsset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageAsset(ImageAsset other) : this() { + Data = other.Data; + FileSize = other.FileSize; + mimeType_ = other.mimeType_; + fullSize_ = other.fullSize_ != null ? other.fullSize_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageAsset Clone() { + return new ImageAsset(this); + } + + /// Field number for the "data" field. + public const int DataFieldNumber = 1; + private static readonly pb::FieldCodec _single_data_codec = pb::FieldCodec.ForClassWrapper(10); + private pb::ByteString data_; + /// + /// The raw bytes data of an image. This field is mutate only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pb::ByteString Data { + get { return data_; } + set { + data_ = value; + } + } + + + /// Field number for the "file_size" field. + public const int FileSizeFieldNumber = 2; + private static readonly pb::FieldCodec _single_fileSize_codec = pb::FieldCodec.ForStructWrapper(18); + private long? fileSize_; + /// + /// File size of the image asset in bytes. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? FileSize { + get { return fileSize_; } + set { + fileSize_ = value; + } + } + + + /// Field number for the "mime_type" field. + public const int MimeTypeFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types.MimeType mimeType_ = 0; + /// + /// MIME type of the image asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types.MimeType MimeType { + get { return mimeType_; } + set { + mimeType_ = value; + } + } + + /// Field number for the "full_size" field. + public const int FullSizeFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Common.ImageDimension fullSize_; + /// + /// Metadata for this image at its original size. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ImageDimension FullSize { + get { return fullSize_; } + set { + fullSize_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ImageAsset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ImageAsset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Data != other.Data) return false; + if (FileSize != other.FileSize) return false; + if (MimeType != other.MimeType) return false; + if (!object.Equals(FullSize, other.FullSize)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (data_ != null) hash ^= Data.GetHashCode(); + if (fileSize_ != null) hash ^= FileSize.GetHashCode(); + if (MimeType != 0) hash ^= MimeType.GetHashCode(); + if (fullSize_ != null) hash ^= FullSize.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (data_ != null) { + _single_data_codec.WriteTagAndValue(output, Data); + } + if (fileSize_ != null) { + _single_fileSize_codec.WriteTagAndValue(output, FileSize); + } + if (MimeType != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) MimeType); + } + if (fullSize_ != null) { + output.WriteRawTag(34); + output.WriteMessage(FullSize); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (data_ != null) { + size += _single_data_codec.CalculateSizeWithTag(Data); + } + if (fileSize_ != null) { + size += _single_fileSize_codec.CalculateSizeWithTag(FileSize); + } + if (MimeType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MimeType); + } + if (fullSize_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(FullSize); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ImageAsset other) { + if (other == null) { + return; + } + if (other.data_ != null) { + if (data_ == null || other.Data != pb::ByteString.Empty) { + Data = other.Data; + } + } + if (other.fileSize_ != null) { + if (fileSize_ == null || other.FileSize != 0L) { + FileSize = other.FileSize; + } + } + if (other.MimeType != 0) { + MimeType = other.MimeType; + } + if (other.fullSize_ != null) { + if (fullSize_ == null) { + FullSize = new global::Google.Ads.GoogleAds.V3.Common.ImageDimension(); + } + FullSize.MergeFrom(other.FullSize); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + pb::ByteString value = _single_data_codec.Read(input); + if (data_ == null || value != pb::ByteString.Empty) { + Data = value; + } + break; + } + case 18: { + long? value = _single_fileSize_codec.Read(input); + if (fileSize_ == null || value != 0L) { + FileSize = value; + } + break; + } + case 24: { + MimeType = (global::Google.Ads.GoogleAds.V3.Enums.MimeTypeEnum.Types.MimeType) input.ReadEnum(); + break; + } + case 34: { + if (fullSize_ == null) { + FullSize = new global::Google.Ads.GoogleAds.V3.Common.ImageDimension(); + } + input.ReadMessage(FullSize); + break; + } + } + } + } + + } + + /// + /// Metadata for an image at a certain size, either original or resized. + /// + public sealed partial class ImageDimension : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ImageDimension()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AssetTypesReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageDimension() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageDimension(ImageDimension other) : this() { + HeightPixels = other.HeightPixels; + WidthPixels = other.WidthPixels; + Url = other.Url; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageDimension Clone() { + return new ImageDimension(this); + } + + /// Field number for the "height_pixels" field. + public const int HeightPixelsFieldNumber = 1; + private static readonly pb::FieldCodec _single_heightPixels_codec = pb::FieldCodec.ForStructWrapper(10); + private long? heightPixels_; + /// + /// Height of the image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? HeightPixels { + get { return heightPixels_; } + set { + heightPixels_ = value; + } + } + + + /// Field number for the "width_pixels" field. + public const int WidthPixelsFieldNumber = 2; + private static readonly pb::FieldCodec _single_widthPixels_codec = pb::FieldCodec.ForStructWrapper(18); + private long? widthPixels_; + /// + /// Width of the image. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? WidthPixels { + get { return widthPixels_; } + set { + widthPixels_ = value; + } + } + + + /// Field number for the "url" field. + public const int UrlFieldNumber = 3; + private static readonly pb::FieldCodec _single_url_codec = pb::FieldCodec.ForClassWrapper(26); + private string url_; + /// + /// A URL that returns the image with this height and width. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Url { + get { return url_; } + set { + url_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ImageDimension); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ImageDimension other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (HeightPixels != other.HeightPixels) return false; + if (WidthPixels != other.WidthPixels) return false; + if (Url != other.Url) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (heightPixels_ != null) hash ^= HeightPixels.GetHashCode(); + if (widthPixels_ != null) hash ^= WidthPixels.GetHashCode(); + if (url_ != null) hash ^= Url.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (heightPixels_ != null) { + _single_heightPixels_codec.WriteTagAndValue(output, HeightPixels); + } + if (widthPixels_ != null) { + _single_widthPixels_codec.WriteTagAndValue(output, WidthPixels); + } + if (url_ != null) { + _single_url_codec.WriteTagAndValue(output, Url); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (heightPixels_ != null) { + size += _single_heightPixels_codec.CalculateSizeWithTag(HeightPixels); + } + if (widthPixels_ != null) { + size += _single_widthPixels_codec.CalculateSizeWithTag(WidthPixels); + } + if (url_ != null) { + size += _single_url_codec.CalculateSizeWithTag(Url); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ImageDimension other) { + if (other == null) { + return; + } + if (other.heightPixels_ != null) { + if (heightPixels_ == null || other.HeightPixels != 0L) { + HeightPixels = other.HeightPixels; + } + } + if (other.widthPixels_ != null) { + if (widthPixels_ == null || other.WidthPixels != 0L) { + WidthPixels = other.WidthPixels; + } + } + if (other.url_ != null) { + if (url_ == null || other.Url != "") { + Url = other.Url; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_heightPixels_codec.Read(input); + if (heightPixels_ == null || value != 0L) { + HeightPixels = value; + } + break; + } + case 18: { + long? value = _single_widthPixels_codec.Read(input); + if (widthPixels_ == null || value != 0L) { + WidthPixels = value; + } + break; + } + case 26: { + string value = _single_url_codec.Read(input); + if (url_ == null || value != "") { + Url = value; + } + break; + } + } + } + } + + } + + /// + /// A Text asset. + /// + public sealed partial class TextAsset : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TextAsset()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.AssetTypesReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextAsset() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextAsset(TextAsset other) : this() { + Text = other.Text; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextAsset Clone() { + return new TextAsset(this); + } + + /// Field number for the "text" field. + public const int TextFieldNumber = 1; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(10); + private string text_; + /// + /// Text content of the text asset. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TextAsset); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TextAsset other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Text != other.Text) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (text_ != null) hash ^= Text.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TextAsset other) { + if (other == null) { + return; + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AttributionModel.cs b/src/V3/Stubs/AttributionModel.cs new file mode 100644 index 000000000..37a79d783 --- /dev/null +++ b/src/V3/Stubs/AttributionModel.cs @@ -0,0 +1,219 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/attribution_model.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/attribution_model.proto + public static partial class AttributionModelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/attribution_model.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AttributionModelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hdHRyaWJ1dGlvbl9t", + "b2RlbC5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdv", + "b2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ixgIKFEF0dHJpYnV0aW9uTW9k", + "ZWxFbnVtIq0CChBBdHRyaWJ1dGlvbk1vZGVsEg8KC1VOU1BFQ0lGSUVEEAAS", + "CwoHVU5LTk9XThABEgwKCEVYVEVSTkFMEGQSGQoVR09PR0xFX0FEU19MQVNU", + "X0NMSUNLEGUSKQolR09PR0xFX1NFQVJDSF9BVFRSSUJVVElPTl9GSVJTVF9D", + "TElDSxBmEiQKIEdPT0dMRV9TRUFSQ0hfQVRUUklCVVRJT05fTElORUFSEGcS", + "KAokR09PR0xFX1NFQVJDSF9BVFRSSUJVVElPTl9USU1FX0RFQ0FZEGgSLAoo", + "R09PR0xFX1NFQVJDSF9BVFRSSUJVVElPTl9QT1NJVElPTl9CQVNFRBBpEikK", + "JUdPT0dMRV9TRUFSQ0hfQVRUUklCVVRJT05fREFUQV9EUklWRU4QakLqAQoh", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhVBdHRyaWJ1dGlv", + "bk1vZGVsUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgId", + "R29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYz", + "OjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.AttributionModelEnum), global::Google.Ads.GoogleAds.V3.Enums.AttributionModelEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.AttributionModelEnum.Types.AttributionModel) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum representing the attribution model that describes how to + /// distribute credit for a particular conversion across potentially many prior + /// interactions. + /// + public sealed partial class AttributionModelEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AttributionModelEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.AttributionModelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributionModelEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributionModelEnum(AttributionModelEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributionModelEnum Clone() { + return new AttributionModelEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AttributionModelEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AttributionModelEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AttributionModelEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AttributionModelEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The attribution model that describes how to distribute credit for a + /// particular conversion across potentially many prior interactions. + /// + public enum AttributionModel { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Uses external attribution. + /// + [pbr::OriginalName("EXTERNAL")] External = 100, + /// + /// Attributes all credit for a conversion to its last click. + /// + [pbr::OriginalName("GOOGLE_ADS_LAST_CLICK")] GoogleAdsLastClick = 101, + /// + /// Attributes all credit for a conversion to its first click using Google + /// Search attribution. + /// + [pbr::OriginalName("GOOGLE_SEARCH_ATTRIBUTION_FIRST_CLICK")] GoogleSearchAttributionFirstClick = 102, + /// + /// Attributes credit for a conversion equally across all of its clicks using + /// Google Search attribution. + /// + [pbr::OriginalName("GOOGLE_SEARCH_ATTRIBUTION_LINEAR")] GoogleSearchAttributionLinear = 103, + /// + /// Attributes exponentially more credit for a conversion to its more recent + /// clicks using Google Search attribution (half-life is 1 week). + /// + [pbr::OriginalName("GOOGLE_SEARCH_ATTRIBUTION_TIME_DECAY")] GoogleSearchAttributionTimeDecay = 104, + /// + /// Attributes 40% of the credit for a conversion to its first and last + /// clicks. Remaining 20% is evenly distributed across all other clicks. This + /// uses Google Search attribution. + /// + [pbr::OriginalName("GOOGLE_SEARCH_ATTRIBUTION_POSITION_BASED")] GoogleSearchAttributionPositionBased = 105, + /// + /// Flexible model that uses machine learning to determine the appropriate + /// distribution of credit among clicks using Google Search attribution. + /// + [pbr::OriginalName("GOOGLE_SEARCH_ATTRIBUTION_DATA_DRIVEN")] GoogleSearchAttributionDataDriven = 106, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AuthenticationError.cs b/src/V3/Stubs/AuthenticationError.cs new file mode 100644 index 000000000..1793d1cb2 --- /dev/null +++ b/src/V3/Stubs/AuthenticationError.cs @@ -0,0 +1,266 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/authentication_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/authentication_error.proto + public static partial class AuthenticationErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/authentication_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AuthenticationErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYXV0aGVudGljYXRp", + "b25fZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9y", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLoBAoXQXV0aGVudGlj", + "YXRpb25FcnJvckVudW0izAQKE0F1dGhlbnRpY2F0aW9uRXJyb3ISDwoLVU5T", + "UEVDSUZJRUQQABILCgdVTktOT1dOEAESGAoUQVVUSEVOVElDQVRJT05fRVJS", + "T1IQAhIeChpDTElFTlRfQ1VTVE9NRVJfSURfSU5WQUxJRBAFEhYKEkNVU1RP", + "TUVSX05PVF9GT1VORBAIEhoKFkdPT0dMRV9BQ0NPVU5UX0RFTEVURUQQCRIh", + "Ch1HT09HTEVfQUNDT1VOVF9DT09LSUVfSU5WQUxJRBAKEigKJEdPT0dMRV9B", + "Q0NPVU5UX0FVVEhFTlRJQ0FUSU9OX0ZBSUxFRBAZEi0KKUdPT0dMRV9BQ0NP", + "VU5UX1VTRVJfQU5EX0FEU19VU0VSX01JU01BVENIEAwSGQoVTE9HSU5fQ09P", + "S0lFX1JFUVVJUkVEEA0SEAoMTk9UX0FEU19VU0VSEA4SFwoTT0FVVEhfVE9L", + "RU5fSU5WQUxJRBAPEhcKE09BVVRIX1RPS0VOX0VYUElSRUQQEBIYChRPQVVU", + "SF9UT0tFTl9ESVNBQkxFRBAREhcKE09BVVRIX1RPS0VOX1JFVk9LRUQQEhIe", + "ChpPQVVUSF9UT0tFTl9IRUFERVJfSU5WQUxJRBATEhgKFExPR0lOX0NPT0tJ", + "RV9JTlZBTElEEBQSEwoPVVNFUl9JRF9JTlZBTElEEBYSJgoiVFdPX1NURVBf", + "VkVSSUZJQ0FUSU9OX05PVF9FTlJPTExFRBAXEiQKIEFEVkFOQ0VEX1BST1RF", + "Q1RJT05fTk9UX0VOUk9MTEVEEBhC8wEKImNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnNCGEF1dGhlbnRpY2F0aW9uRXJyb3JQcm90b1ABWkRn", + "b29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29n", + "bGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVy", + "cm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AuthenticationErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AuthenticationErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AuthenticationErrorEnum.Types.AuthenticationError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible authentication errors. + /// + public sealed partial class AuthenticationErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AuthenticationErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AuthenticationErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AuthenticationErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AuthenticationErrorEnum(AuthenticationErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AuthenticationErrorEnum Clone() { + return new AuthenticationErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AuthenticationErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AuthenticationErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AuthenticationErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AuthenticationErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible authentication errors. + /// + public enum AuthenticationError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Authentication of the request failed. + /// + [pbr::OriginalName("AUTHENTICATION_ERROR")] AuthenticationError = 2, + /// + /// Client Customer Id is not a number. + /// + [pbr::OriginalName("CLIENT_CUSTOMER_ID_INVALID")] ClientCustomerIdInvalid = 5, + /// + /// No customer found for the provided customer id. + /// + [pbr::OriginalName("CUSTOMER_NOT_FOUND")] CustomerNotFound = 8, + /// + /// Client's Google Account is deleted. + /// + [pbr::OriginalName("GOOGLE_ACCOUNT_DELETED")] GoogleAccountDeleted = 9, + /// + /// Google account login token in the cookie is invalid. + /// + [pbr::OriginalName("GOOGLE_ACCOUNT_COOKIE_INVALID")] GoogleAccountCookieInvalid = 10, + /// + /// A problem occurred during Google account authentication. + /// + [pbr::OriginalName("GOOGLE_ACCOUNT_AUTHENTICATION_FAILED")] GoogleAccountAuthenticationFailed = 25, + /// + /// The user in the google account login token does not match the UserId in + /// the cookie. + /// + [pbr::OriginalName("GOOGLE_ACCOUNT_USER_AND_ADS_USER_MISMATCH")] GoogleAccountUserAndAdsUserMismatch = 12, + /// + /// Login cookie is required for authentication. + /// + [pbr::OriginalName("LOGIN_COOKIE_REQUIRED")] LoginCookieRequired = 13, + /// + /// User in the cookie is not a valid Ads user. + /// + [pbr::OriginalName("NOT_ADS_USER")] NotAdsUser = 14, + /// + /// Oauth token in the header is not valid. + /// + [pbr::OriginalName("OAUTH_TOKEN_INVALID")] OauthTokenInvalid = 15, + /// + /// Oauth token in the header has expired. + /// + [pbr::OriginalName("OAUTH_TOKEN_EXPIRED")] OauthTokenExpired = 16, + /// + /// Oauth token in the header has been disabled. + /// + [pbr::OriginalName("OAUTH_TOKEN_DISABLED")] OauthTokenDisabled = 17, + /// + /// Oauth token in the header has been revoked. + /// + [pbr::OriginalName("OAUTH_TOKEN_REVOKED")] OauthTokenRevoked = 18, + /// + /// Oauth token HTTP header is malformed. + /// + [pbr::OriginalName("OAUTH_TOKEN_HEADER_INVALID")] OauthTokenHeaderInvalid = 19, + /// + /// Login cookie is not valid. + /// + [pbr::OriginalName("LOGIN_COOKIE_INVALID")] LoginCookieInvalid = 20, + /// + /// User Id in the header is not a valid id. + /// + [pbr::OriginalName("USER_ID_INVALID")] UserIdInvalid = 22, + /// + /// An account administrator changed this account's authentication settings. + /// To access this Google Ads account, enable 2-Step Verification in your + /// Google account at https://www.google.com/landing/2step. + /// + [pbr::OriginalName("TWO_STEP_VERIFICATION_NOT_ENROLLED")] TwoStepVerificationNotEnrolled = 23, + /// + /// An account administrator changed this account's authentication settings. + /// To access this Google Ads account, enable Advanced Protection in your + /// Google account at https://landing.google.com/advancedprotection. + /// + [pbr::OriginalName("ADVANCED_PROTECTION_NOT_ENROLLED")] AdvancedProtectionNotEnrolled = 24, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/AuthorizationError.cs b/src/V3/Stubs/AuthorizationError.cs new file mode 100644 index 000000000..b9784ac26 --- /dev/null +++ b/src/V3/Stubs/AuthorizationError.cs @@ -0,0 +1,241 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/authorization_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/authorization_error.proto + public static partial class AuthorizationErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/authorization_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static AuthorizationErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYXV0aG9yaXphdGlv", + "bl9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIrUDChZBdXRob3JpemF0", + "aW9uRXJyb3JFbnVtIpoDChJBdXRob3JpemF0aW9uRXJyb3ISDwoLVU5TUEVD", + "SUZJRUQQABILCgdVTktOT1dOEAESGgoWVVNFUl9QRVJNSVNTSU9OX0RFTklF", + "RBACEiMKH0RFVkVMT1BFUl9UT0tFTl9OT1RfV0hJVEVMSVNURUQQAxIeChpE", + "RVZFTE9QRVJfVE9LRU5fUFJPSElCSVRFRBAEEhQKEFBST0pFQ1RfRElTQUJM", + "RUQQBRIXChNBVVRIT1JJWkFUSU9OX0VSUk9SEAYSGAoUQUNUSU9OX05PVF9Q", + "RVJNSVRURUQQBxIVChFJTkNPTVBMRVRFX1NJR05VUBAIEhgKFENVU1RPTUVS", + "X05PVF9FTkFCTEVEEBgSDwoLTUlTU0lOR19UT1MQCRIgChxERVZFTE9QRVJf", + "VE9LRU5fTk9UX0FQUFJPVkVEEAoSPQo5SU5WQUxJRF9MT0dJTl9DVVNUT01F", + "Ul9JRF9TRVJWSU5HX0NVU1RPTUVSX0lEX0NPTUJJTkFUSU9OEAsSGQoVU0VS", + "VklDRV9BQ0NFU1NfREVOSUVEEAxC8gEKImNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnNCF0F1dGhvcml6YXRpb25FcnJvclByb3RvUAFaRGdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9lcnJvcnM7ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29n", + "bGVBZHMuVjMuRXJyb3JzygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJy", + "b3Jz6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJv", + "dG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.AuthorizationErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.AuthorizationErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.AuthorizationErrorEnum.Types.AuthorizationError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible authorization errors. + /// + public sealed partial class AuthorizationErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AuthorizationErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.AuthorizationErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AuthorizationErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AuthorizationErrorEnum(AuthorizationErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AuthorizationErrorEnum Clone() { + return new AuthorizationErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AuthorizationErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AuthorizationErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AuthorizationErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the AuthorizationErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible authorization errors. + /// + public enum AuthorizationError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// User doesn't have permission to access customer. Note: If you're + /// accessing a client customer, the manager's customer ID must be set in the + /// `login-customer-id` header. Learn more at + /// https://developers.google.com/google-ads/api/docs/concepts/call-structure#cid + /// + [pbr::OriginalName("USER_PERMISSION_DENIED")] UserPermissionDenied = 2, + /// + /// The developer token is not whitelisted. + /// + [pbr::OriginalName("DEVELOPER_TOKEN_NOT_WHITELISTED")] DeveloperTokenNotWhitelisted = 3, + /// + /// The developer token is not allowed with the project sent in the request. + /// + [pbr::OriginalName("DEVELOPER_TOKEN_PROHIBITED")] DeveloperTokenProhibited = 4, + /// + /// The Google Cloud project sent in the request does not have permission to + /// access the api. + /// + [pbr::OriginalName("PROJECT_DISABLED")] ProjectDisabled = 5, + /// + /// Authorization of the client failed. + /// + [pbr::OriginalName("AUTHORIZATION_ERROR")] AuthorizationError = 6, + /// + /// The user does not have permission to perform this action + /// (e.g., ADD, UPDATE, REMOVE) on the resource or call a method. + /// + [pbr::OriginalName("ACTION_NOT_PERMITTED")] ActionNotPermitted = 7, + /// + /// Signup not complete. + /// + [pbr::OriginalName("INCOMPLETE_SIGNUP")] IncompleteSignup = 8, + /// + /// The customer can't be used because it isn't enabled. + /// + [pbr::OriginalName("CUSTOMER_NOT_ENABLED")] CustomerNotEnabled = 24, + /// + /// The developer must sign the terms of service. They can be found here: + /// ads.google.com/aw/apicenter + /// + [pbr::OriginalName("MISSING_TOS")] MissingTos = 9, + /// + /// The developer token is not approved. Non-approved developer tokens can + /// only be used with test accounts. + /// + [pbr::OriginalName("DEVELOPER_TOKEN_NOT_APPROVED")] DeveloperTokenNotApproved = 10, + /// + /// The login customer specified does not have access to the account + /// specified, so the request is invalid. + /// + [pbr::OriginalName("INVALID_LOGIN_CUSTOMER_ID_SERVING_CUSTOMER_ID_COMBINATION")] InvalidLoginCustomerIdServingCustomerIdCombination = 11, + /// + /// The developer specified does not have access to the service. + /// + [pbr::OriginalName("SERVICE_ACCESS_DENIED")] ServiceAccessDenied = 12, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BidModifierSource.cs b/src/V3/Stubs/BidModifierSource.cs new file mode 100644 index 000000000..d80e269ab --- /dev/null +++ b/src/V3/Stubs/BidModifierSource.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/bid_modifier_source.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/bid_modifier_source.proto + public static partial class BidModifierSourceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/bid_modifier_source.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BidModifierSourceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9iaWRfbW9kaWZpZXJf", + "c291cmNlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxoc", + "Z29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJmChVCaWRNb2RpZmllclNv", + "dXJjZUVudW0iTQoRQmlkTW9kaWZpZXJTb3VyY2USDwoLVU5TUEVDSUZJRUQQ", + "ABILCgdVTktOT1dOEAESDAoIQ0FNUEFJR04QAhIMCghBRF9HUk9VUBADQusB", + "CiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCFkJpZE1vZGlm", + "aWVyU291cmNlUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8v", + "Z29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FB", + "qgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRz", + "XEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BidModifierSourceEnum), global::Google.Ads.GoogleAds.V3.Enums.BidModifierSourceEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BidModifierSourceEnum.Types.BidModifierSource) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible bid modifier sources. + /// + public sealed partial class BidModifierSourceEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BidModifierSourceEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BidModifierSourceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BidModifierSourceEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BidModifierSourceEnum(BidModifierSourceEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BidModifierSourceEnum Clone() { + return new BidModifierSourceEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BidModifierSourceEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BidModifierSourceEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BidModifierSourceEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BidModifierSourceEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible bid modifier sources. + /// + public enum BidModifierSource { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The bid modifier is specified at the campaign level, on the campaign + /// level criterion. + /// + [pbr::OriginalName("CAMPAIGN")] Campaign = 2, + /// + /// The bid modifier is specified (overridden) at the ad group level. + /// + [pbr::OriginalName("AD_GROUP")] AdGroup = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Bidding.cs b/src/V3/Stubs/Bidding.cs new file mode 100644 index 000000000..4cd34ef2d --- /dev/null +++ b/src/V3/Stubs/Bidding.cs @@ -0,0 +1,2068 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/bidding.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/bidding.proto + public static partial class BiddingReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/bidding.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BiddingReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cixnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vYmlkZGluZy5wcm90", + "bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uGkRnb29nbGUvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcy90YXJnZXRfaW1wcmVzc2lvbl9zaGFyZV9s", + "b2NhdGlvbi5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3Rv", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIkkKCkNvbW1pc3Npb24S", + "OwoWY29tbWlzc2lvbl9yYXRlX21pY3JvcxgBIAEoCzIbLmdvb2dsZS5wcm90", + "b2J1Zi5JbnQ2NFZhbHVlIg0KC0VuaGFuY2VkQ3BjIkUKCU1hbnVhbENwYxI4", + "ChRlbmhhbmNlZF9jcGNfZW5hYmxlZBgBIAEoCzIaLmdvb2dsZS5wcm90b2J1", + "Zi5Cb29sVmFsdWUiCwoJTWFudWFsQ3BtIgsKCU1hbnVhbENwdiIVChNNYXhp", + "bWl6ZUNvbnZlcnNpb25zIkwKF01heGltaXplQ29udmVyc2lvblZhbHVlEjEK", + "C3RhcmdldF9yb2FzGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLkRvdWJsZVZh", + "bHVlIrsBCglUYXJnZXRDcGESNgoRdGFyZ2V0X2NwYV9taWNyb3MYASABKAsy", + "Gy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZRI7ChZjcGNfYmlkX2NlaWxp", + "bmdfbWljcm9zGAIgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUS", + "OQoUY3BjX2JpZF9mbG9vcl9taWNyb3MYAyABKAsyGy5nb29nbGUucHJvdG9i", + "dWYuSW50NjRWYWx1ZSILCglUYXJnZXRDcG0ihQIKFVRhcmdldEltcHJlc3Np", + "b25TaGFyZRJwCghsb2NhdGlvbhgBIAEoDjJeLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zLlRhcmdldEltcHJlc3Npb25TaGFyZUxvY2F0aW9uRW51", + "bS5UYXJnZXRJbXByZXNzaW9uU2hhcmVMb2NhdGlvbhI9Chhsb2NhdGlvbl9m", + "cmFjdGlvbl9taWNyb3MYAiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRW", + "YWx1ZRI7ChZjcGNfYmlkX2NlaWxpbmdfbWljcm9zGAMgASgLMhsuZ29vZ2xl", + "LnByb3RvYnVmLkludDY0VmFsdWUitwEKClRhcmdldFJvYXMSMQoLdGFyZ2V0", + "X3JvYXMYASABKAsyHC5nb29nbGUucHJvdG9idWYuRG91YmxlVmFsdWUSOwoW", + "Y3BjX2JpZF9jZWlsaW5nX21pY3JvcxgCIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQ2NFZhbHVlEjkKFGNwY19iaWRfZmxvb3JfbWljcm9zGAMgASgLMhsu", + "Z29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUihAEKC1RhcmdldFNwZW5kEjgK", + "E3RhcmdldF9zcGVuZF9taWNyb3MYASABKAsyGy5nb29nbGUucHJvdG9idWYu", + "SW50NjRWYWx1ZRI7ChZjcGNfYmlkX2NlaWxpbmdfbWljcm9zGAIgASgLMhsu", + "Z29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUigwEKClBlcmNlbnRDcGMSOwoW", + "Y3BjX2JpZF9jZWlsaW5nX21pY3JvcxgBIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQ2NFZhbHVlEjgKFGVuaGFuY2VkX2NwY19lbmFibGVkGAIgASgLMhou", + "Z29vZ2xlLnByb3RvYnVmLkJvb2xWYWx1ZULnAQoiY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmNvbW1vbkIMQmlkZGluZ1Byb3RvUAFaRGdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9jb21tb247Y29tbW9uogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMu", + "VjMuQ29tbW9uygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcQ29tbW9u6gIi", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkNvbW1vbmIGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.TargetImpressionShareLocationReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.Commission), global::Google.Ads.GoogleAds.V3.Common.Commission.Parser, new[]{ "CommissionRateMicros" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.EnhancedCpc), global::Google.Ads.GoogleAds.V3.Common.EnhancedCpc.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ManualCpc), global::Google.Ads.GoogleAds.V3.Common.ManualCpc.Parser, new[]{ "EnhancedCpcEnabled" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ManualCpm), global::Google.Ads.GoogleAds.V3.Common.ManualCpm.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ManualCpv), global::Google.Ads.GoogleAds.V3.Common.ManualCpv.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.MaximizeConversions), global::Google.Ads.GoogleAds.V3.Common.MaximizeConversions.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.MaximizeConversionValue), global::Google.Ads.GoogleAds.V3.Common.MaximizeConversionValue.Parser, new[]{ "TargetRoas" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TargetCpa), global::Google.Ads.GoogleAds.V3.Common.TargetCpa.Parser, new[]{ "TargetCpaMicros", "CpcBidCeilingMicros", "CpcBidFloorMicros" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TargetCpm), global::Google.Ads.GoogleAds.V3.Common.TargetCpm.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare), global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare.Parser, new[]{ "Location", "LocationFractionMicros", "CpcBidCeilingMicros" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TargetRoas), global::Google.Ads.GoogleAds.V3.Common.TargetRoas.Parser, new[]{ "TargetRoas_", "CpcBidCeilingMicros", "CpcBidFloorMicros" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TargetSpend), global::Google.Ads.GoogleAds.V3.Common.TargetSpend.Parser, new[]{ "TargetSpendMicros", "CpcBidCeilingMicros" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.PercentCpc), global::Google.Ads.GoogleAds.V3.Common.PercentCpc.Parser, new[]{ "CpcBidCeilingMicros", "EnhancedCpcEnabled" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Commission is an automatic bidding strategy in which the advertiser pays a + /// certain portion of the conversion value. + /// + public sealed partial class Commission : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Commission()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Commission() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Commission(Commission other) : this() { + CommissionRateMicros = other.CommissionRateMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Commission Clone() { + return new Commission(this); + } + + /// Field number for the "commission_rate_micros" field. + public const int CommissionRateMicrosFieldNumber = 1; + private static readonly pb::FieldCodec _single_commissionRateMicros_codec = pb::FieldCodec.ForStructWrapper(10); + private long? commissionRateMicros_; + /// + /// Commission rate defines the portion of the conversion value that the + /// advertiser will be billed. A commission rate of x should be passed into + /// this field as (x * 1,000,000). For example, 106,000 represents a commission + /// rate of 0.106 (10.6%). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CommissionRateMicros { + get { return commissionRateMicros_; } + set { + commissionRateMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as Commission); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(Commission other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CommissionRateMicros != other.CommissionRateMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (commissionRateMicros_ != null) hash ^= CommissionRateMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (commissionRateMicros_ != null) { + _single_commissionRateMicros_codec.WriteTagAndValue(output, CommissionRateMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (commissionRateMicros_ != null) { + size += _single_commissionRateMicros_codec.CalculateSizeWithTag(CommissionRateMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(Commission other) { + if (other == null) { + return; + } + if (other.commissionRateMicros_ != null) { + if (commissionRateMicros_ == null || other.CommissionRateMicros != 0L) { + CommissionRateMicros = other.CommissionRateMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_commissionRateMicros_codec.Read(input); + if (commissionRateMicros_ == null || value != 0L) { + CommissionRateMicros = value; + } + break; + } + } + } + } + + } + + /// + /// An automated bidding strategy that raises bids for clicks + /// that seem more likely to lead to a conversion and lowers + /// them for clicks where they seem less likely. + /// + public sealed partial class EnhancedCpc : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new EnhancedCpc()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EnhancedCpc() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EnhancedCpc(EnhancedCpc other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EnhancedCpc Clone() { + return new EnhancedCpc(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as EnhancedCpc); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(EnhancedCpc other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(EnhancedCpc other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// Manual click-based bidding where user pays per click. + /// + public sealed partial class ManualCpc : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ManualCpc()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpc() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpc(ManualCpc other) : this() { + EnhancedCpcEnabled = other.EnhancedCpcEnabled; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpc Clone() { + return new ManualCpc(this); + } + + /// Field number for the "enhanced_cpc_enabled" field. + public const int EnhancedCpcEnabledFieldNumber = 1; + private static readonly pb::FieldCodec _single_enhancedCpcEnabled_codec = pb::FieldCodec.ForStructWrapper(10); + private bool? enhancedCpcEnabled_; + /// + /// Whether bids are to be enhanced based on conversion optimizer data. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? EnhancedCpcEnabled { + get { return enhancedCpcEnabled_; } + set { + enhancedCpcEnabled_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ManualCpc); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ManualCpc other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (EnhancedCpcEnabled != other.EnhancedCpcEnabled) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (enhancedCpcEnabled_ != null) hash ^= EnhancedCpcEnabled.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (enhancedCpcEnabled_ != null) { + _single_enhancedCpcEnabled_codec.WriteTagAndValue(output, EnhancedCpcEnabled); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (enhancedCpcEnabled_ != null) { + size += _single_enhancedCpcEnabled_codec.CalculateSizeWithTag(EnhancedCpcEnabled); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ManualCpc other) { + if (other == null) { + return; + } + if (other.enhancedCpcEnabled_ != null) { + if (enhancedCpcEnabled_ == null || other.EnhancedCpcEnabled != false) { + EnhancedCpcEnabled = other.EnhancedCpcEnabled; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + bool? value = _single_enhancedCpcEnabled_codec.Read(input); + if (enhancedCpcEnabled_ == null || value != false) { + EnhancedCpcEnabled = value; + } + break; + } + } + } + } + + } + + /// + /// Manual impression-based bidding where user pays per thousand impressions. + /// + public sealed partial class ManualCpm : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ManualCpm()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpm() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpm(ManualCpm other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpm Clone() { + return new ManualCpm(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ManualCpm); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ManualCpm other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ManualCpm other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// View based bidding where user pays per video view. + /// + public sealed partial class ManualCpv : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ManualCpv()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpv() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpv(ManualCpv other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ManualCpv Clone() { + return new ManualCpv(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ManualCpv); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ManualCpv other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ManualCpv other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// An automated bidding strategy that sets bids to help get the most conversions + /// for your campaign while spending your budget. + /// + public sealed partial class MaximizeConversions : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MaximizeConversions()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MaximizeConversions() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MaximizeConversions(MaximizeConversions other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MaximizeConversions Clone() { + return new MaximizeConversions(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MaximizeConversions); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MaximizeConversions other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MaximizeConversions other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// An automated bidding strategy which tries to maximize conversion value + /// given a daily budget. + /// + public sealed partial class MaximizeConversionValue : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MaximizeConversionValue()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MaximizeConversionValue() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MaximizeConversionValue(MaximizeConversionValue other) : this() { + TargetRoas = other.TargetRoas; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MaximizeConversionValue Clone() { + return new MaximizeConversionValue(this); + } + + /// Field number for the "target_roas" field. + public const int TargetRoasFieldNumber = 1; + private static readonly pb::FieldCodec _single_targetRoas_codec = pb::FieldCodec.ForStructWrapper(10); + private double? targetRoas_; + /// + /// The target return on ad spend (ROAS) option. If set, the bid strategy will + /// maximize revenue while averaging the target return on ad spend. If the + /// target ROAS is high, the bid strategy may not be able to spend the full + /// budget. If the target ROAS is not set, the bid strategy will aim to + /// achieve the highest possible ROAS for the budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? TargetRoas { + get { return targetRoas_; } + set { + targetRoas_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MaximizeConversionValue); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MaximizeConversionValue other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(TargetRoas, other.TargetRoas)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (targetRoas_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(TargetRoas); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (targetRoas_ != null) { + _single_targetRoas_codec.WriteTagAndValue(output, TargetRoas); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (targetRoas_ != null) { + size += _single_targetRoas_codec.CalculateSizeWithTag(TargetRoas); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MaximizeConversionValue other) { + if (other == null) { + return; + } + if (other.targetRoas_ != null) { + if (targetRoas_ == null || other.TargetRoas != 0D) { + TargetRoas = other.TargetRoas; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + double? value = _single_targetRoas_codec.Read(input); + if (targetRoas_ == null || value != 0D) { + TargetRoas = value; + } + break; + } + } + } + } + + } + + /// + /// An automated bid strategy that sets bids to help get as many conversions as + /// possible at the target cost-per-acquisition (CPA) you set. + /// + public sealed partial class TargetCpa : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TargetCpa()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetCpa() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetCpa(TargetCpa other) : this() { + TargetCpaMicros = other.TargetCpaMicros; + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + CpcBidFloorMicros = other.CpcBidFloorMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetCpa Clone() { + return new TargetCpa(this); + } + + /// Field number for the "target_cpa_micros" field. + public const int TargetCpaMicrosFieldNumber = 1; + private static readonly pb::FieldCodec _single_targetCpaMicros_codec = pb::FieldCodec.ForStructWrapper(10); + private long? targetCpaMicros_; + /// + /// Average CPA target. + /// This target should be greater than or equal to minimum billable unit based + /// on the currency for the account. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TargetCpaMicros { + get { return targetCpaMicros_; } + set { + targetCpaMicros_ = value; + } + } + + + /// Field number for the "cpc_bid_ceiling_micros" field. + public const int CpcBidCeilingMicrosFieldNumber = 2; + private static readonly pb::FieldCodec _single_cpcBidCeilingMicros_codec = pb::FieldCodec.ForStructWrapper(18); + private long? cpcBidCeilingMicros_; + /// + /// Maximum bid limit that can be set by the bid strategy. + /// The limit applies to all keywords managed by the strategy. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidCeilingMicros { + get { return cpcBidCeilingMicros_; } + set { + cpcBidCeilingMicros_ = value; + } + } + + + /// Field number for the "cpc_bid_floor_micros" field. + public const int CpcBidFloorMicrosFieldNumber = 3; + private static readonly pb::FieldCodec _single_cpcBidFloorMicros_codec = pb::FieldCodec.ForStructWrapper(26); + private long? cpcBidFloorMicros_; + /// + /// Minimum bid limit that can be set by the bid strategy. + /// The limit applies to all keywords managed by the strategy. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidFloorMicros { + get { return cpcBidFloorMicros_; } + set { + cpcBidFloorMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TargetCpa); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TargetCpa other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (TargetCpaMicros != other.TargetCpaMicros) return false; + if (CpcBidCeilingMicros != other.CpcBidCeilingMicros) return false; + if (CpcBidFloorMicros != other.CpcBidFloorMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (targetCpaMicros_ != null) hash ^= TargetCpaMicros.GetHashCode(); + if (cpcBidCeilingMicros_ != null) hash ^= CpcBidCeilingMicros.GetHashCode(); + if (cpcBidFloorMicros_ != null) hash ^= CpcBidFloorMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (targetCpaMicros_ != null) { + _single_targetCpaMicros_codec.WriteTagAndValue(output, TargetCpaMicros); + } + if (cpcBidCeilingMicros_ != null) { + _single_cpcBidCeilingMicros_codec.WriteTagAndValue(output, CpcBidCeilingMicros); + } + if (cpcBidFloorMicros_ != null) { + _single_cpcBidFloorMicros_codec.WriteTagAndValue(output, CpcBidFloorMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (targetCpaMicros_ != null) { + size += _single_targetCpaMicros_codec.CalculateSizeWithTag(TargetCpaMicros); + } + if (cpcBidCeilingMicros_ != null) { + size += _single_cpcBidCeilingMicros_codec.CalculateSizeWithTag(CpcBidCeilingMicros); + } + if (cpcBidFloorMicros_ != null) { + size += _single_cpcBidFloorMicros_codec.CalculateSizeWithTag(CpcBidFloorMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TargetCpa other) { + if (other == null) { + return; + } + if (other.targetCpaMicros_ != null) { + if (targetCpaMicros_ == null || other.TargetCpaMicros != 0L) { + TargetCpaMicros = other.TargetCpaMicros; + } + } + if (other.cpcBidCeilingMicros_ != null) { + if (cpcBidCeilingMicros_ == null || other.CpcBidCeilingMicros != 0L) { + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + } + } + if (other.cpcBidFloorMicros_ != null) { + if (cpcBidFloorMicros_ == null || other.CpcBidFloorMicros != 0L) { + CpcBidFloorMicros = other.CpcBidFloorMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_targetCpaMicros_codec.Read(input); + if (targetCpaMicros_ == null || value != 0L) { + TargetCpaMicros = value; + } + break; + } + case 18: { + long? value = _single_cpcBidCeilingMicros_codec.Read(input); + if (cpcBidCeilingMicros_ == null || value != 0L) { + CpcBidCeilingMicros = value; + } + break; + } + case 26: { + long? value = _single_cpcBidFloorMicros_codec.Read(input); + if (cpcBidFloorMicros_ == null || value != 0L) { + CpcBidFloorMicros = value; + } + break; + } + } + } + } + + } + + /// + /// Target CPM (cost per thousand impressions) is an automated bidding strategy + /// that sets bids to optimize performance given the target CPM you set. + /// + public sealed partial class TargetCpm : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TargetCpm()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetCpm() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetCpm(TargetCpm other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetCpm Clone() { + return new TargetCpm(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TargetCpm); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TargetCpm other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TargetCpm other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// An automated bidding strategy that sets bids so that a certain percentage of + /// search ads are shown at the top of the first page (or other targeted + /// location). + /// Next Id = 4 + /// + public sealed partial class TargetImpressionShare : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TargetImpressionShare()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[9]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetImpressionShare() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetImpressionShare(TargetImpressionShare other) : this() { + location_ = other.location_; + LocationFractionMicros = other.LocationFractionMicros; + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetImpressionShare Clone() { + return new TargetImpressionShare(this); + } + + /// Field number for the "location" field. + public const int LocationFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.TargetImpressionShareLocationEnum.Types.TargetImpressionShareLocation location_ = 0; + /// + /// The targeted location on the search results page. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TargetImpressionShareLocationEnum.Types.TargetImpressionShareLocation Location { + get { return location_; } + set { + location_ = value; + } + } + + /// Field number for the "location_fraction_micros" field. + public const int LocationFractionMicrosFieldNumber = 2; + private static readonly pb::FieldCodec _single_locationFractionMicros_codec = pb::FieldCodec.ForStructWrapper(18); + private long? locationFractionMicros_; + /// + /// The desired fraction of ads to be shown in the targeted location in micros. + /// E.g. 1% equals 10,000. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? LocationFractionMicros { + get { return locationFractionMicros_; } + set { + locationFractionMicros_ = value; + } + } + + + /// Field number for the "cpc_bid_ceiling_micros" field. + public const int CpcBidCeilingMicrosFieldNumber = 3; + private static readonly pb::FieldCodec _single_cpcBidCeilingMicros_codec = pb::FieldCodec.ForStructWrapper(26); + private long? cpcBidCeilingMicros_; + /// + /// The highest CPC bid the automated bidding system is permitted to specify. + /// This is a required field entered by the advertiser that sets the ceiling + /// and specified in local micros. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidCeilingMicros { + get { return cpcBidCeilingMicros_; } + set { + cpcBidCeilingMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TargetImpressionShare); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TargetImpressionShare other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Location != other.Location) return false; + if (LocationFractionMicros != other.LocationFractionMicros) return false; + if (CpcBidCeilingMicros != other.CpcBidCeilingMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Location != 0) hash ^= Location.GetHashCode(); + if (locationFractionMicros_ != null) hash ^= LocationFractionMicros.GetHashCode(); + if (cpcBidCeilingMicros_ != null) hash ^= CpcBidCeilingMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Location != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Location); + } + if (locationFractionMicros_ != null) { + _single_locationFractionMicros_codec.WriteTagAndValue(output, LocationFractionMicros); + } + if (cpcBidCeilingMicros_ != null) { + _single_cpcBidCeilingMicros_codec.WriteTagAndValue(output, CpcBidCeilingMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Location != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Location); + } + if (locationFractionMicros_ != null) { + size += _single_locationFractionMicros_codec.CalculateSizeWithTag(LocationFractionMicros); + } + if (cpcBidCeilingMicros_ != null) { + size += _single_cpcBidCeilingMicros_codec.CalculateSizeWithTag(CpcBidCeilingMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TargetImpressionShare other) { + if (other == null) { + return; + } + if (other.Location != 0) { + Location = other.Location; + } + if (other.locationFractionMicros_ != null) { + if (locationFractionMicros_ == null || other.LocationFractionMicros != 0L) { + LocationFractionMicros = other.LocationFractionMicros; + } + } + if (other.cpcBidCeilingMicros_ != null) { + if (cpcBidCeilingMicros_ == null || other.CpcBidCeilingMicros != 0L) { + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Location = (global::Google.Ads.GoogleAds.V3.Enums.TargetImpressionShareLocationEnum.Types.TargetImpressionShareLocation) input.ReadEnum(); + break; + } + case 18: { + long? value = _single_locationFractionMicros_codec.Read(input); + if (locationFractionMicros_ == null || value != 0L) { + LocationFractionMicros = value; + } + break; + } + case 26: { + long? value = _single_cpcBidCeilingMicros_codec.Read(input); + if (cpcBidCeilingMicros_ == null || value != 0L) { + CpcBidCeilingMicros = value; + } + break; + } + } + } + } + + } + + /// + /// An automated bidding strategy that helps you maximize revenue while + /// averaging a specific target return on ad spend (ROAS). + /// + public sealed partial class TargetRoas : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TargetRoas()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[10]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetRoas() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetRoas(TargetRoas other) : this() { + TargetRoas_ = other.TargetRoas_; + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + CpcBidFloorMicros = other.CpcBidFloorMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetRoas Clone() { + return new TargetRoas(this); + } + + /// Field number for the "target_roas" field. + public const int TargetRoas_FieldNumber = 1; + private static readonly pb::FieldCodec _single_targetRoas_codec = pb::FieldCodec.ForStructWrapper(10); + private double? targetRoas_; + /// + /// Required. The desired revenue (based on conversion data) per unit of spend. + /// Value must be between 0.01 and 1000.0, inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? TargetRoas_ { + get { return targetRoas_; } + set { + targetRoas_ = value; + } + } + + + /// Field number for the "cpc_bid_ceiling_micros" field. + public const int CpcBidCeilingMicrosFieldNumber = 2; + private static readonly pb::FieldCodec _single_cpcBidCeilingMicros_codec = pb::FieldCodec.ForStructWrapper(18); + private long? cpcBidCeilingMicros_; + /// + /// Maximum bid limit that can be set by the bid strategy. + /// The limit applies to all keywords managed by the strategy. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidCeilingMicros { + get { return cpcBidCeilingMicros_; } + set { + cpcBidCeilingMicros_ = value; + } + } + + + /// Field number for the "cpc_bid_floor_micros" field. + public const int CpcBidFloorMicrosFieldNumber = 3; + private static readonly pb::FieldCodec _single_cpcBidFloorMicros_codec = pb::FieldCodec.ForStructWrapper(26); + private long? cpcBidFloorMicros_; + /// + /// Minimum bid limit that can be set by the bid strategy. + /// The limit applies to all keywords managed by the strategy. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidFloorMicros { + get { return cpcBidFloorMicros_; } + set { + cpcBidFloorMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TargetRoas); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TargetRoas other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(TargetRoas_, other.TargetRoas_)) return false; + if (CpcBidCeilingMicros != other.CpcBidCeilingMicros) return false; + if (CpcBidFloorMicros != other.CpcBidFloorMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (targetRoas_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(TargetRoas_); + if (cpcBidCeilingMicros_ != null) hash ^= CpcBidCeilingMicros.GetHashCode(); + if (cpcBidFloorMicros_ != null) hash ^= CpcBidFloorMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (targetRoas_ != null) { + _single_targetRoas_codec.WriteTagAndValue(output, TargetRoas_); + } + if (cpcBidCeilingMicros_ != null) { + _single_cpcBidCeilingMicros_codec.WriteTagAndValue(output, CpcBidCeilingMicros); + } + if (cpcBidFloorMicros_ != null) { + _single_cpcBidFloorMicros_codec.WriteTagAndValue(output, CpcBidFloorMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (targetRoas_ != null) { + size += _single_targetRoas_codec.CalculateSizeWithTag(TargetRoas_); + } + if (cpcBidCeilingMicros_ != null) { + size += _single_cpcBidCeilingMicros_codec.CalculateSizeWithTag(CpcBidCeilingMicros); + } + if (cpcBidFloorMicros_ != null) { + size += _single_cpcBidFloorMicros_codec.CalculateSizeWithTag(CpcBidFloorMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TargetRoas other) { + if (other == null) { + return; + } + if (other.targetRoas_ != null) { + if (targetRoas_ == null || other.TargetRoas_ != 0D) { + TargetRoas_ = other.TargetRoas_; + } + } + if (other.cpcBidCeilingMicros_ != null) { + if (cpcBidCeilingMicros_ == null || other.CpcBidCeilingMicros != 0L) { + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + } + } + if (other.cpcBidFloorMicros_ != null) { + if (cpcBidFloorMicros_ == null || other.CpcBidFloorMicros != 0L) { + CpcBidFloorMicros = other.CpcBidFloorMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + double? value = _single_targetRoas_codec.Read(input); + if (targetRoas_ == null || value != 0D) { + TargetRoas_ = value; + } + break; + } + case 18: { + long? value = _single_cpcBidCeilingMicros_codec.Read(input); + if (cpcBidCeilingMicros_ == null || value != 0L) { + CpcBidCeilingMicros = value; + } + break; + } + case 26: { + long? value = _single_cpcBidFloorMicros_codec.Read(input); + if (cpcBidFloorMicros_ == null || value != 0L) { + CpcBidFloorMicros = value; + } + break; + } + } + } + } + + } + + /// + /// An automated bid strategy that sets your bids to help get as many clicks + /// as possible within your budget. + /// + public sealed partial class TargetSpend : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TargetSpend()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[11]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetSpend() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetSpend(TargetSpend other) : this() { + TargetSpendMicros = other.TargetSpendMicros; + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetSpend Clone() { + return new TargetSpend(this); + } + + /// Field number for the "target_spend_micros" field. + public const int TargetSpendMicrosFieldNumber = 1; + private static readonly pb::FieldCodec _single_targetSpendMicros_codec = pb::FieldCodec.ForStructWrapper(10); + private long? targetSpendMicros_; + /// + /// The spend target under which to maximize clicks. + /// A TargetSpend bidder will attempt to spend the smaller of this value + /// or the natural throttling spend amount. + /// If not specified, the budget is used as the spend target. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TargetSpendMicros { + get { return targetSpendMicros_; } + set { + targetSpendMicros_ = value; + } + } + + + /// Field number for the "cpc_bid_ceiling_micros" field. + public const int CpcBidCeilingMicrosFieldNumber = 2; + private static readonly pb::FieldCodec _single_cpcBidCeilingMicros_codec = pb::FieldCodec.ForStructWrapper(18); + private long? cpcBidCeilingMicros_; + /// + /// Maximum bid limit that can be set by the bid strategy. + /// The limit applies to all keywords managed by the strategy. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidCeilingMicros { + get { return cpcBidCeilingMicros_; } + set { + cpcBidCeilingMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TargetSpend); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TargetSpend other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (TargetSpendMicros != other.TargetSpendMicros) return false; + if (CpcBidCeilingMicros != other.CpcBidCeilingMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (targetSpendMicros_ != null) hash ^= TargetSpendMicros.GetHashCode(); + if (cpcBidCeilingMicros_ != null) hash ^= CpcBidCeilingMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (targetSpendMicros_ != null) { + _single_targetSpendMicros_codec.WriteTagAndValue(output, TargetSpendMicros); + } + if (cpcBidCeilingMicros_ != null) { + _single_cpcBidCeilingMicros_codec.WriteTagAndValue(output, CpcBidCeilingMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (targetSpendMicros_ != null) { + size += _single_targetSpendMicros_codec.CalculateSizeWithTag(TargetSpendMicros); + } + if (cpcBidCeilingMicros_ != null) { + size += _single_cpcBidCeilingMicros_codec.CalculateSizeWithTag(CpcBidCeilingMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TargetSpend other) { + if (other == null) { + return; + } + if (other.targetSpendMicros_ != null) { + if (targetSpendMicros_ == null || other.TargetSpendMicros != 0L) { + TargetSpendMicros = other.TargetSpendMicros; + } + } + if (other.cpcBidCeilingMicros_ != null) { + if (cpcBidCeilingMicros_ == null || other.CpcBidCeilingMicros != 0L) { + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_targetSpendMicros_codec.Read(input); + if (targetSpendMicros_ == null || value != 0L) { + TargetSpendMicros = value; + } + break; + } + case 18: { + long? value = _single_cpcBidCeilingMicros_codec.Read(input); + if (cpcBidCeilingMicros_ == null || value != 0L) { + CpcBidCeilingMicros = value; + } + break; + } + } + } + } + + } + + /// + /// A bidding strategy where bids are a fraction of the advertised price for + /// some good or service. + /// + public sealed partial class PercentCpc : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PercentCpc()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor.MessageTypes[12]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PercentCpc() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PercentCpc(PercentCpc other) : this() { + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + EnhancedCpcEnabled = other.EnhancedCpcEnabled; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PercentCpc Clone() { + return new PercentCpc(this); + } + + /// Field number for the "cpc_bid_ceiling_micros" field. + public const int CpcBidCeilingMicrosFieldNumber = 1; + private static readonly pb::FieldCodec _single_cpcBidCeilingMicros_codec = pb::FieldCodec.ForStructWrapper(10); + private long? cpcBidCeilingMicros_; + /// + /// Maximum bid limit that can be set by the bid strategy. This is + /// an optional field entered by the advertiser and specified in local micros. + /// Note: A zero value is interpreted in the same way as having bid_ceiling + /// undefined. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidCeilingMicros { + get { return cpcBidCeilingMicros_; } + set { + cpcBidCeilingMicros_ = value; + } + } + + + /// Field number for the "enhanced_cpc_enabled" field. + public const int EnhancedCpcEnabledFieldNumber = 2; + private static readonly pb::FieldCodec _single_enhancedCpcEnabled_codec = pb::FieldCodec.ForStructWrapper(18); + private bool? enhancedCpcEnabled_; + /// + /// Adjusts the bid for each auction upward or downward, depending on the + /// likelihood of a conversion. Individual bids may exceed + /// cpc_bid_ceiling_micros, but the average bid amount for a campaign should + /// not. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? EnhancedCpcEnabled { + get { return enhancedCpcEnabled_; } + set { + enhancedCpcEnabled_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PercentCpc); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PercentCpc other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CpcBidCeilingMicros != other.CpcBidCeilingMicros) return false; + if (EnhancedCpcEnabled != other.EnhancedCpcEnabled) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (cpcBidCeilingMicros_ != null) hash ^= CpcBidCeilingMicros.GetHashCode(); + if (enhancedCpcEnabled_ != null) hash ^= EnhancedCpcEnabled.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (cpcBidCeilingMicros_ != null) { + _single_cpcBidCeilingMicros_codec.WriteTagAndValue(output, CpcBidCeilingMicros); + } + if (enhancedCpcEnabled_ != null) { + _single_enhancedCpcEnabled_codec.WriteTagAndValue(output, EnhancedCpcEnabled); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (cpcBidCeilingMicros_ != null) { + size += _single_cpcBidCeilingMicros_codec.CalculateSizeWithTag(CpcBidCeilingMicros); + } + if (enhancedCpcEnabled_ != null) { + size += _single_enhancedCpcEnabled_codec.CalculateSizeWithTag(EnhancedCpcEnabled); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PercentCpc other) { + if (other == null) { + return; + } + if (other.cpcBidCeilingMicros_ != null) { + if (cpcBidCeilingMicros_ == null || other.CpcBidCeilingMicros != 0L) { + CpcBidCeilingMicros = other.CpcBidCeilingMicros; + } + } + if (other.enhancedCpcEnabled_ != null) { + if (enhancedCpcEnabled_ == null || other.EnhancedCpcEnabled != false) { + EnhancedCpcEnabled = other.EnhancedCpcEnabled; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_cpcBidCeilingMicros_codec.Read(input); + if (cpcBidCeilingMicros_ == null || value != 0L) { + CpcBidCeilingMicros = value; + } + break; + } + case 18: { + bool? value = _single_enhancedCpcEnabled_codec.Read(input); + if (enhancedCpcEnabled_ == null || value != false) { + EnhancedCpcEnabled = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BiddingError.cs b/src/V3/Stubs/BiddingError.cs new file mode 100644 index 000000000..b54399a55 --- /dev/null +++ b/src/V3/Stubs/BiddingError.cs @@ -0,0 +1,301 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/bidding_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/bidding_error.proto + public static partial class BiddingErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/bidding_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BiddingErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYmlkZGluZ19lcnJv", + "ci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvIu4IChBCaWRkaW5nRXJyb3JFbnVt", + "ItkICgxCaWRkaW5nRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dO", + "EAESKwonQklERElOR19TVFJBVEVHWV9UUkFOU0lUSU9OX05PVF9BTExPV0VE", + "EAISLgoqQ0FOTk9UX0FUVEFDSF9CSURESU5HX1NUUkFURUdZX1RPX0NBTVBB", + "SUdOEAcSKwonSU5WQUxJRF9BTk9OWU1PVVNfQklERElOR19TVFJBVEVHWV9U", + "WVBFEAoSIQodSU5WQUxJRF9CSURESU5HX1NUUkFURUdZX1RZUEUQDhIPCgtJ", + "TlZBTElEX0JJRBAREjMKL0JJRERJTkdfU1RSQVRFR1lfTk9UX0FWQUlMQUJM", + "RV9GT1JfQUNDT1VOVF9UWVBFEBISIwofQ09OVkVSU0lPTl9UUkFDS0lOR19O", + "T1RfRU5BQkxFRBATEhoKFk5PVF9FTk9VR0hfQ09OVkVSU0lPTlMQFBIwCixD", + "QU5OT1RfQ1JFQVRFX0NBTVBBSUdOX1dJVEhfQklERElOR19TVFJBVEVHWRAV", + "Ek8KS0NBTk5PVF9UQVJHRVRfQ09OVEVOVF9ORVRXT1JLX09OTFlfV0lUSF9D", + "QU1QQUlHTl9MRVZFTF9QT1BfQklERElOR19TVFJBVEVHWRAXEjMKL0JJRERJ", + "TkdfU1RSQVRFR1lfTk9UX1NVUFBPUlRFRF9XSVRIX0FEX1NDSEVEVUxFEBgS", + "MQotUEFZX1BFUl9DT05WRVJTSU9OX05PVF9BVkFJTEFCTEVfRk9SX0NVU1RP", + "TUVSEBkSMgouUEFZX1BFUl9DT05WRVJTSU9OX05PVF9BTExPV0VEX1dJVEhf", + "VEFSR0VUX0NQQRAaEjoKNkJJRERJTkdfU1RSQVRFR1lfTk9UX0FMTE9XRURf", + "Rk9SX1NFQVJDSF9PTkxZX0NBTVBBSUdOUxAbEjsKN0JJRERJTkdfU1RSQVRF", + "R1lfTk9UX1NVUFBPUlRFRF9JTl9EUkFGVFNfT1JfRVhQRVJJTUVOVFMQHBJJ", + "CkVCSURESU5HX1NUUkFURUdZX1RZUEVfRE9FU19OT1RfU1VQUE9SVF9QUk9E", + "VUNUX1RZUEVfQURHUk9VUF9DUklURVJJT04QHRIRCg1CSURfVE9PX1NNQUxM", + "EB4SDwoLQklEX1RPT19CSUcQHxIiCh5CSURfVE9PX01BTllfRlJBQ1RJT05B", + "TF9ESUdJVFMQIBIXChNJTlZBTElEX0RPTUFJTl9OQU1FECESJAogTk9UX0NP", + "TVBBVElCTEVfV0lUSF9QQVlNRU5UX01PREUQIhIjCh9OT1RfQ09NUEFUSUJM", + "RV9XSVRIX0JVREdFVF9UWVBFECMSLQopTk9UX0NPTVBBVElCTEVfV0lUSF9C", + "SURESU5HX1NUUkFURUdZX1RZUEUQJBI5CjVCSURESU5HX1NUUkFURUdZX1RZ", + "UEVfSU5DT01QQVRJQkxFX1dJVEhfU0hBUkVEX0JVREdFVBAlQuwBCiJjb20u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQhFCaWRkaW5nRXJyb3JQ", + "cm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlz", + "L2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2ds", + "ZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xl", + "QWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpF", + "cnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.BiddingErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.BiddingErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.BiddingErrorEnum.Types.BiddingError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible bidding errors. + /// + public sealed partial class BiddingErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BiddingErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.BiddingErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingErrorEnum(BiddingErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingErrorEnum Clone() { + return new BiddingErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BiddingErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BiddingErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BiddingErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BiddingErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible bidding errors. + /// + public enum BiddingError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Cannot transition to new bidding strategy. + /// + [pbr::OriginalName("BIDDING_STRATEGY_TRANSITION_NOT_ALLOWED")] BiddingStrategyTransitionNotAllowed = 2, + /// + /// Cannot attach bidding strategy to campaign. + /// + [pbr::OriginalName("CANNOT_ATTACH_BIDDING_STRATEGY_TO_CAMPAIGN")] CannotAttachBiddingStrategyToCampaign = 7, + /// + /// Bidding strategy is not supported or cannot be used as anonymous. + /// + [pbr::OriginalName("INVALID_ANONYMOUS_BIDDING_STRATEGY_TYPE")] InvalidAnonymousBiddingStrategyType = 10, + /// + /// The type does not match the named strategy's type. + /// + [pbr::OriginalName("INVALID_BIDDING_STRATEGY_TYPE")] InvalidBiddingStrategyType = 14, + /// + /// The bid is invalid. + /// + [pbr::OriginalName("INVALID_BID")] InvalidBid = 17, + /// + /// Bidding strategy is not available for the account type. + /// + [pbr::OriginalName("BIDDING_STRATEGY_NOT_AVAILABLE_FOR_ACCOUNT_TYPE")] BiddingStrategyNotAvailableForAccountType = 18, + /// + /// Conversion tracking is not enabled for the campaign for VBB transition. + /// + [pbr::OriginalName("CONVERSION_TRACKING_NOT_ENABLED")] ConversionTrackingNotEnabled = 19, + /// + /// Not enough conversions tracked for VBB transitions. + /// + [pbr::OriginalName("NOT_ENOUGH_CONVERSIONS")] NotEnoughConversions = 20, + /// + /// Campaign can not be created with given bidding strategy. It can be + /// transitioned to the strategy, once eligible. + /// + [pbr::OriginalName("CANNOT_CREATE_CAMPAIGN_WITH_BIDDING_STRATEGY")] CannotCreateCampaignWithBiddingStrategy = 21, + /// + /// Cannot target content network only as campaign uses Page One Promoted + /// bidding strategy. + /// + [pbr::OriginalName("CANNOT_TARGET_CONTENT_NETWORK_ONLY_WITH_CAMPAIGN_LEVEL_POP_BIDDING_STRATEGY")] CannotTargetContentNetworkOnlyWithCampaignLevelPopBiddingStrategy = 23, + /// + /// Budget Optimizer and Target Spend bidding strategies are not supported + /// for campaigns with AdSchedule targeting. + /// + [pbr::OriginalName("BIDDING_STRATEGY_NOT_SUPPORTED_WITH_AD_SCHEDULE")] BiddingStrategyNotSupportedWithAdSchedule = 24, + /// + /// Pay per conversion is not available to all the customer, only few + /// whitelisted customers can use this. + /// + [pbr::OriginalName("PAY_PER_CONVERSION_NOT_AVAILABLE_FOR_CUSTOMER")] PayPerConversionNotAvailableForCustomer = 25, + /// + /// Pay per conversion is not allowed with Target CPA. + /// + [pbr::OriginalName("PAY_PER_CONVERSION_NOT_ALLOWED_WITH_TARGET_CPA")] PayPerConversionNotAllowedWithTargetCpa = 26, + /// + /// Cannot set bidding strategy to Manual CPM for search network only + /// campaigns. + /// + [pbr::OriginalName("BIDDING_STRATEGY_NOT_ALLOWED_FOR_SEARCH_ONLY_CAMPAIGNS")] BiddingStrategyNotAllowedForSearchOnlyCampaigns = 27, + /// + /// The bidding strategy is not supported for use in drafts or experiments. + /// + [pbr::OriginalName("BIDDING_STRATEGY_NOT_SUPPORTED_IN_DRAFTS_OR_EXPERIMENTS")] BiddingStrategyNotSupportedInDraftsOrExperiments = 28, + /// + /// Bidding strategy type does not support product type ad group criterion. + /// + [pbr::OriginalName("BIDDING_STRATEGY_TYPE_DOES_NOT_SUPPORT_PRODUCT_TYPE_ADGROUP_CRITERION")] BiddingStrategyTypeDoesNotSupportProductTypeAdgroupCriterion = 29, + /// + /// Bid amount is too small. + /// + [pbr::OriginalName("BID_TOO_SMALL")] BidTooSmall = 30, + /// + /// Bid amount is too big. + /// + [pbr::OriginalName("BID_TOO_BIG")] BidTooBig = 31, + /// + /// Bid has too many fractional digit precision. + /// + [pbr::OriginalName("BID_TOO_MANY_FRACTIONAL_DIGITS")] BidTooManyFractionalDigits = 32, + /// + /// Invalid domain name specified. + /// + [pbr::OriginalName("INVALID_DOMAIN_NAME")] InvalidDomainName = 33, + /// + /// The field is not compatible with the payment mode. + /// + [pbr::OriginalName("NOT_COMPATIBLE_WITH_PAYMENT_MODE")] NotCompatibleWithPaymentMode = 34, + /// + /// The field is not compatible with the budget type. + /// + [pbr::OriginalName("NOT_COMPATIBLE_WITH_BUDGET_TYPE")] NotCompatibleWithBudgetType = 35, + /// + /// The field is not compatible with the bidding strategy type. + /// + [pbr::OriginalName("NOT_COMPATIBLE_WITH_BIDDING_STRATEGY_TYPE")] NotCompatibleWithBiddingStrategyType = 36, + /// + /// Bidding strategy type is incompatible with shared budget. + /// + [pbr::OriginalName("BIDDING_STRATEGY_TYPE_INCOMPATIBLE_WITH_SHARED_BUDGET")] BiddingStrategyTypeIncompatibleWithSharedBudget = 37, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BiddingSource.cs b/src/V3/Stubs/BiddingSource.cs new file mode 100644 index 000000000..8c87659fa --- /dev/null +++ b/src/V3/Stubs/BiddingSource.cs @@ -0,0 +1,191 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/bidding_source.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/bidding_source.proto + public static partial class BiddingSourceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/bidding_source.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BiddingSourceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9iaWRkaW5nX3NvdXJj", + "ZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2ds", + "ZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ihwEKEUJpZGRpbmdTb3VyY2VFbnVt", + "InIKDUJpZGRpbmdTb3VyY2USDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dO", + "EAESHQoZQ0FNUEFJR05fQklERElOR19TVFJBVEVHWRAFEgwKCEFEX0dST1VQ", + "EAYSFgoSQURfR1JPVVBfQ1JJVEVSSU9OEAdC5wEKIWNvbS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5lbnVtc0ISQmlkZGluZ1NvdXJjZVByb3RvUAFaQmdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xl", + "QWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPq", + "AiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum), global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceEnum.Types.BiddingSource) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible bidding sources. + /// + public sealed partial class BiddingSourceEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BiddingSourceEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BiddingSourceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingSourceEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingSourceEnum(BiddingSourceEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingSourceEnum Clone() { + return new BiddingSourceEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BiddingSourceEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BiddingSourceEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BiddingSourceEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BiddingSourceEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Indicates where a bid or target is defined. For example, an ad group + /// criterion may define a cpc bid directly, or it can inherit its cpc bid from + /// the ad group. + /// + public enum BiddingSource { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Effective bid or target is inherited from campaign bidding strategy. + /// + [pbr::OriginalName("CAMPAIGN_BIDDING_STRATEGY")] CampaignBiddingStrategy = 5, + /// + /// The bid or target is defined on the ad group. + /// + [pbr::OriginalName("AD_GROUP")] AdGroup = 6, + /// + /// The bid or target is defined on the ad group criterion. + /// + [pbr::OriginalName("AD_GROUP_CRITERION")] AdGroupCriterion = 7, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BiddingStrategy.cs b/src/V3/Stubs/BiddingStrategy.cs new file mode 100644 index 000000000..d1e0a469f --- /dev/null +++ b/src/V3/Stubs/BiddingStrategy.cs @@ -0,0 +1,680 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/bidding_strategy.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/bidding_strategy.proto + public static partial class BiddingStrategyReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/bidding_strategy.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BiddingStrategyReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYmlkZGluZ19z", + "dHJhdGVneS5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzGixnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vYmlkZGluZy5w", + "cm90bxo7Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvYmlkZGluZ19z", + "dHJhdGVneV9zdGF0dXMucHJvdG8aOWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL2JpZGRpbmdfc3RyYXRlZ3lfdHlwZS5wcm90bxofZ29vZ2xlL2Fw", + "aS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJjZS5w", + "cm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUv", + "YXBpL2Fubm90YXRpb25zLnByb3RvItQHCg9CaWRkaW5nU3RyYXRlZ3kSRwoN", + "cmVzb3VyY2VfbmFtZRgBIAEoCUIw4EEF+kEqCihnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vQmlkZGluZ1N0cmF0ZWd5EiwKAmlkGAMgASgLMhsuZ29vZ2xl", + "LnByb3RvYnVmLkludDY0VmFsdWVCA+BBAxIqCgRuYW1lGAQgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEmMKBnN0YXR1cxgPIAEoDjJOLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkJpZGRpbmdTdHJhdGVneVN0", + "YXR1c0VudW0uQmlkZGluZ1N0cmF0ZWd5U3RhdHVzQgPgQQMSXQoEdHlwZRgF", + "IAEoDjJKLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkJpZGRpbmdT", + "dHJhdGVneVR5cGVFbnVtLkJpZGRpbmdTdHJhdGVneVR5cGVCA+BBAxI4Cg5j", + "YW1wYWlnbl9jb3VudBgNIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZh", + "bHVlQgPgQQMSRAoabm9uX3JlbW92ZWRfY2FtcGFpZ25fY291bnQYDiABKAsy", + "Gy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEkMKDGVuaGFuY2Vk", + "X2NwYxgHIAEoCzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5F", + "bmhhbmNlZENwY0gAEj8KCnRhcmdldF9jcGEYCSABKAsyKS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5jb21tb24uVGFyZ2V0Q3BhSAASWAoXdGFyZ2V0X2lt", + "cHJlc3Npb25fc2hhcmUYMCABKAsyNS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5jb21tb24uVGFyZ2V0SW1wcmVzc2lvblNoYXJlSAASQQoLdGFyZ2V0X3Jv", + "YXMYCyABKAsyKi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uVGFy", + "Z2V0Um9hc0gAEkMKDHRhcmdldF9zcGVuZBgMIAEoCzIrLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmNvbW1vbi5UYXJnZXRTcGVuZEgAOmjqQWUKKGdvb2ds", + "ZWFkcy5nb29nbGVhcGlzLmNvbS9CaWRkaW5nU3RyYXRlZ3kSOWN1c3RvbWVy", + "cy97Y3VzdG9tZXJ9L2JpZGRpbmdTdHJhdGVnaWVzL3tiaWRkaW5nX3N0cmF0", + "ZWd5fUIICgZzY2hlbWVCgQIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5yZXNvdXJjZXNCFEJpZGRpbmdTdHJhdGVneVByb3RvUAFaSmdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29n", + "bGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "UmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291", + "cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy), global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy.Parser, new[]{ "ResourceName", "Id", "Name", "Status", "Type", "CampaignCount", "NonRemovedCampaignCount", "EnhancedCpc", "TargetCpa", "TargetImpressionShare", "TargetRoas", "TargetSpend" }, new[]{ "Scheme" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A bidding strategy. + /// + public sealed partial class BiddingStrategy : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BiddingStrategy()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategyReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategy() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategy(BiddingStrategy other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + status_ = other.status_; + type_ = other.type_; + CampaignCount = other.CampaignCount; + NonRemovedCampaignCount = other.NonRemovedCampaignCount; + switch (other.SchemeCase) { + case SchemeOneofCase.EnhancedCpc: + EnhancedCpc = other.EnhancedCpc.Clone(); + break; + case SchemeOneofCase.TargetCpa: + TargetCpa = other.TargetCpa.Clone(); + break; + case SchemeOneofCase.TargetImpressionShare: + TargetImpressionShare = other.TargetImpressionShare.Clone(); + break; + case SchemeOneofCase.TargetRoas: + TargetRoas = other.TargetRoas.Clone(); + break; + case SchemeOneofCase.TargetSpend: + TargetSpend = other.TargetSpend.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategy Clone() { + return new BiddingStrategy(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the bidding strategy. + /// Bidding strategy resource names have the form: + /// + /// `customers/{customer_id}/biddingStrategies/{bidding_strategy_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the bidding strategy. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// The name of the bidding strategy. + /// All bidding strategies within an account must be named distinctly. + /// + /// The length of this string should be between 1 and 255, inclusive, + /// in UTF-8 bytes, (trimmed). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 15; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyStatusEnum.Types.BiddingStrategyStatus status_ = 0; + /// + /// Output only. The status of the bidding strategy. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyStatusEnum.Types.BiddingStrategyStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum.Types.BiddingStrategyType type_ = 0; + /// + /// Output only. The type of the bidding strategy. + /// Create a bidding strategy by setting the bidding scheme. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum.Types.BiddingStrategyType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "campaign_count" field. + public const int CampaignCountFieldNumber = 13; + private static readonly pb::FieldCodec _single_campaignCount_codec = pb::FieldCodec.ForStructWrapper(106); + private long? campaignCount_; + /// + /// Output only. The number of campaigns attached to this bidding strategy. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CampaignCount { + get { return campaignCount_; } + set { + campaignCount_ = value; + } + } + + + /// Field number for the "non_removed_campaign_count" field. + public const int NonRemovedCampaignCountFieldNumber = 14; + private static readonly pb::FieldCodec _single_nonRemovedCampaignCount_codec = pb::FieldCodec.ForStructWrapper(114); + private long? nonRemovedCampaignCount_; + /// + /// Output only. The number of non-removed campaigns attached to this bidding strategy. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? NonRemovedCampaignCount { + get { return nonRemovedCampaignCount_; } + set { + nonRemovedCampaignCount_ = value; + } + } + + + /// Field number for the "enhanced_cpc" field. + public const int EnhancedCpcFieldNumber = 7; + /// + /// A bidding strategy that raises bids for clicks that seem more likely to + /// lead to a conversion and lowers them for clicks where they seem less + /// likely. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.EnhancedCpc EnhancedCpc { + get { return schemeCase_ == SchemeOneofCase.EnhancedCpc ? (global::Google.Ads.GoogleAds.V3.Common.EnhancedCpc) scheme_ : null; } + set { + scheme_ = value; + schemeCase_ = value == null ? SchemeOneofCase.None : SchemeOneofCase.EnhancedCpc; + } + } + + /// Field number for the "target_cpa" field. + public const int TargetCpaFieldNumber = 9; + /// + /// A bidding strategy that sets bids to help get as many conversions as + /// possible at the target cost-per-acquisition (CPA) you set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetCpa TargetCpa { + get { return schemeCase_ == SchemeOneofCase.TargetCpa ? (global::Google.Ads.GoogleAds.V3.Common.TargetCpa) scheme_ : null; } + set { + scheme_ = value; + schemeCase_ = value == null ? SchemeOneofCase.None : SchemeOneofCase.TargetCpa; + } + } + + /// Field number for the "target_impression_share" field. + public const int TargetImpressionShareFieldNumber = 48; + /// + /// A bidding strategy that automatically optimizes towards a desired + /// percentage of impressions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare TargetImpressionShare { + get { return schemeCase_ == SchemeOneofCase.TargetImpressionShare ? (global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare) scheme_ : null; } + set { + scheme_ = value; + schemeCase_ = value == null ? SchemeOneofCase.None : SchemeOneofCase.TargetImpressionShare; + } + } + + /// Field number for the "target_roas" field. + public const int TargetRoasFieldNumber = 11; + /// + /// A bidding strategy that helps you maximize revenue while averaging a + /// specific target Return On Ad Spend (ROAS). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetRoas TargetRoas { + get { return schemeCase_ == SchemeOneofCase.TargetRoas ? (global::Google.Ads.GoogleAds.V3.Common.TargetRoas) scheme_ : null; } + set { + scheme_ = value; + schemeCase_ = value == null ? SchemeOneofCase.None : SchemeOneofCase.TargetRoas; + } + } + + /// Field number for the "target_spend" field. + public const int TargetSpendFieldNumber = 12; + /// + /// A bid strategy that sets your bids to help get as many clicks as + /// possible within your budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetSpend TargetSpend { + get { return schemeCase_ == SchemeOneofCase.TargetSpend ? (global::Google.Ads.GoogleAds.V3.Common.TargetSpend) scheme_ : null; } + set { + scheme_ = value; + schemeCase_ = value == null ? SchemeOneofCase.None : SchemeOneofCase.TargetSpend; + } + } + + private object scheme_; + /// Enum of possible cases for the "scheme" oneof. + public enum SchemeOneofCase { + None = 0, + EnhancedCpc = 7, + TargetCpa = 9, + TargetImpressionShare = 48, + TargetRoas = 11, + TargetSpend = 12, + } + private SchemeOneofCase schemeCase_ = SchemeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SchemeOneofCase SchemeCase { + get { return schemeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearScheme() { + schemeCase_ = SchemeOneofCase.None; + scheme_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BiddingStrategy); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BiddingStrategy other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (Status != other.Status) return false; + if (Type != other.Type) return false; + if (CampaignCount != other.CampaignCount) return false; + if (NonRemovedCampaignCount != other.NonRemovedCampaignCount) return false; + if (!object.Equals(EnhancedCpc, other.EnhancedCpc)) return false; + if (!object.Equals(TargetCpa, other.TargetCpa)) return false; + if (!object.Equals(TargetImpressionShare, other.TargetImpressionShare)) return false; + if (!object.Equals(TargetRoas, other.TargetRoas)) return false; + if (!object.Equals(TargetSpend, other.TargetSpend)) return false; + if (SchemeCase != other.SchemeCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (campaignCount_ != null) hash ^= CampaignCount.GetHashCode(); + if (nonRemovedCampaignCount_ != null) hash ^= NonRemovedCampaignCount.GetHashCode(); + if (schemeCase_ == SchemeOneofCase.EnhancedCpc) hash ^= EnhancedCpc.GetHashCode(); + if (schemeCase_ == SchemeOneofCase.TargetCpa) hash ^= TargetCpa.GetHashCode(); + if (schemeCase_ == SchemeOneofCase.TargetImpressionShare) hash ^= TargetImpressionShare.GetHashCode(); + if (schemeCase_ == SchemeOneofCase.TargetRoas) hash ^= TargetRoas.GetHashCode(); + if (schemeCase_ == SchemeOneofCase.TargetSpend) hash ^= TargetSpend.GetHashCode(); + hash ^= (int) schemeCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (Type != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Type); + } + if (schemeCase_ == SchemeOneofCase.EnhancedCpc) { + output.WriteRawTag(58); + output.WriteMessage(EnhancedCpc); + } + if (schemeCase_ == SchemeOneofCase.TargetCpa) { + output.WriteRawTag(74); + output.WriteMessage(TargetCpa); + } + if (schemeCase_ == SchemeOneofCase.TargetRoas) { + output.WriteRawTag(90); + output.WriteMessage(TargetRoas); + } + if (schemeCase_ == SchemeOneofCase.TargetSpend) { + output.WriteRawTag(98); + output.WriteMessage(TargetSpend); + } + if (campaignCount_ != null) { + _single_campaignCount_codec.WriteTagAndValue(output, CampaignCount); + } + if (nonRemovedCampaignCount_ != null) { + _single_nonRemovedCampaignCount_codec.WriteTagAndValue(output, NonRemovedCampaignCount); + } + if (Status != 0) { + output.WriteRawTag(120); + output.WriteEnum((int) Status); + } + if (schemeCase_ == SchemeOneofCase.TargetImpressionShare) { + output.WriteRawTag(130, 3); + output.WriteMessage(TargetImpressionShare); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (campaignCount_ != null) { + size += _single_campaignCount_codec.CalculateSizeWithTag(CampaignCount); + } + if (nonRemovedCampaignCount_ != null) { + size += _single_nonRemovedCampaignCount_codec.CalculateSizeWithTag(NonRemovedCampaignCount); + } + if (schemeCase_ == SchemeOneofCase.EnhancedCpc) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(EnhancedCpc); + } + if (schemeCase_ == SchemeOneofCase.TargetCpa) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(TargetCpa); + } + if (schemeCase_ == SchemeOneofCase.TargetImpressionShare) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetImpressionShare); + } + if (schemeCase_ == SchemeOneofCase.TargetRoas) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(TargetRoas); + } + if (schemeCase_ == SchemeOneofCase.TargetSpend) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(TargetSpend); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BiddingStrategy other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.campaignCount_ != null) { + if (campaignCount_ == null || other.CampaignCount != 0L) { + CampaignCount = other.CampaignCount; + } + } + if (other.nonRemovedCampaignCount_ != null) { + if (nonRemovedCampaignCount_ == null || other.NonRemovedCampaignCount != 0L) { + NonRemovedCampaignCount = other.NonRemovedCampaignCount; + } + } + switch (other.SchemeCase) { + case SchemeOneofCase.EnhancedCpc: + if (EnhancedCpc == null) { + EnhancedCpc = new global::Google.Ads.GoogleAds.V3.Common.EnhancedCpc(); + } + EnhancedCpc.MergeFrom(other.EnhancedCpc); + break; + case SchemeOneofCase.TargetCpa: + if (TargetCpa == null) { + TargetCpa = new global::Google.Ads.GoogleAds.V3.Common.TargetCpa(); + } + TargetCpa.MergeFrom(other.TargetCpa); + break; + case SchemeOneofCase.TargetImpressionShare: + if (TargetImpressionShare == null) { + TargetImpressionShare = new global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare(); + } + TargetImpressionShare.MergeFrom(other.TargetImpressionShare); + break; + case SchemeOneofCase.TargetRoas: + if (TargetRoas == null) { + TargetRoas = new global::Google.Ads.GoogleAds.V3.Common.TargetRoas(); + } + TargetRoas.MergeFrom(other.TargetRoas); + break; + case SchemeOneofCase.TargetSpend: + if (TargetSpend == null) { + TargetSpend = new global::Google.Ads.GoogleAds.V3.Common.TargetSpend(); + } + TargetSpend.MergeFrom(other.TargetSpend); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 40: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum.Types.BiddingStrategyType) input.ReadEnum(); + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Common.EnhancedCpc subBuilder = new global::Google.Ads.GoogleAds.V3.Common.EnhancedCpc(); + if (schemeCase_ == SchemeOneofCase.EnhancedCpc) { + subBuilder.MergeFrom(EnhancedCpc); + } + input.ReadMessage(subBuilder); + EnhancedCpc = subBuilder; + break; + } + case 74: { + global::Google.Ads.GoogleAds.V3.Common.TargetCpa subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetCpa(); + if (schemeCase_ == SchemeOneofCase.TargetCpa) { + subBuilder.MergeFrom(TargetCpa); + } + input.ReadMessage(subBuilder); + TargetCpa = subBuilder; + break; + } + case 90: { + global::Google.Ads.GoogleAds.V3.Common.TargetRoas subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetRoas(); + if (schemeCase_ == SchemeOneofCase.TargetRoas) { + subBuilder.MergeFrom(TargetRoas); + } + input.ReadMessage(subBuilder); + TargetRoas = subBuilder; + break; + } + case 98: { + global::Google.Ads.GoogleAds.V3.Common.TargetSpend subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetSpend(); + if (schemeCase_ == SchemeOneofCase.TargetSpend) { + subBuilder.MergeFrom(TargetSpend); + } + input.ReadMessage(subBuilder); + TargetSpend = subBuilder; + break; + } + case 106: { + long? value = _single_campaignCount_codec.Read(input); + if (campaignCount_ == null || value != 0L) { + CampaignCount = value; + } + break; + } + case 114: { + long? value = _single_nonRemovedCampaignCount_codec.Read(input); + if (nonRemovedCampaignCount_ == null || value != 0L) { + NonRemovedCampaignCount = value; + } + break; + } + case 120: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyStatusEnum.Types.BiddingStrategyStatus) input.ReadEnum(); + break; + } + case 386: { + global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare(); + if (schemeCase_ == SchemeOneofCase.TargetImpressionShare) { + subBuilder.MergeFrom(TargetImpressionShare); + } + input.ReadMessage(subBuilder); + TargetImpressionShare = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BiddingStrategyError.cs b/src/V3/Stubs/BiddingStrategyError.cs new file mode 100644 index 000000000..bd3944aba --- /dev/null +++ b/src/V3/Stubs/BiddingStrategyError.cs @@ -0,0 +1,203 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/bidding_strategy_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/bidding_strategy_error.proto + public static partial class BiddingStrategyErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/bidding_strategy_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BiddingStrategyErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYmlkZGluZ19zdHJh", + "dGVneV9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJy", + "b3JzGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIpsCChhCaWRkaW5n", + "U3RyYXRlZ3lFcnJvckVudW0i/gEKFEJpZGRpbmdTdHJhdGVneUVycm9yEg8K", + "C1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhIKDkRVUExJQ0FURV9OQU1F", + "EAISJwojQ0FOTk9UX0NIQU5HRV9CSURESU5HX1NUUkFURUdZX1RZUEUQAxIl", + "CiFDQU5OT1RfUkVNT1ZFX0FTU09DSUFURURfU1RSQVRFR1kQBBIiCh5CSURE", + "SU5HX1NUUkFURUdZX05PVF9TVVBQT1JURUQQBRJACjxJTkNPTVBBVElCTEVf", + "QklERElOR19TVFJBVEVHWV9BTkRfQklERElOR19TVFJBVEVHWV9HT0FMX1RZ", + "UEUQBkL0AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IZ", + "QmlkZGluZ1N0cmF0ZWd5RXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9y", + "Zy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3Jz", + "O2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9y", + "c8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.BiddingStrategyErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.BiddingStrategyErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.BiddingStrategyErrorEnum.Types.BiddingStrategyError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible bidding strategy errors. + /// + public sealed partial class BiddingStrategyErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BiddingStrategyErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.BiddingStrategyErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyErrorEnum(BiddingStrategyErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyErrorEnum Clone() { + return new BiddingStrategyErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BiddingStrategyErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BiddingStrategyErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BiddingStrategyErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BiddingStrategyErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible bidding strategy errors. + /// + public enum BiddingStrategyError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Each bidding strategy must have a unique name. + /// + [pbr::OriginalName("DUPLICATE_NAME")] DuplicateName = 2, + /// + /// Bidding strategy type is immutable. + /// + [pbr::OriginalName("CANNOT_CHANGE_BIDDING_STRATEGY_TYPE")] CannotChangeBiddingStrategyType = 3, + /// + /// Only bidding strategies not linked to campaigns, adgroups or adgroup + /// criteria can be removed. + /// + [pbr::OriginalName("CANNOT_REMOVE_ASSOCIATED_STRATEGY")] CannotRemoveAssociatedStrategy = 4, + /// + /// The specified bidding strategy is not supported. + /// + [pbr::OriginalName("BIDDING_STRATEGY_NOT_SUPPORTED")] BiddingStrategyNotSupported = 5, + /// + /// The bidding strategy is incompatible with the campaign's bidding + /// strategy goal type. + /// + [pbr::OriginalName("INCOMPATIBLE_BIDDING_STRATEGY_AND_BIDDING_STRATEGY_GOAL_TYPE")] IncompatibleBiddingStrategyAndBiddingStrategyGoalType = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BiddingStrategyService.cs b/src/V3/Stubs/BiddingStrategyService.cs new file mode 100644 index 000000000..0dbda4c00 --- /dev/null +++ b/src/V3/Stubs/BiddingStrategyService.cs @@ -0,0 +1,1036 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/bidding_strategy_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/bidding_strategy_service.proto + public static partial class BiddingStrategyServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/bidding_strategy_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BiddingStrategyServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9iaWRkaW5nX3N0", + "cmF0ZWd5X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "YmlkZGluZ19zdHJhdGVneS5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkv", + "ZmllbGRfYmVoYXZpb3IucHJvdG8aIGdvb2dsZS9wcm90b2J1Zi9maWVsZF9t", + "YXNrLnByb3RvGhdnb29nbGUvcnBjL3N0YXR1cy5wcm90byI3ChlHZXRCaWRk", + "aW5nU3RyYXRlZ3lSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BB", + "AiK/AQoeTXV0YXRlQmlkZGluZ1N0cmF0ZWdpZXNSZXF1ZXN0EhgKC2N1c3Rv", + "bWVyX2lkGAEgASgJQgPgQQISUwoKb3BlcmF0aW9ucxgCIAMoCzI6Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkJpZGRpbmdTdHJhdGVneU9w", + "ZXJhdGlvbkID4EECEhcKD3BhcnRpYWxfZmFpbHVyZRgDIAEoCBIVCg12YWxp", + "ZGF0ZV9vbmx5GAQgASgIIvYBChhCaWRkaW5nU3RyYXRlZ3lPcGVyYXRpb24S", + "LwoLdXBkYXRlX21hc2sYBCABKAsyGi5nb29nbGUucHJvdG9idWYuRmllbGRN", + "YXNrEkQKBmNyZWF0ZRgBIAEoCzIyLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlcy5CaWRkaW5nU3RyYXRlZ3lIABJECgZ1cGRhdGUYAiABKAsy", + "Mi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQmlkZGluZ1N0", + "cmF0ZWd5SAASEAoGcmVtb3ZlGAMgASgJSABCCwoJb3BlcmF0aW9uIqQBCh9N", + "dXRhdGVCaWRkaW5nU3RyYXRlZ2llc1Jlc3BvbnNlEjEKFXBhcnRpYWxfZmFp", + "bHVyZV9lcnJvchgDIAEoCzISLmdvb2dsZS5ycGMuU3RhdHVzEk4KB3Jlc3Vs", + "dHMYAiADKAsyPS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5N", + "dXRhdGVCaWRkaW5nU3RyYXRlZ3lSZXN1bHQiNAobTXV0YXRlQmlkZGluZ1N0", + "cmF0ZWd5UmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAkyhwQKFkJpZGRp", + "bmdTdHJhdGVneVNlcnZpY2US0gEKEkdldEJpZGRpbmdTdHJhdGVneRI7Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEJpZGRpbmdTdHJh", + "dGVneVJlcXVlc3QaMi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMuQmlkZGluZ1N0cmF0ZWd5IkuC0+STAjUSMy92My97cmVzb3VyY2VfbmFt", + "ZT1jdXN0b21lcnMvKi9iaWRkaW5nU3RyYXRlZ2llcy8qfdpBDXJlc291cmNl", + "X25hbWUS+gEKF011dGF0ZUJpZGRpbmdTdHJhdGVnaWVzEkAuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQmlkZGluZ1N0cmF0ZWdp", + "ZXNSZXF1ZXN0GkEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "TXV0YXRlQmlkZGluZ1N0cmF0ZWdpZXNSZXNwb25zZSJagtPkkwI7IjYvdjMv", + "Y3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfS9iaWRkaW5nU3RyYXRlZ2llczpt", + "dXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVyYXRpb25zGhvKQRhnb29nbGVh", + "ZHMuZ29vZ2xlYXBpcy5jb21CggIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlc0IbQmlkZGluZ1N0cmF0ZWd5U2VydmljZVByb3RvUAFa", + "SGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5B", + "ZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVB", + "ZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6", + "U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategyReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetBiddingStrategyRequest), global::Google.Ads.GoogleAds.V3.Services.GetBiddingStrategyRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesRequest), global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyOperation), global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesResponse), global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategyResult), global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategyResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [BiddingStrategyService.GetBiddingStrategy][google.ads.googleads.v3.services.BiddingStrategyService.GetBiddingStrategy]. + /// + public sealed partial class GetBiddingStrategyRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetBiddingStrategyRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetBiddingStrategyRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetBiddingStrategyRequest(GetBiddingStrategyRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetBiddingStrategyRequest Clone() { + return new GetBiddingStrategyRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the bidding strategy to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetBiddingStrategyRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetBiddingStrategyRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetBiddingStrategyRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [BiddingStrategyService.MutateBiddingStrategies][google.ads.googleads.v3.services.BiddingStrategyService.MutateBiddingStrategies]. + /// + public sealed partial class MutateBiddingStrategiesRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateBiddingStrategiesRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategiesRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategiesRequest(MutateBiddingStrategiesRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategiesRequest Clone() { + return new MutateBiddingStrategiesRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose bidding strategies are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual bidding strategies. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateBiddingStrategiesRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateBiddingStrategiesRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateBiddingStrategiesRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a bidding strategy. + /// + public sealed partial class BiddingStrategyOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BiddingStrategyOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyOperation(BiddingStrategyOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyOperation Clone() { + return new BiddingStrategyOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new bidding + /// strategy. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The bidding strategy is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed bidding strategy is + /// expected, in this format: + /// + /// `customers/{customer_id}/biddingStrategies/{bidding_strategy_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BiddingStrategyOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BiddingStrategyOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BiddingStrategyOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for bidding strategy mutate. + /// + public sealed partial class MutateBiddingStrategiesResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateBiddingStrategiesResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategiesResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategiesResponse(MutateBiddingStrategiesResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategiesResponse Clone() { + return new MutateBiddingStrategiesResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategyResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateBiddingStrategiesResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateBiddingStrategiesResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateBiddingStrategiesResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the bidding strategy mutate. + /// + public sealed partial class MutateBiddingStrategyResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateBiddingStrategyResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategyResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategyResult(MutateBiddingStrategyResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBiddingStrategyResult Clone() { + return new MutateBiddingStrategyResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateBiddingStrategyResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateBiddingStrategyResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateBiddingStrategyResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BiddingStrategyServiceClient.cs b/src/V3/Stubs/BiddingStrategyServiceClient.cs new file mode 100644 index 000000000..04cb7af7e --- /dev/null +++ b/src/V3/Stubs/BiddingStrategyServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class BiddingStrategyServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static BiddingStrategyServiceSettings GetDefault() => new BiddingStrategyServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public BiddingStrategyServiceSettings() { } + + private BiddingStrategyServiceSettings(BiddingStrategyServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetBiddingStrategySettings = existing.GetBiddingStrategySettings; + MutateBiddingStrategiesSettings = existing.MutateBiddingStrategiesSettings; + OnCopy(existing); + } + + partial void OnCopy(BiddingStrategyServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// BiddingStrategyServiceClient.GetBiddingStrategy and BiddingStrategyServiceClient.GetBiddingStrategyAsync. + /// + /// + /// The default BiddingStrategyServiceClient.GetBiddingStrategy and + /// BiddingStrategyServiceClient.GetBiddingStrategyAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetBiddingStrategySettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// BiddingStrategyServiceClient.MutateBiddingStrategies and BiddingStrategyServiceClient.MutateBiddingStrategiesAsync. + /// + /// + /// The default BiddingStrategyServiceClient.MutateBiddingStrategies and + /// BiddingStrategyServiceClient.MutateBiddingStrategiesAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateBiddingStrategiesSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public BiddingStrategyServiceSettings Clone() => new BiddingStrategyServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class BiddingStrategyServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public BiddingStrategyServiceSettings Settings { get; set; } + + /// + public override BiddingStrategyServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return BiddingStrategyServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return BiddingStrategyServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => BiddingStrategyServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => BiddingStrategyServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => BiddingStrategyServiceClient.ChannelPool; + } + + /// + /// BiddingStrategyService client wrapper, for convenient use. + /// + public abstract partial class BiddingStrategyServiceClient + { + /// + /// The default endpoint for the BiddingStrategyService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default BiddingStrategyService scopes. + /// + /// + /// The default BiddingStrategyService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// BiddingStrategyServiceClient client = await BiddingStrategyServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// BiddingStrategyServiceClient.DefaultEndpoint.Host, BiddingStrategyServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// BiddingStrategyServiceClient client = BiddingStrategyServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, BiddingStrategyServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// BiddingStrategyServiceClient client = BiddingStrategyServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// BiddingStrategyServiceClient.DefaultEndpoint.Host, BiddingStrategyServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// BiddingStrategyServiceClient client = BiddingStrategyServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static BiddingStrategyServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, BiddingStrategyServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static BiddingStrategyServiceClient Create(grpccore::Channel channel, BiddingStrategyServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static BiddingStrategyServiceClient Create(grpccore::CallInvoker callInvoker, BiddingStrategyServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + BiddingStrategyService.BiddingStrategyServiceClient grpcClient = new BiddingStrategyService.BiddingStrategyServiceClient(callInvoker); + return new BiddingStrategyServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC BiddingStrategyService client. + /// + public virtual BiddingStrategyService.BiddingStrategyServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// + /// Required. The resource name of the bidding strategy to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetBiddingStrategyAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetBiddingStrategyAsync( + new GetBiddingStrategyRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// + /// Required. The resource name of the bidding strategy to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetBiddingStrategyAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetBiddingStrategyAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// + /// Required. The resource name of the bidding strategy to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::BiddingStrategy GetBiddingStrategy( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetBiddingStrategy( + new GetBiddingStrategyRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetBiddingStrategyAsync( + GetBiddingStrategyRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetBiddingStrategyAsync( + GetBiddingStrategyRequest request, + st::CancellationToken cancellationToken) => GetBiddingStrategyAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::BiddingStrategy GetBiddingStrategy( + GetBiddingStrategyRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose bidding strategies are being modified. + /// + /// + /// Required. The list of operations to perform on individual bidding strategies. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBiddingStrategiesAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateBiddingStrategiesAsync( + new MutateBiddingStrategiesRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose bidding strategies are being modified. + /// + /// + /// Required. The list of operations to perform on individual bidding strategies. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBiddingStrategiesAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateBiddingStrategiesAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose bidding strategies are being modified. + /// + /// + /// Required. The list of operations to perform on individual bidding strategies. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateBiddingStrategiesResponse MutateBiddingStrategies( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateBiddingStrategies( + new MutateBiddingStrategiesRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose bidding strategies are being modified. + /// + /// + /// Required. The list of operations to perform on individual bidding strategies. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBiddingStrategiesAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateBiddingStrategiesAsync( + new MutateBiddingStrategiesRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose bidding strategies are being modified. + /// + /// + /// Required. The list of operations to perform on individual bidding strategies. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBiddingStrategiesAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateBiddingStrategiesAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose bidding strategies are being modified. + /// + /// + /// Required. The list of operations to perform on individual bidding strategies. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateBiddingStrategiesResponse MutateBiddingStrategies( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateBiddingStrategies( + new MutateBiddingStrategiesRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBiddingStrategiesAsync( + MutateBiddingStrategiesRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBiddingStrategiesAsync( + MutateBiddingStrategiesRequest request, + st::CancellationToken cancellationToken) => MutateBiddingStrategiesAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateBiddingStrategiesResponse MutateBiddingStrategies( + MutateBiddingStrategiesRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// BiddingStrategyService client wrapper implementation, for convenient use. + /// + public sealed partial class BiddingStrategyServiceClientImpl : BiddingStrategyServiceClient + { + private readonly gaxgrpc::ApiCall _callGetBiddingStrategy; + private readonly gaxgrpc::ApiCall _callMutateBiddingStrategies; + + /// + /// Constructs a client wrapper for the BiddingStrategyService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public BiddingStrategyServiceClientImpl(BiddingStrategyService.BiddingStrategyServiceClient grpcClient, BiddingStrategyServiceSettings settings) + { + GrpcClient = grpcClient; + BiddingStrategyServiceSettings effectiveSettings = settings ?? BiddingStrategyServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetBiddingStrategy = clientHelper.BuildApiCall( + GrpcClient.GetBiddingStrategyAsync, GrpcClient.GetBiddingStrategy, effectiveSettings.GetBiddingStrategySettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateBiddingStrategies = clientHelper.BuildApiCall( + GrpcClient.MutateBiddingStrategiesAsync, GrpcClient.MutateBiddingStrategies, effectiveSettings.MutateBiddingStrategiesSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetBiddingStrategy); + Modify_GetBiddingStrategyApiCall(ref _callGetBiddingStrategy); + Modify_ApiCall(ref _callMutateBiddingStrategies); + Modify_MutateBiddingStrategiesApiCall(ref _callMutateBiddingStrategies); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetBiddingStrategyApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateBiddingStrategiesApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(BiddingStrategyService.BiddingStrategyServiceClient grpcClient, BiddingStrategyServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC BiddingStrategyService client. + /// + public override BiddingStrategyService.BiddingStrategyServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetBiddingStrategyRequest(ref GetBiddingStrategyRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateBiddingStrategiesRequest(ref MutateBiddingStrategiesRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetBiddingStrategyAsync( + GetBiddingStrategyRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetBiddingStrategyRequest(ref request, ref callSettings); + return _callGetBiddingStrategy.Async(request, callSettings); + } + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::BiddingStrategy GetBiddingStrategy( + GetBiddingStrategyRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetBiddingStrategyRequest(ref request, ref callSettings); + return _callGetBiddingStrategy.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateBiddingStrategiesAsync( + MutateBiddingStrategiesRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateBiddingStrategiesRequest(ref request, ref callSettings); + return _callMutateBiddingStrategies.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateBiddingStrategiesResponse MutateBiddingStrategies( + MutateBiddingStrategiesRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateBiddingStrategiesRequest(ref request, ref callSettings); + return _callMutateBiddingStrategies.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/BiddingStrategyServiceGrpc.cs b/src/V3/Stubs/BiddingStrategyServiceGrpc.cs new file mode 100644 index 000000000..eb3383a59 --- /dev/null +++ b/src/V3/Stubs/BiddingStrategyServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/bidding_strategy_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage bidding strategies. + /// + public static partial class BiddingStrategyService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.BiddingStrategyService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetBiddingStrategyRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetBiddingStrategyRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_BiddingStrategy = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateBiddingStrategiesRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateBiddingStrategiesResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetBiddingStrategy = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetBiddingStrategy", + __Marshaller_google_ads_googleads_v3_services_GetBiddingStrategyRequest, + __Marshaller_google_ads_googleads_v3_resources_BiddingStrategy); + + static readonly grpc::Method __Method_MutateBiddingStrategies = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateBiddingStrategies", + __Marshaller_google_ads_googleads_v3_services_MutateBiddingStrategiesRequest, + __Marshaller_google_ads_googleads_v3_services_MutateBiddingStrategiesResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of BiddingStrategyService + public abstract partial class BiddingStrategyServiceBase + { + /// + /// Returns the requested bidding strategy in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetBiddingStrategy(global::Google.Ads.GoogleAds.V3.Services.GetBiddingStrategyRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateBiddingStrategies(global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for BiddingStrategyService + public partial class BiddingStrategyServiceClient : grpc::ClientBase + { + /// Creates a new client for BiddingStrategyService + /// The channel to use to make remote calls. + public BiddingStrategyServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for BiddingStrategyService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public BiddingStrategyServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected BiddingStrategyServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected BiddingStrategyServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested bidding strategy in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy GetBiddingStrategy(global::Google.Ads.GoogleAds.V3.Services.GetBiddingStrategyRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetBiddingStrategy(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested bidding strategy in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy GetBiddingStrategy(global::Google.Ads.GoogleAds.V3.Services.GetBiddingStrategyRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetBiddingStrategy, null, options, request); + } + /// + /// Returns the requested bidding strategy in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetBiddingStrategyAsync(global::Google.Ads.GoogleAds.V3.Services.GetBiddingStrategyRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetBiddingStrategyAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested bidding strategy in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetBiddingStrategyAsync(global::Google.Ads.GoogleAds.V3.Services.GetBiddingStrategyRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetBiddingStrategy, null, options, request); + } + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesResponse MutateBiddingStrategies(global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateBiddingStrategies(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesResponse MutateBiddingStrategies(global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateBiddingStrategies, null, options, request); + } + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateBiddingStrategiesAsync(global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateBiddingStrategiesAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes bidding strategies. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateBiddingStrategiesAsync(global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategiesRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateBiddingStrategies, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override BiddingStrategyServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new BiddingStrategyServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(BiddingStrategyServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetBiddingStrategy, serviceImpl.GetBiddingStrategy) + .AddMethod(__Method_MutateBiddingStrategies, serviceImpl.MutateBiddingStrategies).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, BiddingStrategyServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetBiddingStrategy, serviceImpl.GetBiddingStrategy); + serviceBinder.AddMethod(__Method_MutateBiddingStrategies, serviceImpl.MutateBiddingStrategies); + } + + } +} +#endregion diff --git a/src/V3/Stubs/BiddingStrategyStatus.cs b/src/V3/Stubs/BiddingStrategyStatus.cs new file mode 100644 index 000000000..066fe3bf5 --- /dev/null +++ b/src/V3/Stubs/BiddingStrategyStatus.cs @@ -0,0 +1,187 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/bidding_strategy_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/bidding_strategy_status.proto + public static partial class BiddingStrategyStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/bidding_strategy_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BiddingStrategyStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9iaWRkaW5nX3N0cmF0", + "ZWd5X3N0YXR1cy5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ibAoZQmlkZGluZ1N0", + "cmF0ZWd5U3RhdHVzRW51bSJPChVCaWRkaW5nU3RyYXRlZ3lTdGF0dXMSDwoL", + "VU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESCwoHRU5BQkxFRBACEgsKB1JF", + "TU9WRUQQBELvAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "QhpCaWRkaW5nU3RyYXRlZ3lTdGF0dXNQcm90b1ABWkJnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVt", + "c8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyStatusEnum.Types.BiddingStrategyStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing BiddingStrategy statuses. + /// + public sealed partial class BiddingStrategyStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BiddingStrategyStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyStatusEnum(BiddingStrategyStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyStatusEnum Clone() { + return new BiddingStrategyStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BiddingStrategyStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BiddingStrategyStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BiddingStrategyStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BiddingStrategyStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of a BiddingStrategy. + /// + public enum BiddingStrategyStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The bidding strategy is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// The bidding strategy is removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BiddingStrategyType.cs b/src/V3/Stubs/BiddingStrategyType.cs new file mode 100644 index 000000000..7bf61b292 --- /dev/null +++ b/src/V3/Stubs/BiddingStrategyType.cs @@ -0,0 +1,264 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/bidding_strategy_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/bidding_strategy_type.proto + public static partial class BiddingStrategyTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/bidding_strategy_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BiddingStrategyTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9iaWRkaW5nX3N0cmF0", + "ZWd5X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvwCChdCaWRkaW5nU3Ry", + "YXRlZ3lUeXBlRW51bSLgAgoTQmlkZGluZ1N0cmF0ZWd5VHlwZRIPCgtVTlNQ", + "RUNJRklFRBAAEgsKB1VOS05PV04QARIOCgpDT01NSVNTSU9OEBASEAoMRU5I", + "QU5DRURfQ1BDEAISDgoKTUFOVUFMX0NQQxADEg4KCk1BTlVBTF9DUE0QBBIO", + "CgpNQU5VQUxfQ1BWEA0SGAoUTUFYSU1JWkVfQ09OVkVSU0lPTlMQChIdChlN", + "QVhJTUlaRV9DT05WRVJTSU9OX1ZBTFVFEAsSFQoRUEFHRV9PTkVfUFJPTU9U", + "RUQQBRIPCgtQRVJDRU5UX0NQQxAMEg4KClRBUkdFVF9DUEEQBhIOCgpUQVJH", + "RVRfQ1BNEA4SGwoXVEFSR0VUX0lNUFJFU1NJT05fU0hBUkUQDxIYChRUQVJH", + "RVRfT1VUUkFOS19TSEFSRRAHEg8KC1RBUkdFVF9ST0FTEAgSEAoMVEFSR0VU", + "X1NQRU5EEAlC7QEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "c0IYQmlkZGluZ1N0cmF0ZWd5VHlwZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcu", + "b3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVt", + "cztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1z", + "ygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFk", + "czo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum.Types.BiddingStrategyType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible bidding strategy types. + /// + public sealed partial class BiddingStrategyTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BiddingStrategyTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyTypeEnum(BiddingStrategyTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BiddingStrategyTypeEnum Clone() { + return new BiddingStrategyTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BiddingStrategyTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BiddingStrategyTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BiddingStrategyTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BiddingStrategyTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible bidding strategy types. + /// + public enum BiddingStrategyType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Commission is an automatic bidding strategy in which the advertiser pays + /// a certain portion of the conversion value. + /// + [pbr::OriginalName("COMMISSION")] Commission = 16, + /// + /// Enhanced CPC is a bidding strategy that raises bids for clicks + /// that seem more likely to lead to a conversion and lowers + /// them for clicks where they seem less likely. + /// + [pbr::OriginalName("ENHANCED_CPC")] EnhancedCpc = 2, + /// + /// Manual click based bidding where user pays per click. + /// + [pbr::OriginalName("MANUAL_CPC")] ManualCpc = 3, + /// + /// Manual impression based bidding + /// where user pays per thousand impressions. + /// + [pbr::OriginalName("MANUAL_CPM")] ManualCpm = 4, + /// + /// A bidding strategy that pays a configurable amount per video view. + /// + [pbr::OriginalName("MANUAL_CPV")] ManualCpv = 13, + /// + /// A bidding strategy that automatically maximizes number of conversions + /// given a daily budget. + /// + [pbr::OriginalName("MAXIMIZE_CONVERSIONS")] MaximizeConversions = 10, + /// + /// An automated bidding strategy that automatically sets bids to maximize + /// revenue while spending your budget. + /// + [pbr::OriginalName("MAXIMIZE_CONVERSION_VALUE")] MaximizeConversionValue = 11, + /// + /// Page-One Promoted bidding scheme, which sets max cpc bids to + /// target impressions on page one or page one promoted slots on google.com. + /// This enum value is deprecated. + /// + [pbr::OriginalName("PAGE_ONE_PROMOTED")] PageOnePromoted = 5, + /// + /// Percent Cpc is bidding strategy where bids are a fraction of the + /// advertised price for some good or service. + /// + [pbr::OriginalName("PERCENT_CPC")] PercentCpc = 12, + /// + /// Target CPA is an automated bid strategy that sets bids + /// to help get as many conversions as possible + /// at the target cost-per-acquisition (CPA) you set. + /// + [pbr::OriginalName("TARGET_CPA")] TargetCpa = 6, + /// + /// Target CPM is an automated bid strategy that sets bids to help get + /// as many impressions as possible at the target cost per one thousand + /// impressions (CPM) you set. + /// + [pbr::OriginalName("TARGET_CPM")] TargetCpm = 14, + /// + /// An automated bidding strategy that sets bids so that a certain percentage + /// of search ads are shown at the top of the first page (or other targeted + /// location). + /// + [pbr::OriginalName("TARGET_IMPRESSION_SHARE")] TargetImpressionShare = 15, + /// + /// Target Outrank Share is an automated bidding strategy that sets bids + /// based on the target fraction of auctions where the advertiser + /// should outrank a specific competitor. + /// This enum value is deprecated. + /// + [pbr::OriginalName("TARGET_OUTRANK_SHARE")] TargetOutrankShare = 7, + /// + /// Target ROAS is an automated bidding strategy + /// that helps you maximize revenue while averaging + /// a specific target Return On Average Spend (ROAS). + /// + [pbr::OriginalName("TARGET_ROAS")] TargetRoas = 8, + /// + /// Target Spend is an automated bid strategy that sets your bids + /// to help get as many clicks as possible within your budget. + /// + [pbr::OriginalName("TARGET_SPEND")] TargetSpend = 9, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BillingSetup.cs b/src/V3/Stubs/BillingSetup.cs new file mode 100644 index 000000000..66ee93eda --- /dev/null +++ b/src/V3/Stubs/BillingSetup.cs @@ -0,0 +1,870 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/billing_setup.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/billing_setup.proto + public static partial class BillingSetupReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/billing_setup.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BillingSetupReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYmlsbGluZ19z", + "ZXR1cC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "Gjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9iaWxsaW5nX3NldHVw", + "X3N0YXR1cy5wcm90bxotZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMv", + "dGltZV90eXBlLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnBy", + "b3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9i", + "dWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJv", + "dG8iuAkKDEJpbGxpbmdTZXR1cBJECg1yZXNvdXJjZV9uYW1lGAEgASgJQi3g", + "QQX6QScKJWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9CaWxsaW5nU2V0dXAS", + "LAoCaWQYAiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EED", + "El0KBnN0YXR1cxgDIAEoDjJILmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zLkJpbGxpbmdTZXR1cFN0YXR1c0VudW0uQmlsbGluZ1NldHVwU3RhdHVz", + "QgPgQQMSaAoQcGF5bWVudHNfYWNjb3VudBgLIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZUIw4EEF+kEqCihnb29nbGVhZHMuZ29vZ2xlYXBp", + "cy5jb20vUGF5bWVudHNBY2NvdW50EmcKFXBheW1lbnRzX2FjY291bnRfaW5m", + "bxgMIAEoCzJDLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5C", + "aWxsaW5nU2V0dXAuUGF5bWVudHNBY2NvdW50SW5mb0ID4EEFEjwKD3N0YXJ0", + "X2RhdGVfdGltZRgJIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZUID4EEFSAASVAoPc3RhcnRfdGltZV90eXBlGAogASgOMjQuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMuVGltZVR5cGVFbnVtLlRpbWVUeXBlQgPg", + "QQVIABI6Cg1lbmRfZGF0ZV90aW1lGA0gASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlQgPgQQNIARJSCg1lbmRfdGltZV90eXBlGA4gASgOMjQu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuVGltZVR5cGVFbnVtLlRp", + "bWVUeXBlQgPgQQNIARrjAgoTUGF5bWVudHNBY2NvdW50SW5mbxI+ChNwYXlt", + "ZW50c19hY2NvdW50X2lkGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlQgPgQQMSQAoVcGF5bWVudHNfYWNjb3VudF9uYW1lGAIgASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQUSPgoTcGF5bWVudHNf", + "cHJvZmlsZV9pZBgDIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZUID4EEFEkAKFXBheW1lbnRzX3Byb2ZpbGVfbmFtZRgEIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEkgKHXNlY29uZGFyeV9wYXlt", + "ZW50c19wcm9maWxlX2lkGAUgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlQgPgQQM6XupBWwolZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0Jp", + "bGxpbmdTZXR1cBIyY3VzdG9tZXJzL3tjdXN0b21lcn0vYmlsbGluZ1NldHVw", + "cy97YmlsbGluZ19zZXR1cH1CDAoKc3RhcnRfdGltZUIKCghlbmRfdGltZUL+", + "AQolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IRQmls", + "bGluZ1NldHVwUHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8v", + "Z29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJj", + "ZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPK", + "AiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.BillingSetupStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.TimeTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.BillingSetup), global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Parser, new[]{ "ResourceName", "Id", "Status", "PaymentsAccount", "PaymentsAccountInfo", "StartDateTime", "StartTimeType", "EndDateTime", "EndTimeType" }, new[]{ "StartTime", "EndTime" }, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Types.PaymentsAccountInfo), global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Types.PaymentsAccountInfo.Parser, new[]{ "PaymentsAccountId", "PaymentsAccountName", "PaymentsProfileId", "PaymentsProfileName", "SecondaryPaymentsProfileId" }, null, null, null)}) + })); + } + #endregion + + } + #region Messages + /// + /// A billing setup, which associates a payments account and an advertiser. A + /// billing setup is specific to one advertiser. + /// + public sealed partial class BillingSetup : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BillingSetup()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.BillingSetupReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetup() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetup(BillingSetup other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + status_ = other.status_; + PaymentsAccount = other.PaymentsAccount; + paymentsAccountInfo_ = other.paymentsAccountInfo_ != null ? other.paymentsAccountInfo_.Clone() : null; + switch (other.StartTimeCase) { + case StartTimeOneofCase.StartDateTime: + StartDateTime = other.StartDateTime; + break; + case StartTimeOneofCase.StartTimeType: + StartTimeType = other.StartTimeType; + break; + } + + switch (other.EndTimeCase) { + case EndTimeOneofCase.EndDateTime: + EndDateTime = other.EndDateTime; + break; + case EndTimeOneofCase.EndTimeType: + EndTimeType = other.EndTimeType; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetup Clone() { + return new BillingSetup(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the billing setup. + /// BillingSetup resource names have the form: + /// + /// `customers/{customer_id}/billingSetups/{billing_setup_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the billing setup. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.BillingSetupStatusEnum.Types.BillingSetupStatus status_ = 0; + /// + /// Output only. The status of the billing setup. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BillingSetupStatusEnum.Types.BillingSetupStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "payments_account" field. + public const int PaymentsAccountFieldNumber = 11; + private static readonly pb::FieldCodec _single_paymentsAccount_codec = pb::FieldCodec.ForClassWrapper(90); + private string paymentsAccount_; + /// + /// Immutable. The resource name of the payments account associated with this billing + /// setup. Payments resource names have the form: + /// + /// `customers/{customer_id}/paymentsAccounts/{payments_account_id}` + /// When setting up billing, this is used to signup with an existing payments + /// account (and then payments_account_info should not be set). + /// When getting a billing setup, this and payments_account_info will be + /// populated. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PaymentsAccount { + get { return paymentsAccount_; } + set { + paymentsAccount_ = value; + } + } + + + /// Field number for the "payments_account_info" field. + public const int PaymentsAccountInfoFieldNumber = 12; + private global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Types.PaymentsAccountInfo paymentsAccountInfo_; + /// + /// Immutable. The payments account information associated with this billing setup. + /// When setting up billing, this is used to signup with a new payments account + /// (and then payments_account should not be set). + /// When getting a billing setup, this and payments_account will be + /// populated. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Types.PaymentsAccountInfo PaymentsAccountInfo { + get { return paymentsAccountInfo_; } + set { + paymentsAccountInfo_ = value; + } + } + + /// Field number for the "start_date_time" field. + public const int StartDateTimeFieldNumber = 9; + private static readonly pb::FieldCodec _oneof_startDateTime_codec = pb::FieldCodec.ForClassWrapper(74); + /// + /// Immutable. The start date time in yyyy-MM-dd or yyyy-MM-dd HH:mm:ss format. Only a + /// future time is allowed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDateTime { + get { return startTimeCase_ == StartTimeOneofCase.StartDateTime ? (string) startTime_ : (string) null; } + set { + startTime_ = value; + startTimeCase_ = value == null ? StartTimeOneofCase.None : StartTimeOneofCase.StartDateTime; + } + } + + /// Field number for the "start_time_type" field. + public const int StartTimeTypeFieldNumber = 10; + /// + /// Immutable. The start time as a type. Only NOW is allowed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType StartTimeType { + get { return startTimeCase_ == StartTimeOneofCase.StartTimeType ? (global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType) startTime_ : 0; } + set { + startTime_ = value; + startTimeCase_ = StartTimeOneofCase.StartTimeType; + } + } + + /// Field number for the "end_date_time" field. + public const int EndDateTimeFieldNumber = 13; + private static readonly pb::FieldCodec _oneof_endDateTime_codec = pb::FieldCodec.ForClassWrapper(106); + /// + /// Output only. The end date time in yyyy-MM-dd or yyyy-MM-dd HH:mm:ss format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDateTime { + get { return endTimeCase_ == EndTimeOneofCase.EndDateTime ? (string) endTime_ : (string) null; } + set { + endTime_ = value; + endTimeCase_ = value == null ? EndTimeOneofCase.None : EndTimeOneofCase.EndDateTime; + } + } + + /// Field number for the "end_time_type" field. + public const int EndTimeTypeFieldNumber = 14; + /// + /// Output only. The end time as a type. The only possible value is FOREVER. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType EndTimeType { + get { return endTimeCase_ == EndTimeOneofCase.EndTimeType ? (global::Google.Ads.GoogleAds.V3.Enums.TimeTypeEnum.Types.TimeType) endTime_ : 0; } + set { + endTime_ = value; + endTimeCase_ = EndTimeOneofCase.EndTimeType; + } + } + + private object startTime_; + /// Enum of possible cases for the "start_time" oneof. + public enum StartTimeOneofCase { + None = 0, + StartDateTime = 9, + StartTimeType = 10, + } + private StartTimeOneofCase startTimeCase_ = StartTimeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public StartTimeOneofCase StartTimeCase { + get { return startTimeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearStartTime() { + startTimeCase_ = StartTimeOneofCase.None; + startTime_ = null; + } + + private object endTime_; + /// Enum of possible cases for the "end_time" oneof. + public enum EndTimeOneofCase { + None = 0, + EndDateTime = 13, + EndTimeType = 14, + } + private EndTimeOneofCase endTimeCase_ = EndTimeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EndTimeOneofCase EndTimeCase { + get { return endTimeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearEndTime() { + endTimeCase_ = EndTimeOneofCase.None; + endTime_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BillingSetup); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BillingSetup other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Status != other.Status) return false; + if (PaymentsAccount != other.PaymentsAccount) return false; + if (!object.Equals(PaymentsAccountInfo, other.PaymentsAccountInfo)) return false; + if (StartDateTime != other.StartDateTime) return false; + if (StartTimeType != other.StartTimeType) return false; + if (EndDateTime != other.EndDateTime) return false; + if (EndTimeType != other.EndTimeType) return false; + if (StartTimeCase != other.StartTimeCase) return false; + if (EndTimeCase != other.EndTimeCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (paymentsAccount_ != null) hash ^= PaymentsAccount.GetHashCode(); + if (paymentsAccountInfo_ != null) hash ^= PaymentsAccountInfo.GetHashCode(); + if (startTimeCase_ == StartTimeOneofCase.StartDateTime) hash ^= StartDateTime.GetHashCode(); + if (startTimeCase_ == StartTimeOneofCase.StartTimeType) hash ^= StartTimeType.GetHashCode(); + if (endTimeCase_ == EndTimeOneofCase.EndDateTime) hash ^= EndDateTime.GetHashCode(); + if (endTimeCase_ == EndTimeOneofCase.EndTimeType) hash ^= EndTimeType.GetHashCode(); + hash ^= (int) startTimeCase_; + hash ^= (int) endTimeCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (Status != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Status); + } + if (startTimeCase_ == StartTimeOneofCase.StartDateTime) { + _oneof_startDateTime_codec.WriteTagAndValue(output, (string) startTime_); + } + if (startTimeCase_ == StartTimeOneofCase.StartTimeType) { + output.WriteRawTag(80); + output.WriteEnum((int) StartTimeType); + } + if (paymentsAccount_ != null) { + _single_paymentsAccount_codec.WriteTagAndValue(output, PaymentsAccount); + } + if (paymentsAccountInfo_ != null) { + output.WriteRawTag(98); + output.WriteMessage(PaymentsAccountInfo); + } + if (endTimeCase_ == EndTimeOneofCase.EndDateTime) { + _oneof_endDateTime_codec.WriteTagAndValue(output, (string) endTime_); + } + if (endTimeCase_ == EndTimeOneofCase.EndTimeType) { + output.WriteRawTag(112); + output.WriteEnum((int) EndTimeType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (paymentsAccount_ != null) { + size += _single_paymentsAccount_codec.CalculateSizeWithTag(PaymentsAccount); + } + if (paymentsAccountInfo_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PaymentsAccountInfo); + } + if (startTimeCase_ == StartTimeOneofCase.StartDateTime) { + size += _oneof_startDateTime_codec.CalculateSizeWithTag(StartDateTime); + } + if (startTimeCase_ == StartTimeOneofCase.StartTimeType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) StartTimeType); + } + if (endTimeCase_ == EndTimeOneofCase.EndDateTime) { + size += _oneof_endDateTime_codec.CalculateSizeWithTag(EndDateTime); + } + if (endTimeCase_ == EndTimeOneofCase.EndTimeType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) EndTimeType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BillingSetup other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.paymentsAccount_ != null) { + if (paymentsAccount_ == null || other.PaymentsAccount != "") { + PaymentsAccount = other.PaymentsAccount; + } + } + if (other.paymentsAccountInfo_ != null) { + if (paymentsAccountInfo_ == null) { + PaymentsAccountInfo = new global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Types.PaymentsAccountInfo(); + } + PaymentsAccountInfo.MergeFrom(other.PaymentsAccountInfo); + } + switch (other.StartTimeCase) { + case StartTimeOneofCase.StartDateTime: + StartDateTime = other.StartDateTime; + break; + case StartTimeOneofCase.StartTimeType: + StartTimeType = other.StartTimeType; + break; + } + + switch (other.EndTimeCase) { + case EndTimeOneofCase.EndDateTime: + EndDateTime = other.EndDateTime; + break; + case EndTimeOneofCase.EndTimeType: + EndTimeType = other.EndTimeType; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 24: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.BillingSetupStatusEnum.Types.BillingSetupStatus) input.ReadEnum(); + break; + } + case 74: { + StartDateTime = _oneof_startDateTime_codec.Read(input); + break; + } + case 80: { + startTime_ = input.ReadEnum(); + startTimeCase_ = StartTimeOneofCase.StartTimeType; + break; + } + case 90: { + string value = _single_paymentsAccount_codec.Read(input); + if (paymentsAccount_ == null || value != "") { + PaymentsAccount = value; + } + break; + } + case 98: { + if (paymentsAccountInfo_ == null) { + PaymentsAccountInfo = new global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Types.PaymentsAccountInfo(); + } + input.ReadMessage(PaymentsAccountInfo); + break; + } + case 106: { + EndDateTime = _oneof_endDateTime_codec.Read(input); + break; + } + case 112: { + endTime_ = input.ReadEnum(); + endTimeCase_ = EndTimeOneofCase.EndTimeType; + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the BillingSetup message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Container of payments account information for this billing. + /// + public sealed partial class PaymentsAccountInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PaymentsAccountInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PaymentsAccountInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PaymentsAccountInfo(PaymentsAccountInfo other) : this() { + PaymentsAccountId = other.PaymentsAccountId; + PaymentsAccountName = other.PaymentsAccountName; + PaymentsProfileId = other.PaymentsProfileId; + PaymentsProfileName = other.PaymentsProfileName; + SecondaryPaymentsProfileId = other.SecondaryPaymentsProfileId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PaymentsAccountInfo Clone() { + return new PaymentsAccountInfo(this); + } + + /// Field number for the "payments_account_id" field. + public const int PaymentsAccountIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_paymentsAccountId_codec = pb::FieldCodec.ForClassWrapper(10); + private string paymentsAccountId_; + /// + /// Output only. A 16 digit id used to identify the payments account associated with the + /// billing setup. + /// + /// This must be passed as a string with dashes, e.g. "1234-5678-9012-3456". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PaymentsAccountId { + get { return paymentsAccountId_; } + set { + paymentsAccountId_ = value; + } + } + + + /// Field number for the "payments_account_name" field. + public const int PaymentsAccountNameFieldNumber = 2; + private static readonly pb::FieldCodec _single_paymentsAccountName_codec = pb::FieldCodec.ForClassWrapper(18); + private string paymentsAccountName_; + /// + /// Immutable. The name of the payments account associated with the billing setup. + /// + /// This enables the user to specify a meaningful name for a payments account + /// to aid in reconciling monthly invoices. + /// + /// This name will be printed in the monthly invoices. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PaymentsAccountName { + get { return paymentsAccountName_; } + set { + paymentsAccountName_ = value; + } + } + + + /// Field number for the "payments_profile_id" field. + public const int PaymentsProfileIdFieldNumber = 3; + private static readonly pb::FieldCodec _single_paymentsProfileId_codec = pb::FieldCodec.ForClassWrapper(26); + private string paymentsProfileId_; + /// + /// Immutable. A 12 digit id used to identify the payments profile associated with the + /// billing setup. + /// + /// This must be passed in as a string with dashes, e.g. "1234-5678-9012". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PaymentsProfileId { + get { return paymentsProfileId_; } + set { + paymentsProfileId_ = value; + } + } + + + /// Field number for the "payments_profile_name" field. + public const int PaymentsProfileNameFieldNumber = 4; + private static readonly pb::FieldCodec _single_paymentsProfileName_codec = pb::FieldCodec.ForClassWrapper(34); + private string paymentsProfileName_; + /// + /// Output only. The name of the payments profile associated with the billing setup. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PaymentsProfileName { + get { return paymentsProfileName_; } + set { + paymentsProfileName_ = value; + } + } + + + /// Field number for the "secondary_payments_profile_id" field. + public const int SecondaryPaymentsProfileIdFieldNumber = 5; + private static readonly pb::FieldCodec _single_secondaryPaymentsProfileId_codec = pb::FieldCodec.ForClassWrapper(42); + private string secondaryPaymentsProfileId_; + /// + /// Output only. A secondary payments profile id present in uncommon situations, e.g. + /// when a sequential liability agreement has been arranged. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string SecondaryPaymentsProfileId { + get { return secondaryPaymentsProfileId_; } + set { + secondaryPaymentsProfileId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PaymentsAccountInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PaymentsAccountInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (PaymentsAccountId != other.PaymentsAccountId) return false; + if (PaymentsAccountName != other.PaymentsAccountName) return false; + if (PaymentsProfileId != other.PaymentsProfileId) return false; + if (PaymentsProfileName != other.PaymentsProfileName) return false; + if (SecondaryPaymentsProfileId != other.SecondaryPaymentsProfileId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (paymentsAccountId_ != null) hash ^= PaymentsAccountId.GetHashCode(); + if (paymentsAccountName_ != null) hash ^= PaymentsAccountName.GetHashCode(); + if (paymentsProfileId_ != null) hash ^= PaymentsProfileId.GetHashCode(); + if (paymentsProfileName_ != null) hash ^= PaymentsProfileName.GetHashCode(); + if (secondaryPaymentsProfileId_ != null) hash ^= SecondaryPaymentsProfileId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (paymentsAccountId_ != null) { + _single_paymentsAccountId_codec.WriteTagAndValue(output, PaymentsAccountId); + } + if (paymentsAccountName_ != null) { + _single_paymentsAccountName_codec.WriteTagAndValue(output, PaymentsAccountName); + } + if (paymentsProfileId_ != null) { + _single_paymentsProfileId_codec.WriteTagAndValue(output, PaymentsProfileId); + } + if (paymentsProfileName_ != null) { + _single_paymentsProfileName_codec.WriteTagAndValue(output, PaymentsProfileName); + } + if (secondaryPaymentsProfileId_ != null) { + _single_secondaryPaymentsProfileId_codec.WriteTagAndValue(output, SecondaryPaymentsProfileId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (paymentsAccountId_ != null) { + size += _single_paymentsAccountId_codec.CalculateSizeWithTag(PaymentsAccountId); + } + if (paymentsAccountName_ != null) { + size += _single_paymentsAccountName_codec.CalculateSizeWithTag(PaymentsAccountName); + } + if (paymentsProfileId_ != null) { + size += _single_paymentsProfileId_codec.CalculateSizeWithTag(PaymentsProfileId); + } + if (paymentsProfileName_ != null) { + size += _single_paymentsProfileName_codec.CalculateSizeWithTag(PaymentsProfileName); + } + if (secondaryPaymentsProfileId_ != null) { + size += _single_secondaryPaymentsProfileId_codec.CalculateSizeWithTag(SecondaryPaymentsProfileId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PaymentsAccountInfo other) { + if (other == null) { + return; + } + if (other.paymentsAccountId_ != null) { + if (paymentsAccountId_ == null || other.PaymentsAccountId != "") { + PaymentsAccountId = other.PaymentsAccountId; + } + } + if (other.paymentsAccountName_ != null) { + if (paymentsAccountName_ == null || other.PaymentsAccountName != "") { + PaymentsAccountName = other.PaymentsAccountName; + } + } + if (other.paymentsProfileId_ != null) { + if (paymentsProfileId_ == null || other.PaymentsProfileId != "") { + PaymentsProfileId = other.PaymentsProfileId; + } + } + if (other.paymentsProfileName_ != null) { + if (paymentsProfileName_ == null || other.PaymentsProfileName != "") { + PaymentsProfileName = other.PaymentsProfileName; + } + } + if (other.secondaryPaymentsProfileId_ != null) { + if (secondaryPaymentsProfileId_ == null || other.SecondaryPaymentsProfileId != "") { + SecondaryPaymentsProfileId = other.SecondaryPaymentsProfileId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_paymentsAccountId_codec.Read(input); + if (paymentsAccountId_ == null || value != "") { + PaymentsAccountId = value; + } + break; + } + case 18: { + string value = _single_paymentsAccountName_codec.Read(input); + if (paymentsAccountName_ == null || value != "") { + PaymentsAccountName = value; + } + break; + } + case 26: { + string value = _single_paymentsProfileId_codec.Read(input); + if (paymentsProfileId_ == null || value != "") { + PaymentsProfileId = value; + } + break; + } + case 34: { + string value = _single_paymentsProfileName_codec.Read(input); + if (paymentsProfileName_ == null || value != "") { + PaymentsProfileName = value; + } + break; + } + case 42: { + string value = _single_secondaryPaymentsProfileId_codec.Read(input); + if (secondaryPaymentsProfileId_ == null || value != "") { + SecondaryPaymentsProfileId = value; + } + break; + } + } + } + } + + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BillingSetupError.cs b/src/V3/Stubs/BillingSetupError.cs new file mode 100644 index 000000000..5e08c3724 --- /dev/null +++ b/src/V3/Stubs/BillingSetupError.cs @@ -0,0 +1,269 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/billing_setup_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/billing_setup_error.proto + public static partial class BillingSetupErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/billing_setup_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BillingSetupErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYmlsbGluZ19zZXR1", + "cF9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvItkFChVCaWxsaW5nU2V0", + "dXBFcnJvckVudW0ivwUKEUJpbGxpbmdTZXR1cEVycm9yEg8KC1VOU1BFQ0lG", + "SUVEEAASCwoHVU5LTk9XThABEicKI0NBTk5PVF9VU0VfRVhJU1RJTkdfQU5E", + "X05FV19BQ0NPVU5UEAISJwojQ0FOTk9UX1JFTU9WRV9TVEFSVEVEX0JJTExJ", + "TkdfU0VUVVAQAxIyCi5DQU5OT1RfQ0hBTkdFX0JJTExJTkdfVE9fU0FNRV9Q", + "QVlNRU5UU19BQ0NPVU5UEAQSMwovQklMTElOR19TRVRVUF9OT1RfUEVSTUlU", + "VEVEX0ZPUl9DVVNUT01FUl9TVEFUVVMQBRIcChhJTlZBTElEX1BBWU1FTlRT", + "X0FDQ09VTlQQBhI1CjFCSUxMSU5HX1NFVFVQX05PVF9QRVJNSVRURURfRk9S", + "X0NVU1RPTUVSX0NBVEVHT1JZEAcSGwoXSU5WQUxJRF9TVEFSVF9USU1FX1RZ", + "UEUQCBIjCh9USElSRF9QQVJUWV9BTFJFQURZX0hBU19CSUxMSU5HEAkSHQoZ", + "QklMTElOR19TRVRVUF9JTl9QUk9HUkVTUxAKEhgKFE5PX1NJR05VUF9QRVJN", + "SVNTSU9OEAsSIQodQ0hBTkdFX09GX0JJTExfVE9fSU5fUFJPR1JFU1MQDBIe", + "ChpQQVlNRU5UU19QUk9GSUxFX05PVF9GT1VORBANEh4KGlBBWU1FTlRTX0FD", + "Q09VTlRfTk9UX0ZPVU5EEA4SHwobUEFZTUVOVFNfUFJPRklMRV9JTkVMSUdJ", + "QkxFEA8SHwobUEFZTUVOVFNfQUNDT1VOVF9JTkVMSUdJQkxFEBASJAogQ1VT", + "VE9NRVJfTkVFRFNfSU5URVJOQUxfQVBQUk9WQUwQERI2CjJQQVlNRU5UU19B", + "Q0NPVU5UX0lORUxJR0lCTEVfQ1VSUkVOQ1lfQ09ERV9NSVNNQVRDSBATQvEB", + "CiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQhZCaWxsaW5n", + "U2V0dXBFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3Rv", + "L2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJyb3JzogID", + "R0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIeR29vZ2xl", + "XEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdvb2ds", + "ZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.BillingSetupErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.BillingSetupErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.BillingSetupErrorEnum.Types.BillingSetupError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible billing setup errors. + /// + public sealed partial class BillingSetupErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BillingSetupErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.BillingSetupErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupErrorEnum(BillingSetupErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupErrorEnum Clone() { + return new BillingSetupErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BillingSetupErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BillingSetupErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BillingSetupErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BillingSetupErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible billing setup errors. + /// + public enum BillingSetupError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Cannot specify both an existing payments account and a new payments + /// account when setting up billing. + /// + [pbr::OriginalName("CANNOT_USE_EXISTING_AND_NEW_ACCOUNT")] CannotUseExistingAndNewAccount = 2, + /// + /// Cannot cancel an approved billing setup whose start time has passed. + /// + [pbr::OriginalName("CANNOT_REMOVE_STARTED_BILLING_SETUP")] CannotRemoveStartedBillingSetup = 3, + /// + /// Cannot perform a Change of Bill-To (CBT) to the same payments account. + /// + [pbr::OriginalName("CANNOT_CHANGE_BILLING_TO_SAME_PAYMENTS_ACCOUNT")] CannotChangeBillingToSamePaymentsAccount = 4, + /// + /// Billing setups can only be used by customers with ENABLED or DRAFT + /// status. + /// + [pbr::OriginalName("BILLING_SETUP_NOT_PERMITTED_FOR_CUSTOMER_STATUS")] BillingSetupNotPermittedForCustomerStatus = 5, + /// + /// Billing setups must either include a correctly formatted existing + /// payments account id, or a non-empty new payments account name. + /// + [pbr::OriginalName("INVALID_PAYMENTS_ACCOUNT")] InvalidPaymentsAccount = 6, + /// + /// Only billable and third-party customers can create billing setups. + /// + [pbr::OriginalName("BILLING_SETUP_NOT_PERMITTED_FOR_CUSTOMER_CATEGORY")] BillingSetupNotPermittedForCustomerCategory = 7, + /// + /// Billing setup creations can only use NOW for start time type. + /// + [pbr::OriginalName("INVALID_START_TIME_TYPE")] InvalidStartTimeType = 8, + /// + /// Billing setups can only be created for a third-party customer if they do + /// not already have a setup. + /// + [pbr::OriginalName("THIRD_PARTY_ALREADY_HAS_BILLING")] ThirdPartyAlreadyHasBilling = 9, + /// + /// Billing setups cannot be created if there is already a pending billing in + /// progress. + /// + [pbr::OriginalName("BILLING_SETUP_IN_PROGRESS")] BillingSetupInProgress = 10, + /// + /// Billing setups can only be created by customers who have permission to + /// setup billings. Users can contact a representative for help setting up + /// permissions. + /// + [pbr::OriginalName("NO_SIGNUP_PERMISSION")] NoSignupPermission = 11, + /// + /// Billing setups cannot be created if there is already a future-approved + /// billing. + /// + [pbr::OriginalName("CHANGE_OF_BILL_TO_IN_PROGRESS")] ChangeOfBillToInProgress = 12, + /// + /// Requested payments profile not found. + /// + [pbr::OriginalName("PAYMENTS_PROFILE_NOT_FOUND")] PaymentsProfileNotFound = 13, + /// + /// Requested payments account not found. + /// + [pbr::OriginalName("PAYMENTS_ACCOUNT_NOT_FOUND")] PaymentsAccountNotFound = 14, + /// + /// Billing setup creation failed because the payments profile is ineligible. + /// + [pbr::OriginalName("PAYMENTS_PROFILE_INELIGIBLE")] PaymentsProfileIneligible = 15, + /// + /// Billing setup creation failed because the payments account is ineligible. + /// + [pbr::OriginalName("PAYMENTS_ACCOUNT_INELIGIBLE")] PaymentsAccountIneligible = 16, + /// + /// Billing setup creation failed because the payments profile needs internal + /// approval. + /// + [pbr::OriginalName("CUSTOMER_NEEDS_INTERNAL_APPROVAL")] CustomerNeedsInternalApproval = 17, + /// + /// Payments account has different currency code than the current customer + /// and hence cannot be used to setup billing. + /// + [pbr::OriginalName("PAYMENTS_ACCOUNT_INELIGIBLE_CURRENCY_CODE_MISMATCH")] PaymentsAccountIneligibleCurrencyCodeMismatch = 19, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BillingSetupService.cs b/src/V3/Stubs/BillingSetupService.cs new file mode 100644 index 000000000..1d2bc4b1a --- /dev/null +++ b/src/V3/Stubs/BillingSetupService.cs @@ -0,0 +1,872 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/billing_setup_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/billing_setup_service.proto + public static partial class BillingSetupServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/billing_setup_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BillingSetupServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9iaWxsaW5nX3Nl", + "dHVwX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzGjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYmls", + "bGluZ19zZXR1cC5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRf", + "YmVoYXZpb3IucHJvdG8iNAoWR2V0QmlsbGluZ1NldHVwUmVxdWVzdBIaCg1y", + "ZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIihgEKGU11dGF0ZUJpbGxpbmdTZXR1", + "cFJlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlCA+BBAhJPCglvcGVyYXRp", + "b24YAiABKAsyNy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5C", + "aWxsaW5nU2V0dXBPcGVyYXRpb25CA+BBAiJ5ChVCaWxsaW5nU2V0dXBPcGVy", + "YXRpb24SQQoGY3JlYXRlGAIgASgLMi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzLkJpbGxpbmdTZXR1cEgAEhAKBnJlbW92ZRgBIAEoCUgA", + "QgsKCW9wZXJhdGlvbiJoChpNdXRhdGVCaWxsaW5nU2V0dXBSZXNwb25zZRJK", + "CgZyZXN1bHQYASABKAsyOi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5NdXRhdGVCaWxsaW5nU2V0dXBSZXN1bHQiMQoYTXV0YXRlQmlsbGlu", + "Z1NldHVwUmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAky4wMKE0JpbGxp", + "bmdTZXR1cFNlcnZpY2USxQEKD0dldEJpbGxpbmdTZXR1cBI4Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEJpbGxpbmdTZXR1cFJlcXVl", + "c3QaLy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQmlsbGlu", + "Z1NldHVwIkeC0+STAjESLy92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMv", + "Ki9iaWxsaW5nU2V0dXBzLyp92kENcmVzb3VyY2VfbmFtZRLmAQoSTXV0YXRl", + "QmlsbGluZ1NldHVwEjsuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuTXV0YXRlQmlsbGluZ1NldHVwUmVxdWVzdBo8Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUJpbGxpbmdTZXR1cFJlc3BvbnNl", + "IlWC0+STAjciMi92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2JpbGxp", + "bmdTZXR1cHM6bXV0YXRlOgEq2kEVY3VzdG9tZXJfaWQsb3BlcmF0aW9uGhvK", + "QRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21C/wEKJGNvbS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlc0IYQmlsbGluZ1NldHVwU2VydmljZVBy", + "b3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.BillingSetupReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetBillingSetupRequest), global::Google.Ads.GoogleAds.V3.Services.GetBillingSetupRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupRequest), global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupRequest.Parser, new[]{ "CustomerId", "Operation" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.BillingSetupOperation), global::Google.Ads.GoogleAds.V3.Services.BillingSetupOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResponse), global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResponse.Parser, new[]{ "Result" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResult), global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [BillingSetupService.GetBillingSetup][google.ads.googleads.v3.services.BillingSetupService.GetBillingSetup]. + /// + public sealed partial class GetBillingSetupRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetBillingSetupRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BillingSetupServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetBillingSetupRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetBillingSetupRequest(GetBillingSetupRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetBillingSetupRequest Clone() { + return new GetBillingSetupRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the billing setup to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetBillingSetupRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetBillingSetupRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetBillingSetupRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for billing setup mutate operations. + /// + public sealed partial class MutateBillingSetupRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateBillingSetupRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BillingSetupServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupRequest(MutateBillingSetupRequest other) : this() { + customerId_ = other.customerId_; + operation_ = other.operation_ != null ? other.operation_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupRequest Clone() { + return new MutateBillingSetupRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. Id of the customer to apply the billing setup mutate operation to. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operation" field. + public const int OperationFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Services.BillingSetupOperation operation_; + /// + /// Required. The operation to perform. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.BillingSetupOperation Operation { + get { return operation_; } + set { + operation_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateBillingSetupRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateBillingSetupRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (!object.Equals(Operation, other.Operation)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (operation_ != null) hash ^= Operation.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (operation_ != null) { + output.WriteRawTag(18); + output.WriteMessage(Operation); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (operation_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Operation); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateBillingSetupRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.operation_ != null) { + if (operation_ == null) { + Operation = new global::Google.Ads.GoogleAds.V3.Services.BillingSetupOperation(); + } + Operation.MergeFrom(other.Operation); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + if (operation_ == null) { + Operation = new global::Google.Ads.GoogleAds.V3.Services.BillingSetupOperation(); + } + input.ReadMessage(Operation); + break; + } + } + } + } + + } + + /// + /// A single operation on a billing setup, which describes the cancellation of an + /// existing billing setup. + /// + public sealed partial class BillingSetupOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BillingSetupOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BillingSetupServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupOperation(BillingSetupOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupOperation Clone() { + return new BillingSetupOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 2; + /// + /// Creates a billing setup. No resource name is expected for the new billing + /// setup. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.BillingSetup Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.BillingSetup) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 1; + /// + /// Resource name of the billing setup to remove. A setup cannot be + /// removed unless it is in a pending state or its scheduled start time is in + /// the future. The resource name looks like + /// `customers/{customer_id}/billingSetups/{billing_id}`. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 2, + Remove = 1, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BillingSetupOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BillingSetupOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(10); + output.WriteString(Remove); + } + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(18); + output.WriteMessage(Create); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BillingSetupOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.BillingSetup(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + Remove = input.ReadString(); + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.BillingSetup subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.BillingSetup(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + } + } + } + + } + + /// + /// Response message for a billing setup operation. + /// + public sealed partial class MutateBillingSetupResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateBillingSetupResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BillingSetupServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupResponse(MutateBillingSetupResponse other) : this() { + result_ = other.result_ != null ? other.result_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupResponse Clone() { + return new MutateBillingSetupResponse(this); + } + + /// Field number for the "result" field. + public const int ResultFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResult result_; + /// + /// A result that identifies the resource affected by the mutate request. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResult Result { + get { return result_; } + set { + result_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateBillingSetupResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateBillingSetupResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Result, other.Result)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (result_ != null) hash ^= Result.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (result_ != null) { + output.WriteRawTag(10); + output.WriteMessage(Result); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (result_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Result); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateBillingSetupResponse other) { + if (other == null) { + return; + } + if (other.result_ != null) { + if (result_ == null) { + Result = new global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResult(); + } + Result.MergeFrom(other.Result); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (result_ == null) { + Result = new global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResult(); + } + input.ReadMessage(Result); + break; + } + } + } + } + + } + + /// + /// Result for a single billing setup mutate. + /// + public sealed partial class MutateBillingSetupResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateBillingSetupResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.BillingSetupServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupResult(MutateBillingSetupResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateBillingSetupResult Clone() { + return new MutateBillingSetupResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateBillingSetupResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateBillingSetupResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateBillingSetupResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BillingSetupServiceClient.cs b/src/V3/Stubs/BillingSetupServiceClient.cs new file mode 100644 index 000000000..710e692f6 --- /dev/null +++ b/src/V3/Stubs/BillingSetupServiceClient.cs @@ -0,0 +1,770 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class BillingSetupServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static BillingSetupServiceSettings GetDefault() => new BillingSetupServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public BillingSetupServiceSettings() { } + + private BillingSetupServiceSettings(BillingSetupServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetBillingSetupSettings = existing.GetBillingSetupSettings; + MutateBillingSetupSettings = existing.MutateBillingSetupSettings; + OnCopy(existing); + } + + partial void OnCopy(BillingSetupServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// BillingSetupServiceClient.GetBillingSetup and BillingSetupServiceClient.GetBillingSetupAsync. + /// + /// + /// The default BillingSetupServiceClient.GetBillingSetup and + /// BillingSetupServiceClient.GetBillingSetupAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetBillingSetupSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// BillingSetupServiceClient.MutateBillingSetup and BillingSetupServiceClient.MutateBillingSetupAsync. + /// + /// + /// The default BillingSetupServiceClient.MutateBillingSetup and + /// BillingSetupServiceClient.MutateBillingSetupAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateBillingSetupSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public BillingSetupServiceSettings Clone() => new BillingSetupServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class BillingSetupServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public BillingSetupServiceSettings Settings { get; set; } + + /// + public override BillingSetupServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return BillingSetupServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return BillingSetupServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => BillingSetupServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => BillingSetupServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => BillingSetupServiceClient.ChannelPool; + } + + /// + /// BillingSetupService client wrapper, for convenient use. + /// + public abstract partial class BillingSetupServiceClient + { + /// + /// The default endpoint for the BillingSetupService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default BillingSetupService scopes. + /// + /// + /// The default BillingSetupService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// BillingSetupServiceClient client = await BillingSetupServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// BillingSetupServiceClient.DefaultEndpoint.Host, BillingSetupServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// BillingSetupServiceClient client = BillingSetupServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, BillingSetupServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// BillingSetupServiceClient client = BillingSetupServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// BillingSetupServiceClient.DefaultEndpoint.Host, BillingSetupServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// BillingSetupServiceClient client = BillingSetupServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static BillingSetupServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, BillingSetupServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static BillingSetupServiceClient Create(grpccore::Channel channel, BillingSetupServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static BillingSetupServiceClient Create(grpccore::CallInvoker callInvoker, BillingSetupServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + BillingSetupService.BillingSetupServiceClient grpcClient = new BillingSetupService.BillingSetupServiceClient(callInvoker); + return new BillingSetupServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC BillingSetupService client. + /// + public virtual BillingSetupService.BillingSetupServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns a billing setup. + /// + /// + /// Required. The resource name of the billing setup to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetBillingSetupAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetBillingSetupAsync( + new GetBillingSetupRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns a billing setup. + /// + /// + /// Required. The resource name of the billing setup to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetBillingSetupAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetBillingSetupAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns a billing setup. + /// + /// + /// Required. The resource name of the billing setup to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::BillingSetup GetBillingSetup( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetBillingSetup( + new GetBillingSetupRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns a billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetBillingSetupAsync( + GetBillingSetupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns a billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetBillingSetupAsync( + GetBillingSetupRequest request, + st::CancellationToken cancellationToken) => GetBillingSetupAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns a billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::BillingSetup GetBillingSetup( + GetBillingSetupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// + /// Required. Id of the customer to apply the billing setup mutate operation to. + /// + /// + /// Required. The operation to perform. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBillingSetupAsync( + string customerId, + BillingSetupOperation operation, + gaxgrpc::CallSettings callSettings = null) => MutateBillingSetupAsync( + new MutateBillingSetupRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + }, + callSettings); + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// + /// Required. Id of the customer to apply the billing setup mutate operation to. + /// + /// + /// Required. The operation to perform. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBillingSetupAsync( + string customerId, + BillingSetupOperation operation, + st::CancellationToken cancellationToken) => MutateBillingSetupAsync( + customerId, + operation, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// + /// Required. Id of the customer to apply the billing setup mutate operation to. + /// + /// + /// Required. The operation to perform. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateBillingSetupResponse MutateBillingSetup( + string customerId, + BillingSetupOperation operation, + gaxgrpc::CallSettings callSettings = null) => MutateBillingSetup( + new MutateBillingSetupRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + }, + callSettings); + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBillingSetupAsync( + MutateBillingSetupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateBillingSetupAsync( + MutateBillingSetupRequest request, + st::CancellationToken cancellationToken) => MutateBillingSetupAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateBillingSetupResponse MutateBillingSetup( + MutateBillingSetupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// BillingSetupService client wrapper implementation, for convenient use. + /// + public sealed partial class BillingSetupServiceClientImpl : BillingSetupServiceClient + { + private readonly gaxgrpc::ApiCall _callGetBillingSetup; + private readonly gaxgrpc::ApiCall _callMutateBillingSetup; + + /// + /// Constructs a client wrapper for the BillingSetupService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public BillingSetupServiceClientImpl(BillingSetupService.BillingSetupServiceClient grpcClient, BillingSetupServiceSettings settings) + { + GrpcClient = grpcClient; + BillingSetupServiceSettings effectiveSettings = settings ?? BillingSetupServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetBillingSetup = clientHelper.BuildApiCall( + GrpcClient.GetBillingSetupAsync, GrpcClient.GetBillingSetup, effectiveSettings.GetBillingSetupSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateBillingSetup = clientHelper.BuildApiCall( + GrpcClient.MutateBillingSetupAsync, GrpcClient.MutateBillingSetup, effectiveSettings.MutateBillingSetupSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetBillingSetup); + Modify_GetBillingSetupApiCall(ref _callGetBillingSetup); + Modify_ApiCall(ref _callMutateBillingSetup); + Modify_MutateBillingSetupApiCall(ref _callMutateBillingSetup); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetBillingSetupApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateBillingSetupApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(BillingSetupService.BillingSetupServiceClient grpcClient, BillingSetupServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC BillingSetupService client. + /// + public override BillingSetupService.BillingSetupServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetBillingSetupRequest(ref GetBillingSetupRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateBillingSetupRequest(ref MutateBillingSetupRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns a billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetBillingSetupAsync( + GetBillingSetupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetBillingSetupRequest(ref request, ref callSettings); + return _callGetBillingSetup.Async(request, callSettings); + } + + /// + /// Returns a billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::BillingSetup GetBillingSetup( + GetBillingSetupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetBillingSetupRequest(ref request, ref callSettings); + return _callGetBillingSetup.Sync(request, callSettings); + } + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateBillingSetupAsync( + MutateBillingSetupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateBillingSetupRequest(ref request, ref callSettings); + return _callMutateBillingSetup.Async(request, callSettings); + } + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateBillingSetupResponse MutateBillingSetup( + MutateBillingSetupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateBillingSetupRequest(ref request, ref callSettings); + return _callMutateBillingSetup.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/BillingSetupServiceGrpc.cs b/src/V3/Stubs/BillingSetupServiceGrpc.cs new file mode 100644 index 000000000..f2dd78b01 --- /dev/null +++ b/src/V3/Stubs/BillingSetupServiceGrpc.cs @@ -0,0 +1,232 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/billing_setup_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// A service for designating the business entity responsible for accrued costs. + /// + /// A billing setup is associated with a payments account. Billing-related + /// activity for all billing setups associated with a particular payments account + /// will appear on a single invoice generated monthly. + /// + /// Mutates: + /// The REMOVE operation cancels a pending billing setup. + /// The CREATE operation creates a new billing setup. + /// + public static partial class BillingSetupService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.BillingSetupService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetBillingSetupRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetBillingSetupRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_BillingSetup = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.BillingSetup.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateBillingSetupRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateBillingSetupResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetBillingSetup = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetBillingSetup", + __Marshaller_google_ads_googleads_v3_services_GetBillingSetupRequest, + __Marshaller_google_ads_googleads_v3_resources_BillingSetup); + + static readonly grpc::Method __Method_MutateBillingSetup = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateBillingSetup", + __Marshaller_google_ads_googleads_v3_services_MutateBillingSetupRequest, + __Marshaller_google_ads_googleads_v3_services_MutateBillingSetupResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.BillingSetupServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of BillingSetupService + public abstract partial class BillingSetupServiceBase + { + /// + /// Returns a billing setup. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetBillingSetup(global::Google.Ads.GoogleAds.V3.Services.GetBillingSetupRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateBillingSetup(global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for BillingSetupService + public partial class BillingSetupServiceClient : grpc::ClientBase + { + /// Creates a new client for BillingSetupService + /// The channel to use to make remote calls. + public BillingSetupServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for BillingSetupService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public BillingSetupServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected BillingSetupServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected BillingSetupServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns a billing setup. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.BillingSetup GetBillingSetup(global::Google.Ads.GoogleAds.V3.Services.GetBillingSetupRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetBillingSetup(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns a billing setup. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.BillingSetup GetBillingSetup(global::Google.Ads.GoogleAds.V3.Services.GetBillingSetupRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetBillingSetup, null, options, request); + } + /// + /// Returns a billing setup. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetBillingSetupAsync(global::Google.Ads.GoogleAds.V3.Services.GetBillingSetupRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetBillingSetupAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns a billing setup. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetBillingSetupAsync(global::Google.Ads.GoogleAds.V3.Services.GetBillingSetupRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetBillingSetup, null, options, request); + } + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResponse MutateBillingSetup(global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateBillingSetup(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupResponse MutateBillingSetup(global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateBillingSetup, null, options, request); + } + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateBillingSetupAsync(global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateBillingSetupAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates a billing setup, or cancels an existing billing setup. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateBillingSetupAsync(global::Google.Ads.GoogleAds.V3.Services.MutateBillingSetupRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateBillingSetup, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override BillingSetupServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new BillingSetupServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(BillingSetupServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetBillingSetup, serviceImpl.GetBillingSetup) + .AddMethod(__Method_MutateBillingSetup, serviceImpl.MutateBillingSetup).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, BillingSetupServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetBillingSetup, serviceImpl.GetBillingSetup); + serviceBinder.AddMethod(__Method_MutateBillingSetup, serviceImpl.MutateBillingSetup); + } + + } +} +#endregion diff --git a/src/V3/Stubs/BillingSetupStatus.cs b/src/V3/Stubs/BillingSetupStatus.cs new file mode 100644 index 000000000..4cb6dde05 --- /dev/null +++ b/src/V3/Stubs/BillingSetupStatus.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/billing_setup_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/billing_setup_status.proto + public static partial class BillingSetupStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/billing_setup_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BillingSetupStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9iaWxsaW5nX3NldHVw", + "X3N0YXR1cy5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMa", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iiQEKFkJpbGxpbmdTZXR1", + "cFN0YXR1c0VudW0ibwoSQmlsbGluZ1NldHVwU3RhdHVzEg8KC1VOU1BFQ0lG", + "SUVEEAASCwoHVU5LTk9XThABEgsKB1BFTkRJTkcQAhIRCg1BUFBST1ZFRF9I", + "RUxEEAMSDAoIQVBQUk9WRUQQBBINCglDQU5DRUxMRUQQBULsAQohY29tLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhdCaWxsaW5nU2V0dXBTdGF0", + "dXNQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xl", + "QWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVu", + "dW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BillingSetupStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.BillingSetupStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BillingSetupStatusEnum.Types.BillingSetupStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing BillingSetup statuses. + /// + public sealed partial class BillingSetupStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BillingSetupStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BillingSetupStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupStatusEnum(BillingSetupStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BillingSetupStatusEnum Clone() { + return new BillingSetupStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BillingSetupStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BillingSetupStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BillingSetupStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BillingSetupStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of a BillingSetup. + /// + public enum BillingSetupStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The billing setup is pending approval. + /// + [pbr::OriginalName("PENDING")] Pending = 2, + /// + /// The billing setup has been approved but the corresponding first budget + /// has not. This can only occur for billing setups configured for monthly + /// invoicing. + /// + [pbr::OriginalName("APPROVED_HELD")] ApprovedHeld = 3, + /// + /// The billing setup has been approved. + /// + [pbr::OriginalName("APPROVED")] Approved = 4, + /// + /// The billing setup was cancelled by the user prior to approval. + /// + [pbr::OriginalName("CANCELLED")] Cancelled = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BrandSafetySuitability.cs b/src/V3/Stubs/BrandSafetySuitability.cs new file mode 100644 index 000000000..9409eb1c3 --- /dev/null +++ b/src/V3/Stubs/BrandSafetySuitability.cs @@ -0,0 +1,210 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/brand_safety_suitability.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/brand_safety_suitability.proto + public static partial class BrandSafetySuitabilityReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/brand_safety_suitability.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BrandSafetySuitabilityReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9icmFuZF9zYWZldHlf", + "c3VpdGFiaWxpdHkucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIpsBChpCcmFuZFNh", + "ZmV0eVN1aXRhYmlsaXR5RW51bSJ9ChZCcmFuZFNhZmV0eVN1aXRhYmlsaXR5", + "Eg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhYKEkVYUEFOREVEX0lO", + "VkVOVE9SWRACEhYKElNUQU5EQVJEX0lOVkVOVE9SWRADEhUKEUxJTUlURURf", + "SU5WRU5UT1JZEARC8AEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtc0IbQnJhbmRTYWZldHlTdWl0YWJpbGl0eVByb3RvUAFaQmdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BrandSafetySuitabilityEnum), global::Google.Ads.GoogleAds.V3.Enums.BrandSafetySuitabilityEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BrandSafetySuitabilityEnum.Types.BrandSafetySuitability) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum with 3-Tier brand safety suitability control. + /// + public sealed partial class BrandSafetySuitabilityEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BrandSafetySuitabilityEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BrandSafetySuitabilityReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BrandSafetySuitabilityEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BrandSafetySuitabilityEnum(BrandSafetySuitabilityEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BrandSafetySuitabilityEnum Clone() { + return new BrandSafetySuitabilityEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BrandSafetySuitabilityEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BrandSafetySuitabilityEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BrandSafetySuitabilityEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BrandSafetySuitabilityEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// 3-Tier brand safety suitability control. + /// + public enum BrandSafetySuitability { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// This option lets you show ads across all inventory on YouTube and video + /// partners that meet our standards for monetization. This option may be an + /// appropriate choice for brands that want maximum access to the full + /// breadth of videos eligible for ads, including, for example, videos that + /// have strong profanity in the context of comedy or a documentary, or + /// excessive violence as featured in video games. + /// + [pbr::OriginalName("EXPANDED_INVENTORY")] ExpandedInventory = 2, + /// + /// This option lets you show ads across a wide range of content that's + /// appropriate for most brands, such as popular music videos, documentaries, + /// and movie trailers. The content you can show ads on is based on YouTube's + /// advertiser-friendly content guidelines that take into account, for + /// example, the strength or frequency of profanity, or the appropriateness + /// of subject matter like sensitive events. Ads won't show, for example, on + /// content with repeated strong profanity, strong sexual content, or graphic + /// violence. + /// + [pbr::OriginalName("STANDARD_INVENTORY")] StandardInventory = 3, + /// + /// This option lets you show ads on a reduced range of content that's + /// appropriate for brands with particularly strict guidelines around + /// inappropriate language and sexual suggestiveness; above and beyond what + /// YouTube's advertiser-friendly content guidelines address. The videos + /// accessible in this sensitive category meet heightened requirements, + /// especially for inappropriate language and sexual suggestiveness. For + /// example, your ads will be excluded from showing on some of YouTube's most + /// popular music videos and other pop culture content across YouTube and + /// Google video partners. + /// + [pbr::OriginalName("LIMITED_INVENTORY")] LimitedInventory = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BudgetDeliveryMethod.cs b/src/V3/Stubs/BudgetDeliveryMethod.cs new file mode 100644 index 000000000..e2a188460 --- /dev/null +++ b/src/V3/Stubs/BudgetDeliveryMethod.cs @@ -0,0 +1,188 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/budget_delivery_method.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/budget_delivery_method.proto + public static partial class BudgetDeliveryMethodReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/budget_delivery_method.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BudgetDeliveryMethodReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9idWRnZXRfZGVsaXZl", + "cnlfbWV0aG9kLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJvChhCdWRnZXREZWxp", + "dmVyeU1ldGhvZEVudW0iUwoUQnVkZ2V0RGVsaXZlcnlNZXRob2QSDwoLVU5T", + "UEVDSUZJRUQQABILCgdVTktOT1dOEAESDAoIU1RBTkRBUkQQAhIPCgtBQ0NF", + "TEVSQVRFRBADQu4BCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXNCGUJ1ZGdldERlbGl2ZXJ5TWV0aG9kUHJvdG9QAVpCZ29vZ2xlLmdvbGFu", + "Zy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vu", + "dW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51", + "bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum), global::Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing Budget delivery methods. A delivery method determines the + /// rate at which the Budget is spent. + /// + public sealed partial class BudgetDeliveryMethodEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BudgetDeliveryMethodEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetDeliveryMethodEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetDeliveryMethodEnum(BudgetDeliveryMethodEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetDeliveryMethodEnum Clone() { + return new BudgetDeliveryMethodEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BudgetDeliveryMethodEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BudgetDeliveryMethodEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BudgetDeliveryMethodEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BudgetDeliveryMethodEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible delivery methods of a Budget. + /// + public enum BudgetDeliveryMethod { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The budget server will throttle serving evenly across + /// the entire time period. + /// + [pbr::OriginalName("STANDARD")] Standard = 2, + /// + /// The budget server will not throttle serving, + /// and ads will serve as fast as possible. + /// + [pbr::OriginalName("ACCELERATED")] Accelerated = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BudgetPeriod.cs b/src/V3/Stubs/BudgetPeriod.cs new file mode 100644 index 000000000..43f0448ed --- /dev/null +++ b/src/V3/Stubs/BudgetPeriod.cs @@ -0,0 +1,180 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/budget_period.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/budget_period.proto + public static partial class BudgetPeriodReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/budget_period.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BudgetPeriodReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9idWRnZXRfcGVyaW9k", + "LnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byJLChBCdWRnZXRQZXJpb2RFbnVtIjcK", + "DEJ1ZGdldFBlcmlvZBIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIJ", + "CgVEQUlMWRACQuYBCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXNCEUJ1ZGdldFBlcmlvZFByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVt", + "c6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BudgetPeriodEnum), global::Google.Ads.GoogleAds.V3.Enums.BudgetPeriodEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BudgetPeriodEnum.Types.BudgetPeriod) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing Budget period. + /// + public sealed partial class BudgetPeriodEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BudgetPeriodEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BudgetPeriodReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetPeriodEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetPeriodEnum(BudgetPeriodEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetPeriodEnum Clone() { + return new BudgetPeriodEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BudgetPeriodEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BudgetPeriodEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BudgetPeriodEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BudgetPeriodEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible period of a Budget. + /// + public enum BudgetPeriod { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Daily budget. + /// + [pbr::OriginalName("DAILY")] Daily = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BudgetStatus.cs b/src/V3/Stubs/BudgetStatus.cs new file mode 100644 index 000000000..f51135493 --- /dev/null +++ b/src/V3/Stubs/BudgetStatus.cs @@ -0,0 +1,184 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/budget_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/budget_status.proto + public static partial class BudgetStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/budget_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BudgetStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9idWRnZXRfc3RhdHVz", + "LnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byJaChBCdWRnZXRTdGF0dXNFbnVtIkYK", + "DEJ1ZGdldFN0YXR1cxIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIL", + "CgdFTkFCTEVEEAISCwoHUkVNT1ZFRBADQuYBCiFjb20uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuZW51bXNCEUJ1ZGdldFN0YXR1c1Byb3RvUAFaQmdvb2ds", + "ZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFk", + "cy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFH", + "b29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BudgetStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.BudgetStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BudgetStatusEnum.Types.BudgetStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing a Budget status + /// + public sealed partial class BudgetStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BudgetStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BudgetStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetStatusEnum(BudgetStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetStatusEnum Clone() { + return new BudgetStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BudgetStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BudgetStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BudgetStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BudgetStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a Budget. + /// + public enum BudgetStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Budget is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Budget is removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/BudgetType.cs b/src/V3/Stubs/BudgetType.cs new file mode 100644 index 000000000..0eefdc4b7 --- /dev/null +++ b/src/V3/Stubs/BudgetType.cs @@ -0,0 +1,202 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/budget_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/budget_type.proto + public static partial class BudgetTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/budget_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static BudgetTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9idWRnZXRfdHlwZS5w", + "cm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8icwoOQnVkZ2V0VHlwZUVudW0iYQoKQnVk", + "Z2V0VHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIMCghTVEFO", + "REFSRBACEhgKFEhPVEVMX0FEU19DT01NSVNTSU9OEAMSDQoJRklYRURfQ1BB", + "EARC5AEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IPQnVk", + "Z2V0VHlwZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoC", + "HUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.BudgetTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.BudgetTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.BudgetTypeEnum.Types.BudgetType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Describes Budget types. + /// + public sealed partial class BudgetTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new BudgetTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.BudgetTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetTypeEnum(BudgetTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public BudgetTypeEnum Clone() { + return new BudgetTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as BudgetTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(BudgetTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(BudgetTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the BudgetTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible Budget types. + /// + public enum BudgetType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Budget type for standard Google Ads usage. + /// Caps daily spend at two times the specified budget amount. + /// Full details: https://support.google.com/google-ads/answer/6385083 + /// + [pbr::OriginalName("STANDARD")] Standard = 2, + /// + /// Budget type for Hotels Ads commission program. + /// Full details: https://support.google.com/google-ads/answer/9243945 + /// + /// This type is only supported by campaigns with + /// AdvertisingChannelType.HOTEL, BiddingStrategyType.COMMISSION and + /// PaymentMode.CONVERSION_VALUE. + /// + [pbr::OriginalName("HOTEL_ADS_COMMISSION")] HotelAdsCommission = 3, + /// + /// Budget type with a fixed cost-per-acquisition (conversion). + /// Full details: https://support.google.com/google-ads/answer/7528254 + /// + /// This type is only supported by campaigns with + /// AdvertisingChannelType.DISPLAY (excluding + /// AdvertisingChannelSubType.DISPLAY_GMAIL), + /// BiddingStrategyType.TARGET_CPA and PaymentMode.CONVERSIONS. + /// + [pbr::OriginalName("FIXED_CPA")] FixedCpa = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CallConversionReportingState.cs b/src/V3/Stubs/CallConversionReportingState.cs new file mode 100644 index 000000000..a54f8ae8f --- /dev/null +++ b/src/V3/Stubs/CallConversionReportingState.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/call_conversion_reporting_state.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/call_conversion_reporting_state.proto + public static partial class CallConversionReportingStateReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/call_conversion_reporting_state.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CallConversionReportingStateReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYWxsX2NvbnZlcnNp", + "b25fcmVwb3J0aW5nX3N0YXRlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLMAQog", + "Q2FsbENvbnZlcnNpb25SZXBvcnRpbmdTdGF0ZUVudW0ipwEKHENhbGxDb252", + "ZXJzaW9uUmVwb3J0aW5nU3RhdGUSDwoLVU5TUEVDSUZJRUQQABILCgdVTktO", + "T1dOEAESDAoIRElTQUJMRUQQAhIsCihVU0VfQUNDT1VOVF9MRVZFTF9DQUxM", + "X0NPTlZFUlNJT05fQUNUSU9OEAMSLQopVVNFX1JFU09VUkNFX0xFVkVMX0NB", + "TExfQ09OVkVSU0lPTl9BQ1RJT04QBEL2AQohY29tLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVudW1zQiFDYWxsQ29udmVyc2lvblJlcG9ydGluZ1N0YXRl", + "UHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBp", + "cy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xl", + "LkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFk", + "c1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVt", + "c2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum), global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum.Types.CallConversionReportingState) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible data types for call conversion + /// reporting state. + /// + public sealed partial class CallConversionReportingStateEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CallConversionReportingStateEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversionReportingStateEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversionReportingStateEnum(CallConversionReportingStateEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversionReportingStateEnum Clone() { + return new CallConversionReportingStateEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CallConversionReportingStateEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CallConversionReportingStateEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CallConversionReportingStateEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CallConversionReportingStateEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible data types for a call conversion action state. + /// + public enum CallConversionReportingState { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Call conversion action is disabled. + /// + [pbr::OriginalName("DISABLED")] Disabled = 2, + /// + /// Call conversion action will use call conversion type set at the + /// account level. + /// + [pbr::OriginalName("USE_ACCOUNT_LEVEL_CALL_CONVERSION_ACTION")] UseAccountLevelCallConversionAction = 3, + /// + /// Call conversion action will use call conversion type set at the resource + /// (call only ads/call extensions) level. + /// + [pbr::OriginalName("USE_RESOURCE_LEVEL_CALL_CONVERSION_ACTION")] UseResourceLevelCallConversionAction = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CallPlaceholderField.cs b/src/V3/Stubs/CallPlaceholderField.cs new file mode 100644 index 000000000..f8e5b8f4a --- /dev/null +++ b/src/V3/Stubs/CallPlaceholderField.cs @@ -0,0 +1,206 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/call_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/call_placeholder_field.proto + public static partial class CallPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/call_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CallPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYWxsX3BsYWNlaG9s", + "ZGVyX2ZpZWxkLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byK6AQoYQ2FsbFBsYWNl", + "aG9sZGVyRmllbGRFbnVtIp0BChRDYWxsUGxhY2Vob2xkZXJGaWVsZBIPCgtV", + "TlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIQCgxQSE9ORV9OVU1CRVIQAhIQ", + "CgxDT1VOVFJZX0NPREUQAxILCgdUUkFDS0VEEAQSFgoSQ09OVkVSU0lPTl9U", + "WVBFX0lEEAUSHgoaQ09OVkVSU0lPTl9SRVBPUlRJTkdfU1RBVEUQBkLuAQoh", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhlDYWxsUGxhY2Vo", + "b2xkZXJGaWVsZFByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3Rv", + "L2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dB", + "QaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFk", + "c1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CallPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.CallPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CallPlaceholderFieldEnum.Types.CallPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Call placeholder fields. + /// + public sealed partial class CallPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CallPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CallPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallPlaceholderFieldEnum(CallPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallPlaceholderFieldEnum Clone() { + return new CallPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CallPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CallPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CallPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CallPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Call placeholder fields. + /// + public enum CallPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: STRING. The advertiser's phone number to append to the ad. + /// + [pbr::OriginalName("PHONE_NUMBER")] PhoneNumber = 2, + /// + /// Data Type: STRING. Uppercase two-letter country code of the advertiser's + /// phone number. + /// + [pbr::OriginalName("COUNTRY_CODE")] CountryCode = 3, + /// + /// Data Type: BOOLEAN. Indicates whether call tracking is enabled. Default: + /// true. + /// + [pbr::OriginalName("TRACKED")] Tracked = 4, + /// + /// Data Type: INT64. The ID of an AdCallMetricsConversion object. This + /// object contains the phoneCallDurationfield which is the minimum duration + /// (in seconds) of a call to be considered a conversion. + /// + [pbr::OriginalName("CONVERSION_TYPE_ID")] ConversionTypeId = 5, + /// + /// Data Type: STRING. Indicates whether this call extension uses its own + /// call conversion setting or follows the account level setting. + /// Valid values are: USE_ACCOUNT_LEVEL_CALL_CONVERSION_ACTION and + /// USE_RESOURCE_LEVEL_CALL_CONVERSION_ACTION. + /// + [pbr::OriginalName("CONVERSION_REPORTING_STATE")] ConversionReportingState = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CalloutPlaceholderField.cs b/src/V3/Stubs/CalloutPlaceholderField.cs new file mode 100644 index 000000000..ec9511560 --- /dev/null +++ b/src/V3/Stubs/CalloutPlaceholderField.cs @@ -0,0 +1,181 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/callout_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/callout_placeholder_field.proto + public static partial class CalloutPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/callout_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CalloutPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYWxsb3V0X3BsYWNl", + "aG9sZGVyX2ZpZWxkLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJoChtDYWxsb3V0", + "UGxhY2Vob2xkZXJGaWVsZEVudW0iSQoXQ2FsbG91dFBsYWNlaG9sZGVyRmll", + "bGQSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESEAoMQ0FMTE9VVF9U", + "RVhUEAJC8QEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0Ic", + "Q2FsbG91dFBsYWNlaG9sZGVyRmllbGRQcm90b1ABWkJnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVt", + "c8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CalloutPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.CalloutPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CalloutPlaceholderFieldEnum.Types.CalloutPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Callout placeholder fields. + /// + public sealed partial class CalloutPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CalloutPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CalloutPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CalloutPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CalloutPlaceholderFieldEnum(CalloutPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CalloutPlaceholderFieldEnum Clone() { + return new CalloutPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CalloutPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CalloutPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CalloutPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CalloutPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Callout placeholder fields. + /// + public enum CalloutPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: STRING. Callout text. + /// + [pbr::OriginalName("CALLOUT_TEXT")] CalloutText = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Campaign.cs b/src/V3/Stubs/Campaign.cs new file mode 100644 index 000000000..5c26ac34c --- /dev/null +++ b/src/V3/Stubs/Campaign.cs @@ -0,0 +1,3729 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign.proto + public static partial class CampaignReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ24u", + "cHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcxosZ29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL2JpZGRpbmcucHJvdG8aNWdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9jdXN0b21fcGFyYW1ldGVy", + "LnByb3RvGjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZnJlcXVl", + "bmN5X2NhcC5wcm90bxo+Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9u", + "L3JlYWxfdGltZV9iaWRkaW5nX3NldHRpbmcucHJvdG8aNmdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2NvbW1vbi90YXJnZXRpbmdfc2V0dGluZy5wcm90bxpC", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvYWRfc2VydmluZ19vcHRp", + "bWl6YXRpb25fc3RhdHVzLnByb3RvGkBnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9hZHZlcnRpc2luZ19jaGFubmVsX3N1Yl90eXBlLnByb3RvGjxn", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZHZlcnRpc2luZ19jaGFu", + "bmVsX3R5cGUucHJvdG8aOmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1z", + "L2FwcF9jYW1wYWlnbl9hcHBfc3RvcmUucHJvdG8aS2dvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL2VudW1zL2FwcF9jYW1wYWlnbl9iaWRkaW5nX3N0cmF0ZWd5", + "X2dvYWxfdHlwZS5wcm90bxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXMvYmlkZGluZ19zdHJhdGVneV90eXBlLnByb3RvGjxnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcy9icmFuZF9zYWZldHlfc3VpdGFiaWxpdHkucHJv", + "dG8aPGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2NhbXBhaWduX2V4", + "cGVyaW1lbnRfdHlwZS5wcm90bxo7Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "ZW51bXMvY2FtcGFpZ25fc2VydmluZ19zdGF0dXMucHJvdG8aM2dvb2dsZS9h", + "ZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2NhbXBhaWduX3N0YXR1cy5wcm90bxo8", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvbmVnYXRpdmVfZ2VvX3Rh", + "cmdldF90eXBlLnByb3RvGjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVt", + "cy9wYXltZW50X21vZGUucHJvdG8aPGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL3Bvc2l0aXZlX2dlb190YXJnZXRfdHlwZS5wcm90bxpCZ29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvdmFuaXR5X3BoYXJtYV9kaXNwbGF5", + "X3VybF9tb2RlLnByb3RvGjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVt", + "cy92YW5pdHlfcGhhcm1hX3RleHQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRf", + "YmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdv", + "b2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5v", + "dGF0aW9ucy5wcm90byKuLQoIQ2FtcGFpZ24SQAoNcmVzb3VyY2VfbmFtZRgB", + "IAEoCUIp4EEF+kEjCiFnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2FtcGFp", + "Z24SLAoCaWQYAyABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID", + "4EEDEioKBG5hbWUYBCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFs", + "dWUSUAoGc3RhdHVzGAUgASgOMkAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuQ2FtcGFpZ25TdGF0dXNFbnVtLkNhbXBhaWduU3RhdHVzEmsKDnNl", + "cnZpbmdfc3RhdHVzGBUgASgOMk4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuQ2FtcGFpZ25TZXJ2aW5nU3RhdHVzRW51bS5DYW1wYWlnblNlcnZp", + "bmdTdGF0dXNCA+BBAxKCAQoeYWRfc2VydmluZ19vcHRpbWl6YXRpb25fc3Rh", + "dHVzGAggASgOMlouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQWRT", + "ZXJ2aW5nT3B0aW1pemF0aW9uU3RhdHVzRW51bS5BZFNlcnZpbmdPcHRpbWl6", + "YXRpb25TdGF0dXMSdwoYYWR2ZXJ0aXNpbmdfY2hhbm5lbF90eXBlGAkgASgO", + "MlAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQWR2ZXJ0aXNpbmdD", + "aGFubmVsVHlwZUVudW0uQWR2ZXJ0aXNpbmdDaGFubmVsVHlwZUID4EEFEoEB", + "ChxhZHZlcnRpc2luZ19jaGFubmVsX3N1Yl90eXBlGAogASgOMlYuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXMuQWR2ZXJ0aXNpbmdDaGFubmVsU3Vi", + "VHlwZUVudW0uQWR2ZXJ0aXNpbmdDaGFubmVsU3ViVHlwZUID4EEFEjsKFXRy", + "YWNraW5nX3VybF90ZW1wbGF0ZRgLIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZRJOChV1cmxfY3VzdG9tX3BhcmFtZXRlcnMYDCADKAsyLy5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQ3VzdG9tUGFyYW1ldGVy", + "ElkKGXJlYWxfdGltZV9iaWRkaW5nX3NldHRpbmcYJyABKAsyNi5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5jb21tb24uUmVhbFRpbWVCaWRkaW5nU2V0dGlu", + "ZxJVChBuZXR3b3JrX3NldHRpbmdzGA4gASgLMjsuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduLk5ldHdvcmtTZXR0aW5ncxJY", + "Cg1ob3RlbF9zZXR0aW5nGCAgASgLMjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzLkNhbXBhaWduLkhvdGVsU2V0dGluZ0luZm9CA+BBBRJn", + "ChpkeW5hbWljX3NlYXJjaF9hZHNfc2V0dGluZxghIAEoCzJDLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DYW1wYWlnbi5EeW5hbWljU2Vh", + "cmNoQWRzU2V0dGluZxJVChBzaG9wcGluZ19zZXR0aW5nGCQgASgLMjsuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduLlNob3Bw", + "aW5nU2V0dGluZxJLChF0YXJnZXRpbmdfc2V0dGluZxgrIAEoCzIwLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5UYXJnZXRpbmdTZXR0aW5nEmEK", + "F2dlb190YXJnZXRfdHlwZV9zZXR0aW5nGC8gASgLMkAuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduLkdlb1RhcmdldFR5cGVT", + "ZXR0aW5nElwKFGFwcF9jYW1wYWlnbl9zZXR0aW5nGDMgASgLMj4uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduLkFwcENhbXBh", + "aWduU2V0dGluZxJcCgZsYWJlbHMYNSADKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWVCLuBBA/pBKAomZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29t", + "L0NhbXBhaWduTGFiZWwSbgoPZXhwZXJpbWVudF90eXBlGBEgASgOMlAuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQ2FtcGFpZ25FeHBlcmltZW50", + "VHlwZUVudW0uQ2FtcGFpZ25FeHBlcmltZW50VHlwZUID4EEDEl4KDWJhc2Vf", + "Y2FtcGFpZ24YHCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVC", + "KeBBA/pBIwohZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0NhbXBhaWduEmMK", + "D2NhbXBhaWduX2J1ZGdldBgGIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZUIs+kEpCidnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2FtcGFp", + "Z25CdWRnZXQSbgoVYmlkZGluZ19zdHJhdGVneV90eXBlGBYgASgOMkouZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQmlkZGluZ1N0cmF0ZWd5VHlw", + "ZUVudW0uQmlkZGluZ1N0cmF0ZWd5VHlwZUID4EEDEjAKCnN0YXJ0X2RhdGUY", + "EyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSLgoIZW5kX2Rh", + "dGUYFCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSNgoQZmlu", + "YWxfdXJsX3N1ZmZpeBgmIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZRJJCg5mcmVxdWVuY3lfY2FwcxgoIAMoCzIxLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmNvbW1vbi5GcmVxdWVuY3lDYXBFbnRyeRJ9Ch52aWRlb19i", + "cmFuZF9zYWZldHlfc3VpdGFiaWxpdHkYKiABKA4yUC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtcy5CcmFuZFNhZmV0eVN1aXRhYmlsaXR5RW51bS5C", + "cmFuZFNhZmV0eVN1aXRhYmlsaXR5QgPgQQMSTwoNdmFuaXR5X3BoYXJtYRgs", + "IAEoCzI4Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DYW1w", + "YWlnbi5WYW5pdHlQaGFybWESYQoWc2VsZWN0aXZlX29wdGltaXphdGlvbhgt", + "IAEoCzJBLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DYW1w", + "YWlnbi5TZWxlY3RpdmVPcHRpbWl6YXRpb24SWgoQdHJhY2tpbmdfc2V0dGlu", + "ZxguIAEoCzI7Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5D", + "YW1wYWlnbi5UcmFja2luZ1NldHRpbmdCA+BBAxJQCgxwYXltZW50X21vZGUY", + "NCABKA4yOi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5QYXltZW50", + "TW9kZUVudW0uUGF5bWVudE1vZGUSZwoQYmlkZGluZ19zdHJhdGVneRgXIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIt+kEqCihnb29nbGVh", + "ZHMuZ29vZ2xlYXBpcy5jb20vQmlkZGluZ1N0cmF0ZWd5SAASQAoKY29tbWlz", + "c2lvbhgxIAEoCzIqLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5D", + "b21taXNzaW9uSAASPwoKbWFudWFsX2NwYxgYIAEoCzIpLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmNvbW1vbi5NYW51YWxDcGNIABI/CgptYW51YWxfY3Bt", + "GBkgASgLMikuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLk1hbnVh", + "bENwbUgAEkQKCm1hbnVhbF9jcHYYJSABKAsyKS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5jb21tb24uTWFudWFsQ3B2QgPgQQNIABJTChRtYXhpbWl6ZV9j", + "b252ZXJzaW9ucxgeIAEoCzIzLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNv", + "bW1vbi5NYXhpbWl6ZUNvbnZlcnNpb25zSAASXAoZbWF4aW1pemVfY29udmVy", + "c2lvbl92YWx1ZRgfIAEoCzI3Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNv", + "bW1vbi5NYXhpbWl6ZUNvbnZlcnNpb25WYWx1ZUgAEj8KCnRhcmdldF9jcGEY", + "GiABKAsyKS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uVGFyZ2V0", + "Q3BhSAASWAoXdGFyZ2V0X2ltcHJlc3Npb25fc2hhcmUYMCABKAsyNS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uVGFyZ2V0SW1wcmVzc2lvblNo", + "YXJlSAASQQoLdGFyZ2V0X3JvYXMYHSABKAsyKi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5jb21tb24uVGFyZ2V0Um9hc0gAEkMKDHRhcmdldF9zcGVuZBgb", + "IAEoCzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5UYXJnZXRT", + "cGVuZEgAEkEKC3BlcmNlbnRfY3BjGCIgASgLMiouZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLlBlcmNlbnRDcGNIABI/Cgp0YXJnZXRfY3BtGCkg", + "ASgLMikuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLlRhcmdldENw", + "bUgAGoUCCg9OZXR3b3JrU2V0dGluZ3MSOAoUdGFyZ2V0X2dvb2dsZV9zZWFy", + "Y2gYASABKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlEjkKFXRhcmdl", + "dF9zZWFyY2hfbmV0d29yaxgCIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29s", + "VmFsdWUSOgoWdGFyZ2V0X2NvbnRlbnRfbmV0d29yaxgDIAEoCzIaLmdvb2ds", + "ZS5wcm90b2J1Zi5Cb29sVmFsdWUSQQoddGFyZ2V0X3BhcnRuZXJfc2VhcmNo", + "X25ldHdvcmsYBCABKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlGk0K", + "EEhvdGVsU2V0dGluZ0luZm8SOQoPaG90ZWxfY2VudGVyX2lkGAEgASgLMhsu", + "Z29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWVCA+BBBRqRAgoXRHluYW1pY1Nl", + "YXJjaEFkc1NldHRpbmcSMQoLZG9tYWluX25hbWUYASABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWUSMwoNbGFuZ3VhZ2VfY29kZRgCIAEoCzIc", + "Lmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI6ChZ1c2Vfc3VwcGxpZWRf", + "dXJsc19vbmx5GAMgASgLMhouZ29vZ2xlLnByb3RvYnVmLkJvb2xWYWx1ZRJS", + "CgVmZWVkcxgFIAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIl", + "4EED+kEfCh1nb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRmVlZBrsAQoPU2hv", + "cHBpbmdTZXR0aW5nEjUKC21lcmNoYW50X2lkGAEgASgLMhsuZ29vZ2xlLnBy", + "b3RvYnVmLkludDY0VmFsdWVCA+BBBRI4Cg1zYWxlc19jb3VudHJ5GAIgASgL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQUSNgoRY2FtcGFp", + "Z25fcHJpb3JpdHkYAyABKAsyGy5nb29nbGUucHJvdG9idWYuSW50MzJWYWx1", + "ZRIwCgxlbmFibGVfbG9jYWwYBCABKAsyGi5nb29nbGUucHJvdG9idWYuQm9v", + "bFZhbHVlGkoKD1RyYWNraW5nU2V0dGluZxI3Cgx0cmFja2luZ191cmwYASAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxr6AQoUR2Vv", + "VGFyZ2V0VHlwZVNldHRpbmcScAoYcG9zaXRpdmVfZ2VvX3RhcmdldF90eXBl", + "GAEgASgOMk4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuUG9zaXRp", + "dmVHZW9UYXJnZXRUeXBlRW51bS5Qb3NpdGl2ZUdlb1RhcmdldFR5cGUScAoY", + "bmVnYXRpdmVfZ2VvX3RhcmdldF90eXBlGAIgASgOMk4uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuZW51bXMuTmVnYXRpdmVHZW9UYXJnZXRUeXBlRW51bS5O", + "ZWdhdGl2ZUdlb1RhcmdldFR5cGUaugIKEkFwcENhbXBhaWduU2V0dGluZxKM", + "AQoaYmlkZGluZ19zdHJhdGVneV9nb2FsX3R5cGUYASABKA4yaC5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtcy5BcHBDYW1wYWlnbkJpZGRpbmdTdHJh", + "dGVneUdvYWxUeXBlRW51bS5BcHBDYW1wYWlnbkJpZGRpbmdTdHJhdGVneUdv", + "YWxUeXBlEjEKBmFwcF9pZBgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZUID4EEFEmIKCWFwcF9zdG9yZRgDIAEoDjJKLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zLkFwcENhbXBhaWduQXBwU3RvcmVFbnVtLkFw", + "cENhbXBhaWduQXBwU3RvcmVCA+BBBRrzAQoMVmFuaXR5UGhhcm1hEoABCh52", + "YW5pdHlfcGhhcm1hX2Rpc3BsYXlfdXJsX21vZGUYASABKA4yWC5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtcy5WYW5pdHlQaGFybWFEaXNwbGF5VXJs", + "TW9kZUVudW0uVmFuaXR5UGhhcm1hRGlzcGxheVVybE1vZGUSYAoSdmFuaXR5", + "X3BoYXJtYV90ZXh0GAIgASgOMkQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuVmFuaXR5UGhhcm1hVGV4dEVudW0uVmFuaXR5UGhhcm1hVGV4dBqB", + "AQoVU2VsZWN0aXZlT3B0aW1pemF0aW9uEmgKEmNvbnZlcnNpb25fYWN0aW9u", + "cxgBIAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIu+kErCiln", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ29udmVyc2lvbkFjdGlvbjpR6kFO", + "CiFnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2FtcGFpZ24SKWN1c3RvbWVy", + "cy97Y3VzdG9tZXJ9L2NhbXBhaWducy97Y2FtcGFpZ259QhsKGWNhbXBhaWdu", + "X2JpZGRpbmdfc3RyYXRlZ3lC+gEKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXNCDUNhbXBhaWduUHJvdG9QAVpKZ29vZ2xlLmdvbGFu", + "Zy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jl", + "c291cmNlcztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5SZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNv", + "dXJjZXPqAiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2Vz", + "YgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.BiddingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.CustomParameterReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.FrequencyCapReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.RealTimeBiddingSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.TargetingSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdServingOptimizationStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BrandSafetySuitabilityReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CampaignServingStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CampaignStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.NegativeGeoTargetTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PaymentModeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PositiveGeoTargetTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.VanityPharmaDisplayUrlModeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.VanityPharmaTextReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Parser, new[]{ "ResourceName", "Id", "Name", "Status", "ServingStatus", "AdServingOptimizationStatus", "AdvertisingChannelType", "AdvertisingChannelSubType", "TrackingUrlTemplate", "UrlCustomParameters", "RealTimeBiddingSetting", "NetworkSettings", "HotelSetting", "DynamicSearchAdsSetting", "ShoppingSetting", "TargetingSetting", "GeoTargetTypeSetting", "AppCampaignSetting", "Labels", "ExperimentType", "BaseCampaign", "CampaignBudget", "BiddingStrategyType", "StartDate", "EndDate", "FinalUrlSuffix", "FrequencyCaps", "VideoBrandSafetySuitability", "VanityPharma", "SelectiveOptimization", "TrackingSetting", "PaymentMode", "BiddingStrategy", "Commission", "ManualCpc", "ManualCpm", "ManualCpv", "MaximizeConversions", "MaximizeConversionValue", "TargetCpa", "TargetImpressionShare", "TargetRoas", "TargetSpend", "PercentCpc", "TargetCpm" }, new[]{ "CampaignBiddingStrategy" }, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings.Parser, new[]{ "TargetGoogleSearch", "TargetSearchNetwork", "TargetContentNetwork", "TargetPartnerSearchNetwork" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.HotelSettingInfo), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.HotelSettingInfo.Parser, new[]{ "HotelCenterId" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.DynamicSearchAdsSetting), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.DynamicSearchAdsSetting.Parser, new[]{ "DomainName", "LanguageCode", "UseSuppliedUrlsOnly", "Feeds" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.ShoppingSetting), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.ShoppingSetting.Parser, new[]{ "MerchantId", "SalesCountry", "CampaignPriority", "EnableLocal" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.TrackingSetting), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.TrackingSetting.Parser, new[]{ "TrackingUrl" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.GeoTargetTypeSetting), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.GeoTargetTypeSetting.Parser, new[]{ "PositiveGeoTargetType", "NegativeGeoTargetType" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.AppCampaignSetting), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.AppCampaignSetting.Parser, new[]{ "BiddingStrategyGoalType", "AppId", "AppStore" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.VanityPharma), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.VanityPharma.Parser, new[]{ "VanityPharmaDisplayUrlMode", "VanityPharmaText" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.SelectiveOptimization), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.SelectiveOptimization.Parser, new[]{ "ConversionActions" }, null, null, null)}) + })); + } + #endregion + + } + #region Messages + /// + /// A campaign. + /// + public sealed partial class Campaign : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Campaign()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Campaign() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Campaign(Campaign other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + status_ = other.status_; + servingStatus_ = other.servingStatus_; + adServingOptimizationStatus_ = other.adServingOptimizationStatus_; + advertisingChannelType_ = other.advertisingChannelType_; + advertisingChannelSubType_ = other.advertisingChannelSubType_; + TrackingUrlTemplate = other.TrackingUrlTemplate; + urlCustomParameters_ = other.urlCustomParameters_.Clone(); + realTimeBiddingSetting_ = other.realTimeBiddingSetting_ != null ? other.realTimeBiddingSetting_.Clone() : null; + networkSettings_ = other.networkSettings_ != null ? other.networkSettings_.Clone() : null; + hotelSetting_ = other.hotelSetting_ != null ? other.hotelSetting_.Clone() : null; + dynamicSearchAdsSetting_ = other.dynamicSearchAdsSetting_ != null ? other.dynamicSearchAdsSetting_.Clone() : null; + shoppingSetting_ = other.shoppingSetting_ != null ? other.shoppingSetting_.Clone() : null; + targetingSetting_ = other.targetingSetting_ != null ? other.targetingSetting_.Clone() : null; + geoTargetTypeSetting_ = other.geoTargetTypeSetting_ != null ? other.geoTargetTypeSetting_.Clone() : null; + appCampaignSetting_ = other.appCampaignSetting_ != null ? other.appCampaignSetting_.Clone() : null; + labels_ = other.labels_.Clone(); + experimentType_ = other.experimentType_; + BaseCampaign = other.BaseCampaign; + CampaignBudget = other.CampaignBudget; + biddingStrategyType_ = other.biddingStrategyType_; + StartDate = other.StartDate; + EndDate = other.EndDate; + FinalUrlSuffix = other.FinalUrlSuffix; + frequencyCaps_ = other.frequencyCaps_.Clone(); + videoBrandSafetySuitability_ = other.videoBrandSafetySuitability_; + vanityPharma_ = other.vanityPharma_ != null ? other.vanityPharma_.Clone() : null; + selectiveOptimization_ = other.selectiveOptimization_ != null ? other.selectiveOptimization_.Clone() : null; + trackingSetting_ = other.trackingSetting_ != null ? other.trackingSetting_.Clone() : null; + paymentMode_ = other.paymentMode_; + switch (other.CampaignBiddingStrategyCase) { + case CampaignBiddingStrategyOneofCase.BiddingStrategy: + BiddingStrategy = other.BiddingStrategy; + break; + case CampaignBiddingStrategyOneofCase.Commission: + Commission = other.Commission.Clone(); + break; + case CampaignBiddingStrategyOneofCase.ManualCpc: + ManualCpc = other.ManualCpc.Clone(); + break; + case CampaignBiddingStrategyOneofCase.ManualCpm: + ManualCpm = other.ManualCpm.Clone(); + break; + case CampaignBiddingStrategyOneofCase.ManualCpv: + ManualCpv = other.ManualCpv.Clone(); + break; + case CampaignBiddingStrategyOneofCase.MaximizeConversions: + MaximizeConversions = other.MaximizeConversions.Clone(); + break; + case CampaignBiddingStrategyOneofCase.MaximizeConversionValue: + MaximizeConversionValue = other.MaximizeConversionValue.Clone(); + break; + case CampaignBiddingStrategyOneofCase.TargetCpa: + TargetCpa = other.TargetCpa.Clone(); + break; + case CampaignBiddingStrategyOneofCase.TargetImpressionShare: + TargetImpressionShare = other.TargetImpressionShare.Clone(); + break; + case CampaignBiddingStrategyOneofCase.TargetRoas: + TargetRoas = other.TargetRoas.Clone(); + break; + case CampaignBiddingStrategyOneofCase.TargetSpend: + TargetSpend = other.TargetSpend.Clone(); + break; + case CampaignBiddingStrategyOneofCase.PercentCpc: + PercentCpc = other.PercentCpc.Clone(); + break; + case CampaignBiddingStrategyOneofCase.TargetCpm: + TargetCpm = other.TargetCpm.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Campaign Clone() { + return new Campaign(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign. + /// Campaign resource names have the form: + /// + /// `customers/{customer_id}/campaigns/{campaign_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// The name of the campaign. + /// + /// This field is required and should not be empty when creating new + /// campaigns. + /// + /// It must not contain any null (code point 0x0), NL line feed + /// (code point 0xA) or carriage return (code point 0xD) characters. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types.CampaignStatus status_ = 0; + /// + /// The status of the campaign. + /// + /// When a new campaign is added, the status defaults to ENABLED. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types.CampaignStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "serving_status" field. + public const int ServingStatusFieldNumber = 21; + private global::Google.Ads.GoogleAds.V3.Enums.CampaignServingStatusEnum.Types.CampaignServingStatus servingStatus_ = 0; + /// + /// Output only. The ad serving status of the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CampaignServingStatusEnum.Types.CampaignServingStatus ServingStatus { + get { return servingStatus_; } + set { + servingStatus_ = value; + } + } + + /// Field number for the "ad_serving_optimization_status" field. + public const int AdServingOptimizationStatusFieldNumber = 8; + private global::Google.Ads.GoogleAds.V3.Enums.AdServingOptimizationStatusEnum.Types.AdServingOptimizationStatus adServingOptimizationStatus_ = 0; + /// + /// The ad serving optimization status of the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdServingOptimizationStatusEnum.Types.AdServingOptimizationStatus AdServingOptimizationStatus { + get { return adServingOptimizationStatus_; } + set { + adServingOptimizationStatus_ = value; + } + } + + /// Field number for the "advertising_channel_type" field. + public const int AdvertisingChannelTypeFieldNumber = 9; + private global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType advertisingChannelType_ = 0; + /// + /// Immutable. The primary serving target for ads within the campaign. + /// The targeting options can be refined in `network_settings`. + /// + /// This field is required and should not be empty when creating new + /// campaigns. + /// + /// Can be set only when creating campaigns. + /// After the campaign is created, the field can not be changed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType AdvertisingChannelType { + get { return advertisingChannelType_; } + set { + advertisingChannelType_ = value; + } + } + + /// Field number for the "advertising_channel_sub_type" field. + public const int AdvertisingChannelSubTypeFieldNumber = 10; + private global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Types.AdvertisingChannelSubType advertisingChannelSubType_ = 0; + /// + /// Immutable. Optional refinement to `advertising_channel_type`. + /// Must be a valid sub-type of the parent channel type. + /// + /// Can be set only when creating campaigns. + /// After campaign is created, the field can not be changed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Types.AdvertisingChannelSubType AdvertisingChannelSubType { + get { return advertisingChannelSubType_; } + set { + advertisingChannelSubType_ = value; + } + } + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 11; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(90); + private string trackingUrlTemplate_; + /// + /// The URL template for constructing a tracking URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "url_custom_parameters" field. + public const int UrlCustomParametersFieldNumber = 12; + private static readonly pb::FieldCodec _repeated_urlCustomParameters_codec + = pb::FieldCodec.ForMessage(98, global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser); + private readonly pbc::RepeatedField urlCustomParameters_ = new pbc::RepeatedField(); + /// + /// The list of mappings used to substitute custom parameter tags in a + /// `tracking_url_template`, `final_urls`, or `mobile_final_urls`. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCustomParameters { + get { return urlCustomParameters_; } + } + + /// Field number for the "real_time_bidding_setting" field. + public const int RealTimeBiddingSettingFieldNumber = 39; + private global::Google.Ads.GoogleAds.V3.Common.RealTimeBiddingSetting realTimeBiddingSetting_; + /// + /// Settings for Real-Time Bidding, a feature only available for campaigns + /// targeting the Ad Exchange network. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.RealTimeBiddingSetting RealTimeBiddingSetting { + get { return realTimeBiddingSetting_; } + set { + realTimeBiddingSetting_ = value; + } + } + + /// Field number for the "network_settings" field. + public const int NetworkSettingsFieldNumber = 14; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings networkSettings_; + /// + /// The network settings for the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings NetworkSettings { + get { return networkSettings_; } + set { + networkSettings_ = value; + } + } + + /// Field number for the "hotel_setting" field. + public const int HotelSettingFieldNumber = 32; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.HotelSettingInfo hotelSetting_; + /// + /// Immutable. The hotel setting for the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.HotelSettingInfo HotelSetting { + get { return hotelSetting_; } + set { + hotelSetting_ = value; + } + } + + /// Field number for the "dynamic_search_ads_setting" field. + public const int DynamicSearchAdsSettingFieldNumber = 33; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.DynamicSearchAdsSetting dynamicSearchAdsSetting_; + /// + /// The setting for controlling Dynamic Search Ads (DSA). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.DynamicSearchAdsSetting DynamicSearchAdsSetting { + get { return dynamicSearchAdsSetting_; } + set { + dynamicSearchAdsSetting_ = value; + } + } + + /// Field number for the "shopping_setting" field. + public const int ShoppingSettingFieldNumber = 36; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.ShoppingSetting shoppingSetting_; + /// + /// The setting for controlling Shopping campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.ShoppingSetting ShoppingSetting { + get { return shoppingSetting_; } + set { + shoppingSetting_ = value; + } + } + + /// Field number for the "targeting_setting" field. + public const int TargetingSettingFieldNumber = 43; + private global::Google.Ads.GoogleAds.V3.Common.TargetingSetting targetingSetting_; + /// + /// Setting for targeting related features. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetingSetting TargetingSetting { + get { return targetingSetting_; } + set { + targetingSetting_ = value; + } + } + + /// Field number for the "geo_target_type_setting" field. + public const int GeoTargetTypeSettingFieldNumber = 47; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.GeoTargetTypeSetting geoTargetTypeSetting_; + /// + /// The setting for ads geotargeting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.GeoTargetTypeSetting GeoTargetTypeSetting { + get { return geoTargetTypeSetting_; } + set { + geoTargetTypeSetting_ = value; + } + } + + /// Field number for the "app_campaign_setting" field. + public const int AppCampaignSettingFieldNumber = 51; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.AppCampaignSetting appCampaignSetting_; + /// + /// The setting related to App Campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.AppCampaignSetting AppCampaignSetting { + get { return appCampaignSetting_; } + set { + appCampaignSetting_ = value; + } + } + + /// Field number for the "labels" field. + public const int LabelsFieldNumber = 53; + private static readonly pb::FieldCodec _repeated_labels_codec + = pb::FieldCodec.ForClassWrapper(426); + private readonly pbc::RepeatedField labels_ = new pbc::RepeatedField(); + /// + /// Output only. The resource names of labels attached to this campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Labels { + get { return labels_; } + } + + /// Field number for the "experiment_type" field. + public const int ExperimentTypeFieldNumber = 17; + private global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTypeEnum.Types.CampaignExperimentType experimentType_ = 0; + /// + /// Output only. The type of campaign: normal, draft, or experiment. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTypeEnum.Types.CampaignExperimentType ExperimentType { + get { return experimentType_; } + set { + experimentType_ = value; + } + } + + /// Field number for the "base_campaign" field. + public const int BaseCampaignFieldNumber = 28; + private static readonly pb::FieldCodec _single_baseCampaign_codec = pb::FieldCodec.ForClassWrapper(226); + private string baseCampaign_; + /// + /// Output only. The resource name of the base campaign of a draft or experiment campaign. + /// For base campaigns, this is equal to `resource_name`. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BaseCampaign { + get { return baseCampaign_; } + set { + baseCampaign_ = value; + } + } + + + /// Field number for the "campaign_budget" field. + public const int CampaignBudgetFieldNumber = 6; + private static readonly pb::FieldCodec _single_campaignBudget_codec = pb::FieldCodec.ForClassWrapper(50); + private string campaignBudget_; + /// + /// The budget of the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignBudget { + get { return campaignBudget_; } + set { + campaignBudget_ = value; + } + } + + + /// Field number for the "bidding_strategy_type" field. + public const int BiddingStrategyTypeFieldNumber = 22; + private global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum.Types.BiddingStrategyType biddingStrategyType_ = 0; + /// + /// Output only. The type of bidding strategy. + /// + /// A bidding strategy can be created by setting either the bidding scheme to + /// create a standard bidding strategy or the `bidding_strategy` field to + /// create a portfolio bidding strategy. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum.Types.BiddingStrategyType BiddingStrategyType { + get { return biddingStrategyType_; } + set { + biddingStrategyType_ = value; + } + } + + /// Field number for the "start_date" field. + public const int StartDateFieldNumber = 19; + private static readonly pb::FieldCodec _single_startDate_codec = pb::FieldCodec.ForClassWrapper(154); + private string startDate_; + /// + /// The date when campaign started. + /// + /// This field must not be used in WHERE clauses. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDate { + get { return startDate_; } + set { + startDate_ = value; + } + } + + + /// Field number for the "end_date" field. + public const int EndDateFieldNumber = 20; + private static readonly pb::FieldCodec _single_endDate_codec = pb::FieldCodec.ForClassWrapper(162); + private string endDate_; + /// + /// The date when campaign ended. + /// + /// This field must not be used in WHERE clauses. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDate { + get { return endDate_; } + set { + endDate_ = value; + } + } + + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 38; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(306); + private string finalUrlSuffix_; + /// + /// Suffix used to append query parameters to landing pages that are served + /// with parallel tracking. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + /// Field number for the "frequency_caps" field. + public const int FrequencyCapsFieldNumber = 40; + private static readonly pb::FieldCodec _repeated_frequencyCaps_codec + = pb::FieldCodec.ForMessage(322, global::Google.Ads.GoogleAds.V3.Common.FrequencyCapEntry.Parser); + private readonly pbc::RepeatedField frequencyCaps_ = new pbc::RepeatedField(); + /// + /// A list that limits how often each user will see this campaign's ads. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FrequencyCaps { + get { return frequencyCaps_; } + } + + /// Field number for the "video_brand_safety_suitability" field. + public const int VideoBrandSafetySuitabilityFieldNumber = 42; + private global::Google.Ads.GoogleAds.V3.Enums.BrandSafetySuitabilityEnum.Types.BrandSafetySuitability videoBrandSafetySuitability_ = 0; + /// + /// Output only. 3-Tier Brand Safety setting for the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BrandSafetySuitabilityEnum.Types.BrandSafetySuitability VideoBrandSafetySuitability { + get { return videoBrandSafetySuitability_; } + set { + videoBrandSafetySuitability_ = value; + } + } + + /// Field number for the "vanity_pharma" field. + public const int VanityPharmaFieldNumber = 44; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.VanityPharma vanityPharma_; + /// + /// Describes how unbranded pharma ads will be displayed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.VanityPharma VanityPharma { + get { return vanityPharma_; } + set { + vanityPharma_ = value; + } + } + + /// Field number for the "selective_optimization" field. + public const int SelectiveOptimizationFieldNumber = 45; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.SelectiveOptimization selectiveOptimization_; + /// + /// Selective optimization setting for this campaign, which includes a set of + /// conversion actions to optimize this campaign towards. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.SelectiveOptimization SelectiveOptimization { + get { return selectiveOptimization_; } + set { + selectiveOptimization_ = value; + } + } + + /// Field number for the "tracking_setting" field. + public const int TrackingSettingFieldNumber = 46; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.TrackingSetting trackingSetting_; + /// + /// Output only. Campaign-level settings for tracking information. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.TrackingSetting TrackingSetting { + get { return trackingSetting_; } + set { + trackingSetting_ = value; + } + } + + /// Field number for the "payment_mode" field. + public const int PaymentModeFieldNumber = 52; + private global::Google.Ads.GoogleAds.V3.Enums.PaymentModeEnum.Types.PaymentMode paymentMode_ = 0; + /// + /// Payment mode for the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PaymentModeEnum.Types.PaymentMode PaymentMode { + get { return paymentMode_; } + set { + paymentMode_ = value; + } + } + + /// Field number for the "bidding_strategy" field. + public const int BiddingStrategyFieldNumber = 23; + private static readonly pb::FieldCodec _oneof_biddingStrategy_codec = pb::FieldCodec.ForClassWrapper(186); + /// + /// Portfolio bidding strategy used by campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BiddingStrategy { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.BiddingStrategy ? (string) campaignBiddingStrategy_ : (string) null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.BiddingStrategy; + } + } + + /// Field number for the "commission" field. + public const int CommissionFieldNumber = 49; + /// + /// Commission is an automatic bidding strategy in which the advertiser pays + /// a certain portion of the conversion value. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.Commission Commission { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.Commission ? (global::Google.Ads.GoogleAds.V3.Common.Commission) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.Commission; + } + } + + /// Field number for the "manual_cpc" field. + public const int ManualCpcFieldNumber = 24; + /// + /// Standard Manual CPC bidding strategy. + /// Manual click-based bidding where user pays per click. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ManualCpc ManualCpc { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpc ? (global::Google.Ads.GoogleAds.V3.Common.ManualCpc) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.ManualCpc; + } + } + + /// Field number for the "manual_cpm" field. + public const int ManualCpmFieldNumber = 25; + /// + /// Standard Manual CPM bidding strategy. + /// Manual impression-based bidding where user pays per thousand + /// impressions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ManualCpm ManualCpm { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpm ? (global::Google.Ads.GoogleAds.V3.Common.ManualCpm) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.ManualCpm; + } + } + + /// Field number for the "manual_cpv" field. + public const int ManualCpvFieldNumber = 37; + /// + /// Output only. A bidding strategy that pays a configurable amount per video view. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ManualCpv ManualCpv { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpv ? (global::Google.Ads.GoogleAds.V3.Common.ManualCpv) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.ManualCpv; + } + } + + /// Field number for the "maximize_conversions" field. + public const int MaximizeConversionsFieldNumber = 30; + /// + /// Standard Maximize Conversions bidding strategy that automatically + /// maximizes number of conversions given a daily budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MaximizeConversions MaximizeConversions { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversions ? (global::Google.Ads.GoogleAds.V3.Common.MaximizeConversions) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.MaximizeConversions; + } + } + + /// Field number for the "maximize_conversion_value" field. + public const int MaximizeConversionValueFieldNumber = 31; + /// + /// Standard Maximize Conversion Value bidding strategy that automatically + /// sets bids to maximize revenue while spending your budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MaximizeConversionValue MaximizeConversionValue { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversionValue ? (global::Google.Ads.GoogleAds.V3.Common.MaximizeConversionValue) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.MaximizeConversionValue; + } + } + + /// Field number for the "target_cpa" field. + public const int TargetCpaFieldNumber = 26; + /// + /// Standard Target CPA bidding strategy that automatically sets bids to + /// help get as many conversions as possible at the target + /// cost-per-acquisition (CPA) you set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetCpa TargetCpa { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpa ? (global::Google.Ads.GoogleAds.V3.Common.TargetCpa) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.TargetCpa; + } + } + + /// Field number for the "target_impression_share" field. + public const int TargetImpressionShareFieldNumber = 48; + /// + /// Target Impression Share bidding strategy. An automated bidding strategy + /// that sets bids to achieve a desired percentage of impressions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare TargetImpressionShare { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetImpressionShare ? (global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.TargetImpressionShare; + } + } + + /// Field number for the "target_roas" field. + public const int TargetRoasFieldNumber = 29; + /// + /// Standard Target ROAS bidding strategy that automatically maximizes + /// revenue while averaging a specific target return on ad spend (ROAS). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetRoas TargetRoas { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetRoas ? (global::Google.Ads.GoogleAds.V3.Common.TargetRoas) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.TargetRoas; + } + } + + /// Field number for the "target_spend" field. + public const int TargetSpendFieldNumber = 27; + /// + /// Standard Target Spend bidding strategy that automatically sets your bids + /// to help get as many clicks as possible within your budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetSpend TargetSpend { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetSpend ? (global::Google.Ads.GoogleAds.V3.Common.TargetSpend) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.TargetSpend; + } + } + + /// Field number for the "percent_cpc" field. + public const int PercentCpcFieldNumber = 34; + /// + /// Standard Percent Cpc bidding strategy where bids are a fraction of the + /// advertised price for some good or service. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PercentCpc PercentCpc { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.PercentCpc ? (global::Google.Ads.GoogleAds.V3.Common.PercentCpc) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.PercentCpc; + } + } + + /// Field number for the "target_cpm" field. + public const int TargetCpmFieldNumber = 41; + /// + /// A bidding strategy that automatically optimizes cost per thousand + /// impressions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TargetCpm TargetCpm { + get { return campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpm ? (global::Google.Ads.GoogleAds.V3.Common.TargetCpm) campaignBiddingStrategy_ : null; } + set { + campaignBiddingStrategy_ = value; + campaignBiddingStrategyCase_ = value == null ? CampaignBiddingStrategyOneofCase.None : CampaignBiddingStrategyOneofCase.TargetCpm; + } + } + + private object campaignBiddingStrategy_; + /// Enum of possible cases for the "campaign_bidding_strategy" oneof. + public enum CampaignBiddingStrategyOneofCase { + None = 0, + BiddingStrategy = 23, + Commission = 49, + ManualCpc = 24, + ManualCpm = 25, + ManualCpv = 37, + MaximizeConversions = 30, + MaximizeConversionValue = 31, + TargetCpa = 26, + TargetImpressionShare = 48, + TargetRoas = 29, + TargetSpend = 27, + PercentCpc = 34, + TargetCpm = 41, + } + private CampaignBiddingStrategyOneofCase campaignBiddingStrategyCase_ = CampaignBiddingStrategyOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBiddingStrategyOneofCase CampaignBiddingStrategyCase { + get { return campaignBiddingStrategyCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearCampaignBiddingStrategy() { + campaignBiddingStrategyCase_ = CampaignBiddingStrategyOneofCase.None; + campaignBiddingStrategy_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as Campaign); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(Campaign other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (Status != other.Status) return false; + if (ServingStatus != other.ServingStatus) return false; + if (AdServingOptimizationStatus != other.AdServingOptimizationStatus) return false; + if (AdvertisingChannelType != other.AdvertisingChannelType) return false; + if (AdvertisingChannelSubType != other.AdvertisingChannelSubType) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if(!urlCustomParameters_.Equals(other.urlCustomParameters_)) return false; + if (!object.Equals(RealTimeBiddingSetting, other.RealTimeBiddingSetting)) return false; + if (!object.Equals(NetworkSettings, other.NetworkSettings)) return false; + if (!object.Equals(HotelSetting, other.HotelSetting)) return false; + if (!object.Equals(DynamicSearchAdsSetting, other.DynamicSearchAdsSetting)) return false; + if (!object.Equals(ShoppingSetting, other.ShoppingSetting)) return false; + if (!object.Equals(TargetingSetting, other.TargetingSetting)) return false; + if (!object.Equals(GeoTargetTypeSetting, other.GeoTargetTypeSetting)) return false; + if (!object.Equals(AppCampaignSetting, other.AppCampaignSetting)) return false; + if(!labels_.Equals(other.labels_)) return false; + if (ExperimentType != other.ExperimentType) return false; + if (BaseCampaign != other.BaseCampaign) return false; + if (CampaignBudget != other.CampaignBudget) return false; + if (BiddingStrategyType != other.BiddingStrategyType) return false; + if (StartDate != other.StartDate) return false; + if (EndDate != other.EndDate) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + if(!frequencyCaps_.Equals(other.frequencyCaps_)) return false; + if (VideoBrandSafetySuitability != other.VideoBrandSafetySuitability) return false; + if (!object.Equals(VanityPharma, other.VanityPharma)) return false; + if (!object.Equals(SelectiveOptimization, other.SelectiveOptimization)) return false; + if (!object.Equals(TrackingSetting, other.TrackingSetting)) return false; + if (PaymentMode != other.PaymentMode) return false; + if (BiddingStrategy != other.BiddingStrategy) return false; + if (!object.Equals(Commission, other.Commission)) return false; + if (!object.Equals(ManualCpc, other.ManualCpc)) return false; + if (!object.Equals(ManualCpm, other.ManualCpm)) return false; + if (!object.Equals(ManualCpv, other.ManualCpv)) return false; + if (!object.Equals(MaximizeConversions, other.MaximizeConversions)) return false; + if (!object.Equals(MaximizeConversionValue, other.MaximizeConversionValue)) return false; + if (!object.Equals(TargetCpa, other.TargetCpa)) return false; + if (!object.Equals(TargetImpressionShare, other.TargetImpressionShare)) return false; + if (!object.Equals(TargetRoas, other.TargetRoas)) return false; + if (!object.Equals(TargetSpend, other.TargetSpend)) return false; + if (!object.Equals(PercentCpc, other.PercentCpc)) return false; + if (!object.Equals(TargetCpm, other.TargetCpm)) return false; + if (CampaignBiddingStrategyCase != other.CampaignBiddingStrategyCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (ServingStatus != 0) hash ^= ServingStatus.GetHashCode(); + if (AdServingOptimizationStatus != 0) hash ^= AdServingOptimizationStatus.GetHashCode(); + if (AdvertisingChannelType != 0) hash ^= AdvertisingChannelType.GetHashCode(); + if (AdvertisingChannelSubType != 0) hash ^= AdvertisingChannelSubType.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + hash ^= urlCustomParameters_.GetHashCode(); + if (realTimeBiddingSetting_ != null) hash ^= RealTimeBiddingSetting.GetHashCode(); + if (networkSettings_ != null) hash ^= NetworkSettings.GetHashCode(); + if (hotelSetting_ != null) hash ^= HotelSetting.GetHashCode(); + if (dynamicSearchAdsSetting_ != null) hash ^= DynamicSearchAdsSetting.GetHashCode(); + if (shoppingSetting_ != null) hash ^= ShoppingSetting.GetHashCode(); + if (targetingSetting_ != null) hash ^= TargetingSetting.GetHashCode(); + if (geoTargetTypeSetting_ != null) hash ^= GeoTargetTypeSetting.GetHashCode(); + if (appCampaignSetting_ != null) hash ^= AppCampaignSetting.GetHashCode(); + hash ^= labels_.GetHashCode(); + if (ExperimentType != 0) hash ^= ExperimentType.GetHashCode(); + if (baseCampaign_ != null) hash ^= BaseCampaign.GetHashCode(); + if (campaignBudget_ != null) hash ^= CampaignBudget.GetHashCode(); + if (BiddingStrategyType != 0) hash ^= BiddingStrategyType.GetHashCode(); + if (startDate_ != null) hash ^= StartDate.GetHashCode(); + if (endDate_ != null) hash ^= EndDate.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + hash ^= frequencyCaps_.GetHashCode(); + if (VideoBrandSafetySuitability != 0) hash ^= VideoBrandSafetySuitability.GetHashCode(); + if (vanityPharma_ != null) hash ^= VanityPharma.GetHashCode(); + if (selectiveOptimization_ != null) hash ^= SelectiveOptimization.GetHashCode(); + if (trackingSetting_ != null) hash ^= TrackingSetting.GetHashCode(); + if (PaymentMode != 0) hash ^= PaymentMode.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.BiddingStrategy) hash ^= BiddingStrategy.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.Commission) hash ^= Commission.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpc) hash ^= ManualCpc.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpm) hash ^= ManualCpm.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpv) hash ^= ManualCpv.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversions) hash ^= MaximizeConversions.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversionValue) hash ^= MaximizeConversionValue.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpa) hash ^= TargetCpa.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetImpressionShare) hash ^= TargetImpressionShare.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetRoas) hash ^= TargetRoas.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetSpend) hash ^= TargetSpend.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.PercentCpc) hash ^= PercentCpc.GetHashCode(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpm) hash ^= TargetCpm.GetHashCode(); + hash ^= (int) campaignBiddingStrategyCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (Status != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Status); + } + if (campaignBudget_ != null) { + _single_campaignBudget_codec.WriteTagAndValue(output, CampaignBudget); + } + if (AdServingOptimizationStatus != 0) { + output.WriteRawTag(64); + output.WriteEnum((int) AdServingOptimizationStatus); + } + if (AdvertisingChannelType != 0) { + output.WriteRawTag(72); + output.WriteEnum((int) AdvertisingChannelType); + } + if (AdvertisingChannelSubType != 0) { + output.WriteRawTag(80); + output.WriteEnum((int) AdvertisingChannelSubType); + } + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + urlCustomParameters_.WriteTo(output, _repeated_urlCustomParameters_codec); + if (networkSettings_ != null) { + output.WriteRawTag(114); + output.WriteMessage(NetworkSettings); + } + if (ExperimentType != 0) { + output.WriteRawTag(136, 1); + output.WriteEnum((int) ExperimentType); + } + if (startDate_ != null) { + _single_startDate_codec.WriteTagAndValue(output, StartDate); + } + if (endDate_ != null) { + _single_endDate_codec.WriteTagAndValue(output, EndDate); + } + if (ServingStatus != 0) { + output.WriteRawTag(168, 1); + output.WriteEnum((int) ServingStatus); + } + if (BiddingStrategyType != 0) { + output.WriteRawTag(176, 1); + output.WriteEnum((int) BiddingStrategyType); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.BiddingStrategy) { + _oneof_biddingStrategy_codec.WriteTagAndValue(output, (string) campaignBiddingStrategy_); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpc) { + output.WriteRawTag(194, 1); + output.WriteMessage(ManualCpc); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpm) { + output.WriteRawTag(202, 1); + output.WriteMessage(ManualCpm); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpa) { + output.WriteRawTag(210, 1); + output.WriteMessage(TargetCpa); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetSpend) { + output.WriteRawTag(218, 1); + output.WriteMessage(TargetSpend); + } + if (baseCampaign_ != null) { + _single_baseCampaign_codec.WriteTagAndValue(output, BaseCampaign); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetRoas) { + output.WriteRawTag(234, 1); + output.WriteMessage(TargetRoas); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversions) { + output.WriteRawTag(242, 1); + output.WriteMessage(MaximizeConversions); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversionValue) { + output.WriteRawTag(250, 1); + output.WriteMessage(MaximizeConversionValue); + } + if (hotelSetting_ != null) { + output.WriteRawTag(130, 2); + output.WriteMessage(HotelSetting); + } + if (dynamicSearchAdsSetting_ != null) { + output.WriteRawTag(138, 2); + output.WriteMessage(DynamicSearchAdsSetting); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.PercentCpc) { + output.WriteRawTag(146, 2); + output.WriteMessage(PercentCpc); + } + if (shoppingSetting_ != null) { + output.WriteRawTag(162, 2); + output.WriteMessage(ShoppingSetting); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpv) { + output.WriteRawTag(170, 2); + output.WriteMessage(ManualCpv); + } + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + if (realTimeBiddingSetting_ != null) { + output.WriteRawTag(186, 2); + output.WriteMessage(RealTimeBiddingSetting); + } + frequencyCaps_.WriteTo(output, _repeated_frequencyCaps_codec); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpm) { + output.WriteRawTag(202, 2); + output.WriteMessage(TargetCpm); + } + if (VideoBrandSafetySuitability != 0) { + output.WriteRawTag(208, 2); + output.WriteEnum((int) VideoBrandSafetySuitability); + } + if (targetingSetting_ != null) { + output.WriteRawTag(218, 2); + output.WriteMessage(TargetingSetting); + } + if (vanityPharma_ != null) { + output.WriteRawTag(226, 2); + output.WriteMessage(VanityPharma); + } + if (selectiveOptimization_ != null) { + output.WriteRawTag(234, 2); + output.WriteMessage(SelectiveOptimization); + } + if (trackingSetting_ != null) { + output.WriteRawTag(242, 2); + output.WriteMessage(TrackingSetting); + } + if (geoTargetTypeSetting_ != null) { + output.WriteRawTag(250, 2); + output.WriteMessage(GeoTargetTypeSetting); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetImpressionShare) { + output.WriteRawTag(130, 3); + output.WriteMessage(TargetImpressionShare); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.Commission) { + output.WriteRawTag(138, 3); + output.WriteMessage(Commission); + } + if (appCampaignSetting_ != null) { + output.WriteRawTag(154, 3); + output.WriteMessage(AppCampaignSetting); + } + if (PaymentMode != 0) { + output.WriteRawTag(160, 3); + output.WriteEnum((int) PaymentMode); + } + labels_.WriteTo(output, _repeated_labels_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (ServingStatus != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ServingStatus); + } + if (AdServingOptimizationStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdServingOptimizationStatus); + } + if (AdvertisingChannelType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdvertisingChannelType); + } + if (AdvertisingChannelSubType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdvertisingChannelSubType); + } + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + size += urlCustomParameters_.CalculateSize(_repeated_urlCustomParameters_codec); + if (realTimeBiddingSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(RealTimeBiddingSetting); + } + if (networkSettings_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(NetworkSettings); + } + if (hotelSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(HotelSetting); + } + if (dynamicSearchAdsSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(DynamicSearchAdsSetting); + } + if (shoppingSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ShoppingSetting); + } + if (targetingSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetingSetting); + } + if (geoTargetTypeSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(GeoTargetTypeSetting); + } + if (appCampaignSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AppCampaignSetting); + } + size += labels_.CalculateSize(_repeated_labels_codec); + if (ExperimentType != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ExperimentType); + } + if (baseCampaign_ != null) { + size += _single_baseCampaign_codec.CalculateSizeWithTag(BaseCampaign); + } + if (campaignBudget_ != null) { + size += _single_campaignBudget_codec.CalculateSizeWithTag(CampaignBudget); + } + if (BiddingStrategyType != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) BiddingStrategyType); + } + if (startDate_ != null) { + size += _single_startDate_codec.CalculateSizeWithTag(StartDate); + } + if (endDate_ != null) { + size += _single_endDate_codec.CalculateSizeWithTag(EndDate); + } + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + size += frequencyCaps_.CalculateSize(_repeated_frequencyCaps_codec); + if (VideoBrandSafetySuitability != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) VideoBrandSafetySuitability); + } + if (vanityPharma_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(VanityPharma); + } + if (selectiveOptimization_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(SelectiveOptimization); + } + if (trackingSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TrackingSetting); + } + if (PaymentMode != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) PaymentMode); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.BiddingStrategy) { + size += _oneof_biddingStrategy_codec.CalculateSizeWithTag(BiddingStrategy); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.Commission) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Commission); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpc) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ManualCpc); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpm) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ManualCpm); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpv) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ManualCpv); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversions) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MaximizeConversions); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversionValue) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MaximizeConversionValue); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpa) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetCpa); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetImpressionShare) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetImpressionShare); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetRoas) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetRoas); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetSpend) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetSpend); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.PercentCpc) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(PercentCpc); + } + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpm) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetCpm); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(Campaign other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.ServingStatus != 0) { + ServingStatus = other.ServingStatus; + } + if (other.AdServingOptimizationStatus != 0) { + AdServingOptimizationStatus = other.AdServingOptimizationStatus; + } + if (other.AdvertisingChannelType != 0) { + AdvertisingChannelType = other.AdvertisingChannelType; + } + if (other.AdvertisingChannelSubType != 0) { + AdvertisingChannelSubType = other.AdvertisingChannelSubType; + } + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + urlCustomParameters_.Add(other.urlCustomParameters_); + if (other.realTimeBiddingSetting_ != null) { + if (realTimeBiddingSetting_ == null) { + RealTimeBiddingSetting = new global::Google.Ads.GoogleAds.V3.Common.RealTimeBiddingSetting(); + } + RealTimeBiddingSetting.MergeFrom(other.RealTimeBiddingSetting); + } + if (other.networkSettings_ != null) { + if (networkSettings_ == null) { + NetworkSettings = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings(); + } + NetworkSettings.MergeFrom(other.NetworkSettings); + } + if (other.hotelSetting_ != null) { + if (hotelSetting_ == null) { + HotelSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.HotelSettingInfo(); + } + HotelSetting.MergeFrom(other.HotelSetting); + } + if (other.dynamicSearchAdsSetting_ != null) { + if (dynamicSearchAdsSetting_ == null) { + DynamicSearchAdsSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.DynamicSearchAdsSetting(); + } + DynamicSearchAdsSetting.MergeFrom(other.DynamicSearchAdsSetting); + } + if (other.shoppingSetting_ != null) { + if (shoppingSetting_ == null) { + ShoppingSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.ShoppingSetting(); + } + ShoppingSetting.MergeFrom(other.ShoppingSetting); + } + if (other.targetingSetting_ != null) { + if (targetingSetting_ == null) { + TargetingSetting = new global::Google.Ads.GoogleAds.V3.Common.TargetingSetting(); + } + TargetingSetting.MergeFrom(other.TargetingSetting); + } + if (other.geoTargetTypeSetting_ != null) { + if (geoTargetTypeSetting_ == null) { + GeoTargetTypeSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.GeoTargetTypeSetting(); + } + GeoTargetTypeSetting.MergeFrom(other.GeoTargetTypeSetting); + } + if (other.appCampaignSetting_ != null) { + if (appCampaignSetting_ == null) { + AppCampaignSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.AppCampaignSetting(); + } + AppCampaignSetting.MergeFrom(other.AppCampaignSetting); + } + labels_.Add(other.labels_); + if (other.ExperimentType != 0) { + ExperimentType = other.ExperimentType; + } + if (other.baseCampaign_ != null) { + if (baseCampaign_ == null || other.BaseCampaign != "") { + BaseCampaign = other.BaseCampaign; + } + } + if (other.campaignBudget_ != null) { + if (campaignBudget_ == null || other.CampaignBudget != "") { + CampaignBudget = other.CampaignBudget; + } + } + if (other.BiddingStrategyType != 0) { + BiddingStrategyType = other.BiddingStrategyType; + } + if (other.startDate_ != null) { + if (startDate_ == null || other.StartDate != "") { + StartDate = other.StartDate; + } + } + if (other.endDate_ != null) { + if (endDate_ == null || other.EndDate != "") { + EndDate = other.EndDate; + } + } + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + frequencyCaps_.Add(other.frequencyCaps_); + if (other.VideoBrandSafetySuitability != 0) { + VideoBrandSafetySuitability = other.VideoBrandSafetySuitability; + } + if (other.vanityPharma_ != null) { + if (vanityPharma_ == null) { + VanityPharma = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.VanityPharma(); + } + VanityPharma.MergeFrom(other.VanityPharma); + } + if (other.selectiveOptimization_ != null) { + if (selectiveOptimization_ == null) { + SelectiveOptimization = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.SelectiveOptimization(); + } + SelectiveOptimization.MergeFrom(other.SelectiveOptimization); + } + if (other.trackingSetting_ != null) { + if (trackingSetting_ == null) { + TrackingSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.TrackingSetting(); + } + TrackingSetting.MergeFrom(other.TrackingSetting); + } + if (other.PaymentMode != 0) { + PaymentMode = other.PaymentMode; + } + switch (other.CampaignBiddingStrategyCase) { + case CampaignBiddingStrategyOneofCase.BiddingStrategy: + BiddingStrategy = other.BiddingStrategy; + break; + case CampaignBiddingStrategyOneofCase.Commission: + if (Commission == null) { + Commission = new global::Google.Ads.GoogleAds.V3.Common.Commission(); + } + Commission.MergeFrom(other.Commission); + break; + case CampaignBiddingStrategyOneofCase.ManualCpc: + if (ManualCpc == null) { + ManualCpc = new global::Google.Ads.GoogleAds.V3.Common.ManualCpc(); + } + ManualCpc.MergeFrom(other.ManualCpc); + break; + case CampaignBiddingStrategyOneofCase.ManualCpm: + if (ManualCpm == null) { + ManualCpm = new global::Google.Ads.GoogleAds.V3.Common.ManualCpm(); + } + ManualCpm.MergeFrom(other.ManualCpm); + break; + case CampaignBiddingStrategyOneofCase.ManualCpv: + if (ManualCpv == null) { + ManualCpv = new global::Google.Ads.GoogleAds.V3.Common.ManualCpv(); + } + ManualCpv.MergeFrom(other.ManualCpv); + break; + case CampaignBiddingStrategyOneofCase.MaximizeConversions: + if (MaximizeConversions == null) { + MaximizeConversions = new global::Google.Ads.GoogleAds.V3.Common.MaximizeConversions(); + } + MaximizeConversions.MergeFrom(other.MaximizeConversions); + break; + case CampaignBiddingStrategyOneofCase.MaximizeConversionValue: + if (MaximizeConversionValue == null) { + MaximizeConversionValue = new global::Google.Ads.GoogleAds.V3.Common.MaximizeConversionValue(); + } + MaximizeConversionValue.MergeFrom(other.MaximizeConversionValue); + break; + case CampaignBiddingStrategyOneofCase.TargetCpa: + if (TargetCpa == null) { + TargetCpa = new global::Google.Ads.GoogleAds.V3.Common.TargetCpa(); + } + TargetCpa.MergeFrom(other.TargetCpa); + break; + case CampaignBiddingStrategyOneofCase.TargetImpressionShare: + if (TargetImpressionShare == null) { + TargetImpressionShare = new global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare(); + } + TargetImpressionShare.MergeFrom(other.TargetImpressionShare); + break; + case CampaignBiddingStrategyOneofCase.TargetRoas: + if (TargetRoas == null) { + TargetRoas = new global::Google.Ads.GoogleAds.V3.Common.TargetRoas(); + } + TargetRoas.MergeFrom(other.TargetRoas); + break; + case CampaignBiddingStrategyOneofCase.TargetSpend: + if (TargetSpend == null) { + TargetSpend = new global::Google.Ads.GoogleAds.V3.Common.TargetSpend(); + } + TargetSpend.MergeFrom(other.TargetSpend); + break; + case CampaignBiddingStrategyOneofCase.PercentCpc: + if (PercentCpc == null) { + PercentCpc = new global::Google.Ads.GoogleAds.V3.Common.PercentCpc(); + } + PercentCpc.MergeFrom(other.PercentCpc); + break; + case CampaignBiddingStrategyOneofCase.TargetCpm: + if (TargetCpm == null) { + TargetCpm = new global::Google.Ads.GoogleAds.V3.Common.TargetCpm(); + } + TargetCpm.MergeFrom(other.TargetCpm); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 40: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types.CampaignStatus) input.ReadEnum(); + break; + } + case 50: { + string value = _single_campaignBudget_codec.Read(input); + if (campaignBudget_ == null || value != "") { + CampaignBudget = value; + } + break; + } + case 64: { + AdServingOptimizationStatus = (global::Google.Ads.GoogleAds.V3.Enums.AdServingOptimizationStatusEnum.Types.AdServingOptimizationStatus) input.ReadEnum(); + break; + } + case 72: { + AdvertisingChannelType = (global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType) input.ReadEnum(); + break; + } + case 80: { + AdvertisingChannelSubType = (global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Types.AdvertisingChannelSubType) input.ReadEnum(); + break; + } + case 90: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 98: { + urlCustomParameters_.AddEntriesFrom(input, _repeated_urlCustomParameters_codec); + break; + } + case 114: { + if (networkSettings_ == null) { + NetworkSettings = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.NetworkSettings(); + } + input.ReadMessage(NetworkSettings); + break; + } + case 136: { + ExperimentType = (global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTypeEnum.Types.CampaignExperimentType) input.ReadEnum(); + break; + } + case 154: { + string value = _single_startDate_codec.Read(input); + if (startDate_ == null || value != "") { + StartDate = value; + } + break; + } + case 162: { + string value = _single_endDate_codec.Read(input); + if (endDate_ == null || value != "") { + EndDate = value; + } + break; + } + case 168: { + ServingStatus = (global::Google.Ads.GoogleAds.V3.Enums.CampaignServingStatusEnum.Types.CampaignServingStatus) input.ReadEnum(); + break; + } + case 176: { + BiddingStrategyType = (global::Google.Ads.GoogleAds.V3.Enums.BiddingStrategyTypeEnum.Types.BiddingStrategyType) input.ReadEnum(); + break; + } + case 186: { + BiddingStrategy = _oneof_biddingStrategy_codec.Read(input); + break; + } + case 194: { + global::Google.Ads.GoogleAds.V3.Common.ManualCpc subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ManualCpc(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpc) { + subBuilder.MergeFrom(ManualCpc); + } + input.ReadMessage(subBuilder); + ManualCpc = subBuilder; + break; + } + case 202: { + global::Google.Ads.GoogleAds.V3.Common.ManualCpm subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ManualCpm(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpm) { + subBuilder.MergeFrom(ManualCpm); + } + input.ReadMessage(subBuilder); + ManualCpm = subBuilder; + break; + } + case 210: { + global::Google.Ads.GoogleAds.V3.Common.TargetCpa subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetCpa(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpa) { + subBuilder.MergeFrom(TargetCpa); + } + input.ReadMessage(subBuilder); + TargetCpa = subBuilder; + break; + } + case 218: { + global::Google.Ads.GoogleAds.V3.Common.TargetSpend subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetSpend(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetSpend) { + subBuilder.MergeFrom(TargetSpend); + } + input.ReadMessage(subBuilder); + TargetSpend = subBuilder; + break; + } + case 226: { + string value = _single_baseCampaign_codec.Read(input); + if (baseCampaign_ == null || value != "") { + BaseCampaign = value; + } + break; + } + case 234: { + global::Google.Ads.GoogleAds.V3.Common.TargetRoas subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetRoas(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetRoas) { + subBuilder.MergeFrom(TargetRoas); + } + input.ReadMessage(subBuilder); + TargetRoas = subBuilder; + break; + } + case 242: { + global::Google.Ads.GoogleAds.V3.Common.MaximizeConversions subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MaximizeConversions(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversions) { + subBuilder.MergeFrom(MaximizeConversions); + } + input.ReadMessage(subBuilder); + MaximizeConversions = subBuilder; + break; + } + case 250: { + global::Google.Ads.GoogleAds.V3.Common.MaximizeConversionValue subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MaximizeConversionValue(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.MaximizeConversionValue) { + subBuilder.MergeFrom(MaximizeConversionValue); + } + input.ReadMessage(subBuilder); + MaximizeConversionValue = subBuilder; + break; + } + case 258: { + if (hotelSetting_ == null) { + HotelSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.HotelSettingInfo(); + } + input.ReadMessage(HotelSetting); + break; + } + case 266: { + if (dynamicSearchAdsSetting_ == null) { + DynamicSearchAdsSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.DynamicSearchAdsSetting(); + } + input.ReadMessage(DynamicSearchAdsSetting); + break; + } + case 274: { + global::Google.Ads.GoogleAds.V3.Common.PercentCpc subBuilder = new global::Google.Ads.GoogleAds.V3.Common.PercentCpc(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.PercentCpc) { + subBuilder.MergeFrom(PercentCpc); + } + input.ReadMessage(subBuilder); + PercentCpc = subBuilder; + break; + } + case 290: { + if (shoppingSetting_ == null) { + ShoppingSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.ShoppingSetting(); + } + input.ReadMessage(ShoppingSetting); + break; + } + case 298: { + global::Google.Ads.GoogleAds.V3.Common.ManualCpv subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ManualCpv(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.ManualCpv) { + subBuilder.MergeFrom(ManualCpv); + } + input.ReadMessage(subBuilder); + ManualCpv = subBuilder; + break; + } + case 306: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + case 314: { + if (realTimeBiddingSetting_ == null) { + RealTimeBiddingSetting = new global::Google.Ads.GoogleAds.V3.Common.RealTimeBiddingSetting(); + } + input.ReadMessage(RealTimeBiddingSetting); + break; + } + case 322: { + frequencyCaps_.AddEntriesFrom(input, _repeated_frequencyCaps_codec); + break; + } + case 330: { + global::Google.Ads.GoogleAds.V3.Common.TargetCpm subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetCpm(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetCpm) { + subBuilder.MergeFrom(TargetCpm); + } + input.ReadMessage(subBuilder); + TargetCpm = subBuilder; + break; + } + case 336: { + VideoBrandSafetySuitability = (global::Google.Ads.GoogleAds.V3.Enums.BrandSafetySuitabilityEnum.Types.BrandSafetySuitability) input.ReadEnum(); + break; + } + case 346: { + if (targetingSetting_ == null) { + TargetingSetting = new global::Google.Ads.GoogleAds.V3.Common.TargetingSetting(); + } + input.ReadMessage(TargetingSetting); + break; + } + case 354: { + if (vanityPharma_ == null) { + VanityPharma = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.VanityPharma(); + } + input.ReadMessage(VanityPharma); + break; + } + case 362: { + if (selectiveOptimization_ == null) { + SelectiveOptimization = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.SelectiveOptimization(); + } + input.ReadMessage(SelectiveOptimization); + break; + } + case 370: { + if (trackingSetting_ == null) { + TrackingSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.TrackingSetting(); + } + input.ReadMessage(TrackingSetting); + break; + } + case 378: { + if (geoTargetTypeSetting_ == null) { + GeoTargetTypeSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.GeoTargetTypeSetting(); + } + input.ReadMessage(GeoTargetTypeSetting); + break; + } + case 386: { + global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TargetImpressionShare(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.TargetImpressionShare) { + subBuilder.MergeFrom(TargetImpressionShare); + } + input.ReadMessage(subBuilder); + TargetImpressionShare = subBuilder; + break; + } + case 394: { + global::Google.Ads.GoogleAds.V3.Common.Commission subBuilder = new global::Google.Ads.GoogleAds.V3.Common.Commission(); + if (campaignBiddingStrategyCase_ == CampaignBiddingStrategyOneofCase.Commission) { + subBuilder.MergeFrom(Commission); + } + input.ReadMessage(subBuilder); + Commission = subBuilder; + break; + } + case 410: { + if (appCampaignSetting_ == null) { + AppCampaignSetting = new global::Google.Ads.GoogleAds.V3.Resources.Campaign.Types.AppCampaignSetting(); + } + input.ReadMessage(AppCampaignSetting); + break; + } + case 416: { + PaymentMode = (global::Google.Ads.GoogleAds.V3.Enums.PaymentModeEnum.Types.PaymentMode) input.ReadEnum(); + break; + } + case 426: { + labels_.AddEntriesFrom(input, _repeated_labels_codec); + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the Campaign message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The network settings for the campaign. + /// + public sealed partial class NetworkSettings : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new NetworkSettings()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public NetworkSettings() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public NetworkSettings(NetworkSettings other) : this() { + TargetGoogleSearch = other.TargetGoogleSearch; + TargetSearchNetwork = other.TargetSearchNetwork; + TargetContentNetwork = other.TargetContentNetwork; + TargetPartnerSearchNetwork = other.TargetPartnerSearchNetwork; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public NetworkSettings Clone() { + return new NetworkSettings(this); + } + + /// Field number for the "target_google_search" field. + public const int TargetGoogleSearchFieldNumber = 1; + private static readonly pb::FieldCodec _single_targetGoogleSearch_codec = pb::FieldCodec.ForStructWrapper(10); + private bool? targetGoogleSearch_; + /// + /// Whether ads will be served with google.com search results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? TargetGoogleSearch { + get { return targetGoogleSearch_; } + set { + targetGoogleSearch_ = value; + } + } + + + /// Field number for the "target_search_network" field. + public const int TargetSearchNetworkFieldNumber = 2; + private static readonly pb::FieldCodec _single_targetSearchNetwork_codec = pb::FieldCodec.ForStructWrapper(18); + private bool? targetSearchNetwork_; + /// + /// Whether ads will be served on partner sites in the Google Search Network + /// (requires `target_google_search` to also be `true`). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? TargetSearchNetwork { + get { return targetSearchNetwork_; } + set { + targetSearchNetwork_ = value; + } + } + + + /// Field number for the "target_content_network" field. + public const int TargetContentNetworkFieldNumber = 3; + private static readonly pb::FieldCodec _single_targetContentNetwork_codec = pb::FieldCodec.ForStructWrapper(26); + private bool? targetContentNetwork_; + /// + /// Whether ads will be served on specified placements in the Google Display + /// Network. Placements are specified using the Placement criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? TargetContentNetwork { + get { return targetContentNetwork_; } + set { + targetContentNetwork_ = value; + } + } + + + /// Field number for the "target_partner_search_network" field. + public const int TargetPartnerSearchNetworkFieldNumber = 4; + private static readonly pb::FieldCodec _single_targetPartnerSearchNetwork_codec = pb::FieldCodec.ForStructWrapper(34); + private bool? targetPartnerSearchNetwork_; + /// + /// Whether ads will be served on the Google Partner Network. + /// This is available only to some select Google partner accounts. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? TargetPartnerSearchNetwork { + get { return targetPartnerSearchNetwork_; } + set { + targetPartnerSearchNetwork_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as NetworkSettings); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(NetworkSettings other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (TargetGoogleSearch != other.TargetGoogleSearch) return false; + if (TargetSearchNetwork != other.TargetSearchNetwork) return false; + if (TargetContentNetwork != other.TargetContentNetwork) return false; + if (TargetPartnerSearchNetwork != other.TargetPartnerSearchNetwork) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (targetGoogleSearch_ != null) hash ^= TargetGoogleSearch.GetHashCode(); + if (targetSearchNetwork_ != null) hash ^= TargetSearchNetwork.GetHashCode(); + if (targetContentNetwork_ != null) hash ^= TargetContentNetwork.GetHashCode(); + if (targetPartnerSearchNetwork_ != null) hash ^= TargetPartnerSearchNetwork.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (targetGoogleSearch_ != null) { + _single_targetGoogleSearch_codec.WriteTagAndValue(output, TargetGoogleSearch); + } + if (targetSearchNetwork_ != null) { + _single_targetSearchNetwork_codec.WriteTagAndValue(output, TargetSearchNetwork); + } + if (targetContentNetwork_ != null) { + _single_targetContentNetwork_codec.WriteTagAndValue(output, TargetContentNetwork); + } + if (targetPartnerSearchNetwork_ != null) { + _single_targetPartnerSearchNetwork_codec.WriteTagAndValue(output, TargetPartnerSearchNetwork); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (targetGoogleSearch_ != null) { + size += _single_targetGoogleSearch_codec.CalculateSizeWithTag(TargetGoogleSearch); + } + if (targetSearchNetwork_ != null) { + size += _single_targetSearchNetwork_codec.CalculateSizeWithTag(TargetSearchNetwork); + } + if (targetContentNetwork_ != null) { + size += _single_targetContentNetwork_codec.CalculateSizeWithTag(TargetContentNetwork); + } + if (targetPartnerSearchNetwork_ != null) { + size += _single_targetPartnerSearchNetwork_codec.CalculateSizeWithTag(TargetPartnerSearchNetwork); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(NetworkSettings other) { + if (other == null) { + return; + } + if (other.targetGoogleSearch_ != null) { + if (targetGoogleSearch_ == null || other.TargetGoogleSearch != false) { + TargetGoogleSearch = other.TargetGoogleSearch; + } + } + if (other.targetSearchNetwork_ != null) { + if (targetSearchNetwork_ == null || other.TargetSearchNetwork != false) { + TargetSearchNetwork = other.TargetSearchNetwork; + } + } + if (other.targetContentNetwork_ != null) { + if (targetContentNetwork_ == null || other.TargetContentNetwork != false) { + TargetContentNetwork = other.TargetContentNetwork; + } + } + if (other.targetPartnerSearchNetwork_ != null) { + if (targetPartnerSearchNetwork_ == null || other.TargetPartnerSearchNetwork != false) { + TargetPartnerSearchNetwork = other.TargetPartnerSearchNetwork; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + bool? value = _single_targetGoogleSearch_codec.Read(input); + if (targetGoogleSearch_ == null || value != false) { + TargetGoogleSearch = value; + } + break; + } + case 18: { + bool? value = _single_targetSearchNetwork_codec.Read(input); + if (targetSearchNetwork_ == null || value != false) { + TargetSearchNetwork = value; + } + break; + } + case 26: { + bool? value = _single_targetContentNetwork_codec.Read(input); + if (targetContentNetwork_ == null || value != false) { + TargetContentNetwork = value; + } + break; + } + case 34: { + bool? value = _single_targetPartnerSearchNetwork_codec.Read(input); + if (targetPartnerSearchNetwork_ == null || value != false) { + TargetPartnerSearchNetwork = value; + } + break; + } + } + } + } + + } + + /// + /// Campaign-level settings for hotel ads. + /// + public sealed partial class HotelSettingInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelSettingInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelSettingInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelSettingInfo(HotelSettingInfo other) : this() { + HotelCenterId = other.HotelCenterId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelSettingInfo Clone() { + return new HotelSettingInfo(this); + } + + /// Field number for the "hotel_center_id" field. + public const int HotelCenterIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_hotelCenterId_codec = pb::FieldCodec.ForStructWrapper(10); + private long? hotelCenterId_; + /// + /// Immutable. The linked Hotel Center account. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? HotelCenterId { + get { return hotelCenterId_; } + set { + hotelCenterId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelSettingInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelSettingInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (HotelCenterId != other.HotelCenterId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (hotelCenterId_ != null) hash ^= HotelCenterId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (hotelCenterId_ != null) { + _single_hotelCenterId_codec.WriteTagAndValue(output, HotelCenterId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (hotelCenterId_ != null) { + size += _single_hotelCenterId_codec.CalculateSizeWithTag(HotelCenterId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelSettingInfo other) { + if (other == null) { + return; + } + if (other.hotelCenterId_ != null) { + if (hotelCenterId_ == null || other.HotelCenterId != 0L) { + HotelCenterId = other.HotelCenterId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_hotelCenterId_codec.Read(input); + if (hotelCenterId_ == null || value != 0L) { + HotelCenterId = value; + } + break; + } + } + } + } + + } + + /// + /// The setting for controlling Dynamic Search Ads (DSA). + /// + public sealed partial class DynamicSearchAdsSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DynamicSearchAdsSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DynamicSearchAdsSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DynamicSearchAdsSetting(DynamicSearchAdsSetting other) : this() { + DomainName = other.DomainName; + LanguageCode = other.LanguageCode; + UseSuppliedUrlsOnly = other.UseSuppliedUrlsOnly; + feeds_ = other.feeds_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DynamicSearchAdsSetting Clone() { + return new DynamicSearchAdsSetting(this); + } + + /// Field number for the "domain_name" field. + public const int DomainNameFieldNumber = 1; + private static readonly pb::FieldCodec _single_domainName_codec = pb::FieldCodec.ForClassWrapper(10); + private string domainName_; + /// + /// The Internet domain name that this setting represents, e.g., "google.com" + /// or "www.google.com". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DomainName { + get { return domainName_; } + set { + domainName_ = value; + } + } + + + /// Field number for the "language_code" field. + public const int LanguageCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_languageCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string languageCode_; + /// + /// The language code specifying the language of the domain, e.g., "en". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LanguageCode { + get { return languageCode_; } + set { + languageCode_ = value; + } + } + + + /// Field number for the "use_supplied_urls_only" field. + public const int UseSuppliedUrlsOnlyFieldNumber = 3; + private static readonly pb::FieldCodec _single_useSuppliedUrlsOnly_codec = pb::FieldCodec.ForStructWrapper(26); + private bool? useSuppliedUrlsOnly_; + /// + /// Whether the campaign uses advertiser supplied URLs exclusively. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? UseSuppliedUrlsOnly { + get { return useSuppliedUrlsOnly_; } + set { + useSuppliedUrlsOnly_ = value; + } + } + + + /// Field number for the "feeds" field. + public const int FeedsFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_feeds_codec + = pb::FieldCodec.ForClassWrapper(42); + private readonly pbc::RepeatedField feeds_ = new pbc::RepeatedField(); + /// + /// Output only. The list of page feeds associated with the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Feeds { + get { return feeds_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DynamicSearchAdsSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DynamicSearchAdsSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (DomainName != other.DomainName) return false; + if (LanguageCode != other.LanguageCode) return false; + if (UseSuppliedUrlsOnly != other.UseSuppliedUrlsOnly) return false; + if(!feeds_.Equals(other.feeds_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (domainName_ != null) hash ^= DomainName.GetHashCode(); + if (languageCode_ != null) hash ^= LanguageCode.GetHashCode(); + if (useSuppliedUrlsOnly_ != null) hash ^= UseSuppliedUrlsOnly.GetHashCode(); + hash ^= feeds_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (domainName_ != null) { + _single_domainName_codec.WriteTagAndValue(output, DomainName); + } + if (languageCode_ != null) { + _single_languageCode_codec.WriteTagAndValue(output, LanguageCode); + } + if (useSuppliedUrlsOnly_ != null) { + _single_useSuppliedUrlsOnly_codec.WriteTagAndValue(output, UseSuppliedUrlsOnly); + } + feeds_.WriteTo(output, _repeated_feeds_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (domainName_ != null) { + size += _single_domainName_codec.CalculateSizeWithTag(DomainName); + } + if (languageCode_ != null) { + size += _single_languageCode_codec.CalculateSizeWithTag(LanguageCode); + } + if (useSuppliedUrlsOnly_ != null) { + size += _single_useSuppliedUrlsOnly_codec.CalculateSizeWithTag(UseSuppliedUrlsOnly); + } + size += feeds_.CalculateSize(_repeated_feeds_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DynamicSearchAdsSetting other) { + if (other == null) { + return; + } + if (other.domainName_ != null) { + if (domainName_ == null || other.DomainName != "") { + DomainName = other.DomainName; + } + } + if (other.languageCode_ != null) { + if (languageCode_ == null || other.LanguageCode != "") { + LanguageCode = other.LanguageCode; + } + } + if (other.useSuppliedUrlsOnly_ != null) { + if (useSuppliedUrlsOnly_ == null || other.UseSuppliedUrlsOnly != false) { + UseSuppliedUrlsOnly = other.UseSuppliedUrlsOnly; + } + } + feeds_.Add(other.feeds_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_domainName_codec.Read(input); + if (domainName_ == null || value != "") { + DomainName = value; + } + break; + } + case 18: { + string value = _single_languageCode_codec.Read(input); + if (languageCode_ == null || value != "") { + LanguageCode = value; + } + break; + } + case 26: { + bool? value = _single_useSuppliedUrlsOnly_codec.Read(input); + if (useSuppliedUrlsOnly_ == null || value != false) { + UseSuppliedUrlsOnly = value; + } + break; + } + case 42: { + feeds_.AddEntriesFrom(input, _repeated_feeds_codec); + break; + } + } + } + } + + } + + /// + /// The setting for Shopping campaigns. Defines the universe of products that + /// can be advertised by the campaign, and how this campaign interacts with + /// other Shopping campaigns. + /// + public sealed partial class ShoppingSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ShoppingSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingSetting(ShoppingSetting other) : this() { + MerchantId = other.MerchantId; + SalesCountry = other.SalesCountry; + CampaignPriority = other.CampaignPriority; + EnableLocal = other.EnableLocal; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ShoppingSetting Clone() { + return new ShoppingSetting(this); + } + + /// Field number for the "merchant_id" field. + public const int MerchantIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_merchantId_codec = pb::FieldCodec.ForStructWrapper(10); + private long? merchantId_; + /// + /// Immutable. ID of the Merchant Center account. + /// This field is required for create operations. This field is immutable for + /// Shopping campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? MerchantId { + get { return merchantId_; } + set { + merchantId_ = value; + } + } + + + /// Field number for the "sales_country" field. + public const int SalesCountryFieldNumber = 2; + private static readonly pb::FieldCodec _single_salesCountry_codec = pb::FieldCodec.ForClassWrapper(18); + private string salesCountry_; + /// + /// Immutable. Sales country of products to include in the campaign. + /// This field is required for Shopping campaigns. This field is immutable. + /// This field is optional for non-Shopping campaigns, but it must be equal + /// to 'ZZ' if set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string SalesCountry { + get { return salesCountry_; } + set { + salesCountry_ = value; + } + } + + + /// Field number for the "campaign_priority" field. + public const int CampaignPriorityFieldNumber = 3; + private static readonly pb::FieldCodec _single_campaignPriority_codec = pb::FieldCodec.ForStructWrapper(26); + private int? campaignPriority_; + /// + /// Priority of the campaign. Campaigns with numerically higher priorities + /// take precedence over those with lower priorities. + /// This field is required for Shopping campaigns, with values between 0 and + /// 2, inclusive. + /// This field is optional for Smart Shopping campaigns, but must be equal to + /// 3 if set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int? CampaignPriority { + get { return campaignPriority_; } + set { + campaignPriority_ = value; + } + } + + + /// Field number for the "enable_local" field. + public const int EnableLocalFieldNumber = 4; + private static readonly pb::FieldCodec _single_enableLocal_codec = pb::FieldCodec.ForStructWrapper(34); + private bool? enableLocal_; + /// + /// Whether to include local products. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? EnableLocal { + get { return enableLocal_; } + set { + enableLocal_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ShoppingSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ShoppingSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (MerchantId != other.MerchantId) return false; + if (SalesCountry != other.SalesCountry) return false; + if (CampaignPriority != other.CampaignPriority) return false; + if (EnableLocal != other.EnableLocal) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (merchantId_ != null) hash ^= MerchantId.GetHashCode(); + if (salesCountry_ != null) hash ^= SalesCountry.GetHashCode(); + if (campaignPriority_ != null) hash ^= CampaignPriority.GetHashCode(); + if (enableLocal_ != null) hash ^= EnableLocal.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (merchantId_ != null) { + _single_merchantId_codec.WriteTagAndValue(output, MerchantId); + } + if (salesCountry_ != null) { + _single_salesCountry_codec.WriteTagAndValue(output, SalesCountry); + } + if (campaignPriority_ != null) { + _single_campaignPriority_codec.WriteTagAndValue(output, CampaignPriority); + } + if (enableLocal_ != null) { + _single_enableLocal_codec.WriteTagAndValue(output, EnableLocal); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (merchantId_ != null) { + size += _single_merchantId_codec.CalculateSizeWithTag(MerchantId); + } + if (salesCountry_ != null) { + size += _single_salesCountry_codec.CalculateSizeWithTag(SalesCountry); + } + if (campaignPriority_ != null) { + size += _single_campaignPriority_codec.CalculateSizeWithTag(CampaignPriority); + } + if (enableLocal_ != null) { + size += _single_enableLocal_codec.CalculateSizeWithTag(EnableLocal); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ShoppingSetting other) { + if (other == null) { + return; + } + if (other.merchantId_ != null) { + if (merchantId_ == null || other.MerchantId != 0L) { + MerchantId = other.MerchantId; + } + } + if (other.salesCountry_ != null) { + if (salesCountry_ == null || other.SalesCountry != "") { + SalesCountry = other.SalesCountry; + } + } + if (other.campaignPriority_ != null) { + if (campaignPriority_ == null || other.CampaignPriority != 0) { + CampaignPriority = other.CampaignPriority; + } + } + if (other.enableLocal_ != null) { + if (enableLocal_ == null || other.EnableLocal != false) { + EnableLocal = other.EnableLocal; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_merchantId_codec.Read(input); + if (merchantId_ == null || value != 0L) { + MerchantId = value; + } + break; + } + case 18: { + string value = _single_salesCountry_codec.Read(input); + if (salesCountry_ == null || value != "") { + SalesCountry = value; + } + break; + } + case 26: { + int? value = _single_campaignPriority_codec.Read(input); + if (campaignPriority_ == null || value != 0) { + CampaignPriority = value; + } + break; + } + case 34: { + bool? value = _single_enableLocal_codec.Read(input); + if (enableLocal_ == null || value != false) { + EnableLocal = value; + } + break; + } + } + } + } + + } + + /// + /// Campaign-level settings for tracking information. + /// + public sealed partial class TrackingSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TrackingSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TrackingSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TrackingSetting(TrackingSetting other) : this() { + TrackingUrl = other.TrackingUrl; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TrackingSetting Clone() { + return new TrackingSetting(this); + } + + /// Field number for the "tracking_url" field. + public const int TrackingUrlFieldNumber = 1; + private static readonly pb::FieldCodec _single_trackingUrl_codec = pb::FieldCodec.ForClassWrapper(10); + private string trackingUrl_; + /// + /// Output only. The url used for dynamic tracking. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrl { + get { return trackingUrl_; } + set { + trackingUrl_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TrackingSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TrackingSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (TrackingUrl != other.TrackingUrl) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (trackingUrl_ != null) hash ^= TrackingUrl.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (trackingUrl_ != null) { + _single_trackingUrl_codec.WriteTagAndValue(output, TrackingUrl); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (trackingUrl_ != null) { + size += _single_trackingUrl_codec.CalculateSizeWithTag(TrackingUrl); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TrackingSetting other) { + if (other == null) { + return; + } + if (other.trackingUrl_ != null) { + if (trackingUrl_ == null || other.TrackingUrl != "") { + TrackingUrl = other.TrackingUrl; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_trackingUrl_codec.Read(input); + if (trackingUrl_ == null || value != "") { + TrackingUrl = value; + } + break; + } + } + } + } + + } + + /// + /// Represents a collection of settings related to ads geotargeting. + /// + public sealed partial class GeoTargetTypeSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoTargetTypeSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetTypeSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetTypeSetting(GeoTargetTypeSetting other) : this() { + positiveGeoTargetType_ = other.positiveGeoTargetType_; + negativeGeoTargetType_ = other.negativeGeoTargetType_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetTypeSetting Clone() { + return new GeoTargetTypeSetting(this); + } + + /// Field number for the "positive_geo_target_type" field. + public const int PositiveGeoTargetTypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.PositiveGeoTargetTypeEnum.Types.PositiveGeoTargetType positiveGeoTargetType_ = 0; + /// + /// The setting used for positive geotargeting in this particular campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PositiveGeoTargetTypeEnum.Types.PositiveGeoTargetType PositiveGeoTargetType { + get { return positiveGeoTargetType_; } + set { + positiveGeoTargetType_ = value; + } + } + + /// Field number for the "negative_geo_target_type" field. + public const int NegativeGeoTargetTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.NegativeGeoTargetTypeEnum.Types.NegativeGeoTargetType negativeGeoTargetType_ = 0; + /// + /// The setting used for negative geotargeting in this particular campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.NegativeGeoTargetTypeEnum.Types.NegativeGeoTargetType NegativeGeoTargetType { + get { return negativeGeoTargetType_; } + set { + negativeGeoTargetType_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoTargetTypeSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoTargetTypeSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (PositiveGeoTargetType != other.PositiveGeoTargetType) return false; + if (NegativeGeoTargetType != other.NegativeGeoTargetType) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (PositiveGeoTargetType != 0) hash ^= PositiveGeoTargetType.GetHashCode(); + if (NegativeGeoTargetType != 0) hash ^= NegativeGeoTargetType.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (PositiveGeoTargetType != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) PositiveGeoTargetType); + } + if (NegativeGeoTargetType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) NegativeGeoTargetType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (PositiveGeoTargetType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PositiveGeoTargetType); + } + if (NegativeGeoTargetType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) NegativeGeoTargetType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoTargetTypeSetting other) { + if (other == null) { + return; + } + if (other.PositiveGeoTargetType != 0) { + PositiveGeoTargetType = other.PositiveGeoTargetType; + } + if (other.NegativeGeoTargetType != 0) { + NegativeGeoTargetType = other.NegativeGeoTargetType; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + PositiveGeoTargetType = (global::Google.Ads.GoogleAds.V3.Enums.PositiveGeoTargetTypeEnum.Types.PositiveGeoTargetType) input.ReadEnum(); + break; + } + case 16: { + NegativeGeoTargetType = (global::Google.Ads.GoogleAds.V3.Enums.NegativeGeoTargetTypeEnum.Types.NegativeGeoTargetType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Campaign-level settings for App Campaigns. + /// + public sealed partial class AppCampaignSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppCampaignSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignSetting(AppCampaignSetting other) : this() { + biddingStrategyGoalType_ = other.biddingStrategyGoalType_; + AppId = other.AppId; + appStore_ = other.appStore_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppCampaignSetting Clone() { + return new AppCampaignSetting(this); + } + + /// Field number for the "bidding_strategy_goal_type" field. + public const int BiddingStrategyGoalTypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeEnum.Types.AppCampaignBiddingStrategyGoalType biddingStrategyGoalType_ = 0; + /// + /// Represents the goal which the bidding strategy of this app campaign + /// should optimize towards. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeEnum.Types.AppCampaignBiddingStrategyGoalType BiddingStrategyGoalType { + get { return biddingStrategyGoalType_; } + set { + biddingStrategyGoalType_ = value; + } + } + + /// Field number for the "app_id" field. + public const int AppIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_appId_codec = pb::FieldCodec.ForClassWrapper(18); + private string appId_; + /// + /// Immutable. A string that uniquely identifies a mobile application. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AppId { + get { return appId_; } + set { + appId_ = value; + } + } + + + /// Field number for the "app_store" field. + public const int AppStoreFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreEnum.Types.AppCampaignAppStore appStore_ = 0; + /// + /// Immutable. The application store that distributes this specific app. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreEnum.Types.AppCampaignAppStore AppStore { + get { return appStore_; } + set { + appStore_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppCampaignSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppCampaignSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (BiddingStrategyGoalType != other.BiddingStrategyGoalType) return false; + if (AppId != other.AppId) return false; + if (AppStore != other.AppStore) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (BiddingStrategyGoalType != 0) hash ^= BiddingStrategyGoalType.GetHashCode(); + if (appId_ != null) hash ^= AppId.GetHashCode(); + if (AppStore != 0) hash ^= AppStore.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (BiddingStrategyGoalType != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) BiddingStrategyGoalType); + } + if (appId_ != null) { + _single_appId_codec.WriteTagAndValue(output, AppId); + } + if (AppStore != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) AppStore); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (BiddingStrategyGoalType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) BiddingStrategyGoalType); + } + if (appId_ != null) { + size += _single_appId_codec.CalculateSizeWithTag(AppId); + } + if (AppStore != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AppStore); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppCampaignSetting other) { + if (other == null) { + return; + } + if (other.BiddingStrategyGoalType != 0) { + BiddingStrategyGoalType = other.BiddingStrategyGoalType; + } + if (other.appId_ != null) { + if (appId_ == null || other.AppId != "") { + AppId = other.AppId; + } + } + if (other.AppStore != 0) { + AppStore = other.AppStore; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + BiddingStrategyGoalType = (global::Google.Ads.GoogleAds.V3.Enums.AppCampaignBiddingStrategyGoalTypeEnum.Types.AppCampaignBiddingStrategyGoalType) input.ReadEnum(); + break; + } + case 18: { + string value = _single_appId_codec.Read(input); + if (appId_ == null || value != "") { + AppId = value; + } + break; + } + case 24: { + AppStore = (global::Google.Ads.GoogleAds.V3.Enums.AppCampaignAppStoreEnum.Types.AppCampaignAppStore) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Describes how unbranded pharma ads will be displayed. + /// + public sealed partial class VanityPharma : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new VanityPharma()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VanityPharma() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VanityPharma(VanityPharma other) : this() { + vanityPharmaDisplayUrlMode_ = other.vanityPharmaDisplayUrlMode_; + vanityPharmaText_ = other.vanityPharmaText_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public VanityPharma Clone() { + return new VanityPharma(this); + } + + /// Field number for the "vanity_pharma_display_url_mode" field. + public const int VanityPharmaDisplayUrlModeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.VanityPharmaDisplayUrlModeEnum.Types.VanityPharmaDisplayUrlMode vanityPharmaDisplayUrlMode_ = 0; + /// + /// The display mode for vanity pharma URLs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.VanityPharmaDisplayUrlModeEnum.Types.VanityPharmaDisplayUrlMode VanityPharmaDisplayUrlMode { + get { return vanityPharmaDisplayUrlMode_; } + set { + vanityPharmaDisplayUrlMode_ = value; + } + } + + /// Field number for the "vanity_pharma_text" field. + public const int VanityPharmaTextFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.VanityPharmaTextEnum.Types.VanityPharmaText vanityPharmaText_ = 0; + /// + /// The text that will be displayed in display URL of the text ad when + /// website description is the selected display mode for vanity pharma URLs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.VanityPharmaTextEnum.Types.VanityPharmaText VanityPharmaText { + get { return vanityPharmaText_; } + set { + vanityPharmaText_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as VanityPharma); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(VanityPharma other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (VanityPharmaDisplayUrlMode != other.VanityPharmaDisplayUrlMode) return false; + if (VanityPharmaText != other.VanityPharmaText) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (VanityPharmaDisplayUrlMode != 0) hash ^= VanityPharmaDisplayUrlMode.GetHashCode(); + if (VanityPharmaText != 0) hash ^= VanityPharmaText.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (VanityPharmaDisplayUrlMode != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) VanityPharmaDisplayUrlMode); + } + if (VanityPharmaText != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) VanityPharmaText); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (VanityPharmaDisplayUrlMode != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) VanityPharmaDisplayUrlMode); + } + if (VanityPharmaText != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) VanityPharmaText); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(VanityPharma other) { + if (other == null) { + return; + } + if (other.VanityPharmaDisplayUrlMode != 0) { + VanityPharmaDisplayUrlMode = other.VanityPharmaDisplayUrlMode; + } + if (other.VanityPharmaText != 0) { + VanityPharmaText = other.VanityPharmaText; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + VanityPharmaDisplayUrlMode = (global::Google.Ads.GoogleAds.V3.Enums.VanityPharmaDisplayUrlModeEnum.Types.VanityPharmaDisplayUrlMode) input.ReadEnum(); + break; + } + case 16: { + VanityPharmaText = (global::Google.Ads.GoogleAds.V3.Enums.VanityPharmaTextEnum.Types.VanityPharmaText) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Selective optimization setting for this campaign, which includes a set of + /// conversion actions to optimize this campaign towards. + /// + public sealed partial class SelectiveOptimization : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SelectiveOptimization()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Campaign.Descriptor.NestedTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SelectiveOptimization() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SelectiveOptimization(SelectiveOptimization other) : this() { + conversionActions_ = other.conversionActions_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SelectiveOptimization Clone() { + return new SelectiveOptimization(this); + } + + /// Field number for the "conversion_actions" field. + public const int ConversionActionsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_conversionActions_codec + = pb::FieldCodec.ForClassWrapper(10); + private readonly pbc::RepeatedField conversionActions_ = new pbc::RepeatedField(); + /// + /// The selected set of conversion actions for optimizing this campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ConversionActions { + get { return conversionActions_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SelectiveOptimization); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SelectiveOptimization other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!conversionActions_.Equals(other.conversionActions_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= conversionActions_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + conversionActions_.WriteTo(output, _repeated_conversionActions_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += conversionActions_.CalculateSize(_repeated_conversionActions_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SelectiveOptimization other) { + if (other == null) { + return; + } + conversionActions_.Add(other.conversionActions_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + conversionActions_.AddEntriesFrom(input, _repeated_conversionActions_codec); + break; + } + } + } + } + + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignAudienceView.cs b/src/V3/Stubs/CampaignAudienceView.cs new file mode 100644 index 000000000..f03244596 --- /dev/null +++ b/src/V3/Stubs/CampaignAudienceView.cs @@ -0,0 +1,199 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_audience_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_audience_view.proto + public static partial class CampaignAudienceViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_audience_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignAudienceViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "YXVkaWVuY2Vfdmlldy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhln", + "b29nbGUvYXBpL3Jlc291cmNlLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvIt0BChRDYW1wYWlnbkF1ZGllbmNlVmlldxJMCg1yZXNvdXJj", + "ZV9uYW1lGAEgASgJQjXgQQX6QS8KLWdvb2dsZWFkcy5nb29nbGVhcGlzLmNv", + "bS9DYW1wYWlnbkF1ZGllbmNlVmlldzp36kF0Ci1nb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vQ2FtcGFpZ25BdWRpZW5jZVZpZXcSQ2N1c3RvbWVycy97Y3Vz", + "dG9tZXJ9L2NhbXBhaWduQXVkaWVuY2VWaWV3cy97Y2FtcGFpZ25fYXVkaWVu", + "Y2Vfdmlld31ChgIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNv", + "dXJjZXNCGUNhbXBhaWduQXVkaWVuY2VWaWV3UHJvdG9QAVpKZ29vZ2xlLmdv", + "bGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3Yz", + "L3Jlc291cmNlcztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2ds", + "ZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xS", + "ZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3Vy", + "Y2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView), global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A campaign audience view. + /// Includes performance data from interests and remarketing lists for Display + /// Network and YouTube Network ads, and remarketing lists for search ads (RLSA), + /// aggregated by campaign and audience criterion. This view only includes + /// audiences attached at the campaign level. + /// + public sealed partial class CampaignAudienceView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignAudienceView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignAudienceView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignAudienceView(CampaignAudienceView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignAudienceView Clone() { + return new CampaignAudienceView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign audience view. + /// Campaign audience view resource names have the form: + /// + /// `customers/{customer_id}/campaignAudienceViews/{campaign_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignAudienceView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignAudienceView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignAudienceView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignAudienceViewService.cs b/src/V3/Stubs/CampaignAudienceViewService.cs new file mode 100644 index 000000000..6d34867c2 --- /dev/null +++ b/src/V3/Stubs/CampaignAudienceViewService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_audience_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_audience_view_service.proto + public static partial class CampaignAudienceViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_audience_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignAudienceViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9h", + "dWRpZW5jZV92aWV3X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNv", + "dXJjZXMvY2FtcGFpZ25fYXVkaWVuY2Vfdmlldy5wcm90bxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8a", + "H2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8iPAoeR2V0Q2FtcGFp", + "Z25BdWRpZW5jZVZpZXdSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlC", + "A+BBAjKiAgobQ2FtcGFpZ25BdWRpZW5jZVZpZXdTZXJ2aWNlEuUBChdHZXRD", + "YW1wYWlnbkF1ZGllbmNlVmlldxJALmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLkdldENhbXBhaWduQXVkaWVuY2VWaWV3UmVxdWVzdBo3Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DYW1wYWlnbkF1ZGll", + "bmNlVmlldyJPgtPkkwI5EjcvdjMve3Jlc291cmNlX25hbWU9Y3VzdG9tZXJz", + "LyovY2FtcGFpZ25BdWRpZW5jZVZpZXdzLyp92kENcmVzb3VyY2VfbmFtZRob", + "ykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQocCCiRjb20uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXNCIENhbXBhaWduQXVkaWVuY2VWaWV3", + "U2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6IC", + "A0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignAudienceViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignAudienceViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignAudienceViewService.GetCampaignAudienceView][google.ads.googleads.v3.services.CampaignAudienceViewService.GetCampaignAudienceView]. + /// + public sealed partial class GetCampaignAudienceViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignAudienceViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignAudienceViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignAudienceViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignAudienceViewRequest(GetCampaignAudienceViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignAudienceViewRequest Clone() { + return new GetCampaignAudienceViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign audience view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignAudienceViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignAudienceViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignAudienceViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignAudienceViewServiceClient.cs b/src/V3/Stubs/CampaignAudienceViewServiceClient.cs new file mode 100644 index 000000000..49d7d0363 --- /dev/null +++ b/src/V3/Stubs/CampaignAudienceViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignAudienceViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignAudienceViewServiceSettings GetDefault() => new CampaignAudienceViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignAudienceViewServiceSettings() { } + + private CampaignAudienceViewServiceSettings(CampaignAudienceViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignAudienceViewSettings = existing.GetCampaignAudienceViewSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignAudienceViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignAudienceViewServiceClient.GetCampaignAudienceView and CampaignAudienceViewServiceClient.GetCampaignAudienceViewAsync. + /// + /// + /// The default CampaignAudienceViewServiceClient.GetCampaignAudienceView and + /// CampaignAudienceViewServiceClient.GetCampaignAudienceViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignAudienceViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignAudienceViewServiceSettings Clone() => new CampaignAudienceViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignAudienceViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignAudienceViewServiceSettings Settings { get; set; } + + /// + public override CampaignAudienceViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignAudienceViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignAudienceViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignAudienceViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignAudienceViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignAudienceViewServiceClient.ChannelPool; + } + + /// + /// CampaignAudienceViewService client wrapper, for convenient use. + /// + public abstract partial class CampaignAudienceViewServiceClient + { + /// + /// The default endpoint for the CampaignAudienceViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignAudienceViewService scopes. + /// + /// + /// The default CampaignAudienceViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignAudienceViewServiceClient client = await CampaignAudienceViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignAudienceViewServiceClient.DefaultEndpoint.Host, CampaignAudienceViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignAudienceViewServiceClient client = CampaignAudienceViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignAudienceViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignAudienceViewServiceClient client = CampaignAudienceViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignAudienceViewServiceClient.DefaultEndpoint.Host, CampaignAudienceViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignAudienceViewServiceClient client = CampaignAudienceViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignAudienceViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignAudienceViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignAudienceViewServiceClient Create(grpccore::Channel channel, CampaignAudienceViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignAudienceViewServiceClient Create(grpccore::CallInvoker callInvoker, CampaignAudienceViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignAudienceViewService.CampaignAudienceViewServiceClient grpcClient = new CampaignAudienceViewService.CampaignAudienceViewServiceClient(callInvoker); + return new CampaignAudienceViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignAudienceViewService client. + /// + public virtual CampaignAudienceViewService.CampaignAudienceViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// + /// Required. The resource name of the campaign audience view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignAudienceViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignAudienceViewAsync( + new GetCampaignAudienceViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// + /// Required. The resource name of the campaign audience view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignAudienceViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignAudienceViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// + /// Required. The resource name of the campaign audience view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignAudienceView GetCampaignAudienceView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignAudienceView( + new GetCampaignAudienceViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignAudienceViewAsync( + GetCampaignAudienceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignAudienceViewAsync( + GetCampaignAudienceViewRequest request, + st::CancellationToken cancellationToken) => GetCampaignAudienceViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignAudienceView GetCampaignAudienceView( + GetCampaignAudienceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignAudienceViewService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignAudienceViewServiceClientImpl : CampaignAudienceViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignAudienceView; + + /// + /// Constructs a client wrapper for the CampaignAudienceViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignAudienceViewServiceClientImpl(CampaignAudienceViewService.CampaignAudienceViewServiceClient grpcClient, CampaignAudienceViewServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignAudienceViewServiceSettings effectiveSettings = settings ?? CampaignAudienceViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignAudienceView = clientHelper.BuildApiCall( + GrpcClient.GetCampaignAudienceViewAsync, GrpcClient.GetCampaignAudienceView, effectiveSettings.GetCampaignAudienceViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetCampaignAudienceView); + Modify_GetCampaignAudienceViewApiCall(ref _callGetCampaignAudienceView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignAudienceViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignAudienceViewService.CampaignAudienceViewServiceClient grpcClient, CampaignAudienceViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignAudienceViewService client. + /// + public override CampaignAudienceViewService.CampaignAudienceViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignAudienceViewRequest(ref GetCampaignAudienceViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignAudienceViewAsync( + GetCampaignAudienceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignAudienceViewRequest(ref request, ref callSettings); + return _callGetCampaignAudienceView.Async(request, callSettings); + } + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignAudienceView GetCampaignAudienceView( + GetCampaignAudienceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignAudienceViewRequest(ref request, ref callSettings); + return _callGetCampaignAudienceView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignAudienceViewServiceGrpc.cs b/src/V3/Stubs/CampaignAudienceViewServiceGrpc.cs new file mode 100644 index 000000000..37f8e8835 --- /dev/null +++ b/src/V3/Stubs/CampaignAudienceViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_audience_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaign audience views. + /// + public static partial class CampaignAudienceViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignAudienceViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignAudienceViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignAudienceViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignAudienceView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignAudienceView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignAudienceView", + __Marshaller_google_ads_googleads_v3_services_GetCampaignAudienceViewRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignAudienceView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignAudienceViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignAudienceViewService + public abstract partial class CampaignAudienceViewServiceBase + { + /// + /// Returns the requested campaign audience view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignAudienceView(global::Google.Ads.GoogleAds.V3.Services.GetCampaignAudienceViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignAudienceViewService + public partial class CampaignAudienceViewServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignAudienceViewService + /// The channel to use to make remote calls. + public CampaignAudienceViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignAudienceViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignAudienceViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignAudienceViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignAudienceViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign audience view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView GetCampaignAudienceView(global::Google.Ads.GoogleAds.V3.Services.GetCampaignAudienceViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignAudienceView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign audience view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView GetCampaignAudienceView(global::Google.Ads.GoogleAds.V3.Services.GetCampaignAudienceViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignAudienceView, null, options, request); + } + /// + /// Returns the requested campaign audience view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignAudienceViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignAudienceViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignAudienceViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign audience view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignAudienceViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignAudienceViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignAudienceView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignAudienceViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignAudienceViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignAudienceViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignAudienceView, serviceImpl.GetCampaignAudienceView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignAudienceViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignAudienceView, serviceImpl.GetCampaignAudienceView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignBidModifier.cs b/src/V3/Stubs/CampaignBidModifier.cs new file mode 100644 index 000000000..0cbd5fb45 --- /dev/null +++ b/src/V3/Stubs/CampaignBidModifier.cs @@ -0,0 +1,383 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_bid_modifier.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_bid_modifier.proto + public static partial class CampaignBidModifierReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_bid_modifier.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignBidModifierReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "YmlkX21vZGlmaWVyLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMaLWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9jcml0", + "ZXJpYS5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZ", + "Z29vZ2xlL2FwaS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dy", + "YXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIoIE", + "ChNDYW1wYWlnbkJpZE1vZGlmaWVyEksKDXJlc291cmNlX25hbWUYASABKAlC", + "NOBBBfpBLgosZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0NhbXBhaWduQmlk", + "TW9kaWZpZXISWQoIY2FtcGFpZ24YAiABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWVCKeBBA/pBIwohZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29t", + "L0NhbXBhaWduEjYKDGNyaXRlcmlvbl9pZBgDIAEoCzIbLmdvb2dsZS5wcm90", + "b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSMgoMYmlkX21vZGlmaWVyGAQgASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLkRvdWJsZVZhbHVlElQKEGludGVyYWN0aW9uX3R5", + "cGUYBSABKAsyMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uSW50", + "ZXJhY3Rpb25UeXBlSW5mb0ID4EEFSAA6dOpBcQosZ29vZ2xlYWRzLmdvb2ds", + "ZWFwaXMuY29tL0NhbXBhaWduQmlkTW9kaWZpZXISQWN1c3RvbWVycy97Y3Vz", + "dG9tZXJ9L2NhbXBhaWduQmlkTW9kaWZpZXJzL3tjYW1wYWlnbl9iaWRfbW9k", + "aWZpZXJ9QgsKCWNyaXRlcmlvbkKFAgolY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlc0IYQ2FtcGFpZ25CaWRNb2RpZmllclByb3RvUAFa", + "Smdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xl", + "LkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29n", + "bGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier), global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier.Parser, new[]{ "ResourceName", "Campaign", "CriterionId", "BidModifier", "InteractionType" }, new[]{ "Criterion" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents a bid-modifiable only criterion at the campaign level. + /// + public sealed partial class CampaignBidModifier : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignBidModifier()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifierReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBidModifier() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBidModifier(CampaignBidModifier other) : this() { + resourceName_ = other.resourceName_; + Campaign = other.Campaign; + CriterionId = other.CriterionId; + BidModifier = other.BidModifier; + switch (other.CriterionCase) { + case CriterionOneofCase.InteractionType: + InteractionType = other.InteractionType.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBidModifier Clone() { + return new CampaignBidModifier(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign bid modifier. + /// Campaign bid modifier resource names have the form: + /// + /// `customers/{customer_id}/campaignBidModifiers/{campaign_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 2; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(18); + private string campaign_; + /// + /// Output only. The campaign to which this criterion belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "criterion_id" field. + public const int CriterionIdFieldNumber = 3; + private static readonly pb::FieldCodec _single_criterionId_codec = pb::FieldCodec.ForStructWrapper(26); + private long? criterionId_; + /// + /// Output only. The ID of the criterion to bid modify. + /// + /// This field is ignored for mutates. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CriterionId { + get { return criterionId_; } + set { + criterionId_ = value; + } + } + + + /// Field number for the "bid_modifier" field. + public const int BidModifierFieldNumber = 4; + private static readonly pb::FieldCodec _single_bidModifier_codec = pb::FieldCodec.ForStructWrapper(34); + private double? bidModifier_; + /// + /// The modifier for the bid when the criterion matches. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? BidModifier { + get { return bidModifier_; } + set { + bidModifier_ = value; + } + } + + + /// Field number for the "interaction_type" field. + public const int InteractionTypeFieldNumber = 5; + /// + /// Immutable. Criterion for interaction type. Only supported for search campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.InteractionTypeInfo InteractionType { + get { return criterionCase_ == CriterionOneofCase.InteractionType ? (global::Google.Ads.GoogleAds.V3.Common.InteractionTypeInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.InteractionType; + } + } + + private object criterion_; + /// Enum of possible cases for the "criterion" oneof. + public enum CriterionOneofCase { + None = 0, + InteractionType = 5, + } + private CriterionOneofCase criterionCase_ = CriterionOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionOneofCase CriterionCase { + get { return criterionCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearCriterion() { + criterionCase_ = CriterionOneofCase.None; + criterion_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignBidModifier); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignBidModifier other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Campaign != other.Campaign) return false; + if (CriterionId != other.CriterionId) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(BidModifier, other.BidModifier)) return false; + if (!object.Equals(InteractionType, other.InteractionType)) return false; + if (CriterionCase != other.CriterionCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + if (criterionId_ != null) hash ^= CriterionId.GetHashCode(); + if (bidModifier_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(BidModifier); + if (criterionCase_ == CriterionOneofCase.InteractionType) hash ^= InteractionType.GetHashCode(); + hash ^= (int) criterionCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + if (criterionId_ != null) { + _single_criterionId_codec.WriteTagAndValue(output, CriterionId); + } + if (bidModifier_ != null) { + _single_bidModifier_codec.WriteTagAndValue(output, BidModifier); + } + if (criterionCase_ == CriterionOneofCase.InteractionType) { + output.WriteRawTag(42); + output.WriteMessage(InteractionType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + if (criterionId_ != null) { + size += _single_criterionId_codec.CalculateSizeWithTag(CriterionId); + } + if (bidModifier_ != null) { + size += _single_bidModifier_codec.CalculateSizeWithTag(BidModifier); + } + if (criterionCase_ == CriterionOneofCase.InteractionType) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(InteractionType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignBidModifier other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + if (other.criterionId_ != null) { + if (criterionId_ == null || other.CriterionId != 0L) { + CriterionId = other.CriterionId; + } + } + if (other.bidModifier_ != null) { + if (bidModifier_ == null || other.BidModifier != 0D) { + BidModifier = other.BidModifier; + } + } + switch (other.CriterionCase) { + case CriterionOneofCase.InteractionType: + if (InteractionType == null) { + InteractionType = new global::Google.Ads.GoogleAds.V3.Common.InteractionTypeInfo(); + } + InteractionType.MergeFrom(other.InteractionType); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 26: { + long? value = _single_criterionId_codec.Read(input); + if (criterionId_ == null || value != 0L) { + CriterionId = value; + } + break; + } + case 34: { + double? value = _single_bidModifier_codec.Read(input); + if (bidModifier_ == null || value != 0D) { + BidModifier = value; + } + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Common.InteractionTypeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.InteractionTypeInfo(); + if (criterionCase_ == CriterionOneofCase.InteractionType) { + subBuilder.MergeFrom(InteractionType); + } + input.ReadMessage(subBuilder); + InteractionType = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignBidModifierService.cs b/src/V3/Stubs/CampaignBidModifierService.cs new file mode 100644 index 000000000..cea2de2dc --- /dev/null +++ b/src/V3/Stubs/CampaignBidModifierService.cs @@ -0,0 +1,1038 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_bid_modifier_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_bid_modifier_service.proto + public static partial class CampaignBidModifierServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_bid_modifier_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignBidModifierServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9i", + "aWRfbW9kaWZpZXJfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMaPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcy9jYW1wYWlnbl9iaWRfbW9kaWZpZXIucHJvdG8aHGdvb2dsZS9hcGkv", + "YW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9n", + "b29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9i", + "dWYvZmllbGRfbWFzay5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8i", + "OwodR2V0Q2FtcGFpZ25CaWRNb2RpZmllclJlcXVlc3QSGgoNcmVzb3VyY2Vf", + "bmFtZRgBIAEoCUID4EECIsYBCiFNdXRhdGVDYW1wYWlnbkJpZE1vZGlmaWVy", + "c1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlCA+BBAhJXCgpvcGVyYXRp", + "b25zGAIgAygLMj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "Q2FtcGFpZ25CaWRNb2RpZmllck9wZXJhdGlvbkID4EECEhcKD3BhcnRpYWxf", + "ZmFpbHVyZRgDIAEoCBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIoICChxDYW1w", + "YWlnbkJpZE1vZGlmaWVyT3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAQgASgL", + "MhouZ29vZ2xlLnByb3RvYnVmLkZpZWxkTWFzaxJICgZjcmVhdGUYASABKAsy", + "Ni5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2FtcGFpZ25C", + "aWRNb2RpZmllckgAEkgKBnVwZGF0ZRgCIAEoCzI2Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5DYW1wYWlnbkJpZE1vZGlmaWVySAASEAoG", + "cmVtb3ZlGAMgASgJSABCCwoJb3BlcmF0aW9uIqsBCiJNdXRhdGVDYW1wYWln", + "bkJpZE1vZGlmaWVyc1Jlc3BvbnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJv", + "chgDIAEoCzISLmdvb2dsZS5ycGMuU3RhdHVzElIKB3Jlc3VsdHMYAiADKAsy", + "QS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDYW1w", + "YWlnbkJpZE1vZGlmaWVyUmVzdWx0IjgKH011dGF0ZUNhbXBhaWduQmlkTW9k", + "aWZpZXJSZXN1bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTKmBAoaQ2FtcGFp", + "Z25CaWRNb2RpZmllclNlcnZpY2US4QEKFkdldENhbXBhaWduQmlkTW9kaWZp", + "ZXISPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXRDYW1w", + "YWlnbkJpZE1vZGlmaWVyUmVxdWVzdBo2Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5DYW1wYWlnbkJpZE1vZGlmaWVyIk6C0+STAjgSNi92", + "My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9jYW1wYWlnbkJpZE1vZGlm", + "aWVycy8qfdpBDXJlc291cmNlX25hbWUShgIKGk11dGF0ZUNhbXBhaWduQmlk", + "TW9kaWZpZXJzEkMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "TXV0YXRlQ2FtcGFpZ25CaWRNb2RpZmllcnNSZXF1ZXN0GkQuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ2FtcGFpZ25CaWRNb2Rp", + "ZmllcnNSZXNwb25zZSJdgtPkkwI+IjkvdjMvY3VzdG9tZXJzL3tjdXN0b21l", + "cl9pZD0qfS9jYW1wYWlnbkJpZE1vZGlmaWVyczptdXRhdGU6ASraQRZjdXN0", + "b21lcl9pZCxvcGVyYXRpb25zGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b21ChgIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0If", + "Q2FtcGFpZ25CaWRNb2RpZmllclNlcnZpY2VQcm90b1ABWkhnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "c2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZp", + "Y2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZpY2VzYgZw", + "cm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifierReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBidModifierRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignBidModifierRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifierResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifierResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignBidModifierService.GetCampaignBidModifier][google.ads.googleads.v3.services.CampaignBidModifierService.GetCampaignBidModifier]. + /// + public sealed partial class GetCampaignBidModifierRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignBidModifierRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignBidModifierRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignBidModifierRequest(GetCampaignBidModifierRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignBidModifierRequest Clone() { + return new GetCampaignBidModifierRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign bid modifier to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignBidModifierRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignBidModifierRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignBidModifierRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignBidModifierService.MutateCampaignBidModifier][]. + /// + public sealed partial class MutateCampaignBidModifiersRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignBidModifiersRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifiersRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifiersRequest(MutateCampaignBidModifiersRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifiersRequest Clone() { + return new MutateCampaignBidModifiersRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. ID of the customer whose campaign bid modifiers are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual campaign bid modifiers. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignBidModifiersRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignBidModifiersRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignBidModifiersRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove, update) on a campaign bid modifier. + /// + public sealed partial class CampaignBidModifierOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignBidModifierOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBidModifierOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBidModifierOperation(CampaignBidModifierOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBidModifierOperation Clone() { + return new CampaignBidModifierOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new campaign bid + /// modifier. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The campaign bid modifier is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed campaign bid modifier + /// is expected, in this format: + /// + /// `customers/{customer_id}/CampaignBidModifiers/{campaign_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignBidModifierOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignBidModifierOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignBidModifierOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for campaign bid modifiers mutate. + /// + public sealed partial class MutateCampaignBidModifiersResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignBidModifiersResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifiersResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifiersResponse(MutateCampaignBidModifiersResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifiersResponse Clone() { + return new MutateCampaignBidModifiersResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifierResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignBidModifiersResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignBidModifiersResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignBidModifiersResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the criterion mutate. + /// + public sealed partial class MutateCampaignBidModifierResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignBidModifierResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifierResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifierResult(MutateCampaignBidModifierResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBidModifierResult Clone() { + return new MutateCampaignBidModifierResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignBidModifierResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignBidModifierResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignBidModifierResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignBidModifierServiceClient.cs b/src/V3/Stubs/CampaignBidModifierServiceClient.cs new file mode 100644 index 000000000..1d3351ed5 --- /dev/null +++ b/src/V3/Stubs/CampaignBidModifierServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignBidModifierServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignBidModifierServiceSettings GetDefault() => new CampaignBidModifierServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignBidModifierServiceSettings() { } + + private CampaignBidModifierServiceSettings(CampaignBidModifierServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignBidModifierSettings = existing.GetCampaignBidModifierSettings; + MutateCampaignBidModifiersSettings = existing.MutateCampaignBidModifiersSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignBidModifierServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignBidModifierServiceClient.GetCampaignBidModifier and CampaignBidModifierServiceClient.GetCampaignBidModifierAsync. + /// + /// + /// The default CampaignBidModifierServiceClient.GetCampaignBidModifier and + /// CampaignBidModifierServiceClient.GetCampaignBidModifierAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignBidModifierSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignBidModifierServiceClient.MutateCampaignBidModifiers and CampaignBidModifierServiceClient.MutateCampaignBidModifiersAsync. + /// + /// + /// The default CampaignBidModifierServiceClient.MutateCampaignBidModifiers and + /// CampaignBidModifierServiceClient.MutateCampaignBidModifiersAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignBidModifiersSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignBidModifierServiceSettings Clone() => new CampaignBidModifierServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignBidModifierServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignBidModifierServiceSettings Settings { get; set; } + + /// + public override CampaignBidModifierServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignBidModifierServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignBidModifierServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignBidModifierServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignBidModifierServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignBidModifierServiceClient.ChannelPool; + } + + /// + /// CampaignBidModifierService client wrapper, for convenient use. + /// + public abstract partial class CampaignBidModifierServiceClient + { + /// + /// The default endpoint for the CampaignBidModifierService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignBidModifierService scopes. + /// + /// + /// The default CampaignBidModifierService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignBidModifierServiceClient client = await CampaignBidModifierServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignBidModifierServiceClient.DefaultEndpoint.Host, CampaignBidModifierServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignBidModifierServiceClient client = CampaignBidModifierServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignBidModifierServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignBidModifierServiceClient client = CampaignBidModifierServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignBidModifierServiceClient.DefaultEndpoint.Host, CampaignBidModifierServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignBidModifierServiceClient client = CampaignBidModifierServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignBidModifierServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignBidModifierServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignBidModifierServiceClient Create(grpccore::Channel channel, CampaignBidModifierServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignBidModifierServiceClient Create(grpccore::CallInvoker callInvoker, CampaignBidModifierServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignBidModifierService.CampaignBidModifierServiceClient grpcClient = new CampaignBidModifierService.CampaignBidModifierServiceClient(callInvoker); + return new CampaignBidModifierServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignBidModifierService client. + /// + public virtual CampaignBidModifierService.CampaignBidModifierServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// + /// Required. The resource name of the campaign bid modifier to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignBidModifierAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignBidModifierAsync( + new GetCampaignBidModifierRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// + /// Required. The resource name of the campaign bid modifier to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignBidModifierAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignBidModifierAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// + /// Required. The resource name of the campaign bid modifier to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignBidModifier GetCampaignBidModifier( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignBidModifier( + new GetCampaignBidModifierRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignBidModifierAsync( + GetCampaignBidModifierRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignBidModifierAsync( + GetCampaignBidModifierRequest request, + st::CancellationToken cancellationToken) => GetCampaignBidModifierAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignBidModifier GetCampaignBidModifier( + GetCampaignBidModifierRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign bid modifiers. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBidModifiersAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignBidModifiersAsync( + new MutateCampaignBidModifiersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign bid modifiers. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBidModifiersAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignBidModifiersAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign bid modifiers. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignBidModifiersResponse MutateCampaignBidModifiers( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignBidModifiers( + new MutateCampaignBidModifiersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign bid modifiers. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBidModifiersAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignBidModifiersAsync( + new MutateCampaignBidModifiersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign bid modifiers. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBidModifiersAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignBidModifiersAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign bid modifiers are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign bid modifiers. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignBidModifiersResponse MutateCampaignBidModifiers( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignBidModifiers( + new MutateCampaignBidModifiersRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBidModifiersAsync( + MutateCampaignBidModifiersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBidModifiersAsync( + MutateCampaignBidModifiersRequest request, + st::CancellationToken cancellationToken) => MutateCampaignBidModifiersAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignBidModifiersResponse MutateCampaignBidModifiers( + MutateCampaignBidModifiersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignBidModifierService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignBidModifierServiceClientImpl : CampaignBidModifierServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignBidModifier; + private readonly gaxgrpc::ApiCall _callMutateCampaignBidModifiers; + + /// + /// Constructs a client wrapper for the CampaignBidModifierService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignBidModifierServiceClientImpl(CampaignBidModifierService.CampaignBidModifierServiceClient grpcClient, CampaignBidModifierServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignBidModifierServiceSettings effectiveSettings = settings ?? CampaignBidModifierServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignBidModifier = clientHelper.BuildApiCall( + GrpcClient.GetCampaignBidModifierAsync, GrpcClient.GetCampaignBidModifier, effectiveSettings.GetCampaignBidModifierSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaignBidModifiers = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignBidModifiersAsync, GrpcClient.MutateCampaignBidModifiers, effectiveSettings.MutateCampaignBidModifiersSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCampaignBidModifier); + Modify_GetCampaignBidModifierApiCall(ref _callGetCampaignBidModifier); + Modify_ApiCall(ref _callMutateCampaignBidModifiers); + Modify_MutateCampaignBidModifiersApiCall(ref _callMutateCampaignBidModifiers); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignBidModifierApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignBidModifiersApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignBidModifierService.CampaignBidModifierServiceClient grpcClient, CampaignBidModifierServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignBidModifierService client. + /// + public override CampaignBidModifierService.CampaignBidModifierServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignBidModifierRequest(ref GetCampaignBidModifierRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignBidModifiersRequest(ref MutateCampaignBidModifiersRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignBidModifierAsync( + GetCampaignBidModifierRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignBidModifierRequest(ref request, ref callSettings); + return _callGetCampaignBidModifier.Async(request, callSettings); + } + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignBidModifier GetCampaignBidModifier( + GetCampaignBidModifierRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignBidModifierRequest(ref request, ref callSettings); + return _callGetCampaignBidModifier.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignBidModifiersAsync( + MutateCampaignBidModifiersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignBidModifiersRequest(ref request, ref callSettings); + return _callMutateCampaignBidModifiers.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignBidModifiersResponse MutateCampaignBidModifiers( + MutateCampaignBidModifiersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignBidModifiersRequest(ref request, ref callSettings); + return _callMutateCampaignBidModifiers.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignBidModifierServiceGrpc.cs b/src/V3/Stubs/CampaignBidModifierServiceGrpc.cs new file mode 100644 index 000000000..021f8cff6 --- /dev/null +++ b/src/V3/Stubs/CampaignBidModifierServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_bid_modifier_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaign bid modifiers. + /// + public static partial class CampaignBidModifierService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignBidModifierService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignBidModifierRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignBidModifierRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignBidModifier = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignBidModifiersRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignBidModifiersResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignBidModifier = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignBidModifier", + __Marshaller_google_ads_googleads_v3_services_GetCampaignBidModifierRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignBidModifier); + + static readonly grpc::Method __Method_MutateCampaignBidModifiers = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignBidModifiers", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignBidModifiersRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignBidModifiersResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignBidModifierService + public abstract partial class CampaignBidModifierServiceBase + { + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignBidModifier(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBidModifierRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignBidModifiers(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignBidModifierService + public partial class CampaignBidModifierServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignBidModifierService + /// The channel to use to make remote calls. + public CampaignBidModifierServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignBidModifierService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignBidModifierServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignBidModifierServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignBidModifierServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier GetCampaignBidModifier(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBidModifierRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignBidModifier(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier GetCampaignBidModifier(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBidModifierRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignBidModifier, null, options, request); + } + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignBidModifierAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBidModifierRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignBidModifierAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign bid modifier in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignBidModifierAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBidModifierRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignBidModifier, null, options, request); + } + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersResponse MutateCampaignBidModifiers(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignBidModifiers(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersResponse MutateCampaignBidModifiers(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignBidModifiers, null, options, request); + } + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignBidModifiersAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignBidModifiersAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign bid modifiers. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignBidModifiersAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifiersRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignBidModifiers, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignBidModifierServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignBidModifierServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignBidModifierServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignBidModifier, serviceImpl.GetCampaignBidModifier) + .AddMethod(__Method_MutateCampaignBidModifiers, serviceImpl.MutateCampaignBidModifiers).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignBidModifierServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignBidModifier, serviceImpl.GetCampaignBidModifier); + serviceBinder.AddMethod(__Method_MutateCampaignBidModifiers, serviceImpl.MutateCampaignBidModifiers); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignBudget.cs b/src/V3/Stubs/CampaignBudget.cs new file mode 100644 index 000000000..f11922f33 --- /dev/null +++ b/src/V3/Stubs/CampaignBudget.cs @@ -0,0 +1,846 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_budget.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_budget.proto + public static partial class CampaignBudgetReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_budget.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignBudgetReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "YnVkZ2V0LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMaOmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2J1ZGdldF9kZWxp", + "dmVyeV9tZXRob2QucHJvdG8aMWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vu", + "dW1zL2J1ZGdldF9wZXJpb2QucHJvdG8aMWdvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL2VudW1zL2J1ZGdldF9zdGF0dXMucHJvdG8aL2dvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL2VudW1zL2J1ZGdldF90eXBlLnByb3RvGh9nb29nbGUvYXBp", + "L2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnBy", + "b3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8i3QoKDkNhbXBhaWduQnVkZ2V0EkYKDXJl", + "c291cmNlX25hbWUYASABKAlCL+BBBfpBKQonZ29vZ2xlYWRzLmdvb2dsZWFw", + "aXMuY29tL0NhbXBhaWduQnVkZ2V0EiwKAmlkGAMgASgLMhsuZ29vZ2xlLnBy", + "b3RvYnVmLkludDY0VmFsdWVCA+BBAxIqCgRuYW1lGAQgASgLMhwuZ29vZ2xl", + "LnByb3RvYnVmLlN0cmluZ1ZhbHVlEjIKDWFtb3VudF9taWNyb3MYBSABKAsy", + "Gy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZRI4ChN0b3RhbF9hbW91bnRf", + "bWljcm9zGAogASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUSUQoG", + "c3RhdHVzGAYgASgOMjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMu", + "QnVkZ2V0U3RhdHVzRW51bS5CdWRnZXRTdGF0dXNCA+BBAxJlCg9kZWxpdmVy", + "eV9tZXRob2QYByABKA4yTC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cy5CdWRnZXREZWxpdmVyeU1ldGhvZEVudW0uQnVkZ2V0RGVsaXZlcnlNZXRo", + "b2QSNQoRZXhwbGljaXRseV9zaGFyZWQYCCABKAsyGi5nb29nbGUucHJvdG9i", + "dWYuQm9vbFZhbHVlEjkKD3JlZmVyZW5jZV9jb3VudBgJIAEoCzIbLmdvb2ds", + "ZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSPwoWaGFzX3JlY29tbWVuZGVk", + "X2J1ZGdldBgLIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29sVmFsdWVCA+BB", + "AxJKCiByZWNvbW1lbmRlZF9idWRnZXRfYW1vdW50X21pY3JvcxgMIAEoCzIb", + "Lmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSUQoGcGVyaW9kGA0g", + "ASgOMjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQnVkZ2V0UGVy", + "aW9kRW51bS5CdWRnZXRQZXJpb2RCA+BBBRJbCjFyZWNvbW1lbmRlZF9idWRn", + "ZXRfZXN0aW1hdGVkX2NoYW5nZV93ZWVrbHlfY2xpY2tzGA4gASgLMhsuZ29v", + "Z2xlLnByb3RvYnVmLkludDY0VmFsdWVCA+BBAxJgCjZyZWNvbW1lbmRlZF9i", + "dWRnZXRfZXN0aW1hdGVkX2NoYW5nZV93ZWVrbHlfY29zdF9taWNyb3MYDyAB", + "KAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEmEKN3JlY29t", + "bWVuZGVkX2J1ZGdldF9lc3RpbWF0ZWRfY2hhbmdlX3dlZWtseV9pbnRlcmFj", + "dGlvbnMYECABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EED", + "EloKMHJlY29tbWVuZGVkX2J1ZGdldF9lc3RpbWF0ZWRfY2hhbmdlX3dlZWts", + "eV92aWV3cxgRIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPg", + "QQMSSwoEdHlwZRgSIAEoDjI4Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zLkJ1ZGdldFR5cGVFbnVtLkJ1ZGdldFR5cGVCA+BBBTpk6kFhCidnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2FtcGFpZ25CdWRnZXQSNmN1c3RvbWVy", + "cy97Y3VzdG9tZXJ9L2NhbXBhaWduQnVkZ2V0cy97Y2FtcGFpZ25fYnVkZ2V0", + "fUKAAgolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IT", + "Q2FtcGFpZ25CdWRnZXRQcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5w", + "cm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jl", + "c291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291", + "cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BudgetPeriodReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BudgetStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.BudgetTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget), global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget.Parser, new[]{ "ResourceName", "Id", "Name", "AmountMicros", "TotalAmountMicros", "Status", "DeliveryMethod", "ExplicitlyShared", "ReferenceCount", "HasRecommendedBudget", "RecommendedBudgetAmountMicros", "Period", "RecommendedBudgetEstimatedChangeWeeklyClicks", "RecommendedBudgetEstimatedChangeWeeklyCostMicros", "RecommendedBudgetEstimatedChangeWeeklyInteractions", "RecommendedBudgetEstimatedChangeWeeklyViews", "Type" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A campaign budget. + /// + public sealed partial class CampaignBudget : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignBudget()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignBudgetReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudget() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudget(CampaignBudget other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + AmountMicros = other.AmountMicros; + TotalAmountMicros = other.TotalAmountMicros; + status_ = other.status_; + deliveryMethod_ = other.deliveryMethod_; + ExplicitlyShared = other.ExplicitlyShared; + ReferenceCount = other.ReferenceCount; + HasRecommendedBudget = other.HasRecommendedBudget; + RecommendedBudgetAmountMicros = other.RecommendedBudgetAmountMicros; + period_ = other.period_; + RecommendedBudgetEstimatedChangeWeeklyClicks = other.RecommendedBudgetEstimatedChangeWeeklyClicks; + RecommendedBudgetEstimatedChangeWeeklyCostMicros = other.RecommendedBudgetEstimatedChangeWeeklyCostMicros; + RecommendedBudgetEstimatedChangeWeeklyInteractions = other.RecommendedBudgetEstimatedChangeWeeklyInteractions; + RecommendedBudgetEstimatedChangeWeeklyViews = other.RecommendedBudgetEstimatedChangeWeeklyViews; + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudget Clone() { + return new CampaignBudget(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign budget. + /// Campaign budget resource names have the form: + /// + /// `customers/{customer_id}/campaignBudgets/{budget_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the campaign budget. + /// + /// A campaign budget is created using the CampaignBudgetService create + /// operation and is assigned a budget ID. A budget ID can be shared across + /// different campaigns; the system will then allocate the campaign budget + /// among different campaigns to get optimum results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// The name of the campaign budget. + /// + /// When creating a campaign budget through CampaignBudgetService, every + /// explicitly shared campaign budget must have a non-null, non-empty name. + /// Campaign budgets that are not explicitly shared derive their name from the + /// attached campaign's name. + /// + /// The length of this string must be between 1 and 255, inclusive, + /// in UTF-8 bytes, (trimmed). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "amount_micros" field. + public const int AmountMicrosFieldNumber = 5; + private static readonly pb::FieldCodec _single_amountMicros_codec = pb::FieldCodec.ForStructWrapper(42); + private long? amountMicros_; + /// + /// The amount of the budget, in the local currency for the account. + /// Amount is specified in micros, where one million is equivalent to one + /// currency unit. Monthly spend is capped at 30.4 times this amount. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AmountMicros { + get { return amountMicros_; } + set { + amountMicros_ = value; + } + } + + + /// Field number for the "total_amount_micros" field. + public const int TotalAmountMicrosFieldNumber = 10; + private static readonly pb::FieldCodec _single_totalAmountMicros_codec = pb::FieldCodec.ForStructWrapper(82); + private long? totalAmountMicros_; + /// + /// The lifetime amount of the budget, in the local currency for the account. + /// Amount is specified in micros, where one million is equivalent to one + /// currency unit. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TotalAmountMicros { + get { return totalAmountMicros_; } + set { + totalAmountMicros_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.BudgetStatusEnum.Types.BudgetStatus status_ = 0; + /// + /// Output only. The status of this campaign budget. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BudgetStatusEnum.Types.BudgetStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "delivery_method" field. + public const int DeliveryMethodFieldNumber = 7; + private global::Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod deliveryMethod_ = 0; + /// + /// The delivery method that determines the rate at which the campaign budget + /// is spent. + /// + /// Defaults to STANDARD if unspecified in a create operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod DeliveryMethod { + get { return deliveryMethod_; } + set { + deliveryMethod_ = value; + } + } + + /// Field number for the "explicitly_shared" field. + public const int ExplicitlySharedFieldNumber = 8; + private static readonly pb::FieldCodec _single_explicitlyShared_codec = pb::FieldCodec.ForStructWrapper(66); + private bool? explicitlyShared_; + /// + /// Specifies whether the budget is explicitly shared. Defaults to true if + /// unspecified in a create operation. + /// + /// If true, the budget was created with the purpose of sharing + /// across one or more campaigns. + /// + /// If false, the budget was created with the intention of only being used + /// with a single campaign. The budget's name and status will stay in sync + /// with the campaign's name and status. Attempting to share the budget with a + /// second campaign will result in an error. + /// + /// A non-shared budget can become an explicitly shared. The same operation + /// must also assign the budget a name. + /// + /// A shared campaign budget can never become non-shared. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? ExplicitlyShared { + get { return explicitlyShared_; } + set { + explicitlyShared_ = value; + } + } + + + /// Field number for the "reference_count" field. + public const int ReferenceCountFieldNumber = 9; + private static readonly pb::FieldCodec _single_referenceCount_codec = pb::FieldCodec.ForStructWrapper(74); + private long? referenceCount_; + /// + /// Output only. The number of campaigns actively using the budget. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ReferenceCount { + get { return referenceCount_; } + set { + referenceCount_ = value; + } + } + + + /// Field number for the "has_recommended_budget" field. + public const int HasRecommendedBudgetFieldNumber = 11; + private static readonly pb::FieldCodec _single_hasRecommendedBudget_codec = pb::FieldCodec.ForStructWrapper(90); + private bool? hasRecommendedBudget_; + /// + /// Output only. Indicates whether there is a recommended budget for this campaign budget. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? HasRecommendedBudget { + get { return hasRecommendedBudget_; } + set { + hasRecommendedBudget_ = value; + } + } + + + /// Field number for the "recommended_budget_amount_micros" field. + public const int RecommendedBudgetAmountMicrosFieldNumber = 12; + private static readonly pb::FieldCodec _single_recommendedBudgetAmountMicros_codec = pb::FieldCodec.ForStructWrapper(98); + private long? recommendedBudgetAmountMicros_; + /// + /// Output only. The recommended budget amount. If no recommendation is available, this will + /// be set to the budget amount. + /// Amount is specified in micros, where one million is equivalent to one + /// currency unit. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? RecommendedBudgetAmountMicros { + get { return recommendedBudgetAmountMicros_; } + set { + recommendedBudgetAmountMicros_ = value; + } + } + + + /// Field number for the "period" field. + public const int PeriodFieldNumber = 13; + private global::Google.Ads.GoogleAds.V3.Enums.BudgetPeriodEnum.Types.BudgetPeriod period_ = 0; + /// + /// Immutable. Period over which to spend the budget. Defaults to DAILY if not specified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BudgetPeriodEnum.Types.BudgetPeriod Period { + get { return period_; } + set { + period_ = value; + } + } + + /// Field number for the "recommended_budget_estimated_change_weekly_clicks" field. + public const int RecommendedBudgetEstimatedChangeWeeklyClicksFieldNumber = 14; + private static readonly pb::FieldCodec _single_recommendedBudgetEstimatedChangeWeeklyClicks_codec = pb::FieldCodec.ForStructWrapper(114); + private long? recommendedBudgetEstimatedChangeWeeklyClicks_; + /// + /// Output only. The estimated change in weekly clicks if the recommended budget is applied. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? RecommendedBudgetEstimatedChangeWeeklyClicks { + get { return recommendedBudgetEstimatedChangeWeeklyClicks_; } + set { + recommendedBudgetEstimatedChangeWeeklyClicks_ = value; + } + } + + + /// Field number for the "recommended_budget_estimated_change_weekly_cost_micros" field. + public const int RecommendedBudgetEstimatedChangeWeeklyCostMicrosFieldNumber = 15; + private static readonly pb::FieldCodec _single_recommendedBudgetEstimatedChangeWeeklyCostMicros_codec = pb::FieldCodec.ForStructWrapper(122); + private long? recommendedBudgetEstimatedChangeWeeklyCostMicros_; + /// + /// Output only. The estimated change in weekly cost in micros if the recommended budget is + /// applied. One million is equivalent to one currency unit. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? RecommendedBudgetEstimatedChangeWeeklyCostMicros { + get { return recommendedBudgetEstimatedChangeWeeklyCostMicros_; } + set { + recommendedBudgetEstimatedChangeWeeklyCostMicros_ = value; + } + } + + + /// Field number for the "recommended_budget_estimated_change_weekly_interactions" field. + public const int RecommendedBudgetEstimatedChangeWeeklyInteractionsFieldNumber = 16; + private static readonly pb::FieldCodec _single_recommendedBudgetEstimatedChangeWeeklyInteractions_codec = pb::FieldCodec.ForStructWrapper(130); + private long? recommendedBudgetEstimatedChangeWeeklyInteractions_; + /// + /// Output only. The estimated change in weekly interactions if the recommended budget is + /// applied. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? RecommendedBudgetEstimatedChangeWeeklyInteractions { + get { return recommendedBudgetEstimatedChangeWeeklyInteractions_; } + set { + recommendedBudgetEstimatedChangeWeeklyInteractions_ = value; + } + } + + + /// Field number for the "recommended_budget_estimated_change_weekly_views" field. + public const int RecommendedBudgetEstimatedChangeWeeklyViewsFieldNumber = 17; + private static readonly pb::FieldCodec _single_recommendedBudgetEstimatedChangeWeeklyViews_codec = pb::FieldCodec.ForStructWrapper(138); + private long? recommendedBudgetEstimatedChangeWeeklyViews_; + /// + /// Output only. The estimated change in weekly views if the recommended budget is applied. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? RecommendedBudgetEstimatedChangeWeeklyViews { + get { return recommendedBudgetEstimatedChangeWeeklyViews_; } + set { + recommendedBudgetEstimatedChangeWeeklyViews_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 18; + private global::Google.Ads.GoogleAds.V3.Enums.BudgetTypeEnum.Types.BudgetType type_ = 0; + /// + /// Immutable. The type of the campaign budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.BudgetTypeEnum.Types.BudgetType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignBudget); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignBudget other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (AmountMicros != other.AmountMicros) return false; + if (TotalAmountMicros != other.TotalAmountMicros) return false; + if (Status != other.Status) return false; + if (DeliveryMethod != other.DeliveryMethod) return false; + if (ExplicitlyShared != other.ExplicitlyShared) return false; + if (ReferenceCount != other.ReferenceCount) return false; + if (HasRecommendedBudget != other.HasRecommendedBudget) return false; + if (RecommendedBudgetAmountMicros != other.RecommendedBudgetAmountMicros) return false; + if (Period != other.Period) return false; + if (RecommendedBudgetEstimatedChangeWeeklyClicks != other.RecommendedBudgetEstimatedChangeWeeklyClicks) return false; + if (RecommendedBudgetEstimatedChangeWeeklyCostMicros != other.RecommendedBudgetEstimatedChangeWeeklyCostMicros) return false; + if (RecommendedBudgetEstimatedChangeWeeklyInteractions != other.RecommendedBudgetEstimatedChangeWeeklyInteractions) return false; + if (RecommendedBudgetEstimatedChangeWeeklyViews != other.RecommendedBudgetEstimatedChangeWeeklyViews) return false; + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (amountMicros_ != null) hash ^= AmountMicros.GetHashCode(); + if (totalAmountMicros_ != null) hash ^= TotalAmountMicros.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (DeliveryMethod != 0) hash ^= DeliveryMethod.GetHashCode(); + if (explicitlyShared_ != null) hash ^= ExplicitlyShared.GetHashCode(); + if (referenceCount_ != null) hash ^= ReferenceCount.GetHashCode(); + if (hasRecommendedBudget_ != null) hash ^= HasRecommendedBudget.GetHashCode(); + if (recommendedBudgetAmountMicros_ != null) hash ^= RecommendedBudgetAmountMicros.GetHashCode(); + if (Period != 0) hash ^= Period.GetHashCode(); + if (recommendedBudgetEstimatedChangeWeeklyClicks_ != null) hash ^= RecommendedBudgetEstimatedChangeWeeklyClicks.GetHashCode(); + if (recommendedBudgetEstimatedChangeWeeklyCostMicros_ != null) hash ^= RecommendedBudgetEstimatedChangeWeeklyCostMicros.GetHashCode(); + if (recommendedBudgetEstimatedChangeWeeklyInteractions_ != null) hash ^= RecommendedBudgetEstimatedChangeWeeklyInteractions.GetHashCode(); + if (recommendedBudgetEstimatedChangeWeeklyViews_ != null) hash ^= RecommendedBudgetEstimatedChangeWeeklyViews.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (amountMicros_ != null) { + _single_amountMicros_codec.WriteTagAndValue(output, AmountMicros); + } + if (Status != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) Status); + } + if (DeliveryMethod != 0) { + output.WriteRawTag(56); + output.WriteEnum((int) DeliveryMethod); + } + if (explicitlyShared_ != null) { + _single_explicitlyShared_codec.WriteTagAndValue(output, ExplicitlyShared); + } + if (referenceCount_ != null) { + _single_referenceCount_codec.WriteTagAndValue(output, ReferenceCount); + } + if (totalAmountMicros_ != null) { + _single_totalAmountMicros_codec.WriteTagAndValue(output, TotalAmountMicros); + } + if (hasRecommendedBudget_ != null) { + _single_hasRecommendedBudget_codec.WriteTagAndValue(output, HasRecommendedBudget); + } + if (recommendedBudgetAmountMicros_ != null) { + _single_recommendedBudgetAmountMicros_codec.WriteTagAndValue(output, RecommendedBudgetAmountMicros); + } + if (Period != 0) { + output.WriteRawTag(104); + output.WriteEnum((int) Period); + } + if (recommendedBudgetEstimatedChangeWeeklyClicks_ != null) { + _single_recommendedBudgetEstimatedChangeWeeklyClicks_codec.WriteTagAndValue(output, RecommendedBudgetEstimatedChangeWeeklyClicks); + } + if (recommendedBudgetEstimatedChangeWeeklyCostMicros_ != null) { + _single_recommendedBudgetEstimatedChangeWeeklyCostMicros_codec.WriteTagAndValue(output, RecommendedBudgetEstimatedChangeWeeklyCostMicros); + } + if (recommendedBudgetEstimatedChangeWeeklyInteractions_ != null) { + _single_recommendedBudgetEstimatedChangeWeeklyInteractions_codec.WriteTagAndValue(output, RecommendedBudgetEstimatedChangeWeeklyInteractions); + } + if (recommendedBudgetEstimatedChangeWeeklyViews_ != null) { + _single_recommendedBudgetEstimatedChangeWeeklyViews_codec.WriteTagAndValue(output, RecommendedBudgetEstimatedChangeWeeklyViews); + } + if (Type != 0) { + output.WriteRawTag(144, 1); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (amountMicros_ != null) { + size += _single_amountMicros_codec.CalculateSizeWithTag(AmountMicros); + } + if (totalAmountMicros_ != null) { + size += _single_totalAmountMicros_codec.CalculateSizeWithTag(TotalAmountMicros); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (DeliveryMethod != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DeliveryMethod); + } + if (explicitlyShared_ != null) { + size += _single_explicitlyShared_codec.CalculateSizeWithTag(ExplicitlyShared); + } + if (referenceCount_ != null) { + size += _single_referenceCount_codec.CalculateSizeWithTag(ReferenceCount); + } + if (hasRecommendedBudget_ != null) { + size += _single_hasRecommendedBudget_codec.CalculateSizeWithTag(HasRecommendedBudget); + } + if (recommendedBudgetAmountMicros_ != null) { + size += _single_recommendedBudgetAmountMicros_codec.CalculateSizeWithTag(RecommendedBudgetAmountMicros); + } + if (Period != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Period); + } + if (recommendedBudgetEstimatedChangeWeeklyClicks_ != null) { + size += _single_recommendedBudgetEstimatedChangeWeeklyClicks_codec.CalculateSizeWithTag(RecommendedBudgetEstimatedChangeWeeklyClicks); + } + if (recommendedBudgetEstimatedChangeWeeklyCostMicros_ != null) { + size += _single_recommendedBudgetEstimatedChangeWeeklyCostMicros_codec.CalculateSizeWithTag(RecommendedBudgetEstimatedChangeWeeklyCostMicros); + } + if (recommendedBudgetEstimatedChangeWeeklyInteractions_ != null) { + size += _single_recommendedBudgetEstimatedChangeWeeklyInteractions_codec.CalculateSizeWithTag(RecommendedBudgetEstimatedChangeWeeklyInteractions); + } + if (recommendedBudgetEstimatedChangeWeeklyViews_ != null) { + size += _single_recommendedBudgetEstimatedChangeWeeklyViews_codec.CalculateSizeWithTag(RecommendedBudgetEstimatedChangeWeeklyViews); + } + if (Type != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignBudget other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.amountMicros_ != null) { + if (amountMicros_ == null || other.AmountMicros != 0L) { + AmountMicros = other.AmountMicros; + } + } + if (other.totalAmountMicros_ != null) { + if (totalAmountMicros_ == null || other.TotalAmountMicros != 0L) { + TotalAmountMicros = other.TotalAmountMicros; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.DeliveryMethod != 0) { + DeliveryMethod = other.DeliveryMethod; + } + if (other.explicitlyShared_ != null) { + if (explicitlyShared_ == null || other.ExplicitlyShared != false) { + ExplicitlyShared = other.ExplicitlyShared; + } + } + if (other.referenceCount_ != null) { + if (referenceCount_ == null || other.ReferenceCount != 0L) { + ReferenceCount = other.ReferenceCount; + } + } + if (other.hasRecommendedBudget_ != null) { + if (hasRecommendedBudget_ == null || other.HasRecommendedBudget != false) { + HasRecommendedBudget = other.HasRecommendedBudget; + } + } + if (other.recommendedBudgetAmountMicros_ != null) { + if (recommendedBudgetAmountMicros_ == null || other.RecommendedBudgetAmountMicros != 0L) { + RecommendedBudgetAmountMicros = other.RecommendedBudgetAmountMicros; + } + } + if (other.Period != 0) { + Period = other.Period; + } + if (other.recommendedBudgetEstimatedChangeWeeklyClicks_ != null) { + if (recommendedBudgetEstimatedChangeWeeklyClicks_ == null || other.RecommendedBudgetEstimatedChangeWeeklyClicks != 0L) { + RecommendedBudgetEstimatedChangeWeeklyClicks = other.RecommendedBudgetEstimatedChangeWeeklyClicks; + } + } + if (other.recommendedBudgetEstimatedChangeWeeklyCostMicros_ != null) { + if (recommendedBudgetEstimatedChangeWeeklyCostMicros_ == null || other.RecommendedBudgetEstimatedChangeWeeklyCostMicros != 0L) { + RecommendedBudgetEstimatedChangeWeeklyCostMicros = other.RecommendedBudgetEstimatedChangeWeeklyCostMicros; + } + } + if (other.recommendedBudgetEstimatedChangeWeeklyInteractions_ != null) { + if (recommendedBudgetEstimatedChangeWeeklyInteractions_ == null || other.RecommendedBudgetEstimatedChangeWeeklyInteractions != 0L) { + RecommendedBudgetEstimatedChangeWeeklyInteractions = other.RecommendedBudgetEstimatedChangeWeeklyInteractions; + } + } + if (other.recommendedBudgetEstimatedChangeWeeklyViews_ != null) { + if (recommendedBudgetEstimatedChangeWeeklyViews_ == null || other.RecommendedBudgetEstimatedChangeWeeklyViews != 0L) { + RecommendedBudgetEstimatedChangeWeeklyViews = other.RecommendedBudgetEstimatedChangeWeeklyViews; + } + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 42: { + long? value = _single_amountMicros_codec.Read(input); + if (amountMicros_ == null || value != 0L) { + AmountMicros = value; + } + break; + } + case 48: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.BudgetStatusEnum.Types.BudgetStatus) input.ReadEnum(); + break; + } + case 56: { + DeliveryMethod = (global::Google.Ads.GoogleAds.V3.Enums.BudgetDeliveryMethodEnum.Types.BudgetDeliveryMethod) input.ReadEnum(); + break; + } + case 66: { + bool? value = _single_explicitlyShared_codec.Read(input); + if (explicitlyShared_ == null || value != false) { + ExplicitlyShared = value; + } + break; + } + case 74: { + long? value = _single_referenceCount_codec.Read(input); + if (referenceCount_ == null || value != 0L) { + ReferenceCount = value; + } + break; + } + case 82: { + long? value = _single_totalAmountMicros_codec.Read(input); + if (totalAmountMicros_ == null || value != 0L) { + TotalAmountMicros = value; + } + break; + } + case 90: { + bool? value = _single_hasRecommendedBudget_codec.Read(input); + if (hasRecommendedBudget_ == null || value != false) { + HasRecommendedBudget = value; + } + break; + } + case 98: { + long? value = _single_recommendedBudgetAmountMicros_codec.Read(input); + if (recommendedBudgetAmountMicros_ == null || value != 0L) { + RecommendedBudgetAmountMicros = value; + } + break; + } + case 104: { + Period = (global::Google.Ads.GoogleAds.V3.Enums.BudgetPeriodEnum.Types.BudgetPeriod) input.ReadEnum(); + break; + } + case 114: { + long? value = _single_recommendedBudgetEstimatedChangeWeeklyClicks_codec.Read(input); + if (recommendedBudgetEstimatedChangeWeeklyClicks_ == null || value != 0L) { + RecommendedBudgetEstimatedChangeWeeklyClicks = value; + } + break; + } + case 122: { + long? value = _single_recommendedBudgetEstimatedChangeWeeklyCostMicros_codec.Read(input); + if (recommendedBudgetEstimatedChangeWeeklyCostMicros_ == null || value != 0L) { + RecommendedBudgetEstimatedChangeWeeklyCostMicros = value; + } + break; + } + case 130: { + long? value = _single_recommendedBudgetEstimatedChangeWeeklyInteractions_codec.Read(input); + if (recommendedBudgetEstimatedChangeWeeklyInteractions_ == null || value != 0L) { + RecommendedBudgetEstimatedChangeWeeklyInteractions = value; + } + break; + } + case 138: { + long? value = _single_recommendedBudgetEstimatedChangeWeeklyViews_codec.Read(input); + if (recommendedBudgetEstimatedChangeWeeklyViews_ == null || value != 0L) { + RecommendedBudgetEstimatedChangeWeeklyViews = value; + } + break; + } + case 144: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.BudgetTypeEnum.Types.BudgetType) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignBudgetError.cs b/src/V3/Stubs/CampaignBudgetError.cs new file mode 100644 index 000000000..8ee13b13b --- /dev/null +++ b/src/V3/Stubs/CampaignBudgetError.cs @@ -0,0 +1,256 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/campaign_budget_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/campaign_budget_error.proto + public static partial class CampaignBudgetErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/campaign_budget_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignBudgetErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2FtcGFpZ25fYnVk", + "Z2V0X2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJv", + "cnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i4AUKF0NhbXBhaWdu", + "QnVkZ2V0RXJyb3JFbnVtIsQFChNDYW1wYWlnbkJ1ZGdldEVycm9yEg8KC1VO", + "U1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEiQKIENBTVBBSUdOX0JVREdFVF9D", + "QU5OT1RfQkVfU0hBUkVEEBESGwoXQ0FNUEFJR05fQlVER0VUX1JFTU9WRUQQ", + "AhIaChZDQU1QQUlHTl9CVURHRVRfSU5fVVNFEAMSKAokQ0FNUEFJR05fQlVE", + "R0VUX1BFUklPRF9OT1RfQVZBSUxBQkxFEAQSPAo4Q0FOTk9UX01PRElGWV9G", + "SUVMRF9PRl9JTVBMSUNJVExZX1NIQVJFRF9DQU1QQUlHTl9CVURHRVQQBhI2", + "CjJDQU5OT1RfVVBEQVRFX0NBTVBBSUdOX0JVREdFVF9UT19JTVBMSUNJVExZ", + "X1NIQVJFRBAHEkMKP0NBTk5PVF9VUERBVEVfQ0FNUEFJR05fQlVER0VUX1RP", + "X0VYUExJQ0lUTFlfU0hBUkVEX1dJVEhPVVRfTkFNRRAIEjYKMkNBTk5PVF9V", + "UERBVEVfQ0FNUEFJR05fQlVER0VUX1RPX0VYUExJQ0lUTFlfU0hBUkVEEAkS", + "SApEQ0FOTk9UX1VTRV9JTVBMSUNJVExZX1NIQVJFRF9DQU1QQUlHTl9CVURH", + "RVRfV0lUSF9NVUxUSVBMRV9DQU1QQUlHTlMQChISCg5EVVBMSUNBVEVfTkFN", + "RRALEiIKHk1PTkVZX0FNT1VOVF9JTl9XUk9OR19DVVJSRU5DWRAMEi8KK01P", + "TkVZX0FNT1VOVF9MRVNTX1RIQU5fQ1VSUkVOQ1lfTUlOSU1VTV9DUEMQDRIa", + "ChZNT05FWV9BTU9VTlRfVE9PX0xBUkdFEA4SGQoVTkVHQVRJVkVfTU9ORVlf", + "QU1PVU5UEA8SKQolTk9OX01VTFRJUExFX09GX01JTklNVU1fQ1VSUkVOQ1lf", + "VU5JVBAQQvMBCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "QhhDYW1wYWlnbkJ1ZGdldEVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5v", + "cmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9y", + "cztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJv", + "cnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignBudgetErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CampaignBudgetErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignBudgetErrorEnum.Types.CampaignBudgetError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible campaign budget errors. + /// + public sealed partial class CampaignBudgetErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignBudgetErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CampaignBudgetErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudgetErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudgetErrorEnum(CampaignBudgetErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudgetErrorEnum Clone() { + return new CampaignBudgetErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignBudgetErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignBudgetErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignBudgetErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignBudgetErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible campaign budget errors. + /// + public enum CampaignBudgetError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The campaign budget cannot be shared. + /// + [pbr::OriginalName("CAMPAIGN_BUDGET_CANNOT_BE_SHARED")] CampaignBudgetCannotBeShared = 17, + /// + /// The requested campaign budget no longer exists. + /// + [pbr::OriginalName("CAMPAIGN_BUDGET_REMOVED")] CampaignBudgetRemoved = 2, + /// + /// The campaign budget is associated with at least one campaign, and so the + /// campaign budget cannot be removed. + /// + [pbr::OriginalName("CAMPAIGN_BUDGET_IN_USE")] CampaignBudgetInUse = 3, + /// + /// Customer is not whitelisted for this campaign budget period. + /// + [pbr::OriginalName("CAMPAIGN_BUDGET_PERIOD_NOT_AVAILABLE")] CampaignBudgetPeriodNotAvailable = 4, + /// + /// This field is not mutable on implicitly shared campaign budgets + /// + [pbr::OriginalName("CANNOT_MODIFY_FIELD_OF_IMPLICITLY_SHARED_CAMPAIGN_BUDGET")] CannotModifyFieldOfImplicitlySharedCampaignBudget = 6, + /// + /// Cannot change explicitly shared campaign budgets back to implicitly + /// shared ones. + /// + [pbr::OriginalName("CANNOT_UPDATE_CAMPAIGN_BUDGET_TO_IMPLICITLY_SHARED")] CannotUpdateCampaignBudgetToImplicitlyShared = 7, + /// + /// An implicit campaign budget without a name cannot be changed to + /// explicitly shared campaign budget. + /// + [pbr::OriginalName("CANNOT_UPDATE_CAMPAIGN_BUDGET_TO_EXPLICITLY_SHARED_WITHOUT_NAME")] CannotUpdateCampaignBudgetToExplicitlySharedWithoutName = 8, + /// + /// Cannot change an implicitly shared campaign budget to an explicitly + /// shared one. + /// + [pbr::OriginalName("CANNOT_UPDATE_CAMPAIGN_BUDGET_TO_EXPLICITLY_SHARED")] CannotUpdateCampaignBudgetToExplicitlyShared = 9, + /// + /// Only explicitly shared campaign budgets can be used with multiple + /// campaigns. + /// + [pbr::OriginalName("CANNOT_USE_IMPLICITLY_SHARED_CAMPAIGN_BUDGET_WITH_MULTIPLE_CAMPAIGNS")] CannotUseImplicitlySharedCampaignBudgetWithMultipleCampaigns = 10, + /// + /// A campaign budget with this name already exists. + /// + [pbr::OriginalName("DUPLICATE_NAME")] DuplicateName = 11, + /// + /// A money amount was not in the expected currency. + /// + [pbr::OriginalName("MONEY_AMOUNT_IN_WRONG_CURRENCY")] MoneyAmountInWrongCurrency = 12, + /// + /// A money amount was less than the minimum CPC for currency. + /// + [pbr::OriginalName("MONEY_AMOUNT_LESS_THAN_CURRENCY_MINIMUM_CPC")] MoneyAmountLessThanCurrencyMinimumCpc = 13, + /// + /// A money amount was greater than the maximum allowed. + /// + [pbr::OriginalName("MONEY_AMOUNT_TOO_LARGE")] MoneyAmountTooLarge = 14, + /// + /// A money amount was negative. + /// + [pbr::OriginalName("NEGATIVE_MONEY_AMOUNT")] NegativeMoneyAmount = 15, + /// + /// A money amount was not a multiple of a minimum unit. + /// + [pbr::OriginalName("NON_MULTIPLE_OF_MINIMUM_CURRENCY_UNIT")] NonMultipleOfMinimumCurrencyUnit = 16, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignBudgetService.cs b/src/V3/Stubs/CampaignBudgetService.cs new file mode 100644 index 000000000..351e1095d --- /dev/null +++ b/src/V3/Stubs/CampaignBudgetService.cs @@ -0,0 +1,1034 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_budget_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_budget_service.proto + public static partial class CampaignBudgetServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_budget_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignBudgetServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9i", + "dWRnZXRfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXMaN2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9j", + "YW1wYWlnbl9idWRnZXQucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMu", + "cHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2Zp", + "ZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9idWYvZmllbGRfbWFz", + "ay5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8iNgoYR2V0Q2FtcGFp", + "Z25CdWRnZXRSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiK8", + "AQocTXV0YXRlQ2FtcGFpZ25CdWRnZXRzUmVxdWVzdBIYCgtjdXN0b21lcl9p", + "ZBgBIAEoCUID4EECElIKCm9wZXJhdGlvbnMYAiADKAsyOS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlcy5DYW1wYWlnbkJ1ZGdldE9wZXJhdGlv", + "bkID4EECEhcKD3BhcnRpYWxfZmFpbHVyZRgDIAEoCBIVCg12YWxpZGF0ZV9v", + "bmx5GAQgASgIIvMBChdDYW1wYWlnbkJ1ZGdldE9wZXJhdGlvbhIvCgt1cGRh", + "dGVfbWFzaxgEIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5GaWVsZE1hc2sSQwoG", + "Y3JlYXRlGAEgASgLMjEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkNhbXBhaWduQnVkZ2V0SAASQwoGdXBkYXRlGAIgASgLMjEuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduQnVkZ2V0SAAS", + "EAoGcmVtb3ZlGAMgASgJSABCCwoJb3BlcmF0aW9uIqEBCh1NdXRhdGVDYW1w", + "YWlnbkJ1ZGdldHNSZXNwb25zZRIxChVwYXJ0aWFsX2ZhaWx1cmVfZXJyb3IY", + "AyABKAsyEi5nb29nbGUucnBjLlN0YXR1cxJNCgdyZXN1bHRzGAIgAygLMjwu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ2FtcGFp", + "Z25CdWRnZXRSZXN1bHQiMwoaTXV0YXRlQ2FtcGFpZ25CdWRnZXRSZXN1bHQS", + "FQoNcmVzb3VyY2VfbmFtZRgBIAEoCTL5AwoVQ2FtcGFpZ25CdWRnZXRTZXJ2", + "aWNlEs0BChFHZXRDYW1wYWlnbkJ1ZGdldBI6Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzLkdldENhbXBhaWduQnVkZ2V0UmVxdWVzdBoxLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DYW1wYWlnbkJ1ZGdl", + "dCJJgtPkkwIzEjEvdjMve3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovY2Ft", + "cGFpZ25CdWRnZXRzLyp92kENcmVzb3VyY2VfbmFtZRLyAQoVTXV0YXRlQ2Ft", + "cGFpZ25CdWRnZXRzEj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuTXV0YXRlQ2FtcGFpZ25CdWRnZXRzUmVxdWVzdBo/Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUNhbXBhaWduQnVkZ2V0c1Jl", + "c3BvbnNlIliC0+STAjkiNC92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9", + "L2NhbXBhaWduQnVkZ2V0czptdXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVy", + "YXRpb25zGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21CgQIKJGNvbS5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0IaQ2FtcGFpZ25CdWRn", + "ZXRTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8v", + "Z29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2Vz", + "ogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBH", + "b29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignBudgetReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBudgetRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignBudgetRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignBudgetService.GetCampaignBudget][google.ads.googleads.v3.services.CampaignBudgetService.GetCampaignBudget]. + /// + public sealed partial class GetCampaignBudgetRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignBudgetRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignBudgetRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignBudgetRequest(GetCampaignBudgetRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignBudgetRequest Clone() { + return new GetCampaignBudgetRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign budget to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignBudgetRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignBudgetRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignBudgetRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignBudgetService.MutateCampaignBudgets][google.ads.googleads.v3.services.CampaignBudgetService.MutateCampaignBudgets]. + /// + public sealed partial class MutateCampaignBudgetsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignBudgetsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetsRequest(MutateCampaignBudgetsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetsRequest Clone() { + return new MutateCampaignBudgetsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose campaign budgets are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual campaign budgets. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignBudgetsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignBudgetsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignBudgetsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a campaign budget. + /// + public sealed partial class CampaignBudgetOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignBudgetOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudgetOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudgetOperation(CampaignBudgetOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignBudgetOperation Clone() { + return new CampaignBudgetOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The campaign budget is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed budget is expected, in + /// this format: + /// + /// `customers/{customer_id}/campaignBudgets/{budget_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignBudgetOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignBudgetOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignBudgetOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for campaign budget mutate. + /// + public sealed partial class MutateCampaignBudgetsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignBudgetsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetsResponse(MutateCampaignBudgetsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetsResponse Clone() { + return new MutateCampaignBudgetsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignBudgetsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignBudgetsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignBudgetsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the campaign budget mutate. + /// + public sealed partial class MutateCampaignBudgetResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignBudgetResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetResult(MutateCampaignBudgetResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignBudgetResult Clone() { + return new MutateCampaignBudgetResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignBudgetResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignBudgetResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignBudgetResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignBudgetServiceClient.cs b/src/V3/Stubs/CampaignBudgetServiceClient.cs new file mode 100644 index 000000000..3d924dac0 --- /dev/null +++ b/src/V3/Stubs/CampaignBudgetServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignBudgetServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignBudgetServiceSettings GetDefault() => new CampaignBudgetServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignBudgetServiceSettings() { } + + private CampaignBudgetServiceSettings(CampaignBudgetServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignBudgetSettings = existing.GetCampaignBudgetSettings; + MutateCampaignBudgetsSettings = existing.MutateCampaignBudgetsSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignBudgetServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignBudgetServiceClient.GetCampaignBudget and CampaignBudgetServiceClient.GetCampaignBudgetAsync. + /// + /// + /// The default CampaignBudgetServiceClient.GetCampaignBudget and + /// CampaignBudgetServiceClient.GetCampaignBudgetAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignBudgetSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignBudgetServiceClient.MutateCampaignBudgets and CampaignBudgetServiceClient.MutateCampaignBudgetsAsync. + /// + /// + /// The default CampaignBudgetServiceClient.MutateCampaignBudgets and + /// CampaignBudgetServiceClient.MutateCampaignBudgetsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignBudgetsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignBudgetServiceSettings Clone() => new CampaignBudgetServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignBudgetServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignBudgetServiceSettings Settings { get; set; } + + /// + public override CampaignBudgetServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignBudgetServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignBudgetServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignBudgetServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignBudgetServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignBudgetServiceClient.ChannelPool; + } + + /// + /// CampaignBudgetService client wrapper, for convenient use. + /// + public abstract partial class CampaignBudgetServiceClient + { + /// + /// The default endpoint for the CampaignBudgetService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignBudgetService scopes. + /// + /// + /// The default CampaignBudgetService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignBudgetServiceClient client = await CampaignBudgetServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignBudgetServiceClient.DefaultEndpoint.Host, CampaignBudgetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignBudgetServiceClient client = CampaignBudgetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignBudgetServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignBudgetServiceClient client = CampaignBudgetServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignBudgetServiceClient.DefaultEndpoint.Host, CampaignBudgetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignBudgetServiceClient client = CampaignBudgetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignBudgetServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignBudgetServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignBudgetServiceClient Create(grpccore::Channel channel, CampaignBudgetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignBudgetServiceClient Create(grpccore::CallInvoker callInvoker, CampaignBudgetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignBudgetService.CampaignBudgetServiceClient grpcClient = new CampaignBudgetService.CampaignBudgetServiceClient(callInvoker); + return new CampaignBudgetServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignBudgetService client. + /// + public virtual CampaignBudgetService.CampaignBudgetServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// + /// Required. The resource name of the campaign budget to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignBudgetAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignBudgetAsync( + new GetCampaignBudgetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// + /// Required. The resource name of the campaign budget to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignBudgetAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignBudgetAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// + /// Required. The resource name of the campaign budget to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignBudget GetCampaignBudget( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignBudget( + new GetCampaignBudgetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignBudgetAsync( + GetCampaignBudgetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignBudgetAsync( + GetCampaignBudgetRequest request, + st::CancellationToken cancellationToken) => GetCampaignBudgetAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignBudget GetCampaignBudget( + GetCampaignBudgetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign budgets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign budgets. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBudgetsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignBudgetsAsync( + new MutateCampaignBudgetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign budgets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign budgets. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBudgetsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignBudgetsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign budgets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign budgets. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignBudgetsResponse MutateCampaignBudgets( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignBudgets( + new MutateCampaignBudgetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign budgets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign budgets. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBudgetsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignBudgetsAsync( + new MutateCampaignBudgetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign budgets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign budgets. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBudgetsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignBudgetsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign budgets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign budgets. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignBudgetsResponse MutateCampaignBudgets( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignBudgets( + new MutateCampaignBudgetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBudgetsAsync( + MutateCampaignBudgetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignBudgetsAsync( + MutateCampaignBudgetsRequest request, + st::CancellationToken cancellationToken) => MutateCampaignBudgetsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignBudgetsResponse MutateCampaignBudgets( + MutateCampaignBudgetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignBudgetService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignBudgetServiceClientImpl : CampaignBudgetServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignBudget; + private readonly gaxgrpc::ApiCall _callMutateCampaignBudgets; + + /// + /// Constructs a client wrapper for the CampaignBudgetService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignBudgetServiceClientImpl(CampaignBudgetService.CampaignBudgetServiceClient grpcClient, CampaignBudgetServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignBudgetServiceSettings effectiveSettings = settings ?? CampaignBudgetServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignBudget = clientHelper.BuildApiCall( + GrpcClient.GetCampaignBudgetAsync, GrpcClient.GetCampaignBudget, effectiveSettings.GetCampaignBudgetSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaignBudgets = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignBudgetsAsync, GrpcClient.MutateCampaignBudgets, effectiveSettings.MutateCampaignBudgetsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCampaignBudget); + Modify_GetCampaignBudgetApiCall(ref _callGetCampaignBudget); + Modify_ApiCall(ref _callMutateCampaignBudgets); + Modify_MutateCampaignBudgetsApiCall(ref _callMutateCampaignBudgets); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignBudgetApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignBudgetsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignBudgetService.CampaignBudgetServiceClient grpcClient, CampaignBudgetServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignBudgetService client. + /// + public override CampaignBudgetService.CampaignBudgetServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignBudgetRequest(ref GetCampaignBudgetRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignBudgetsRequest(ref MutateCampaignBudgetsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignBudgetAsync( + GetCampaignBudgetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignBudgetRequest(ref request, ref callSettings); + return _callGetCampaignBudget.Async(request, callSettings); + } + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignBudget GetCampaignBudget( + GetCampaignBudgetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignBudgetRequest(ref request, ref callSettings); + return _callGetCampaignBudget.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignBudgetsAsync( + MutateCampaignBudgetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignBudgetsRequest(ref request, ref callSettings); + return _callMutateCampaignBudgets.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignBudgetsResponse MutateCampaignBudgets( + MutateCampaignBudgetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignBudgetsRequest(ref request, ref callSettings); + return _callMutateCampaignBudgets.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignBudgetServiceGrpc.cs b/src/V3/Stubs/CampaignBudgetServiceGrpc.cs new file mode 100644 index 000000000..033ea7079 --- /dev/null +++ b/src/V3/Stubs/CampaignBudgetServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_budget_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaign budgets. + /// + public static partial class CampaignBudgetService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignBudgetService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignBudgetRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignBudgetRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignBudget = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignBudgetsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignBudgetsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignBudget = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignBudget", + __Marshaller_google_ads_googleads_v3_services_GetCampaignBudgetRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignBudget); + + static readonly grpc::Method __Method_MutateCampaignBudgets = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignBudgets", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignBudgetsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignBudgetsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignBudgetService + public abstract partial class CampaignBudgetServiceBase + { + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignBudget(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBudgetRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignBudgets(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignBudgetService + public partial class CampaignBudgetServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignBudgetService + /// The channel to use to make remote calls. + public CampaignBudgetServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignBudgetService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignBudgetServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignBudgetServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignBudgetServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget GetCampaignBudget(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBudgetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignBudget(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget GetCampaignBudget(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBudgetRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignBudget, null, options, request); + } + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignBudgetAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBudgetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignBudgetAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Campaign Budget in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignBudgetAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignBudgetRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignBudget, null, options, request); + } + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsResponse MutateCampaignBudgets(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignBudgets(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsResponse MutateCampaignBudgets(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignBudgets, null, options, request); + } + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignBudgetsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignBudgetsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign budgets. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignBudgetsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignBudgets, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignBudgetServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignBudgetServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignBudgetServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignBudget, serviceImpl.GetCampaignBudget) + .AddMethod(__Method_MutateCampaignBudgets, serviceImpl.MutateCampaignBudgets).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignBudgetServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignBudget, serviceImpl.GetCampaignBudget); + serviceBinder.AddMethod(__Method_MutateCampaignBudgets, serviceImpl.MutateCampaignBudgets); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignCriterion.cs b/src/V3/Stubs/CampaignCriterion.cs new file mode 100644 index 000000000..548d9cb58 --- /dev/null +++ b/src/V3/Stubs/CampaignCriterion.cs @@ -0,0 +1,1628 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_criterion.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_criterion.proto + public static partial class CampaignCriterionReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_criterion.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignCriterionReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "Y3JpdGVyaW9uLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNv", + "dXJjZXMaLWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9jcml0ZXJp", + "YS5wcm90bxo9Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvY2FtcGFp", + "Z25fY3JpdGVyaW9uX3N0YXR1cy5wcm90bxoyZ29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvZW51bXMvY3JpdGVyaW9uX3R5cGUucHJvdG8aH2dvb2dsZS9hcGkv", + "ZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJv", + "dG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90byKmFQoRQ2FtcGFpZ25Dcml0ZXJpb24SSQoN", + "cmVzb3VyY2VfbmFtZRgBIAEoCUIy4EEF+kEsCipnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vQ2FtcGFpZ25Dcml0ZXJpb24SWQoIY2FtcGFpZ24YBCABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCKeBBBfpBIwohZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tL0NhbXBhaWduEjYKDGNyaXRlcmlvbl9pZBgF", + "IAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSMQoMYmlk", + "X21vZGlmaWVyGA4gASgLMhsuZ29vZ2xlLnByb3RvYnVmLkZsb2F0VmFsdWUS", + "MQoIbmVnYXRpdmUYByABKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVl", + "QgPgQQUSUQoEdHlwZRgGIAEoDjI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zLkNyaXRlcmlvblR5cGVFbnVtLkNyaXRlcmlvblR5cGVCA+BBAxJi", + "CgZzdGF0dXMYIyABKA4yUi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cy5DYW1wYWlnbkNyaXRlcmlvblN0YXR1c0VudW0uQ2FtcGFpZ25Dcml0ZXJp", + "b25TdGF0dXMSQwoHa2V5d29yZBgIIAEoCzIrLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmNvbW1vbi5LZXl3b3JkSW5mb0ID4EEFSAASRwoJcGxhY2VtZW50", + "GAkgASgLMi0uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLlBsYWNl", + "bWVudEluZm9CA+BBBUgAElkKE21vYmlsZV9hcHBfY2F0ZWdvcnkYCiABKAsy", + "NS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uTW9iaWxlQXBwQ2F0", + "ZWdvcnlJbmZvQgPgQQVIABJYChJtb2JpbGVfYXBwbGljYXRpb24YCyABKAsy", + "NS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uTW9iaWxlQXBwbGlj", + "YXRpb25JbmZvQgPgQQVIABJFCghsb2NhdGlvbhgMIAEoCzIsLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Mb2NhdGlvbkluZm9CA+BBBUgAEkEK", + "BmRldmljZRgNIAEoCzIqLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1v", + "bi5EZXZpY2VJbmZvQgPgQQVIABJKCgthZF9zY2hlZHVsZRgPIAEoCzIuLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZFNjaGVkdWxlSW5mb0ID", + "4EEFSAASRgoJYWdlX3JhbmdlGBAgASgLMiwuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuY29tbW9uLkFnZVJhbmdlSW5mb0ID4EEFSAASQQoGZ2VuZGVyGBEg", + "ASgLMiouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkdlbmRlcklu", + "Zm9CA+BBBUgAEkwKDGluY29tZV9yYW5nZRgSIAEoCzIvLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmNvbW1vbi5JbmNvbWVSYW5nZUluZm9CA+BBBUgAElIK", + "D3BhcmVudGFsX3N0YXR1cxgTIAEoCzIyLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmNvbW1vbi5QYXJlbnRhbFN0YXR1c0luZm9CA+BBBUgAEkYKCXVzZXJf", + "bGlzdBgWIAEoCzIsLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5V", + "c2VyTGlzdEluZm9CA+BBBUgAEk4KDXlvdXR1YmVfdmlkZW8YFCABKAsyMC5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uWW91VHViZVZpZGVvSW5m", + "b0ID4EEFSAASUgoPeW91dHViZV9jaGFubmVsGBUgASgLMjIuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuY29tbW9uLllvdVR1YmVDaGFubmVsSW5mb0ID4EEF", + "SAASRwoJcHJveGltaXR5GBcgASgLMi0uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuY29tbW9uLlByb3hpbWl0eUluZm9CA+BBBUgAEj8KBXRvcGljGBggASgL", + "MikuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLlRvcGljSW5mb0ID", + "4EEFSAASTgoNbGlzdGluZ19zY29wZRgZIAEoCzIwLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmNvbW1vbi5MaXN0aW5nU2NvcGVJbmZvQgPgQQVIABJFCghs", + "YW5ndWFnZRgaIAEoCzIsLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1v", + "bi5MYW5ndWFnZUluZm9CA+BBBUgAEkQKCGlwX2Jsb2NrGBsgASgLMisuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLklwQmxvY2tJbmZvQgPgQQVI", + "ABJOCg1jb250ZW50X2xhYmVsGBwgASgLMjAuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuY29tbW9uLkNvbnRlbnRMYWJlbEluZm9CA+BBBUgAEkMKB2NhcnJp", + "ZXIYHSABKAsyKy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQ2Fy", + "cmllckluZm9CA+BBBUgAEk4KDXVzZXJfaW50ZXJlc3QYHiABKAsyMC5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uVXNlckludGVyZXN0SW5mb0ID", + "4EEFSAASQwoHd2VicGFnZRgfIAEoCzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmNvbW1vbi5XZWJwYWdlSW5mb0ID4EEFSAASYwoYb3BlcmF0aW5nX3N5", + "c3RlbV92ZXJzaW9uGCAgASgLMjouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "Y29tbW9uLk9wZXJhdGluZ1N5c3RlbVZlcnNpb25JbmZvQgPgQQVIABJOCg1t", + "b2JpbGVfZGV2aWNlGCEgASgLMjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "Y29tbW9uLk1vYmlsZURldmljZUluZm9CA+BBBUgAElAKDmxvY2F0aW9uX2dy", + "b3VwGCIgASgLMjEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkxv", + "Y2F0aW9uR3JvdXBJbmZvQgPgQQVIABJSCg9jdXN0b21fYWZmaW5pdHkYJCAB", + "KAsyMi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQ3VzdG9tQWZm", + "aW5pdHlJbmZvQgPgQQVIADpr6kFoCipnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b20vQ2FtcGFpZ25Dcml0ZXJpb24SOmN1c3RvbWVycy97Y3VzdG9tZXJ9L2Nh", + "bXBhaWduQ3JpdGVyaWEve2NhbXBhaWduX2NyaXRlcmlvbn1CCwoJY3JpdGVy", + "aW9uQoMCCiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "QhZDYW1wYWlnbkNyaXRlcmlvblByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXM7cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMu", + "UmVzb3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz", + "6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJv", + "dG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CampaignCriterionStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion), global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion.Parser, new[]{ "ResourceName", "Campaign", "CriterionId", "BidModifier", "Negative", "Type", "Status", "Keyword", "Placement", "MobileAppCategory", "MobileApplication", "Location", "Device", "AdSchedule", "AgeRange", "Gender", "IncomeRange", "ParentalStatus", "UserList", "YoutubeVideo", "YoutubeChannel", "Proximity", "Topic", "ListingScope", "Language", "IpBlock", "ContentLabel", "Carrier", "UserInterest", "Webpage", "OperatingSystemVersion", "MobileDevice", "LocationGroup", "CustomAffinity" }, new[]{ "Criterion" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A campaign criterion. + /// + public sealed partial class CampaignCriterion : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignCriterion()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterion() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterion(CampaignCriterion other) : this() { + resourceName_ = other.resourceName_; + Campaign = other.Campaign; + CriterionId = other.CriterionId; + BidModifier = other.BidModifier; + Negative = other.Negative; + type_ = other.type_; + status_ = other.status_; + switch (other.CriterionCase) { + case CriterionOneofCase.Keyword: + Keyword = other.Keyword.Clone(); + break; + case CriterionOneofCase.Placement: + Placement = other.Placement.Clone(); + break; + case CriterionOneofCase.MobileAppCategory: + MobileAppCategory = other.MobileAppCategory.Clone(); + break; + case CriterionOneofCase.MobileApplication: + MobileApplication = other.MobileApplication.Clone(); + break; + case CriterionOneofCase.Location: + Location = other.Location.Clone(); + break; + case CriterionOneofCase.Device: + Device = other.Device.Clone(); + break; + case CriterionOneofCase.AdSchedule: + AdSchedule = other.AdSchedule.Clone(); + break; + case CriterionOneofCase.AgeRange: + AgeRange = other.AgeRange.Clone(); + break; + case CriterionOneofCase.Gender: + Gender = other.Gender.Clone(); + break; + case CriterionOneofCase.IncomeRange: + IncomeRange = other.IncomeRange.Clone(); + break; + case CriterionOneofCase.ParentalStatus: + ParentalStatus = other.ParentalStatus.Clone(); + break; + case CriterionOneofCase.UserList: + UserList = other.UserList.Clone(); + break; + case CriterionOneofCase.YoutubeVideo: + YoutubeVideo = other.YoutubeVideo.Clone(); + break; + case CriterionOneofCase.YoutubeChannel: + YoutubeChannel = other.YoutubeChannel.Clone(); + break; + case CriterionOneofCase.Proximity: + Proximity = other.Proximity.Clone(); + break; + case CriterionOneofCase.Topic: + Topic = other.Topic.Clone(); + break; + case CriterionOneofCase.ListingScope: + ListingScope = other.ListingScope.Clone(); + break; + case CriterionOneofCase.Language: + Language = other.Language.Clone(); + break; + case CriterionOneofCase.IpBlock: + IpBlock = other.IpBlock.Clone(); + break; + case CriterionOneofCase.ContentLabel: + ContentLabel = other.ContentLabel.Clone(); + break; + case CriterionOneofCase.Carrier: + Carrier = other.Carrier.Clone(); + break; + case CriterionOneofCase.UserInterest: + UserInterest = other.UserInterest.Clone(); + break; + case CriterionOneofCase.Webpage: + Webpage = other.Webpage.Clone(); + break; + case CriterionOneofCase.OperatingSystemVersion: + OperatingSystemVersion = other.OperatingSystemVersion.Clone(); + break; + case CriterionOneofCase.MobileDevice: + MobileDevice = other.MobileDevice.Clone(); + break; + case CriterionOneofCase.LocationGroup: + LocationGroup = other.LocationGroup.Clone(); + break; + case CriterionOneofCase.CustomAffinity: + CustomAffinity = other.CustomAffinity.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterion Clone() { + return new CampaignCriterion(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign criterion. + /// Campaign criterion resource names have the form: + /// + /// `customers/{customer_id}/campaignCriteria/{campaign_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 4; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(34); + private string campaign_; + /// + /// Immutable. The campaign to which the criterion belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "criterion_id" field. + public const int CriterionIdFieldNumber = 5; + private static readonly pb::FieldCodec _single_criterionId_codec = pb::FieldCodec.ForStructWrapper(42); + private long? criterionId_; + /// + /// Output only. The ID of the criterion. + /// + /// This field is ignored during mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CriterionId { + get { return criterionId_; } + set { + criterionId_ = value; + } + } + + + /// Field number for the "bid_modifier" field. + public const int BidModifierFieldNumber = 14; + private static readonly pb::FieldCodec _single_bidModifier_codec = pb::FieldCodec.ForStructWrapper(114); + private float? bidModifier_; + /// + /// The modifier for the bids when the criterion matches. The modifier must be + /// in the range: 0.1 - 10.0. Most targetable criteria types support modifiers. + /// Use 0 to opt out of a Device type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public float? BidModifier { + get { return bidModifier_; } + set { + bidModifier_ = value; + } + } + + + /// Field number for the "negative" field. + public const int NegativeFieldNumber = 7; + private static readonly pb::FieldCodec _single_negative_codec = pb::FieldCodec.ForStructWrapper(58); + private bool? negative_; + /// + /// Immutable. Whether to target (`false`) or exclude (`true`) the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Negative { + get { return negative_; } + set { + negative_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType type_ = 0; + /// + /// Output only. The type of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 35; + private global::Google.Ads.GoogleAds.V3.Enums.CampaignCriterionStatusEnum.Types.CampaignCriterionStatus status_ = 0; + /// + /// The status of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CampaignCriterionStatusEnum.Types.CampaignCriterionStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "keyword" field. + public const int KeywordFieldNumber = 8; + /// + /// Immutable. Keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.KeywordInfo Keyword { + get { return criterionCase_ == CriterionOneofCase.Keyword ? (global::Google.Ads.GoogleAds.V3.Common.KeywordInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Keyword; + } + } + + /// Field number for the "placement" field. + public const int PlacementFieldNumber = 9; + /// + /// Immutable. Placement. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PlacementInfo Placement { + get { return criterionCase_ == CriterionOneofCase.Placement ? (global::Google.Ads.GoogleAds.V3.Common.PlacementInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Placement; + } + } + + /// Field number for the "mobile_app_category" field. + public const int MobileAppCategoryFieldNumber = 10; + /// + /// Immutable. Mobile app category. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo MobileAppCategory { + get { return criterionCase_ == CriterionOneofCase.MobileAppCategory ? (global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.MobileAppCategory; + } + } + + /// Field number for the "mobile_application" field. + public const int MobileApplicationFieldNumber = 11; + /// + /// Immutable. Mobile application. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo MobileApplication { + get { return criterionCase_ == CriterionOneofCase.MobileApplication ? (global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.MobileApplication; + } + } + + /// Field number for the "location" field. + public const int LocationFieldNumber = 12; + /// + /// Immutable. Location. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.LocationInfo Location { + get { return criterionCase_ == CriterionOneofCase.Location ? (global::Google.Ads.GoogleAds.V3.Common.LocationInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Location; + } + } + + /// Field number for the "device" field. + public const int DeviceFieldNumber = 13; + /// + /// Immutable. Device. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.DeviceInfo Device { + get { return criterionCase_ == CriterionOneofCase.Device ? (global::Google.Ads.GoogleAds.V3.Common.DeviceInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Device; + } + } + + /// Field number for the "ad_schedule" field. + public const int AdScheduleFieldNumber = 15; + /// + /// Immutable. Ad Schedule. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo AdSchedule { + get { return criterionCase_ == CriterionOneofCase.AdSchedule ? (global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.AdSchedule; + } + } + + /// Field number for the "age_range" field. + public const int AgeRangeFieldNumber = 16; + /// + /// Immutable. Age range. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo AgeRange { + get { return criterionCase_ == CriterionOneofCase.AgeRange ? (global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.AgeRange; + } + } + + /// Field number for the "gender" field. + public const int GenderFieldNumber = 17; + /// + /// Immutable. Gender. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.GenderInfo Gender { + get { return criterionCase_ == CriterionOneofCase.Gender ? (global::Google.Ads.GoogleAds.V3.Common.GenderInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Gender; + } + } + + /// Field number for the "income_range" field. + public const int IncomeRangeFieldNumber = 18; + /// + /// Immutable. Income range. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo IncomeRange { + get { return criterionCase_ == CriterionOneofCase.IncomeRange ? (global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.IncomeRange; + } + } + + /// Field number for the "parental_status" field. + public const int ParentalStatusFieldNumber = 19; + /// + /// Immutable. Parental status. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo ParentalStatus { + get { return criterionCase_ == CriterionOneofCase.ParentalStatus ? (global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.ParentalStatus; + } + } + + /// Field number for the "user_list" field. + public const int UserListFieldNumber = 22; + /// + /// Immutable. User List. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.UserListInfo UserList { + get { return criterionCase_ == CriterionOneofCase.UserList ? (global::Google.Ads.GoogleAds.V3.Common.UserListInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.UserList; + } + } + + /// Field number for the "youtube_video" field. + public const int YoutubeVideoFieldNumber = 20; + /// + /// Immutable. YouTube Video. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo YoutubeVideo { + get { return criterionCase_ == CriterionOneofCase.YoutubeVideo ? (global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.YoutubeVideo; + } + } + + /// Field number for the "youtube_channel" field. + public const int YoutubeChannelFieldNumber = 21; + /// + /// Immutable. YouTube Channel. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo YoutubeChannel { + get { return criterionCase_ == CriterionOneofCase.YoutubeChannel ? (global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.YoutubeChannel; + } + } + + /// Field number for the "proximity" field. + public const int ProximityFieldNumber = 23; + /// + /// Immutable. Proximity. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProximityInfo Proximity { + get { return criterionCase_ == CriterionOneofCase.Proximity ? (global::Google.Ads.GoogleAds.V3.Common.ProximityInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Proximity; + } + } + + /// Field number for the "topic" field. + public const int TopicFieldNumber = 24; + /// + /// Immutable. Topic. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TopicInfo Topic { + get { return criterionCase_ == CriterionOneofCase.Topic ? (global::Google.Ads.GoogleAds.V3.Common.TopicInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Topic; + } + } + + /// Field number for the "listing_scope" field. + public const int ListingScopeFieldNumber = 25; + /// + /// Immutable. Listing scope. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ListingScopeInfo ListingScope { + get { return criterionCase_ == CriterionOneofCase.ListingScope ? (global::Google.Ads.GoogleAds.V3.Common.ListingScopeInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.ListingScope; + } + } + + /// Field number for the "language" field. + public const int LanguageFieldNumber = 26; + /// + /// Immutable. Language. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.LanguageInfo Language { + get { return criterionCase_ == CriterionOneofCase.Language ? (global::Google.Ads.GoogleAds.V3.Common.LanguageInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Language; + } + } + + /// Field number for the "ip_block" field. + public const int IpBlockFieldNumber = 27; + /// + /// Immutable. IpBlock. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.IpBlockInfo IpBlock { + get { return criterionCase_ == CriterionOneofCase.IpBlock ? (global::Google.Ads.GoogleAds.V3.Common.IpBlockInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.IpBlock; + } + } + + /// Field number for the "content_label" field. + public const int ContentLabelFieldNumber = 28; + /// + /// Immutable. ContentLabel. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo ContentLabel { + get { return criterionCase_ == CriterionOneofCase.ContentLabel ? (global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.ContentLabel; + } + } + + /// Field number for the "carrier" field. + public const int CarrierFieldNumber = 29; + /// + /// Immutable. Carrier. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CarrierInfo Carrier { + get { return criterionCase_ == CriterionOneofCase.Carrier ? (global::Google.Ads.GoogleAds.V3.Common.CarrierInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Carrier; + } + } + + /// Field number for the "user_interest" field. + public const int UserInterestFieldNumber = 30; + /// + /// Immutable. User Interest. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo UserInterest { + get { return criterionCase_ == CriterionOneofCase.UserInterest ? (global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.UserInterest; + } + } + + /// Field number for the "webpage" field. + public const int WebpageFieldNumber = 31; + /// + /// Immutable. Webpage. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.WebpageInfo Webpage { + get { return criterionCase_ == CriterionOneofCase.Webpage ? (global::Google.Ads.GoogleAds.V3.Common.WebpageInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Webpage; + } + } + + /// Field number for the "operating_system_version" field. + public const int OperatingSystemVersionFieldNumber = 32; + /// + /// Immutable. Operating system version. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.OperatingSystemVersionInfo OperatingSystemVersion { + get { return criterionCase_ == CriterionOneofCase.OperatingSystemVersion ? (global::Google.Ads.GoogleAds.V3.Common.OperatingSystemVersionInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.OperatingSystemVersion; + } + } + + /// Field number for the "mobile_device" field. + public const int MobileDeviceFieldNumber = 33; + /// + /// Immutable. Mobile Device. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MobileDeviceInfo MobileDevice { + get { return criterionCase_ == CriterionOneofCase.MobileDevice ? (global::Google.Ads.GoogleAds.V3.Common.MobileDeviceInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.MobileDevice; + } + } + + /// Field number for the "location_group" field. + public const int LocationGroupFieldNumber = 34; + /// + /// Immutable. Location Group + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.LocationGroupInfo LocationGroup { + get { return criterionCase_ == CriterionOneofCase.LocationGroup ? (global::Google.Ads.GoogleAds.V3.Common.LocationGroupInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.LocationGroup; + } + } + + /// Field number for the "custom_affinity" field. + public const int CustomAffinityFieldNumber = 36; + /// + /// Immutable. Custom Affinity. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo CustomAffinity { + get { return criterionCase_ == CriterionOneofCase.CustomAffinity ? (global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.CustomAffinity; + } + } + + private object criterion_; + /// Enum of possible cases for the "criterion" oneof. + public enum CriterionOneofCase { + None = 0, + Keyword = 8, + Placement = 9, + MobileAppCategory = 10, + MobileApplication = 11, + Location = 12, + Device = 13, + AdSchedule = 15, + AgeRange = 16, + Gender = 17, + IncomeRange = 18, + ParentalStatus = 19, + UserList = 22, + YoutubeVideo = 20, + YoutubeChannel = 21, + Proximity = 23, + Topic = 24, + ListingScope = 25, + Language = 26, + IpBlock = 27, + ContentLabel = 28, + Carrier = 29, + UserInterest = 30, + Webpage = 31, + OperatingSystemVersion = 32, + MobileDevice = 33, + LocationGroup = 34, + CustomAffinity = 36, + } + private CriterionOneofCase criterionCase_ = CriterionOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionOneofCase CriterionCase { + get { return criterionCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearCriterion() { + criterionCase_ = CriterionOneofCase.None; + criterion_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignCriterion); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignCriterion other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Campaign != other.Campaign) return false; + if (CriterionId != other.CriterionId) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableSingleEqualityComparer.Equals(BidModifier, other.BidModifier)) return false; + if (Negative != other.Negative) return false; + if (Type != other.Type) return false; + if (Status != other.Status) return false; + if (!object.Equals(Keyword, other.Keyword)) return false; + if (!object.Equals(Placement, other.Placement)) return false; + if (!object.Equals(MobileAppCategory, other.MobileAppCategory)) return false; + if (!object.Equals(MobileApplication, other.MobileApplication)) return false; + if (!object.Equals(Location, other.Location)) return false; + if (!object.Equals(Device, other.Device)) return false; + if (!object.Equals(AdSchedule, other.AdSchedule)) return false; + if (!object.Equals(AgeRange, other.AgeRange)) return false; + if (!object.Equals(Gender, other.Gender)) return false; + if (!object.Equals(IncomeRange, other.IncomeRange)) return false; + if (!object.Equals(ParentalStatus, other.ParentalStatus)) return false; + if (!object.Equals(UserList, other.UserList)) return false; + if (!object.Equals(YoutubeVideo, other.YoutubeVideo)) return false; + if (!object.Equals(YoutubeChannel, other.YoutubeChannel)) return false; + if (!object.Equals(Proximity, other.Proximity)) return false; + if (!object.Equals(Topic, other.Topic)) return false; + if (!object.Equals(ListingScope, other.ListingScope)) return false; + if (!object.Equals(Language, other.Language)) return false; + if (!object.Equals(IpBlock, other.IpBlock)) return false; + if (!object.Equals(ContentLabel, other.ContentLabel)) return false; + if (!object.Equals(Carrier, other.Carrier)) return false; + if (!object.Equals(UserInterest, other.UserInterest)) return false; + if (!object.Equals(Webpage, other.Webpage)) return false; + if (!object.Equals(OperatingSystemVersion, other.OperatingSystemVersion)) return false; + if (!object.Equals(MobileDevice, other.MobileDevice)) return false; + if (!object.Equals(LocationGroup, other.LocationGroup)) return false; + if (!object.Equals(CustomAffinity, other.CustomAffinity)) return false; + if (CriterionCase != other.CriterionCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + if (criterionId_ != null) hash ^= CriterionId.GetHashCode(); + if (bidModifier_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableSingleEqualityComparer.GetHashCode(BidModifier); + if (negative_ != null) hash ^= Negative.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Keyword) hash ^= Keyword.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Placement) hash ^= Placement.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) hash ^= MobileAppCategory.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.MobileApplication) hash ^= MobileApplication.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Location) hash ^= Location.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Device) hash ^= Device.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.AdSchedule) hash ^= AdSchedule.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.AgeRange) hash ^= AgeRange.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Gender) hash ^= Gender.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.IncomeRange) hash ^= IncomeRange.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.ParentalStatus) hash ^= ParentalStatus.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.UserList) hash ^= UserList.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) hash ^= YoutubeVideo.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) hash ^= YoutubeChannel.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Proximity) hash ^= Proximity.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Topic) hash ^= Topic.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.ListingScope) hash ^= ListingScope.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Language) hash ^= Language.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.IpBlock) hash ^= IpBlock.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.ContentLabel) hash ^= ContentLabel.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Carrier) hash ^= Carrier.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.UserInterest) hash ^= UserInterest.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Webpage) hash ^= Webpage.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.OperatingSystemVersion) hash ^= OperatingSystemVersion.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.MobileDevice) hash ^= MobileDevice.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.LocationGroup) hash ^= LocationGroup.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.CustomAffinity) hash ^= CustomAffinity.GetHashCode(); + hash ^= (int) criterionCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + if (criterionId_ != null) { + _single_criterionId_codec.WriteTagAndValue(output, CriterionId); + } + if (Type != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) Type); + } + if (negative_ != null) { + _single_negative_codec.WriteTagAndValue(output, Negative); + } + if (criterionCase_ == CriterionOneofCase.Keyword) { + output.WriteRawTag(66); + output.WriteMessage(Keyword); + } + if (criterionCase_ == CriterionOneofCase.Placement) { + output.WriteRawTag(74); + output.WriteMessage(Placement); + } + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + output.WriteRawTag(82); + output.WriteMessage(MobileAppCategory); + } + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + output.WriteRawTag(90); + output.WriteMessage(MobileApplication); + } + if (criterionCase_ == CriterionOneofCase.Location) { + output.WriteRawTag(98); + output.WriteMessage(Location); + } + if (criterionCase_ == CriterionOneofCase.Device) { + output.WriteRawTag(106); + output.WriteMessage(Device); + } + if (bidModifier_ != null) { + _single_bidModifier_codec.WriteTagAndValue(output, BidModifier); + } + if (criterionCase_ == CriterionOneofCase.AdSchedule) { + output.WriteRawTag(122); + output.WriteMessage(AdSchedule); + } + if (criterionCase_ == CriterionOneofCase.AgeRange) { + output.WriteRawTag(130, 1); + output.WriteMessage(AgeRange); + } + if (criterionCase_ == CriterionOneofCase.Gender) { + output.WriteRawTag(138, 1); + output.WriteMessage(Gender); + } + if (criterionCase_ == CriterionOneofCase.IncomeRange) { + output.WriteRawTag(146, 1); + output.WriteMessage(IncomeRange); + } + if (criterionCase_ == CriterionOneofCase.ParentalStatus) { + output.WriteRawTag(154, 1); + output.WriteMessage(ParentalStatus); + } + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + output.WriteRawTag(162, 1); + output.WriteMessage(YoutubeVideo); + } + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + output.WriteRawTag(170, 1); + output.WriteMessage(YoutubeChannel); + } + if (criterionCase_ == CriterionOneofCase.UserList) { + output.WriteRawTag(178, 1); + output.WriteMessage(UserList); + } + if (criterionCase_ == CriterionOneofCase.Proximity) { + output.WriteRawTag(186, 1); + output.WriteMessage(Proximity); + } + if (criterionCase_ == CriterionOneofCase.Topic) { + output.WriteRawTag(194, 1); + output.WriteMessage(Topic); + } + if (criterionCase_ == CriterionOneofCase.ListingScope) { + output.WriteRawTag(202, 1); + output.WriteMessage(ListingScope); + } + if (criterionCase_ == CriterionOneofCase.Language) { + output.WriteRawTag(210, 1); + output.WriteMessage(Language); + } + if (criterionCase_ == CriterionOneofCase.IpBlock) { + output.WriteRawTag(218, 1); + output.WriteMessage(IpBlock); + } + if (criterionCase_ == CriterionOneofCase.ContentLabel) { + output.WriteRawTag(226, 1); + output.WriteMessage(ContentLabel); + } + if (criterionCase_ == CriterionOneofCase.Carrier) { + output.WriteRawTag(234, 1); + output.WriteMessage(Carrier); + } + if (criterionCase_ == CriterionOneofCase.UserInterest) { + output.WriteRawTag(242, 1); + output.WriteMessage(UserInterest); + } + if (criterionCase_ == CriterionOneofCase.Webpage) { + output.WriteRawTag(250, 1); + output.WriteMessage(Webpage); + } + if (criterionCase_ == CriterionOneofCase.OperatingSystemVersion) { + output.WriteRawTag(130, 2); + output.WriteMessage(OperatingSystemVersion); + } + if (criterionCase_ == CriterionOneofCase.MobileDevice) { + output.WriteRawTag(138, 2); + output.WriteMessage(MobileDevice); + } + if (criterionCase_ == CriterionOneofCase.LocationGroup) { + output.WriteRawTag(146, 2); + output.WriteMessage(LocationGroup); + } + if (Status != 0) { + output.WriteRawTag(152, 2); + output.WriteEnum((int) Status); + } + if (criterionCase_ == CriterionOneofCase.CustomAffinity) { + output.WriteRawTag(162, 2); + output.WriteMessage(CustomAffinity); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + if (criterionId_ != null) { + size += _single_criterionId_codec.CalculateSizeWithTag(CriterionId); + } + if (bidModifier_ != null) { + size += _single_bidModifier_codec.CalculateSizeWithTag(BidModifier); + } + if (negative_ != null) { + size += _single_negative_codec.CalculateSizeWithTag(Negative); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (Status != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (criterionCase_ == CriterionOneofCase.Keyword) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Keyword); + } + if (criterionCase_ == CriterionOneofCase.Placement) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Placement); + } + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MobileAppCategory); + } + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MobileApplication); + } + if (criterionCase_ == CriterionOneofCase.Location) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Location); + } + if (criterionCase_ == CriterionOneofCase.Device) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Device); + } + if (criterionCase_ == CriterionOneofCase.AdSchedule) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdSchedule); + } + if (criterionCase_ == CriterionOneofCase.AgeRange) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AgeRange); + } + if (criterionCase_ == CriterionOneofCase.Gender) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Gender); + } + if (criterionCase_ == CriterionOneofCase.IncomeRange) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(IncomeRange); + } + if (criterionCase_ == CriterionOneofCase.ParentalStatus) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ParentalStatus); + } + if (criterionCase_ == CriterionOneofCase.UserList) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserList); + } + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(YoutubeVideo); + } + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(YoutubeChannel); + } + if (criterionCase_ == CriterionOneofCase.Proximity) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Proximity); + } + if (criterionCase_ == CriterionOneofCase.Topic) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Topic); + } + if (criterionCase_ == CriterionOneofCase.ListingScope) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ListingScope); + } + if (criterionCase_ == CriterionOneofCase.Language) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Language); + } + if (criterionCase_ == CriterionOneofCase.IpBlock) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(IpBlock); + } + if (criterionCase_ == CriterionOneofCase.ContentLabel) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ContentLabel); + } + if (criterionCase_ == CriterionOneofCase.Carrier) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Carrier); + } + if (criterionCase_ == CriterionOneofCase.UserInterest) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserInterest); + } + if (criterionCase_ == CriterionOneofCase.Webpage) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Webpage); + } + if (criterionCase_ == CriterionOneofCase.OperatingSystemVersion) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(OperatingSystemVersion); + } + if (criterionCase_ == CriterionOneofCase.MobileDevice) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MobileDevice); + } + if (criterionCase_ == CriterionOneofCase.LocationGroup) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(LocationGroup); + } + if (criterionCase_ == CriterionOneofCase.CustomAffinity) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomAffinity); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignCriterion other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + if (other.criterionId_ != null) { + if (criterionId_ == null || other.CriterionId != 0L) { + CriterionId = other.CriterionId; + } + } + if (other.bidModifier_ != null) { + if (bidModifier_ == null || other.BidModifier != 0F) { + BidModifier = other.BidModifier; + } + } + if (other.negative_ != null) { + if (negative_ == null || other.Negative != false) { + Negative = other.Negative; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.Status != 0) { + Status = other.Status; + } + switch (other.CriterionCase) { + case CriterionOneofCase.Keyword: + if (Keyword == null) { + Keyword = new global::Google.Ads.GoogleAds.V3.Common.KeywordInfo(); + } + Keyword.MergeFrom(other.Keyword); + break; + case CriterionOneofCase.Placement: + if (Placement == null) { + Placement = new global::Google.Ads.GoogleAds.V3.Common.PlacementInfo(); + } + Placement.MergeFrom(other.Placement); + break; + case CriterionOneofCase.MobileAppCategory: + if (MobileAppCategory == null) { + MobileAppCategory = new global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo(); + } + MobileAppCategory.MergeFrom(other.MobileAppCategory); + break; + case CriterionOneofCase.MobileApplication: + if (MobileApplication == null) { + MobileApplication = new global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo(); + } + MobileApplication.MergeFrom(other.MobileApplication); + break; + case CriterionOneofCase.Location: + if (Location == null) { + Location = new global::Google.Ads.GoogleAds.V3.Common.LocationInfo(); + } + Location.MergeFrom(other.Location); + break; + case CriterionOneofCase.Device: + if (Device == null) { + Device = new global::Google.Ads.GoogleAds.V3.Common.DeviceInfo(); + } + Device.MergeFrom(other.Device); + break; + case CriterionOneofCase.AdSchedule: + if (AdSchedule == null) { + AdSchedule = new global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo(); + } + AdSchedule.MergeFrom(other.AdSchedule); + break; + case CriterionOneofCase.AgeRange: + if (AgeRange == null) { + AgeRange = new global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo(); + } + AgeRange.MergeFrom(other.AgeRange); + break; + case CriterionOneofCase.Gender: + if (Gender == null) { + Gender = new global::Google.Ads.GoogleAds.V3.Common.GenderInfo(); + } + Gender.MergeFrom(other.Gender); + break; + case CriterionOneofCase.IncomeRange: + if (IncomeRange == null) { + IncomeRange = new global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo(); + } + IncomeRange.MergeFrom(other.IncomeRange); + break; + case CriterionOneofCase.ParentalStatus: + if (ParentalStatus == null) { + ParentalStatus = new global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo(); + } + ParentalStatus.MergeFrom(other.ParentalStatus); + break; + case CriterionOneofCase.UserList: + if (UserList == null) { + UserList = new global::Google.Ads.GoogleAds.V3.Common.UserListInfo(); + } + UserList.MergeFrom(other.UserList); + break; + case CriterionOneofCase.YoutubeVideo: + if (YoutubeVideo == null) { + YoutubeVideo = new global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo(); + } + YoutubeVideo.MergeFrom(other.YoutubeVideo); + break; + case CriterionOneofCase.YoutubeChannel: + if (YoutubeChannel == null) { + YoutubeChannel = new global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo(); + } + YoutubeChannel.MergeFrom(other.YoutubeChannel); + break; + case CriterionOneofCase.Proximity: + if (Proximity == null) { + Proximity = new global::Google.Ads.GoogleAds.V3.Common.ProximityInfo(); + } + Proximity.MergeFrom(other.Proximity); + break; + case CriterionOneofCase.Topic: + if (Topic == null) { + Topic = new global::Google.Ads.GoogleAds.V3.Common.TopicInfo(); + } + Topic.MergeFrom(other.Topic); + break; + case CriterionOneofCase.ListingScope: + if (ListingScope == null) { + ListingScope = new global::Google.Ads.GoogleAds.V3.Common.ListingScopeInfo(); + } + ListingScope.MergeFrom(other.ListingScope); + break; + case CriterionOneofCase.Language: + if (Language == null) { + Language = new global::Google.Ads.GoogleAds.V3.Common.LanguageInfo(); + } + Language.MergeFrom(other.Language); + break; + case CriterionOneofCase.IpBlock: + if (IpBlock == null) { + IpBlock = new global::Google.Ads.GoogleAds.V3.Common.IpBlockInfo(); + } + IpBlock.MergeFrom(other.IpBlock); + break; + case CriterionOneofCase.ContentLabel: + if (ContentLabel == null) { + ContentLabel = new global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo(); + } + ContentLabel.MergeFrom(other.ContentLabel); + break; + case CriterionOneofCase.Carrier: + if (Carrier == null) { + Carrier = new global::Google.Ads.GoogleAds.V3.Common.CarrierInfo(); + } + Carrier.MergeFrom(other.Carrier); + break; + case CriterionOneofCase.UserInterest: + if (UserInterest == null) { + UserInterest = new global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo(); + } + UserInterest.MergeFrom(other.UserInterest); + break; + case CriterionOneofCase.Webpage: + if (Webpage == null) { + Webpage = new global::Google.Ads.GoogleAds.V3.Common.WebpageInfo(); + } + Webpage.MergeFrom(other.Webpage); + break; + case CriterionOneofCase.OperatingSystemVersion: + if (OperatingSystemVersion == null) { + OperatingSystemVersion = new global::Google.Ads.GoogleAds.V3.Common.OperatingSystemVersionInfo(); + } + OperatingSystemVersion.MergeFrom(other.OperatingSystemVersion); + break; + case CriterionOneofCase.MobileDevice: + if (MobileDevice == null) { + MobileDevice = new global::Google.Ads.GoogleAds.V3.Common.MobileDeviceInfo(); + } + MobileDevice.MergeFrom(other.MobileDevice); + break; + case CriterionOneofCase.LocationGroup: + if (LocationGroup == null) { + LocationGroup = new global::Google.Ads.GoogleAds.V3.Common.LocationGroupInfo(); + } + LocationGroup.MergeFrom(other.LocationGroup); + break; + case CriterionOneofCase.CustomAffinity: + if (CustomAffinity == null) { + CustomAffinity = new global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo(); + } + CustomAffinity.MergeFrom(other.CustomAffinity); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 34: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 42: { + long? value = _single_criterionId_codec.Read(input); + if (criterionId_ == null || value != 0L) { + CriterionId = value; + } + break; + } + case 48: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType) input.ReadEnum(); + break; + } + case 58: { + bool? value = _single_negative_codec.Read(input); + if (negative_ == null || value != false) { + Negative = value; + } + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.KeywordInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.KeywordInfo(); + if (criterionCase_ == CriterionOneofCase.Keyword) { + subBuilder.MergeFrom(Keyword); + } + input.ReadMessage(subBuilder); + Keyword = subBuilder; + break; + } + case 74: { + global::Google.Ads.GoogleAds.V3.Common.PlacementInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.PlacementInfo(); + if (criterionCase_ == CriterionOneofCase.Placement) { + subBuilder.MergeFrom(Placement); + } + input.ReadMessage(subBuilder); + Placement = subBuilder; + break; + } + case 82: { + global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo(); + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + subBuilder.MergeFrom(MobileAppCategory); + } + input.ReadMessage(subBuilder); + MobileAppCategory = subBuilder; + break; + } + case 90: { + global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo(); + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + subBuilder.MergeFrom(MobileApplication); + } + input.ReadMessage(subBuilder); + MobileApplication = subBuilder; + break; + } + case 98: { + global::Google.Ads.GoogleAds.V3.Common.LocationInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.LocationInfo(); + if (criterionCase_ == CriterionOneofCase.Location) { + subBuilder.MergeFrom(Location); + } + input.ReadMessage(subBuilder); + Location = subBuilder; + break; + } + case 106: { + global::Google.Ads.GoogleAds.V3.Common.DeviceInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.DeviceInfo(); + if (criterionCase_ == CriterionOneofCase.Device) { + subBuilder.MergeFrom(Device); + } + input.ReadMessage(subBuilder); + Device = subBuilder; + break; + } + case 114: { + float? value = _single_bidModifier_codec.Read(input); + if (bidModifier_ == null || value != 0F) { + BidModifier = value; + } + break; + } + case 122: { + global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo(); + if (criterionCase_ == CriterionOneofCase.AdSchedule) { + subBuilder.MergeFrom(AdSchedule); + } + input.ReadMessage(subBuilder); + AdSchedule = subBuilder; + break; + } + case 130: { + global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo(); + if (criterionCase_ == CriterionOneofCase.AgeRange) { + subBuilder.MergeFrom(AgeRange); + } + input.ReadMessage(subBuilder); + AgeRange = subBuilder; + break; + } + case 138: { + global::Google.Ads.GoogleAds.V3.Common.GenderInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.GenderInfo(); + if (criterionCase_ == CriterionOneofCase.Gender) { + subBuilder.MergeFrom(Gender); + } + input.ReadMessage(subBuilder); + Gender = subBuilder; + break; + } + case 146: { + global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo(); + if (criterionCase_ == CriterionOneofCase.IncomeRange) { + subBuilder.MergeFrom(IncomeRange); + } + input.ReadMessage(subBuilder); + IncomeRange = subBuilder; + break; + } + case 154: { + global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo(); + if (criterionCase_ == CriterionOneofCase.ParentalStatus) { + subBuilder.MergeFrom(ParentalStatus); + } + input.ReadMessage(subBuilder); + ParentalStatus = subBuilder; + break; + } + case 162: { + global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo(); + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + subBuilder.MergeFrom(YoutubeVideo); + } + input.ReadMessage(subBuilder); + YoutubeVideo = subBuilder; + break; + } + case 170: { + global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo(); + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + subBuilder.MergeFrom(YoutubeChannel); + } + input.ReadMessage(subBuilder); + YoutubeChannel = subBuilder; + break; + } + case 178: { + global::Google.Ads.GoogleAds.V3.Common.UserListInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.UserListInfo(); + if (criterionCase_ == CriterionOneofCase.UserList) { + subBuilder.MergeFrom(UserList); + } + input.ReadMessage(subBuilder); + UserList = subBuilder; + break; + } + case 186: { + global::Google.Ads.GoogleAds.V3.Common.ProximityInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProximityInfo(); + if (criterionCase_ == CriterionOneofCase.Proximity) { + subBuilder.MergeFrom(Proximity); + } + input.ReadMessage(subBuilder); + Proximity = subBuilder; + break; + } + case 194: { + global::Google.Ads.GoogleAds.V3.Common.TopicInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TopicInfo(); + if (criterionCase_ == CriterionOneofCase.Topic) { + subBuilder.MergeFrom(Topic); + } + input.ReadMessage(subBuilder); + Topic = subBuilder; + break; + } + case 202: { + global::Google.Ads.GoogleAds.V3.Common.ListingScopeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ListingScopeInfo(); + if (criterionCase_ == CriterionOneofCase.ListingScope) { + subBuilder.MergeFrom(ListingScope); + } + input.ReadMessage(subBuilder); + ListingScope = subBuilder; + break; + } + case 210: { + global::Google.Ads.GoogleAds.V3.Common.LanguageInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.LanguageInfo(); + if (criterionCase_ == CriterionOneofCase.Language) { + subBuilder.MergeFrom(Language); + } + input.ReadMessage(subBuilder); + Language = subBuilder; + break; + } + case 218: { + global::Google.Ads.GoogleAds.V3.Common.IpBlockInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.IpBlockInfo(); + if (criterionCase_ == CriterionOneofCase.IpBlock) { + subBuilder.MergeFrom(IpBlock); + } + input.ReadMessage(subBuilder); + IpBlock = subBuilder; + break; + } + case 226: { + global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo(); + if (criterionCase_ == CriterionOneofCase.ContentLabel) { + subBuilder.MergeFrom(ContentLabel); + } + input.ReadMessage(subBuilder); + ContentLabel = subBuilder; + break; + } + case 234: { + global::Google.Ads.GoogleAds.V3.Common.CarrierInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CarrierInfo(); + if (criterionCase_ == CriterionOneofCase.Carrier) { + subBuilder.MergeFrom(Carrier); + } + input.ReadMessage(subBuilder); + Carrier = subBuilder; + break; + } + case 242: { + global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo(); + if (criterionCase_ == CriterionOneofCase.UserInterest) { + subBuilder.MergeFrom(UserInterest); + } + input.ReadMessage(subBuilder); + UserInterest = subBuilder; + break; + } + case 250: { + global::Google.Ads.GoogleAds.V3.Common.WebpageInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.WebpageInfo(); + if (criterionCase_ == CriterionOneofCase.Webpage) { + subBuilder.MergeFrom(Webpage); + } + input.ReadMessage(subBuilder); + Webpage = subBuilder; + break; + } + case 258: { + global::Google.Ads.GoogleAds.V3.Common.OperatingSystemVersionInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.OperatingSystemVersionInfo(); + if (criterionCase_ == CriterionOneofCase.OperatingSystemVersion) { + subBuilder.MergeFrom(OperatingSystemVersion); + } + input.ReadMessage(subBuilder); + OperatingSystemVersion = subBuilder; + break; + } + case 266: { + global::Google.Ads.GoogleAds.V3.Common.MobileDeviceInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MobileDeviceInfo(); + if (criterionCase_ == CriterionOneofCase.MobileDevice) { + subBuilder.MergeFrom(MobileDevice); + } + input.ReadMessage(subBuilder); + MobileDevice = subBuilder; + break; + } + case 274: { + global::Google.Ads.GoogleAds.V3.Common.LocationGroupInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.LocationGroupInfo(); + if (criterionCase_ == CriterionOneofCase.LocationGroup) { + subBuilder.MergeFrom(LocationGroup); + } + input.ReadMessage(subBuilder); + LocationGroup = subBuilder; + break; + } + case 280: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.CampaignCriterionStatusEnum.Types.CampaignCriterionStatus) input.ReadEnum(); + break; + } + case 290: { + global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo(); + if (criterionCase_ == CriterionOneofCase.CustomAffinity) { + subBuilder.MergeFrom(CustomAffinity); + } + input.ReadMessage(subBuilder); + CustomAffinity = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignCriterionError.cs b/src/V3/Stubs/CampaignCriterionError.cs new file mode 100644 index 000000000..8fe21ea49 --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionError.cs @@ -0,0 +1,234 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/campaign_criterion_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/campaign_criterion_error.proto + public static partial class CampaignCriterionErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/campaign_criterion_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignCriterionErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2FtcGFpZ25fY3Jp", + "dGVyaW9uX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i9QMKGkNhbXBh", + "aWduQ3JpdGVyaW9uRXJyb3JFbnVtItYDChZDYW1wYWlnbkNyaXRlcmlvbkVy", + "cm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhoKFkNPTkNSRVRF", + "X1RZUEVfUkVRVUlSRUQQAhIZChVJTlZBTElEX1BMQUNFTUVOVF9VUkwQAxIg", + "ChxDQU5OT1RfRVhDTFVERV9DUklURVJJQV9UWVBFEAQSJwojQ0FOTk9UX1NF", + "VF9TVEFUVVNfRk9SX0NSSVRFUklBX1RZUEUQBRIrCidDQU5OT1RfU0VUX1NU", + "QVRVU19GT1JfRVhDTFVERURfQ1JJVEVSSUEQBhIdChlDQU5OT1RfVEFSR0VU", + "X0FORF9FWENMVURFEAcSFwoTVE9PX01BTllfT1BFUkFUSU9OUxAIEi0KKU9Q", + "RVJBVE9SX05PVF9TVVBQT1JURURfRk9SX0NSSVRFUklPTl9UWVBFEAkSQwo/", + "U0hPUFBJTkdfQ0FNUEFJR05fU0FMRVNfQ09VTlRSWV9OT1RfU1VQUE9SVEVE", + "X0ZPUl9TQUxFU19DSEFOTkVMEAoSHQoZQ0FOTk9UX0FERF9FWElTVElOR19G", + "SUVMRBALEiQKIENBTk5PVF9VUERBVEVfTkVHQVRJVkVfQ1JJVEVSSU9OEAxC", + "9gEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNCG0NhbXBh", + "aWduQ3JpdGVyaW9uRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9n", + "ZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vy", + "cm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oC", + "Hkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignCriterionErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CampaignCriterionErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignCriterionErrorEnum.Types.CampaignCriterionError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible campaign criterion errors. + /// + public sealed partial class CampaignCriterionErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignCriterionErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CampaignCriterionErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionErrorEnum(CampaignCriterionErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionErrorEnum Clone() { + return new CampaignCriterionErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignCriterionErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignCriterionErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignCriterionErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignCriterionErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible campaign criterion errors. + /// + public enum CampaignCriterionError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Concrete type of criterion (keyword v.s. placement) is required for + /// CREATE and UPDATE operations. + /// + [pbr::OriginalName("CONCRETE_TYPE_REQUIRED")] ConcreteTypeRequired = 2, + /// + /// Invalid placement URL. + /// + [pbr::OriginalName("INVALID_PLACEMENT_URL")] InvalidPlacementUrl = 3, + /// + /// Criteria type can not be excluded for the campaign by the customer. like + /// AOL account type cannot target site type criteria + /// + [pbr::OriginalName("CANNOT_EXCLUDE_CRITERIA_TYPE")] CannotExcludeCriteriaType = 4, + /// + /// Cannot set the campaign criterion status for this criteria type. + /// + [pbr::OriginalName("CANNOT_SET_STATUS_FOR_CRITERIA_TYPE")] CannotSetStatusForCriteriaType = 5, + /// + /// Cannot set the campaign criterion status for an excluded criteria. + /// + [pbr::OriginalName("CANNOT_SET_STATUS_FOR_EXCLUDED_CRITERIA")] CannotSetStatusForExcludedCriteria = 6, + /// + /// Cannot target and exclude the same criterion. + /// + [pbr::OriginalName("CANNOT_TARGET_AND_EXCLUDE")] CannotTargetAndExclude = 7, + /// + /// The mutate contained too many operations. + /// + [pbr::OriginalName("TOO_MANY_OPERATIONS")] TooManyOperations = 8, + /// + /// This operator cannot be applied to a criterion of this type. + /// + [pbr::OriginalName("OPERATOR_NOT_SUPPORTED_FOR_CRITERION_TYPE")] OperatorNotSupportedForCriterionType = 9, + /// + /// The Shopping campaign sales country is not supported for + /// ProductSalesChannel targeting. + /// + [pbr::OriginalName("SHOPPING_CAMPAIGN_SALES_COUNTRY_NOT_SUPPORTED_FOR_SALES_CHANNEL")] ShoppingCampaignSalesCountryNotSupportedForSalesChannel = 10, + /// + /// The existing field can't be updated with CREATE operation. It can be + /// updated with UPDATE operation only. + /// + [pbr::OriginalName("CANNOT_ADD_EXISTING_FIELD")] CannotAddExistingField = 11, + /// + /// Negative criteria are immutable, so updates are not allowed. + /// + [pbr::OriginalName("CANNOT_UPDATE_NEGATIVE_CRITERION")] CannotUpdateNegativeCriterion = 12, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignCriterionService.cs b/src/V3/Stubs/CampaignCriterionService.cs new file mode 100644 index 000000000..c1ebacd7a --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionService.cs @@ -0,0 +1,1035 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_criterion_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_criterion_service.proto + public static partial class CampaignCriterionServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_criterion_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignCriterionServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9j", + "cml0ZXJpb25fc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMaOmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNl", + "cy9jYW1wYWlnbl9jcml0ZXJpb24ucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3Rh", + "dGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUv", + "YXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9idWYvZmll", + "bGRfbWFzay5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8iOQobR2V0", + "Q2FtcGFpZ25Dcml0ZXJpb25SZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASAB", + "KAlCA+BBAiLAAQodTXV0YXRlQ2FtcGFpZ25Dcml0ZXJpYVJlcXVlc3QSGAoL", + "Y3VzdG9tZXJfaWQYASABKAlCA+BBAhJVCgpvcGVyYXRpb25zGAIgAygLMjwu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ2FtcGFpZ25Dcml0", + "ZXJpb25PcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyABKAgS", + "FQoNdmFsaWRhdGVfb25seRgEIAEoCCL8AQoaQ2FtcGFpZ25Dcml0ZXJpb25P", + "cGVyYXRpb24SLwoLdXBkYXRlX21hc2sYBCABKAsyGi5nb29nbGUucHJvdG9i", + "dWYuRmllbGRNYXNrEkYKBmNyZWF0ZRgBIAEoCzI0Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5DYW1wYWlnbkNyaXRlcmlvbkgAEkYKBnVw", + "ZGF0ZRgCIAEoCzI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cy5DYW1wYWlnbkNyaXRlcmlvbkgAEhAKBnJlbW92ZRgDIAEoCUgAQgsKCW9w", + "ZXJhdGlvbiKlAQoeTXV0YXRlQ2FtcGFpZ25Dcml0ZXJpYVJlc3BvbnNlEjEK", + "FXBhcnRpYWxfZmFpbHVyZV9lcnJvchgDIAEoCzISLmdvb2dsZS5ycGMuU3Rh", + "dHVzElAKB3Jlc3VsdHMYAiADKAsyPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5NdXRhdGVDYW1wYWlnbkNyaXRlcmlvblJlc3VsdCI2Ch1N", + "dXRhdGVDYW1wYWlnbkNyaXRlcmlvblJlc3VsdBIVCg1yZXNvdXJjZV9uYW1l", + "GAEgASgJMooEChhDYW1wYWlnbkNyaXRlcmlvblNlcnZpY2US1wEKFEdldENh", + "bXBhaWduQ3JpdGVyaW9uEj0uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuR2V0Q2FtcGFpZ25Dcml0ZXJpb25SZXF1ZXN0GjQuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduQ3JpdGVyaW9uIkqC", + "0+STAjQSMi92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9jYW1wYWln", + "bkNyaXRlcmlhLyp92kENcmVzb3VyY2VfbmFtZRL2AQoWTXV0YXRlQ2FtcGFp", + "Z25Dcml0ZXJpYRI/Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2Vz", + "Lk11dGF0ZUNhbXBhaWduQ3JpdGVyaWFSZXF1ZXN0GkAuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ2FtcGFpZ25Dcml0ZXJpYVJl", + "c3BvbnNlIlmC0+STAjoiNS92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9", + "L2NhbXBhaWduQ3JpdGVyaWE6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3Bl", + "cmF0aW9ucxobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQoQCCiRjb20u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCHUNhbXBhaWduQ3Jp", + "dGVyaW9uU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnBy", + "b3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2", + "aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2Vz", + "ygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriterionResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriterionResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignCriterionService.GetCampaignCriterion][google.ads.googleads.v3.services.CampaignCriterionService.GetCampaignCriterion]. + /// + public sealed partial class GetCampaignCriterionRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignCriterionRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignCriterionRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignCriterionRequest(GetCampaignCriterionRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignCriterionRequest Clone() { + return new GetCampaignCriterionRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the criterion to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignCriterionRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignCriterionRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignCriterionRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignCriterionService.MutateCampaignCriteria][google.ads.googleads.v3.services.CampaignCriterionService.MutateCampaignCriteria]. + /// + public sealed partial class MutateCampaignCriteriaRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignCriteriaRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriteriaRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriteriaRequest(MutateCampaignCriteriaRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriteriaRequest Clone() { + return new MutateCampaignCriteriaRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual criteria. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignCriteriaRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignCriteriaRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignCriteriaRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a campaign criterion. + /// + public sealed partial class CampaignCriterionOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignCriterionOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionOperation(CampaignCriterionOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionOperation Clone() { + return new CampaignCriterionOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The criterion is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed criterion is expected, + /// in this format: + /// + /// `customers/{customer_id}/campaignCriteria/{campaign_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignCriterionOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignCriterionOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignCriterionOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for campaign criterion mutate. + /// + public sealed partial class MutateCampaignCriteriaResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignCriteriaResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriteriaResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriteriaResponse(MutateCampaignCriteriaResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriteriaResponse Clone() { + return new MutateCampaignCriteriaResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriterionResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignCriteriaResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignCriteriaResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignCriteriaResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the criterion mutate. + /// + public sealed partial class MutateCampaignCriterionResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignCriterionResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriterionResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriterionResult(MutateCampaignCriterionResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignCriterionResult Clone() { + return new MutateCampaignCriterionResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignCriterionResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignCriterionResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignCriterionResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignCriterionServiceClient.cs b/src/V3/Stubs/CampaignCriterionServiceClient.cs new file mode 100644 index 000000000..ff9aa081e --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionServiceClient.cs @@ -0,0 +1,887 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignCriterionServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignCriterionServiceSettings GetDefault() => new CampaignCriterionServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignCriterionServiceSettings() { } + + private CampaignCriterionServiceSettings(CampaignCriterionServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignCriterionSettings = existing.GetCampaignCriterionSettings; + MutateCampaignCriteriaSettings = existing.MutateCampaignCriteriaSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignCriterionServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignCriterionServiceClient.GetCampaignCriterion and CampaignCriterionServiceClient.GetCampaignCriterionAsync. + /// + /// + /// The default CampaignCriterionServiceClient.GetCampaignCriterion and + /// CampaignCriterionServiceClient.GetCampaignCriterionAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignCriterionSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignCriterionServiceClient.MutateCampaignCriteria and CampaignCriterionServiceClient.MutateCampaignCriteriaAsync. + /// + /// + /// The default CampaignCriterionServiceClient.MutateCampaignCriteria and + /// CampaignCriterionServiceClient.MutateCampaignCriteriaAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignCriteriaSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignCriterionServiceSettings Clone() => new CampaignCriterionServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignCriterionServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignCriterionServiceSettings Settings { get; set; } + + /// + public override CampaignCriterionServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignCriterionServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignCriterionServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignCriterionServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignCriterionServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignCriterionServiceClient.ChannelPool; + } + + /// + /// CampaignCriterionService client wrapper, for convenient use. + /// + public abstract partial class CampaignCriterionServiceClient + { + /// + /// The default endpoint for the CampaignCriterionService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignCriterionService scopes. + /// + /// + /// The default CampaignCriterionService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignCriterionServiceClient client = await CampaignCriterionServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignCriterionServiceClient.DefaultEndpoint.Host, CampaignCriterionServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignCriterionServiceClient client = CampaignCriterionServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignCriterionServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignCriterionServiceClient client = CampaignCriterionServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignCriterionServiceClient.DefaultEndpoint.Host, CampaignCriterionServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignCriterionServiceClient client = CampaignCriterionServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignCriterionServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignCriterionServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignCriterionServiceClient Create(grpccore::Channel channel, CampaignCriterionServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignCriterionServiceClient Create(grpccore::CallInvoker callInvoker, CampaignCriterionServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignCriterionService.CampaignCriterionServiceClient grpcClient = new CampaignCriterionService.CampaignCriterionServiceClient(callInvoker); + return new CampaignCriterionServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignCriterionService client. + /// + public virtual CampaignCriterionService.CampaignCriterionServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignCriterionAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignCriterionAsync( + new GetCampaignCriterionRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignCriterionAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignCriterionAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignCriterion GetCampaignCriterion( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignCriterion( + new GetCampaignCriterionRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignCriterionAsync( + GetCampaignCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignCriterionAsync( + GetCampaignCriterionRequest request, + st::CancellationToken cancellationToken) => GetCampaignCriterionAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignCriterion GetCampaignCriterion( + GetCampaignCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignCriteriaAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignCriteriaAsync( + new MutateCampaignCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignCriteriaAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignCriteriaAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignCriteriaResponse MutateCampaignCriteria( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignCriteria( + new MutateCampaignCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignCriteriaAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignCriteriaAsync( + new MutateCampaignCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignCriteriaAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignCriteriaAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignCriteriaResponse MutateCampaignCriteria( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignCriteria( + new MutateCampaignCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignCriteriaAsync( + MutateCampaignCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignCriteriaAsync( + MutateCampaignCriteriaRequest request, + st::CancellationToken cancellationToken) => MutateCampaignCriteriaAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignCriteriaResponse MutateCampaignCriteria( + MutateCampaignCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignCriterionService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignCriterionServiceClientImpl : CampaignCriterionServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignCriterion; + private readonly gaxgrpc::ApiCall _callMutateCampaignCriteria; + + /// + /// Constructs a client wrapper for the CampaignCriterionService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignCriterionServiceClientImpl(CampaignCriterionService.CampaignCriterionServiceClient grpcClient, CampaignCriterionServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignCriterionServiceSettings effectiveSettings = settings ?? CampaignCriterionServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignCriterion = clientHelper.BuildApiCall( + GrpcClient.GetCampaignCriterionAsync, GrpcClient.GetCampaignCriterion, effectiveSettings.GetCampaignCriterionSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaignCriteria = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignCriteriaAsync, GrpcClient.MutateCampaignCriteria, effectiveSettings.MutateCampaignCriteriaSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCampaignCriterion); + Modify_GetCampaignCriterionApiCall(ref _callGetCampaignCriterion); + Modify_ApiCall(ref _callMutateCampaignCriteria); + Modify_MutateCampaignCriteriaApiCall(ref _callMutateCampaignCriteria); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignCriterionApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignCriteriaApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignCriterionService.CampaignCriterionServiceClient grpcClient, CampaignCriterionServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignCriterionService client. + /// + public override CampaignCriterionService.CampaignCriterionServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignCriterionRequest(ref GetCampaignCriterionRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignCriteriaRequest(ref MutateCampaignCriteriaRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignCriterionAsync( + GetCampaignCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignCriterionRequest(ref request, ref callSettings); + return _callGetCampaignCriterion.Async(request, callSettings); + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignCriterion GetCampaignCriterion( + GetCampaignCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignCriterionRequest(ref request, ref callSettings); + return _callGetCampaignCriterion.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignCriteriaAsync( + MutateCampaignCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignCriteriaRequest(ref request, ref callSettings); + return _callMutateCampaignCriteria.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignCriteriaResponse MutateCampaignCriteria( + MutateCampaignCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignCriteriaRequest(ref request, ref callSettings); + return _callMutateCampaignCriteria.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignCriterionServiceGrpc.cs b/src/V3/Stubs/CampaignCriterionServiceGrpc.cs new file mode 100644 index 000000000..033d3656d --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_criterion_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaign criteria. + /// + public static partial class CampaignCriterionService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignCriterionService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignCriterionRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignCriterion = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignCriteriaRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignCriteriaResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignCriterion = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignCriterion", + __Marshaller_google_ads_googleads_v3_services_GetCampaignCriterionRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignCriterion); + + static readonly grpc::Method __Method_MutateCampaignCriteria = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignCriteria", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignCriteriaRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignCriteriaResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignCriterionService + public abstract partial class CampaignCriterionServiceBase + { + /// + /// Returns the requested criterion in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignCriterion(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignCriterionService + public partial class CampaignCriterionServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignCriterionService + /// The channel to use to make remote calls. + public CampaignCriterionServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignCriterionService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignCriterionServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignCriterionServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignCriterionServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion GetCampaignCriterion(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignCriterion(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion GetCampaignCriterion(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignCriterion, null, options, request); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignCriterionAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignCriterionAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignCriterionAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignCriterion, null, options, request); + } + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaResponse MutateCampaignCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignCriteria(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaResponse MutateCampaignCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignCriteria, null, options, request); + } + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignCriteriaAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignCriteriaAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignCriteriaAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriteriaRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignCriteria, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignCriterionServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignCriterionServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignCriterionServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignCriterion, serviceImpl.GetCampaignCriterion) + .AddMethod(__Method_MutateCampaignCriteria, serviceImpl.MutateCampaignCriteria).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignCriterionServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignCriterion, serviceImpl.GetCampaignCriterion); + serviceBinder.AddMethod(__Method_MutateCampaignCriteria, serviceImpl.MutateCampaignCriteria); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignCriterionSimulation.cs b/src/V3/Stubs/CampaignCriterionSimulation.cs new file mode 100644 index 000000000..1299a6618 --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionSimulation.cs @@ -0,0 +1,496 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_criterion_simulation.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_criterion_simulation.proto + public static partial class CampaignCriterionSimulationReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_criterion_simulation.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignCriterionSimulationReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "Y3JpdGVyaW9uX3NpbXVsYXRpb24ucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlcxovZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29t", + "bW9uL3NpbXVsYXRpb24ucHJvdG8aQmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL3NpbXVsYXRpb25fbW9kaWZpY2F0aW9uX21ldGhvZC5wcm90bxoz", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvc2ltdWxhdGlvbl90eXBl", + "LnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29n", + "bGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBl", + "cnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iqAYKG0Nh", + "bXBhaWduQ3JpdGVyaW9uU2ltdWxhdGlvbhJTCg1yZXNvdXJjZV9uYW1lGAEg", + "ASgJQjzgQQX6QTYKNGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9DYW1wYWln", + "bkNyaXRlcmlvblNpbXVsYXRpb24SNQoLY2FtcGFpZ25faWQYAiABKAsyGy5n", + "b29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEjYKDGNyaXRlcmlvbl9p", + "ZBgDIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSUwoE", + "dHlwZRgEIAEoDjJALmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLlNp", + "bXVsYXRpb25UeXBlRW51bS5TaW11bGF0aW9uVHlwZUID4EEDEn4KE21vZGlm", + "aWNhdGlvbl9tZXRob2QYBSABKA4yXC5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtcy5TaW11bGF0aW9uTW9kaWZpY2F0aW9uTWV0aG9kRW51bS5TaW11", + "bGF0aW9uTW9kaWZpY2F0aW9uTWV0aG9kQgPgQQMSNQoKc3RhcnRfZGF0ZRgG", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEjMKCGVu", + "ZF9kYXRlGAcgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPg", + "QQMSZgoXYmlkX21vZGlmaWVyX3BvaW50X2xpc3QYCCABKAsyPi5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5jb21tb24uQmlkTW9kaWZpZXJTaW11bGF0aW9u", + "UG9pbnRMaXN0QgPgQQNIADqNAepBiQEKNGdvb2dsZWFkcy5nb29nbGVhcGlz", + "LmNvbS9DYW1wYWlnbkNyaXRlcmlvblNpbXVsYXRpb24SUWN1c3RvbWVycy97", + "Y3VzdG9tZXJ9L2NhbXBhaWduQ3JpdGVyaW9uU2ltdWxhdGlvbnMve2NhbXBh", + "aWduX2NyaXRlcmlvbl9zaW11bGF0aW9ufUIMCgpwb2ludF9saXN0Qo0CCiVj", + "b20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzQiBDYW1wYWln", + "bkNyaXRlcmlvblNpbXVsYXRpb25Qcm90b1ABWkpnb29nbGUuZ29sYW5nLm9y", + "Zy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNl", + "c+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.SimulationReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation), global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation.Parser, new[]{ "ResourceName", "CampaignId", "CriterionId", "Type", "ModificationMethod", "StartDate", "EndDate", "BidModifierPointList" }, new[]{ "PointList" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A campaign criterion simulation. Supported combinations of advertising + /// channel type, criterion ids, simulation type and simulation modification + /// method is detailed below respectively. + /// + /// 1. SEARCH - 30000,30001,30002 - BID_MODIFIER - UNIFORM + /// 2. SHOPPING - 30000,30001,30002 - BID_MODIFIER - UNIFORM + /// 3. DISPLAY - 30001 - BID_MODIFIER - UNIFORM + /// + public sealed partial class CampaignCriterionSimulation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignCriterionSimulation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulationReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionSimulation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionSimulation(CampaignCriterionSimulation other) : this() { + resourceName_ = other.resourceName_; + CampaignId = other.CampaignId; + CriterionId = other.CriterionId; + type_ = other.type_; + modificationMethod_ = other.modificationMethod_; + StartDate = other.StartDate; + EndDate = other.EndDate; + switch (other.PointListCase) { + case PointListOneofCase.BidModifierPointList: + BidModifierPointList = other.BidModifierPointList.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionSimulation Clone() { + return new CampaignCriterionSimulation(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign criterion simulation. + /// Campaign criterion simulation resource names have the form: + /// + /// `customers/{customer_id}/campaignCriterionSimulations/{campaign_id}~{criterion_id}~{type}~{modification_method}~{start_date}~{end_date}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "campaign_id" field. + public const int CampaignIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_campaignId_codec = pb::FieldCodec.ForStructWrapper(18); + private long? campaignId_; + /// + /// Output only. Campaign ID of the simulation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CampaignId { + get { return campaignId_; } + set { + campaignId_ = value; + } + } + + + /// Field number for the "criterion_id" field. + public const int CriterionIdFieldNumber = 3; + private static readonly pb::FieldCodec _single_criterionId_codec = pb::FieldCodec.ForStructWrapper(26); + private long? criterionId_; + /// + /// Output only. Criterion ID of the simulation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CriterionId { + get { return criterionId_; } + set { + criterionId_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType type_ = 0; + /// + /// Output only. The field that the simulation modifies. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "modification_method" field. + public const int ModificationMethodFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod modificationMethod_ = 0; + /// + /// Output only. How the simulation modifies the field. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod ModificationMethod { + get { return modificationMethod_; } + set { + modificationMethod_ = value; + } + } + + /// Field number for the "start_date" field. + public const int StartDateFieldNumber = 6; + private static readonly pb::FieldCodec _single_startDate_codec = pb::FieldCodec.ForClassWrapper(50); + private string startDate_; + /// + /// Output only. First day on which the simulation is based, in YYYY-MM-DD format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDate { + get { return startDate_; } + set { + startDate_ = value; + } + } + + + /// Field number for the "end_date" field. + public const int EndDateFieldNumber = 7; + private static readonly pb::FieldCodec _single_endDate_codec = pb::FieldCodec.ForClassWrapper(58); + private string endDate_; + /// + /// Output only. Last day on which the simulation is based, in YYYY-MM-DD format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDate { + get { return endDate_; } + set { + endDate_ = value; + } + } + + + /// Field number for the "bid_modifier_point_list" field. + public const int BidModifierPointListFieldNumber = 8; + /// + /// Output only. Simulation points if the simulation type is BID_MODIFIER. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.BidModifierSimulationPointList BidModifierPointList { + get { return pointListCase_ == PointListOneofCase.BidModifierPointList ? (global::Google.Ads.GoogleAds.V3.Common.BidModifierSimulationPointList) pointList_ : null; } + set { + pointList_ = value; + pointListCase_ = value == null ? PointListOneofCase.None : PointListOneofCase.BidModifierPointList; + } + } + + private object pointList_; + /// Enum of possible cases for the "point_list" oneof. + public enum PointListOneofCase { + None = 0, + BidModifierPointList = 8, + } + private PointListOneofCase pointListCase_ = PointListOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PointListOneofCase PointListCase { + get { return pointListCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearPointList() { + pointListCase_ = PointListOneofCase.None; + pointList_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignCriterionSimulation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignCriterionSimulation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (CampaignId != other.CampaignId) return false; + if (CriterionId != other.CriterionId) return false; + if (Type != other.Type) return false; + if (ModificationMethod != other.ModificationMethod) return false; + if (StartDate != other.StartDate) return false; + if (EndDate != other.EndDate) return false; + if (!object.Equals(BidModifierPointList, other.BidModifierPointList)) return false; + if (PointListCase != other.PointListCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (campaignId_ != null) hash ^= CampaignId.GetHashCode(); + if (criterionId_ != null) hash ^= CriterionId.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (ModificationMethod != 0) hash ^= ModificationMethod.GetHashCode(); + if (startDate_ != null) hash ^= StartDate.GetHashCode(); + if (endDate_ != null) hash ^= EndDate.GetHashCode(); + if (pointListCase_ == PointListOneofCase.BidModifierPointList) hash ^= BidModifierPointList.GetHashCode(); + hash ^= (int) pointListCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (campaignId_ != null) { + _single_campaignId_codec.WriteTagAndValue(output, CampaignId); + } + if (criterionId_ != null) { + _single_criterionId_codec.WriteTagAndValue(output, CriterionId); + } + if (Type != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) Type); + } + if (ModificationMethod != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) ModificationMethod); + } + if (startDate_ != null) { + _single_startDate_codec.WriteTagAndValue(output, StartDate); + } + if (endDate_ != null) { + _single_endDate_codec.WriteTagAndValue(output, EndDate); + } + if (pointListCase_ == PointListOneofCase.BidModifierPointList) { + output.WriteRawTag(66); + output.WriteMessage(BidModifierPointList); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (campaignId_ != null) { + size += _single_campaignId_codec.CalculateSizeWithTag(CampaignId); + } + if (criterionId_ != null) { + size += _single_criterionId_codec.CalculateSizeWithTag(CriterionId); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (ModificationMethod != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ModificationMethod); + } + if (startDate_ != null) { + size += _single_startDate_codec.CalculateSizeWithTag(StartDate); + } + if (endDate_ != null) { + size += _single_endDate_codec.CalculateSizeWithTag(EndDate); + } + if (pointListCase_ == PointListOneofCase.BidModifierPointList) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(BidModifierPointList); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignCriterionSimulation other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.campaignId_ != null) { + if (campaignId_ == null || other.CampaignId != 0L) { + CampaignId = other.CampaignId; + } + } + if (other.criterionId_ != null) { + if (criterionId_ == null || other.CriterionId != 0L) { + CriterionId = other.CriterionId; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.ModificationMethod != 0) { + ModificationMethod = other.ModificationMethod; + } + if (other.startDate_ != null) { + if (startDate_ == null || other.StartDate != "") { + StartDate = other.StartDate; + } + } + if (other.endDate_ != null) { + if (endDate_ == null || other.EndDate != "") { + EndDate = other.EndDate; + } + } + switch (other.PointListCase) { + case PointListOneofCase.BidModifierPointList: + if (BidModifierPointList == null) { + BidModifierPointList = new global::Google.Ads.GoogleAds.V3.Common.BidModifierSimulationPointList(); + } + BidModifierPointList.MergeFrom(other.BidModifierPointList); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_campaignId_codec.Read(input); + if (campaignId_ == null || value != 0L) { + CampaignId = value; + } + break; + } + case 26: { + long? value = _single_criterionId_codec.Read(input); + if (criterionId_ == null || value != 0L) { + CriterionId = value; + } + break; + } + case 32: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.SimulationTypeEnum.Types.SimulationType) input.ReadEnum(); + break; + } + case 40: { + ModificationMethod = (global::Google.Ads.GoogleAds.V3.Enums.SimulationModificationMethodEnum.Types.SimulationModificationMethod) input.ReadEnum(); + break; + } + case 50: { + string value = _single_startDate_codec.Read(input); + if (startDate_ == null || value != "") { + StartDate = value; + } + break; + } + case 58: { + string value = _single_endDate_codec.Read(input); + if (endDate_ == null || value != "") { + EndDate = value; + } + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.BidModifierSimulationPointList subBuilder = new global::Google.Ads.GoogleAds.V3.Common.BidModifierSimulationPointList(); + if (pointListCase_ == PointListOneofCase.BidModifierPointList) { + subBuilder.MergeFrom(BidModifierPointList); + } + input.ReadMessage(subBuilder); + BidModifierPointList = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignCriterionSimulationService.cs b/src/V3/Stubs/CampaignCriterionSimulationService.cs new file mode 100644 index 000000000..1d4030fce --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionSimulationService.cs @@ -0,0 +1,199 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_criterion_simulation_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_criterion_simulation_service.proto + public static partial class CampaignCriterionSimulationServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_criterion_simulation_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignCriterionSimulationServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9j", + "cml0ZXJpb25fc2ltdWxhdGlvbl9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlcxpFZ29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvcmVzb3VyY2VzL2NhbXBhaWduX2NyaXRlcmlvbl9zaW11bGF0aW9uLnBy", + "b3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBp", + "L2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90", + "byJDCiVHZXRDYW1wYWlnbkNyaXRlcmlvblNpbXVsYXRpb25SZXF1ZXN0EhoK", + "DXJlc291cmNlX25hbWUYASABKAlCA+BBAjLFAgoiQ2FtcGFpZ25Dcml0ZXJp", + "b25TaW11bGF0aW9uU2VydmljZRKBAgoeR2V0Q2FtcGFpZ25Dcml0ZXJpb25T", + "aW11bGF0aW9uEkcuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "R2V0Q2FtcGFpZ25Dcml0ZXJpb25TaW11bGF0aW9uUmVxdWVzdBo+Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DYW1wYWlnbkNyaXRlcmlv", + "blNpbXVsYXRpb24iVoLT5JMCQBI+L3YzL3tyZXNvdXJjZV9uYW1lPWN1c3Rv", + "bWVycy8qL2NhbXBhaWduQ3JpdGVyaW9uU2ltdWxhdGlvbnMvKn3aQQ1yZXNv", + "dXJjZV9uYW1lGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21CjgIKJGNv", + "bS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0InQ2FtcGFpZ25D", + "cml0ZXJpb25TaW11bGF0aW9uU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9z", + "ZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2Vydmlj", + "ZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulationReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionSimulationRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionSimulationRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [CampaignCriterionSimulationService.GetCampaignCriterionSimulation][google.ads.googleads.v3.services.CampaignCriterionSimulationService.GetCampaignCriterionSimulation]. + /// + public sealed partial class GetCampaignCriterionSimulationRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignCriterionSimulationRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionSimulationServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignCriterionSimulationRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignCriterionSimulationRequest(GetCampaignCriterionSimulationRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignCriterionSimulationRequest Clone() { + return new GetCampaignCriterionSimulationRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign criterion simulation to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignCriterionSimulationRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignCriterionSimulationRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignCriterionSimulationRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignCriterionSimulationServiceClient.cs b/src/V3/Stubs/CampaignCriterionSimulationServiceClient.cs new file mode 100644 index 000000000..c1b3623d9 --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionSimulationServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignCriterionSimulationServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignCriterionSimulationServiceSettings GetDefault() => new CampaignCriterionSimulationServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignCriterionSimulationServiceSettings() { } + + private CampaignCriterionSimulationServiceSettings(CampaignCriterionSimulationServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignCriterionSimulationSettings = existing.GetCampaignCriterionSimulationSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignCriterionSimulationServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignCriterionSimulationServiceClient.GetCampaignCriterionSimulation and CampaignCriterionSimulationServiceClient.GetCampaignCriterionSimulationAsync. + /// + /// + /// The default CampaignCriterionSimulationServiceClient.GetCampaignCriterionSimulation and + /// CampaignCriterionSimulationServiceClient.GetCampaignCriterionSimulationAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignCriterionSimulationSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignCriterionSimulationServiceSettings Clone() => new CampaignCriterionSimulationServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignCriterionSimulationServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignCriterionSimulationServiceSettings Settings { get; set; } + + /// + public override CampaignCriterionSimulationServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignCriterionSimulationServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignCriterionSimulationServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignCriterionSimulationServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignCriterionSimulationServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignCriterionSimulationServiceClient.ChannelPool; + } + + /// + /// CampaignCriterionSimulationService client wrapper, for convenient use. + /// + public abstract partial class CampaignCriterionSimulationServiceClient + { + /// + /// The default endpoint for the CampaignCriterionSimulationService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignCriterionSimulationService scopes. + /// + /// + /// The default CampaignCriterionSimulationService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignCriterionSimulationServiceClient client = await CampaignCriterionSimulationServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignCriterionSimulationServiceClient.DefaultEndpoint.Host, CampaignCriterionSimulationServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignCriterionSimulationServiceClient client = CampaignCriterionSimulationServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignCriterionSimulationServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignCriterionSimulationServiceClient client = CampaignCriterionSimulationServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignCriterionSimulationServiceClient.DefaultEndpoint.Host, CampaignCriterionSimulationServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignCriterionSimulationServiceClient client = CampaignCriterionSimulationServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignCriterionSimulationServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignCriterionSimulationServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignCriterionSimulationServiceClient Create(grpccore::Channel channel, CampaignCriterionSimulationServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignCriterionSimulationServiceClient Create(grpccore::CallInvoker callInvoker, CampaignCriterionSimulationServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignCriterionSimulationService.CampaignCriterionSimulationServiceClient grpcClient = new CampaignCriterionSimulationService.CampaignCriterionSimulationServiceClient(callInvoker); + return new CampaignCriterionSimulationServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignCriterionSimulationService client. + /// + public virtual CampaignCriterionSimulationService.CampaignCriterionSimulationServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// + /// Required. The resource name of the campaign criterion simulation to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignCriterionSimulationAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignCriterionSimulationAsync( + new GetCampaignCriterionSimulationRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// + /// Required. The resource name of the campaign criterion simulation to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignCriterionSimulationAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignCriterionSimulationAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// + /// Required. The resource name of the campaign criterion simulation to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignCriterionSimulation GetCampaignCriterionSimulation( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignCriterionSimulation( + new GetCampaignCriterionSimulationRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignCriterionSimulationAsync( + GetCampaignCriterionSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignCriterionSimulationAsync( + GetCampaignCriterionSimulationRequest request, + st::CancellationToken cancellationToken) => GetCampaignCriterionSimulationAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignCriterionSimulation GetCampaignCriterionSimulation( + GetCampaignCriterionSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignCriterionSimulationService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignCriterionSimulationServiceClientImpl : CampaignCriterionSimulationServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignCriterionSimulation; + + /// + /// Constructs a client wrapper for the CampaignCriterionSimulationService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignCriterionSimulationServiceClientImpl(CampaignCriterionSimulationService.CampaignCriterionSimulationServiceClient grpcClient, CampaignCriterionSimulationServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignCriterionSimulationServiceSettings effectiveSettings = settings ?? CampaignCriterionSimulationServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignCriterionSimulation = clientHelper.BuildApiCall( + GrpcClient.GetCampaignCriterionSimulationAsync, GrpcClient.GetCampaignCriterionSimulation, effectiveSettings.GetCampaignCriterionSimulationSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetCampaignCriterionSimulation); + Modify_GetCampaignCriterionSimulationApiCall(ref _callGetCampaignCriterionSimulation); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignCriterionSimulationApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignCriterionSimulationService.CampaignCriterionSimulationServiceClient grpcClient, CampaignCriterionSimulationServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignCriterionSimulationService client. + /// + public override CampaignCriterionSimulationService.CampaignCriterionSimulationServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignCriterionSimulationRequest(ref GetCampaignCriterionSimulationRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignCriterionSimulationAsync( + GetCampaignCriterionSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignCriterionSimulationRequest(ref request, ref callSettings); + return _callGetCampaignCriterionSimulation.Async(request, callSettings); + } + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignCriterionSimulation GetCampaignCriterionSimulation( + GetCampaignCriterionSimulationRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignCriterionSimulationRequest(ref request, ref callSettings); + return _callGetCampaignCriterionSimulation.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignCriterionSimulationServiceGrpc.cs b/src/V3/Stubs/CampaignCriterionSimulationServiceGrpc.cs new file mode 100644 index 000000000..be3528af0 --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionSimulationServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_criterion_simulation_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch campaign criterion simulations. + /// + public static partial class CampaignCriterionSimulationService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignCriterionSimulationService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignCriterionSimulationRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionSimulationRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignCriterionSimulation = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignCriterionSimulation = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignCriterionSimulation", + __Marshaller_google_ads_googleads_v3_services_GetCampaignCriterionSimulationRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignCriterionSimulation); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionSimulationServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignCriterionSimulationService + public abstract partial class CampaignCriterionSimulationServiceBase + { + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignCriterionSimulation(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionSimulationRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignCriterionSimulationService + public partial class CampaignCriterionSimulationServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignCriterionSimulationService + /// The channel to use to make remote calls. + public CampaignCriterionSimulationServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignCriterionSimulationService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignCriterionSimulationServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignCriterionSimulationServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignCriterionSimulationServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation GetCampaignCriterionSimulation(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionSimulationRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignCriterionSimulation(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation GetCampaignCriterionSimulation(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionSimulationRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignCriterionSimulation, null, options, request); + } + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignCriterionSimulationAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionSimulationRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignCriterionSimulationAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign criterion simulation in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignCriterionSimulationAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignCriterionSimulationRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignCriterionSimulation, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignCriterionSimulationServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignCriterionSimulationServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignCriterionSimulationServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignCriterionSimulation, serviceImpl.GetCampaignCriterionSimulation).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignCriterionSimulationServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignCriterionSimulation, serviceImpl.GetCampaignCriterionSimulation); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignCriterionStatus.cs b/src/V3/Stubs/CampaignCriterionStatus.cs new file mode 100644 index 000000000..aefdf330d --- /dev/null +++ b/src/V3/Stubs/CampaignCriterionStatus.cs @@ -0,0 +1,192 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/campaign_criterion_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/campaign_criterion_status.proto + public static partial class CampaignCriterionStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/campaign_criterion_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignCriterionStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWlnbl9jcml0", + "ZXJpb25fc3RhdHVzLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJ8ChtDYW1wYWln", + "bkNyaXRlcmlvblN0YXR1c0VudW0iXQoXQ2FtcGFpZ25Dcml0ZXJpb25TdGF0", + "dXMSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESCwoHRU5BQkxFRBAC", + "EgoKBlBBVVNFRBADEgsKB1JFTU9WRUQQBELxAQohY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zQhxDYW1wYWlnbkNyaXRlcmlvblN0YXR1c1By", + "b3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5B", + "ZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNi", + "BnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignCriterionStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.CampaignCriterionStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignCriterionStatusEnum.Types.CampaignCriterionStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing CampaignCriterion statuses. + /// + public sealed partial class CampaignCriterionStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignCriterionStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CampaignCriterionStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionStatusEnum(CampaignCriterionStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignCriterionStatusEnum Clone() { + return new CampaignCriterionStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignCriterionStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignCriterionStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignCriterionStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignCriterionStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of a CampaignCriterion. + /// + public enum CampaignCriterionStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The campaign criterion is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// The campaign criterion is paused. + /// + [pbr::OriginalName("PAUSED")] Paused = 3, + /// + /// The campaign criterion is removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignDraft.cs b/src/V3/Stubs/CampaignDraft.cs new file mode 100644 index 000000000..0d1047a0b --- /dev/null +++ b/src/V3/Stubs/CampaignDraft.cs @@ -0,0 +1,475 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_draft.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_draft.proto + public static partial class CampaignDraftReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_draft.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignDraftReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "ZHJhZnQucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvY2FtcGFpZ25fZHJh", + "ZnRfc3RhdHVzLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnBy", + "b3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9i", + "dWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJv", + "dG8ivwUKDUNhbXBhaWduRHJhZnQSRQoNcmVzb3VyY2VfbmFtZRgBIAEoCUIu", + "4EEF+kEoCiZnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2FtcGFpZ25EcmFm", + "dBIyCghkcmFmdF9pZBgCIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZh", + "bHVlQgPgQQMSXgoNYmFzZV9jYW1wYWlnbhgDIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZUIp4EEF+kEjCiFnb29nbGVhZHMuZ29vZ2xlYXBp", + "cy5jb20vQ2FtcGFpZ24SKgoEbmFtZRgEIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZRJfCg5kcmFmdF9jYW1wYWlnbhgFIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIp4EED+kEjCiFnb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb20vQ2FtcGFpZ24SXwoGc3RhdHVzGAYgASgOMkouZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXMuQ2FtcGFpZ25EcmFmdFN0YXR1c0Vu", + "dW0uQ2FtcGFpZ25EcmFmdFN0YXR1c0ID4EEDEj8KFmhhc19leHBlcmltZW50", + "X3J1bm5pbmcYByABKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlQgPg", + "QQMSQQoWbG9uZ19ydW5uaW5nX29wZXJhdGlvbhgIIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDOmHqQV4KJmdvb2dsZWFkcy5nb29n", + "bGVhcGlzLmNvbS9DYW1wYWlnbkRyYWZ0EjRjdXN0b21lcnMve2N1c3RvbWVy", + "fS9jYW1wYWlnbkRyYWZ0cy97Y2FtcGFpZ25fZHJhZnR9Qv8BCiVjb20uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzQhJDYW1wYWlnbkRyYWZ0", + "UHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBp", + "cy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNHQUGq", + "AiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29nbGVc", + "QWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.CampaignDraftStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft), global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft.Parser, new[]{ "ResourceName", "DraftId", "BaseCampaign", "Name", "DraftCampaign", "Status", "HasExperimentRunning", "LongRunningOperation" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A campaign draft. + /// + public sealed partial class CampaignDraft : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignDraft()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignDraftReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraft() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraft(CampaignDraft other) : this() { + resourceName_ = other.resourceName_; + DraftId = other.DraftId; + BaseCampaign = other.BaseCampaign; + Name = other.Name; + DraftCampaign = other.DraftCampaign; + status_ = other.status_; + HasExperimentRunning = other.HasExperimentRunning; + LongRunningOperation = other.LongRunningOperation; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraft Clone() { + return new CampaignDraft(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign draft. + /// Campaign draft resource names have the form: + /// + /// `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "draft_id" field. + public const int DraftIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_draftId_codec = pb::FieldCodec.ForStructWrapper(18); + private long? draftId_; + /// + /// Output only. The ID of the draft. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? DraftId { + get { return draftId_; } + set { + draftId_ = value; + } + } + + + /// Field number for the "base_campaign" field. + public const int BaseCampaignFieldNumber = 3; + private static readonly pb::FieldCodec _single_baseCampaign_codec = pb::FieldCodec.ForClassWrapper(26); + private string baseCampaign_; + /// + /// Immutable. The base campaign to which the draft belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BaseCampaign { + get { return baseCampaign_; } + set { + baseCampaign_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// The name of the campaign draft. + /// + /// This field is required and should not be empty when creating new + /// campaign drafts. + /// + /// It must not contain any null (code point 0x0), NL line feed + /// (code point 0xA) or carriage return (code point 0xD) characters. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "draft_campaign" field. + public const int DraftCampaignFieldNumber = 5; + private static readonly pb::FieldCodec _single_draftCampaign_codec = pb::FieldCodec.ForClassWrapper(42); + private string draftCampaign_; + /// + /// Output only. Resource name of the Campaign that results from overlaying the draft + /// changes onto the base campaign. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DraftCampaign { + get { return draftCampaign_; } + set { + draftCampaign_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.CampaignDraftStatusEnum.Types.CampaignDraftStatus status_ = 0; + /// + /// Output only. The status of the campaign draft. This field is read-only. + /// + /// When a new campaign draft is added, the status defaults to PROPOSED. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CampaignDraftStatusEnum.Types.CampaignDraftStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "has_experiment_running" field. + public const int HasExperimentRunningFieldNumber = 7; + private static readonly pb::FieldCodec _single_hasExperimentRunning_codec = pb::FieldCodec.ForStructWrapper(58); + private bool? hasExperimentRunning_; + /// + /// Output only. Whether there is an experiment based on this draft currently serving. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? HasExperimentRunning { + get { return hasExperimentRunning_; } + set { + hasExperimentRunning_ = value; + } + } + + + /// Field number for the "long_running_operation" field. + public const int LongRunningOperationFieldNumber = 8; + private static readonly pb::FieldCodec _single_longRunningOperation_codec = pb::FieldCodec.ForClassWrapper(66); + private string longRunningOperation_; + /// + /// Output only. The resource name of the long-running operation that can be used to poll + /// for completion of draft promotion. This is only set if the draft promotion + /// is in progress or finished. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LongRunningOperation { + get { return longRunningOperation_; } + set { + longRunningOperation_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignDraft); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignDraft other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (DraftId != other.DraftId) return false; + if (BaseCampaign != other.BaseCampaign) return false; + if (Name != other.Name) return false; + if (DraftCampaign != other.DraftCampaign) return false; + if (Status != other.Status) return false; + if (HasExperimentRunning != other.HasExperimentRunning) return false; + if (LongRunningOperation != other.LongRunningOperation) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (draftId_ != null) hash ^= DraftId.GetHashCode(); + if (baseCampaign_ != null) hash ^= BaseCampaign.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (draftCampaign_ != null) hash ^= DraftCampaign.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (hasExperimentRunning_ != null) hash ^= HasExperimentRunning.GetHashCode(); + if (longRunningOperation_ != null) hash ^= LongRunningOperation.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (draftId_ != null) { + _single_draftId_codec.WriteTagAndValue(output, DraftId); + } + if (baseCampaign_ != null) { + _single_baseCampaign_codec.WriteTagAndValue(output, BaseCampaign); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (draftCampaign_ != null) { + _single_draftCampaign_codec.WriteTagAndValue(output, DraftCampaign); + } + if (Status != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) Status); + } + if (hasExperimentRunning_ != null) { + _single_hasExperimentRunning_codec.WriteTagAndValue(output, HasExperimentRunning); + } + if (longRunningOperation_ != null) { + _single_longRunningOperation_codec.WriteTagAndValue(output, LongRunningOperation); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (draftId_ != null) { + size += _single_draftId_codec.CalculateSizeWithTag(DraftId); + } + if (baseCampaign_ != null) { + size += _single_baseCampaign_codec.CalculateSizeWithTag(BaseCampaign); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (draftCampaign_ != null) { + size += _single_draftCampaign_codec.CalculateSizeWithTag(DraftCampaign); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (hasExperimentRunning_ != null) { + size += _single_hasExperimentRunning_codec.CalculateSizeWithTag(HasExperimentRunning); + } + if (longRunningOperation_ != null) { + size += _single_longRunningOperation_codec.CalculateSizeWithTag(LongRunningOperation); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignDraft other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.draftId_ != null) { + if (draftId_ == null || other.DraftId != 0L) { + DraftId = other.DraftId; + } + } + if (other.baseCampaign_ != null) { + if (baseCampaign_ == null || other.BaseCampaign != "") { + BaseCampaign = other.BaseCampaign; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.draftCampaign_ != null) { + if (draftCampaign_ == null || other.DraftCampaign != "") { + DraftCampaign = other.DraftCampaign; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.hasExperimentRunning_ != null) { + if (hasExperimentRunning_ == null || other.HasExperimentRunning != false) { + HasExperimentRunning = other.HasExperimentRunning; + } + } + if (other.longRunningOperation_ != null) { + if (longRunningOperation_ == null || other.LongRunningOperation != "") { + LongRunningOperation = other.LongRunningOperation; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_draftId_codec.Read(input); + if (draftId_ == null || value != 0L) { + DraftId = value; + } + break; + } + case 26: { + string value = _single_baseCampaign_codec.Read(input); + if (baseCampaign_ == null || value != "") { + BaseCampaign = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 42: { + string value = _single_draftCampaign_codec.Read(input); + if (draftCampaign_ == null || value != "") { + DraftCampaign = value; + } + break; + } + case 48: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.CampaignDraftStatusEnum.Types.CampaignDraftStatus) input.ReadEnum(); + break; + } + case 58: { + bool? value = _single_hasExperimentRunning_codec.Read(input); + if (hasExperimentRunning_ == null || value != false) { + HasExperimentRunning = value; + } + break; + } + case 66: { + string value = _single_longRunningOperation_codec.Read(input); + if (longRunningOperation_ == null || value != "") { + LongRunningOperation = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignDraftError.cs b/src/V3/Stubs/CampaignDraftError.cs new file mode 100644 index 000000000..43629dc32 --- /dev/null +++ b/src/V3/Stubs/CampaignDraftError.cs @@ -0,0 +1,230 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/campaign_draft_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/campaign_draft_error.proto + public static partial class CampaignDraftErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/campaign_draft_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignDraftErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2FtcGFpZ25fZHJh", + "ZnRfZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9y", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLIAwoWQ2FtcGFpZ25E", + "cmFmdEVycm9yRW51bSKtAwoSQ2FtcGFpZ25EcmFmdEVycm9yEg8KC1VOU1BF", + "Q0lGSUVEEAASCwoHVU5LTk9XThABEhgKFERVUExJQ0FURV9EUkFGVF9OQU1F", + "EAISKgomSU5WQUxJRF9TVEFUVVNfVFJBTlNJVElPTl9GUk9NX1JFTU9WRUQQ", + "AxIrCidJTlZBTElEX1NUQVRVU19UUkFOU0lUSU9OX0ZST01fUFJPTU9URUQQ", + "BBIxCi1JTlZBTElEX1NUQVRVU19UUkFOU0lUSU9OX0ZST01fUFJPTU9URV9G", + "QUlMRUQQBRIgChxDVVNUT01FUl9DQU5OT1RfQ1JFQVRFX0RSQUZUEAYSIAoc", + "Q0FNUEFJR05fQ0FOTk9UX0NSRUFURV9EUkFGVBAHEhgKFElOVkFMSURfRFJB", + "RlRfQ0hBTkdFEAgSHQoZSU5WQUxJRF9TVEFUVVNfVFJBTlNJVElPThAJEi0K", + "KU1BWF9OVU1CRVJfT0ZfRFJBRlRTX1BFUl9DQU1QQUlHTl9SRUFDSEVEEAoS", + "JwojTElTVF9FUlJPUlNfRk9SX1BST01PVEVEX0RSQUZUX09OTFkQC0LyAQoi", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IXQ2FtcGFpZ25E", + "cmFmdEVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8v", + "Z29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOiAgNH", + "QUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVc", + "QWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29vZ2xl", + "QWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignDraftErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CampaignDraftErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignDraftErrorEnum.Types.CampaignDraftError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible campaign draft errors. + /// + public sealed partial class CampaignDraftErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignDraftErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CampaignDraftErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftErrorEnum(CampaignDraftErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftErrorEnum Clone() { + return new CampaignDraftErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignDraftErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignDraftErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignDraftErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignDraftErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible campaign draft errors. + /// + public enum CampaignDraftError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// A draft with this name already exists for this campaign. + /// + [pbr::OriginalName("DUPLICATE_DRAFT_NAME")] DuplicateDraftName = 2, + /// + /// The draft is removed and cannot be transitioned to another status. + /// + [pbr::OriginalName("INVALID_STATUS_TRANSITION_FROM_REMOVED")] InvalidStatusTransitionFromRemoved = 3, + /// + /// The draft has been promoted and cannot be transitioned to the specified + /// status. + /// + [pbr::OriginalName("INVALID_STATUS_TRANSITION_FROM_PROMOTED")] InvalidStatusTransitionFromPromoted = 4, + /// + /// The draft has failed to be promoted and cannot be transitioned to the + /// specified status. + /// + [pbr::OriginalName("INVALID_STATUS_TRANSITION_FROM_PROMOTE_FAILED")] InvalidStatusTransitionFromPromoteFailed = 5, + /// + /// This customer is not allowed to create drafts. + /// + [pbr::OriginalName("CUSTOMER_CANNOT_CREATE_DRAFT")] CustomerCannotCreateDraft = 6, + /// + /// This campaign is not allowed to create drafts. + /// + [pbr::OriginalName("CAMPAIGN_CANNOT_CREATE_DRAFT")] CampaignCannotCreateDraft = 7, + /// + /// This modification cannot be made on a draft. + /// + [pbr::OriginalName("INVALID_DRAFT_CHANGE")] InvalidDraftChange = 8, + /// + /// The draft cannot be transitioned to the specified status from its + /// current status. + /// + [pbr::OriginalName("INVALID_STATUS_TRANSITION")] InvalidStatusTransition = 9, + /// + /// The campaign has reached the maximum number of drafts that can be created + /// for a campaign throughout its lifetime. No additional drafts can be + /// created for this campaign. Removed drafts also count towards this limit. + /// + [pbr::OriginalName("MAX_NUMBER_OF_DRAFTS_PER_CAMPAIGN_REACHED")] MaxNumberOfDraftsPerCampaignReached = 10, + /// + /// ListAsyncErrors was called without first promoting the draft. + /// + [pbr::OriginalName("LIST_ERRORS_FOR_PROMOTED_DRAFT_ONLY")] ListErrorsForPromotedDraftOnly = 11, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignDraftService.cs b/src/V3/Stubs/CampaignDraftService.cs new file mode 100644 index 000000000..789ead7d8 --- /dev/null +++ b/src/V3/Stubs/CampaignDraftService.cs @@ -0,0 +1,1554 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_draft_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_draft_service.proto + public static partial class CampaignDraftServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_draft_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignDraftServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9k", + "cmFmdF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2Nh", + "bXBhaWduX2RyYWZ0LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVs", + "ZF9iZWhhdmlvci5wcm90bxojZ29vZ2xlL2xvbmdydW5uaW5nL29wZXJhdGlv", + "bnMucHJvdG8aIGdvb2dsZS9wcm90b2J1Zi9maWVsZF9tYXNrLnByb3RvGhdn", + "b29nbGUvcnBjL3N0YXR1cy5wcm90byI1ChdHZXRDYW1wYWlnbkRyYWZ0UmVx", + "dWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIiugEKG011dGF0ZUNh", + "bXBhaWduRHJhZnRzUmVxdWVzdBIYCgtjdXN0b21lcl9pZBgBIAEoCUID4EEC", + "ElEKCm9wZXJhdGlvbnMYAiADKAsyOC5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5DYW1wYWlnbkRyYWZ0T3BlcmF0aW9uQgPgQQISFwoPcGFy", + "dGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlkYXRlX29ubHkYBCABKAgiOgob", + "UHJvbW90ZUNhbXBhaWduRHJhZnRSZXF1ZXN0EhsKDmNhbXBhaWduX2RyYWZ0", + "GAEgASgJQgPgQQIi8AEKFkNhbXBhaWduRHJhZnRPcGVyYXRpb24SLwoLdXBk", + "YXRlX21hc2sYBCABKAsyGi5nb29nbGUucHJvdG9idWYuRmllbGRNYXNrEkIK", + "BmNyZWF0ZRgBIAEoCzIwLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291", + "cmNlcy5DYW1wYWlnbkRyYWZ0SAASQgoGdXBkYXRlGAIgASgLMjAuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduRHJhZnRIABIQ", + "CgZyZW1vdmUYAyABKAlIAEILCglvcGVyYXRpb24inwEKHE11dGF0ZUNhbXBh", + "aWduRHJhZnRzUmVzcG9uc2USMQoVcGFydGlhbF9mYWlsdXJlX2Vycm9yGAMg", + "ASgLMhIuZ29vZ2xlLnJwYy5TdGF0dXMSTAoHcmVzdWx0cxgCIAMoCzI7Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUNhbXBhaWdu", + "RHJhZnRSZXN1bHQiMgoZTXV0YXRlQ2FtcGFpZ25EcmFmdFJlc3VsdBIVCg1y", + "ZXNvdXJjZV9uYW1lGAEgASgJImgKI0xpc3RDYW1wYWlnbkRyYWZ0QXN5bmNF", + "cnJvcnNSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAhISCgpw", + "YWdlX3Rva2VuGAIgASgJEhEKCXBhZ2Vfc2l6ZRgDIAEoBSJjCiRMaXN0Q2Ft", + "cGFpZ25EcmFmdEFzeW5jRXJyb3JzUmVzcG9uc2USIgoGZXJyb3JzGAEgAygL", + "MhIuZ29vZ2xlLnJwYy5TdGF0dXMSFwoPbmV4dF9wYWdlX3Rva2VuGAIgASgJ", + "MuIHChRDYW1wYWlnbkRyYWZ0U2VydmljZRLJAQoQR2V0Q2FtcGFpZ25EcmFm", + "dBI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldENhbXBh", + "aWduRHJhZnRSZXF1ZXN0GjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLkNhbXBhaWduRHJhZnQiSILT5JMCMhIwL3YzL3tyZXNvdXJjZV9u", + "YW1lPWN1c3RvbWVycy8qL2NhbXBhaWduRHJhZnRzLyp92kENcmVzb3VyY2Vf", + "bmFtZRLuAQoUTXV0YXRlQ2FtcGFpZ25EcmFmdHMSPS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDYW1wYWlnbkRyYWZ0c1JlcXVl", + "c3QaPi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVD", + "YW1wYWlnbkRyYWZ0c1Jlc3BvbnNlIleC0+STAjgiMy92My9jdXN0b21lcnMv", + "e2N1c3RvbWVyX2lkPSp9L2NhbXBhaWduRHJhZnRzOm11dGF0ZToBKtpBFmN1", + "c3RvbWVyX2lkLG9wZXJhdGlvbnMS5QEKFFByb21vdGVDYW1wYWlnbkRyYWZ0", + "Ej0uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuUHJvbW90ZUNh", + "bXBhaWduRHJhZnRSZXF1ZXN0Gh0uZ29vZ2xlLmxvbmdydW5uaW5nLk9wZXJh", + "dGlvbiJvgtPkkwI+IjkvdjMve2NhbXBhaWduX2RyYWZ0PWN1c3RvbWVycy8q", + "L2NhbXBhaWduRHJhZnRzLyp9OnByb21vdGU6ASraQQ5jYW1wYWlnbl9kcmFm", + "dMpBFwoVZ29vZ2xlLnByb3RvYnVmLkVtcHR5EocCChxMaXN0Q2FtcGFpZ25E", + "cmFmdEFzeW5jRXJyb3JzEkUuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuTGlzdENhbXBhaWduRHJhZnRBc3luY0Vycm9yc1JlcXVlc3QaRi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5MaXN0Q2FtcGFpZ25E", + "cmFmdEFzeW5jRXJyb3JzUmVzcG9uc2UiWILT5JMCQhJAL3YzL3tyZXNvdXJj", + "ZV9uYW1lPWN1c3RvbWVycy8qL2NhbXBhaWduRHJhZnRzLyp9Omxpc3RBc3lu", + "Y0Vycm9yc9pBDXJlc291cmNlX25hbWUaG8pBGGdvb2dsZWFkcy5nb29nbGVh", + "cGlzLmNvbUKAAgokY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzQhlDYW1wYWlnbkRyYWZ0U2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9z", + "ZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2Vydmlj", + "ZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignDraftReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.LongRunning.OperationsReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignDraftRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignDraftRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignDraftRequest), global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignDraftRequest.Parser, new[]{ "CampaignDraft" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignDraftOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignDraftOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftResult.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsRequest), global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsRequest.Parser, new[]{ "ResourceName", "PageToken", "PageSize" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsResponse), global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsResponse.Parser, new[]{ "Errors", "NextPageToken" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignDraftService.GetCampaignDraft][google.ads.googleads.v3.services.CampaignDraftService.GetCampaignDraft]. + /// + public sealed partial class GetCampaignDraftRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignDraftRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignDraftRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignDraftRequest(GetCampaignDraftRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignDraftRequest Clone() { + return new GetCampaignDraftRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign draft to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignDraftRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignDraftRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignDraftRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignDraftService.MutateCampaignDrafts][google.ads.googleads.v3.services.CampaignDraftService.MutateCampaignDrafts]. + /// + public sealed partial class MutateCampaignDraftsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignDraftsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftsRequest(MutateCampaignDraftsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftsRequest Clone() { + return new MutateCampaignDraftsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose campaign drafts are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignDraftOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual campaign drafts. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignDraftsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignDraftsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignDraftsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignDraftService.PromoteCampaignDraft][google.ads.googleads.v3.services.CampaignDraftService.PromoteCampaignDraft]. + /// + public sealed partial class PromoteCampaignDraftRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PromoteCampaignDraftRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromoteCampaignDraftRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromoteCampaignDraftRequest(PromoteCampaignDraftRequest other) : this() { + campaignDraft_ = other.campaignDraft_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromoteCampaignDraftRequest Clone() { + return new PromoteCampaignDraftRequest(this); + } + + /// Field number for the "campaign_draft" field. + public const int CampaignDraftFieldNumber = 1; + private string campaignDraft_ = ""; + /// + /// Required. The resource name of the campaign draft to promote. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignDraft { + get { return campaignDraft_; } + set { + campaignDraft_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PromoteCampaignDraftRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PromoteCampaignDraftRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CampaignDraft != other.CampaignDraft) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CampaignDraft.Length != 0) hash ^= CampaignDraft.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CampaignDraft.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CampaignDraft); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CampaignDraft.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CampaignDraft); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PromoteCampaignDraftRequest other) { + if (other == null) { + return; + } + if (other.CampaignDraft.Length != 0) { + CampaignDraft = other.CampaignDraft; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CampaignDraft = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a campaign draft. + /// + public sealed partial class CampaignDraftOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignDraftOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftOperation(CampaignDraftOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftOperation Clone() { + return new CampaignDraftOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new campaign + /// draft. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The campaign draft is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: The campaign draft is expected to have a valid + /// resource name, in this format: + /// + /// `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignDraftOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignDraftOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignDraftOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for campaign draft mutate. + /// + public sealed partial class MutateCampaignDraftsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignDraftsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftsResponse(MutateCampaignDraftsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftsResponse Clone() { + return new MutateCampaignDraftsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignDraftsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignDraftsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignDraftsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the campaign draft mutate. + /// + public sealed partial class MutateCampaignDraftResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignDraftResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftResult(MutateCampaignDraftResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignDraftResult Clone() { + return new MutateCampaignDraftResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignDraftResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignDraftResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignDraftResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors]. + /// + public sealed partial class ListCampaignDraftAsyncErrorsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListCampaignDraftAsyncErrorsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignDraftAsyncErrorsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignDraftAsyncErrorsRequest(ListCampaignDraftAsyncErrorsRequest other) : this() { + resourceName_ = other.resourceName_; + pageToken_ = other.pageToken_; + pageSize_ = other.pageSize_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignDraftAsyncErrorsRequest Clone() { + return new ListCampaignDraftAsyncErrorsRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The name of the campaign draft from which to retrieve the async errors. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "page_token" field. + public const int PageTokenFieldNumber = 2; + private string pageToken_ = ""; + /// + /// Token of the page to retrieve. If not specified, the first + /// page of results will be returned. Use the value obtained from + /// `next_page_token` in the previous response in order to request + /// the next page of results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PageToken { + get { return pageToken_; } + set { + pageToken_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "page_size" field. + public const int PageSizeFieldNumber = 3; + private int pageSize_; + /// + /// Number of elements to retrieve in a single page. + /// When a page request is too large, the server may decide to + /// further limit the number of returned resources. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int PageSize { + get { return pageSize_; } + set { + pageSize_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListCampaignDraftAsyncErrorsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListCampaignDraftAsyncErrorsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (PageToken != other.PageToken) return false; + if (PageSize != other.PageSize) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (PageToken.Length != 0) hash ^= PageToken.GetHashCode(); + if (PageSize != 0) hash ^= PageSize.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (PageToken.Length != 0) { + output.WriteRawTag(18); + output.WriteString(PageToken); + } + if (PageSize != 0) { + output.WriteRawTag(24); + output.WriteInt32(PageSize); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (PageToken.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(PageToken); + } + if (PageSize != 0) { + size += 1 + pb::CodedOutputStream.ComputeInt32Size(PageSize); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListCampaignDraftAsyncErrorsRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.PageToken.Length != 0) { + PageToken = other.PageToken; + } + if (other.PageSize != 0) { + PageSize = other.PageSize; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + PageToken = input.ReadString(); + break; + } + case 24: { + PageSize = input.ReadInt32(); + break; + } + } + } + } + + } + + /// + /// Response message for [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors]. + /// + public sealed partial class ListCampaignDraftAsyncErrorsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListCampaignDraftAsyncErrorsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignDraftAsyncErrorsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignDraftAsyncErrorsResponse(ListCampaignDraftAsyncErrorsResponse other) : this() { + errors_ = other.errors_.Clone(); + nextPageToken_ = other.nextPageToken_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignDraftAsyncErrorsResponse Clone() { + return new ListCampaignDraftAsyncErrorsResponse(this); + } + + /// Field number for the "errors" field. + public const int ErrorsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_errors_codec + = pb::FieldCodec.ForMessage(10, global::Google.Rpc.Status.Parser); + private readonly pbc::RepeatedField errors_ = new pbc::RepeatedField(); + /// + /// Details of the errors when performing the asynchronous operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Errors { + get { return errors_; } + } + + /// Field number for the "next_page_token" field. + public const int NextPageTokenFieldNumber = 2; + private string nextPageToken_ = ""; + /// + /// Pagination token used to retrieve the next page of results. + /// Pass the content of this string as the `page_token` attribute of + /// the next request. `next_page_token` is not returned for the last + /// page. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string NextPageToken { + get { return nextPageToken_; } + set { + nextPageToken_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListCampaignDraftAsyncErrorsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListCampaignDraftAsyncErrorsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!errors_.Equals(other.errors_)) return false; + if (NextPageToken != other.NextPageToken) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= errors_.GetHashCode(); + if (NextPageToken.Length != 0) hash ^= NextPageToken.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + errors_.WriteTo(output, _repeated_errors_codec); + if (NextPageToken.Length != 0) { + output.WriteRawTag(18); + output.WriteString(NextPageToken); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += errors_.CalculateSize(_repeated_errors_codec); + if (NextPageToken.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(NextPageToken); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListCampaignDraftAsyncErrorsResponse other) { + if (other == null) { + return; + } + errors_.Add(other.errors_); + if (other.NextPageToken.Length != 0) { + NextPageToken = other.NextPageToken; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + errors_.AddEntriesFrom(input, _repeated_errors_codec); + break; + } + case 18: { + NextPageToken = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignDraftServiceClient.cs b/src/V3/Stubs/CampaignDraftServiceClient.cs new file mode 100644 index 000000000..b1d482928 --- /dev/null +++ b/src/V3/Stubs/CampaignDraftServiceClient.cs @@ -0,0 +1,1417 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using lro = Google.LongRunning; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using gr = Google.Rpc; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignDraftServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignDraftServiceSettings GetDefault() => new CampaignDraftServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignDraftServiceSettings() { } + + private CampaignDraftServiceSettings(CampaignDraftServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignDraftSettings = existing.GetCampaignDraftSettings; + MutateCampaignDraftsSettings = existing.MutateCampaignDraftsSettings; + PromoteCampaignDraftSettings = existing.PromoteCampaignDraftSettings; + PromoteCampaignDraftOperationsSettings = existing.PromoteCampaignDraftOperationsSettings?.Clone(); + ListCampaignDraftAsyncErrorsSettings = existing.ListCampaignDraftAsyncErrorsSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignDraftServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignDraftServiceClient.GetCampaignDraft and CampaignDraftServiceClient.GetCampaignDraftAsync. + /// + /// + /// The default CampaignDraftServiceClient.GetCampaignDraft and + /// CampaignDraftServiceClient.GetCampaignDraftAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignDraftSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignDraftServiceClient.MutateCampaignDrafts and CampaignDraftServiceClient.MutateCampaignDraftsAsync. + /// + /// + /// The default CampaignDraftServiceClient.MutateCampaignDrafts and + /// CampaignDraftServiceClient.MutateCampaignDraftsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignDraftsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignDraftServiceClient.PromoteCampaignDraft and CampaignDraftServiceClient.PromoteCampaignDraftAsync. + /// + /// + /// The default CampaignDraftServiceClient.PromoteCampaignDraft and + /// CampaignDraftServiceClient.PromoteCampaignDraftAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings PromoteCampaignDraftSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Long Running Operation settings for calls to CampaignDraftServiceClient.PromoteCampaignDraft. + /// + /// + /// Uses default of: + /// + /// Initial delay: 500 milliseconds + /// Delay multiplier: 1.5 + /// Maximum delay: 5000 milliseconds + /// Total timeout: 300000 milliseconds + /// + /// + public lro::OperationsSettings PromoteCampaignDraftOperationsSettings { get; set; } = new lro::OperationsSettings + { + DefaultPollSettings = new gax::PollSettings( + gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(300000L)), + sys::TimeSpan.FromMilliseconds(500L), + 1.5, + sys::TimeSpan.FromMilliseconds(5000L)) + }; + + /// + /// for synchronous and asynchronous calls to + /// CampaignDraftServiceClient.ListCampaignDraftAsyncErrors and CampaignDraftServiceClient.ListCampaignDraftAsyncErrorsAsync. + /// + /// + /// The default CampaignDraftServiceClient.ListCampaignDraftAsyncErrors and + /// CampaignDraftServiceClient.ListCampaignDraftAsyncErrorsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings ListCampaignDraftAsyncErrorsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignDraftServiceSettings Clone() => new CampaignDraftServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignDraftServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignDraftServiceSettings Settings { get; set; } + + /// + public override CampaignDraftServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignDraftServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignDraftServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignDraftServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignDraftServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignDraftServiceClient.ChannelPool; + } + + /// + /// CampaignDraftService client wrapper, for convenient use. + /// + public abstract partial class CampaignDraftServiceClient + { + /// + /// The default endpoint for the CampaignDraftService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignDraftService scopes. + /// + /// + /// The default CampaignDraftService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignDraftServiceClient client = await CampaignDraftServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignDraftServiceClient.DefaultEndpoint.Host, CampaignDraftServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignDraftServiceClient client = CampaignDraftServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignDraftServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignDraftServiceClient client = CampaignDraftServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignDraftServiceClient.DefaultEndpoint.Host, CampaignDraftServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignDraftServiceClient client = CampaignDraftServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignDraftServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignDraftServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignDraftServiceClient Create(grpccore::Channel channel, CampaignDraftServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignDraftServiceClient Create(grpccore::CallInvoker callInvoker, CampaignDraftServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignDraftService.CampaignDraftServiceClient grpcClient = new CampaignDraftService.CampaignDraftServiceClient(callInvoker); + return new CampaignDraftServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignDraftService client. + /// + public virtual CampaignDraftService.CampaignDraftServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign draft in full detail. + /// + /// + /// Required. The resource name of the campaign draft to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignDraftAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignDraftAsync( + new GetCampaignDraftRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign draft in full detail. + /// + /// + /// Required. The resource name of the campaign draft to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignDraftAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignDraftAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign draft in full detail. + /// + /// + /// Required. The resource name of the campaign draft to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignDraft GetCampaignDraft( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignDraft( + new GetCampaignDraftRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign draft in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignDraftAsync( + GetCampaignDraftRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign draft in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignDraftAsync( + GetCampaignDraftRequest request, + st::CancellationToken cancellationToken) => GetCampaignDraftAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign draft in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignDraft GetCampaignDraft( + GetCampaignDraftRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign drafts are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign drafts. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignDraftsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignDraftsAsync( + new MutateCampaignDraftsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign drafts are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign drafts. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignDraftsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignDraftsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign drafts are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign drafts. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignDraftsResponse MutateCampaignDrafts( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignDrafts( + new MutateCampaignDraftsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign drafts are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign drafts. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignDraftsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignDraftsAsync( + new MutateCampaignDraftsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign drafts are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign drafts. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignDraftsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignDraftsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign drafts are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign drafts. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignDraftsResponse MutateCampaignDrafts( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignDrafts( + new MutateCampaignDraftsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignDraftsAsync( + MutateCampaignDraftsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignDraftsAsync( + MutateCampaignDraftsRequest request, + st::CancellationToken cancellationToken) => MutateCampaignDraftsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignDraftsResponse MutateCampaignDrafts( + MutateCampaignDraftsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// + /// Required. The resource name of the campaign draft to promote. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> PromoteCampaignDraftAsync( + string campaignDraft, + gaxgrpc::CallSettings callSettings = null) => PromoteCampaignDraftAsync( + new PromoteCampaignDraftRequest + { + CampaignDraft = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignDraft, nameof(campaignDraft)), + }, + callSettings); + + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// + /// Required. The resource name of the campaign draft to promote. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> PromoteCampaignDraftAsync( + string campaignDraft, + st::CancellationToken cancellationToken) => PromoteCampaignDraftAsync( + campaignDraft, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// + /// Required. The resource name of the campaign draft to promote. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual lro::Operation PromoteCampaignDraft( + string campaignDraft, + gaxgrpc::CallSettings callSettings = null) => PromoteCampaignDraft( + new PromoteCampaignDraftRequest + { + CampaignDraft = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignDraft, nameof(campaignDraft)), + }, + callSettings); + + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> PromoteCampaignDraftAsync( + PromoteCampaignDraftRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Asynchronously poll an operation once, using an operationName from a previous invocation of PromoteCampaignDraftAsync. + /// + /// The name of a previously invoked operation. Must not be null or empty. + /// If not null, applies overrides to this RPC call. + /// A task representing the result of polling the operation. + public virtual stt::Task> PollOncePromoteCampaignDraftAsync( + string operationName, + gaxgrpc::CallSettings callSettings = null) => lro::Operation.PollOnceFromNameAsync( + gax::GaxPreconditions.CheckNotNullOrEmpty(operationName, nameof(operationName)), + PromoteCampaignDraftOperationsClient, + callSettings); + + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual lro::Operation PromoteCampaignDraft( + PromoteCampaignDraftRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// The long-running operations client for PromoteCampaignDraft. + /// + public virtual lro::OperationsClient PromoteCampaignDraftOperationsClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Poll an operation once, using an operationName from a previous invocation of PromoteCampaignDraft. + /// + /// The name of a previously invoked operation. Must not be null or empty. + /// If not null, applies overrides to this RPC call. + /// The result of polling the operation. + public virtual lro::Operation PollOncePromoteCampaignDraft( + string operationName, + gaxgrpc::CallSettings callSettings = null) => lro::Operation.PollOnceFromName( + gax::GaxPreconditions.CheckNotNullOrEmpty(operationName, nameof(operationName)), + PromoteCampaignDraftOperationsClient, + callSettings); + + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// + /// Required. The name of the campaign draft from which to retrieve the async errors. + /// + /// + /// The token returned from the previous request. + /// A value of null or an empty string retrieves the first page. + /// + /// + /// The size of page to request. The response will not be larger than this, but may be smaller. + /// A value of null or 0 uses a server-defined page size. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public virtual gax::PagedAsyncEnumerable ListCampaignDraftAsyncErrorsAsync( + string resourceName, + string pageToken = null, + int? pageSize = null, + gaxgrpc::CallSettings callSettings = null) => ListCampaignDraftAsyncErrorsAsync( + new ListCampaignDraftAsyncErrorsRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + PageToken = pageToken ?? "", + PageSize = pageSize ?? 0, + }, + callSettings); + + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// + /// Required. The name of the campaign draft from which to retrieve the async errors. + /// + /// + /// The token returned from the previous request. + /// A value of null or an empty string retrieves the first page. + /// + /// + /// The size of page to request. The response will not be larger than this, but may be smaller. + /// A value of null or 0 uses a server-defined page size. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public virtual gax::PagedEnumerable ListCampaignDraftAsyncErrors( + string resourceName, + string pageToken = null, + int? pageSize = null, + gaxgrpc::CallSettings callSettings = null) => ListCampaignDraftAsyncErrors( + new ListCampaignDraftAsyncErrorsRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + PageToken = pageToken ?? "", + PageSize = pageSize ?? 0, + }, + callSettings); + + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public virtual gax::PagedAsyncEnumerable ListCampaignDraftAsyncErrorsAsync( + ListCampaignDraftAsyncErrorsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public virtual gax::PagedEnumerable ListCampaignDraftAsyncErrors( + ListCampaignDraftAsyncErrorsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignDraftService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignDraftServiceClientImpl : CampaignDraftServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignDraft; + private readonly gaxgrpc::ApiCall _callMutateCampaignDrafts; + private readonly gaxgrpc::ApiCall _callPromoteCampaignDraft; + private readonly gaxgrpc::ApiCall _callListCampaignDraftAsyncErrors; + + /// + /// Constructs a client wrapper for the CampaignDraftService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignDraftServiceClientImpl(CampaignDraftService.CampaignDraftServiceClient grpcClient, CampaignDraftServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignDraftServiceSettings effectiveSettings = settings ?? CampaignDraftServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + PromoteCampaignDraftOperationsClient = new lro::OperationsClientImpl( + grpcClient.CreateOperationsClient(), effectiveSettings.PromoteCampaignDraftOperationsSettings); + _callGetCampaignDraft = clientHelper.BuildApiCall( + GrpcClient.GetCampaignDraftAsync, GrpcClient.GetCampaignDraft, effectiveSettings.GetCampaignDraftSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaignDrafts = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignDraftsAsync, GrpcClient.MutateCampaignDrafts, effectiveSettings.MutateCampaignDraftsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callPromoteCampaignDraft = clientHelper.BuildApiCall( + GrpcClient.PromoteCampaignDraftAsync, GrpcClient.PromoteCampaignDraft, effectiveSettings.PromoteCampaignDraftSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"campaign_draft={request.CampaignDraft}")); + _callListCampaignDraftAsyncErrors = clientHelper.BuildApiCall( + GrpcClient.ListCampaignDraftAsyncErrorsAsync, GrpcClient.ListCampaignDraftAsyncErrors, effectiveSettings.ListCampaignDraftAsyncErrorsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetCampaignDraft); + Modify_GetCampaignDraftApiCall(ref _callGetCampaignDraft); + Modify_ApiCall(ref _callMutateCampaignDrafts); + Modify_MutateCampaignDraftsApiCall(ref _callMutateCampaignDrafts); + Modify_ApiCall(ref _callPromoteCampaignDraft); + Modify_PromoteCampaignDraftApiCall(ref _callPromoteCampaignDraft); + Modify_ApiCall(ref _callListCampaignDraftAsyncErrors); + Modify_ListCampaignDraftAsyncErrorsApiCall(ref _callListCampaignDraftAsyncErrors); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignDraftApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignDraftsApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_PromoteCampaignDraftApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_ListCampaignDraftAsyncErrorsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignDraftService.CampaignDraftServiceClient grpcClient, CampaignDraftServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignDraftService client. + /// + public override CampaignDraftService.CampaignDraftServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignDraftRequest(ref GetCampaignDraftRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignDraftsRequest(ref MutateCampaignDraftsRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_PromoteCampaignDraftRequest(ref PromoteCampaignDraftRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_ListCampaignDraftAsyncErrorsRequest(ref ListCampaignDraftAsyncErrorsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign draft in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignDraftAsync( + GetCampaignDraftRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignDraftRequest(ref request, ref callSettings); + return _callGetCampaignDraft.Async(request, callSettings); + } + + /// + /// Returns the requested campaign draft in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignDraft GetCampaignDraft( + GetCampaignDraftRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignDraftRequest(ref request, ref callSettings); + return _callGetCampaignDraft.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignDraftsAsync( + MutateCampaignDraftsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignDraftsRequest(ref request, ref callSettings); + return _callMutateCampaignDrafts.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignDraftsResponse MutateCampaignDrafts( + MutateCampaignDraftsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignDraftsRequest(ref request, ref callSettings); + return _callMutateCampaignDrafts.Sync(request, callSettings); + } + + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override async stt::Task> PromoteCampaignDraftAsync( + PromoteCampaignDraftRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_PromoteCampaignDraftRequest(ref request, ref callSettings); + return new lro::Operation( + await _callPromoteCampaignDraft.Async(request, callSettings).ConfigureAwait(false), PromoteCampaignDraftOperationsClient); + } + + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override lro::Operation PromoteCampaignDraft( + PromoteCampaignDraftRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_PromoteCampaignDraftRequest(ref request, ref callSettings); + return new lro::Operation( + _callPromoteCampaignDraft.Sync(request, callSettings), PromoteCampaignDraftOperationsClient); + } + + /// + /// The long-running operations client for PromoteCampaignDraft. + /// + public override lro::OperationsClient PromoteCampaignDraftOperationsClient { get; } + + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public override gax::PagedAsyncEnumerable ListCampaignDraftAsyncErrorsAsync( + ListCampaignDraftAsyncErrorsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_ListCampaignDraftAsyncErrorsRequest(ref request, ref callSettings); + return new gaxgrpc::GrpcPagedAsyncEnumerable(_callListCampaignDraftAsyncErrors, request, callSettings); + } + + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public override gax::PagedEnumerable ListCampaignDraftAsyncErrors( + ListCampaignDraftAsyncErrorsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_ListCampaignDraftAsyncErrorsRequest(ref request, ref callSettings); + return new gaxgrpc::GrpcPagedEnumerable(_callListCampaignDraftAsyncErrors, request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + public partial class ListCampaignDraftAsyncErrorsRequest : gaxgrpc::IPageRequest { } + public partial class ListCampaignDraftAsyncErrorsResponse : gaxgrpc::IPageResponse + { + /// + /// Returns an enumerator that iterates through the resources in this response. + /// + public scg::IEnumerator GetEnumerator() => Errors.GetEnumerator(); + + /// + sc::IEnumerator sc::IEnumerable.GetEnumerator() => GetEnumerator(); + } + + // Partial Grpc class to enable LRO client creation + public static partial class CampaignDraftService + { + public partial class CampaignDraftServiceClient + { + /// + /// Creates a new instance of using the same call invoker as this client. + /// + /// A new Operations client for the same target as this client. + public virtual lro::Operations.OperationsClient CreateOperationsClient() => new lro::Operations.OperationsClient(CallInvoker); + } + } + + +} diff --git a/src/V3/Stubs/CampaignDraftServiceGrpc.cs b/src/V3/Stubs/CampaignDraftServiceGrpc.cs new file mode 100644 index 000000000..1b19b99b2 --- /dev/null +++ b/src/V3/Stubs/CampaignDraftServiceGrpc.cs @@ -0,0 +1,411 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_draft_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaign drafts. + /// + public static partial class CampaignDraftService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignDraftService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignDraftRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignDraftRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignDraft = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignDraftsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignDraftsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_PromoteCampaignDraftRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignDraftRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_longrunning_Operation = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.LongRunning.Operation.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_ListCampaignDraftAsyncErrorsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_ListCampaignDraftAsyncErrorsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignDraft = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignDraft", + __Marshaller_google_ads_googleads_v3_services_GetCampaignDraftRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignDraft); + + static readonly grpc::Method __Method_MutateCampaignDrafts = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignDrafts", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignDraftsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignDraftsResponse); + + static readonly grpc::Method __Method_PromoteCampaignDraft = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "PromoteCampaignDraft", + __Marshaller_google_ads_googleads_v3_services_PromoteCampaignDraftRequest, + __Marshaller_google_longrunning_Operation); + + static readonly grpc::Method __Method_ListCampaignDraftAsyncErrors = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "ListCampaignDraftAsyncErrors", + __Marshaller_google_ads_googleads_v3_services_ListCampaignDraftAsyncErrorsRequest, + __Marshaller_google_ads_googleads_v3_services_ListCampaignDraftAsyncErrorsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignDraftService + public abstract partial class CampaignDraftServiceBase + { + /// + /// Returns the requested campaign draft in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignDraft(global::Google.Ads.GoogleAds.V3.Services.GetCampaignDraftRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignDrafts(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task PromoteCampaignDraft(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignDraftRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task ListCampaignDraftAsyncErrors(global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignDraftService + public partial class CampaignDraftServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignDraftService + /// The channel to use to make remote calls. + public CampaignDraftServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignDraftService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignDraftServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignDraftServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignDraftServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign draft in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft GetCampaignDraft(global::Google.Ads.GoogleAds.V3.Services.GetCampaignDraftRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignDraft(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign draft in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft GetCampaignDraft(global::Google.Ads.GoogleAds.V3.Services.GetCampaignDraftRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignDraft, null, options, request); + } + /// + /// Returns the requested campaign draft in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignDraftAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignDraftRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignDraftAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign draft in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignDraftAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignDraftRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignDraft, null, options, request); + } + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsResponse MutateCampaignDrafts(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignDrafts(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsResponse MutateCampaignDrafts(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignDrafts, null, options, request); + } + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignDraftsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignDraftsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign drafts. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignDraftsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignDrafts, null, options, request); + } + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.LongRunning.Operation PromoteCampaignDraft(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignDraftRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return PromoteCampaignDraft(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.LongRunning.Operation PromoteCampaignDraft(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignDraftRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_PromoteCampaignDraft, null, options, request); + } + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall PromoteCampaignDraftAsync(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignDraftRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return PromoteCampaignDraftAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Promotes the changes in a draft back to the base campaign. + /// + /// This method returns a Long Running Operation (LRO) indicating if the + /// Promote is done. Use [Operations.GetOperation] to poll the LRO until it + /// is done. Only a done status is returned in the response. See the status + /// in the Campaign Draft resource to determine if the promotion was + /// successful. If the LRO failed, use + /// [CampaignDraftService.ListCampaignDraftAsyncErrors][google.ads.googleads.v3.services.CampaignDraftService.ListCampaignDraftAsyncErrors] to view the list of + /// error reasons. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall PromoteCampaignDraftAsync(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignDraftRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_PromoteCampaignDraft, null, options, request); + } + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsResponse ListCampaignDraftAsyncErrors(global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return ListCampaignDraftAsyncErrors(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsResponse ListCampaignDraftAsyncErrors(global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_ListCampaignDraftAsyncErrors, null, options, request); + } + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall ListCampaignDraftAsyncErrorsAsync(global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return ListCampaignDraftAsyncErrorsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all errors that occurred during CampaignDraft promote. Throws an + /// error if called before campaign draft is promoted. + /// Supports standard list paging. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall ListCampaignDraftAsyncErrorsAsync(global::Google.Ads.GoogleAds.V3.Services.ListCampaignDraftAsyncErrorsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_ListCampaignDraftAsyncErrors, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignDraftServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignDraftServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignDraftServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignDraft, serviceImpl.GetCampaignDraft) + .AddMethod(__Method_MutateCampaignDrafts, serviceImpl.MutateCampaignDrafts) + .AddMethod(__Method_PromoteCampaignDraft, serviceImpl.PromoteCampaignDraft) + .AddMethod(__Method_ListCampaignDraftAsyncErrors, serviceImpl.ListCampaignDraftAsyncErrors).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignDraftServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignDraft, serviceImpl.GetCampaignDraft); + serviceBinder.AddMethod(__Method_MutateCampaignDrafts, serviceImpl.MutateCampaignDrafts); + serviceBinder.AddMethod(__Method_PromoteCampaignDraft, serviceImpl.PromoteCampaignDraft); + serviceBinder.AddMethod(__Method_ListCampaignDraftAsyncErrors, serviceImpl.ListCampaignDraftAsyncErrors); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignDraftStatus.cs b/src/V3/Stubs/CampaignDraftStatus.cs new file mode 100644 index 000000000..f3865c138 --- /dev/null +++ b/src/V3/Stubs/CampaignDraftStatus.cs @@ -0,0 +1,204 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/campaign_draft_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/campaign_draft_status.proto + public static partial class CampaignDraftStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/campaign_draft_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignDraftStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWlnbl9kcmFm", + "dF9zdGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIpoBChdDYW1wYWlnbkRy", + "YWZ0U3RhdHVzRW51bSJ/ChNDYW1wYWlnbkRyYWZ0U3RhdHVzEg8KC1VOU1BF", + "Q0lGSUVEEAASCwoHVU5LTk9XThABEgwKCFBST1BPU0VEEAISCwoHUkVNT1ZF", + "RBADEg0KCVBST01PVElORxAFEgwKCFBST01PVEVEEAQSEgoOUFJPTU9URV9G", + "QUlMRUQQBkLtAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "QhhDYW1wYWlnbkRyYWZ0U3RhdHVzUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5v", + "cmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1z", + "O2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPK", + "Ah1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignDraftStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.CampaignDraftStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignDraftStatusEnum.Types.CampaignDraftStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of a campaign draft. + /// + public sealed partial class CampaignDraftStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignDraftStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CampaignDraftStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftStatusEnum(CampaignDraftStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignDraftStatusEnum Clone() { + return new CampaignDraftStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignDraftStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignDraftStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignDraftStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignDraftStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a campaign draft. + /// + public enum CampaignDraftStatus { + /// + /// The status has not been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Initial state of the draft, the advertiser can start adding changes with + /// no effect on serving. + /// + [pbr::OriginalName("PROPOSED")] Proposed = 2, + /// + /// The campaign draft is removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + /// + /// Advertiser requested to promote draft's changes back into the original + /// campaign. Advertiser can poll the long running operation returned by + /// the promote action to see the status of the promotion. + /// + [pbr::OriginalName("PROMOTING")] Promoting = 5, + /// + /// The process to merge changes in the draft back to the original campaign + /// has completed successfully. + /// + [pbr::OriginalName("PROMOTED")] Promoted = 4, + /// + /// The promotion failed after it was partially applied. Promote cannot be + /// attempted again safely, so the issue must be corrected in the original + /// campaign. + /// + [pbr::OriginalName("PROMOTE_FAILED")] PromoteFailed = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignError.cs b/src/V3/Stubs/CampaignError.cs new file mode 100644 index 000000000..eea26f1e9 --- /dev/null +++ b/src/V3/Stubs/CampaignError.cs @@ -0,0 +1,388 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/campaign_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/campaign_error.proto + public static partial class CampaignErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/campaign_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2FtcGFpZ25fZXJy", + "b3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKuDQoRQ2FtcGFpZ25FcnJvckVu", + "dW0imA0KDUNhbXBhaWduRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktO", + "T1dOEAESIQodQ0FOTk9UX1RBUkdFVF9DT05URU5UX05FVFdPUksQAxIgChxD", + "QU5OT1RfVEFSR0VUX1NFQVJDSF9ORVRXT1JLEAQSNgoyQ0FOTk9UX1RBUkdF", + "VF9TRUFSQ0hfTkVUV09SS19XSVRIT1VUX0dPT0dMRV9TRUFSQ0gQBRIwCixD", + "QU5OT1RfVEFSR0VUX0dPT0dMRV9TRUFSQ0hfRk9SX0NQTV9DQU1QQUlHThAG", + "Ei0KKUNBTVBBSUdOX01VU1RfVEFSR0VUX0FUX0xFQVNUX09ORV9ORVRXT1JL", + "EAcSKAokQ0FOTk9UX1RBUkdFVF9QQVJUTkVSX1NFQVJDSF9ORVRXT1JLEAgS", + "SwpHQ0FOTk9UX1RBUkdFVF9DT05URU5UX05FVFdPUktfT05MWV9XSVRIX0NS", + "SVRFUklBX0xFVkVMX0JJRERJTkdfU1RSQVRFR1kQCRI2CjJDQU1QQUlHTl9E", + "VVJBVElPTl9NVVNUX0NPTlRBSU5fQUxMX1JVTk5BQkxFX1RSSUFMUxAKEiQK", + "IENBTk5PVF9NT0RJRllfRk9SX1RSSUFMX0NBTVBBSUdOEAsSGwoXRFVQTElD", + "QVRFX0NBTVBBSUdOX05BTUUQDBIfChtJTkNPTVBBVElCTEVfQ0FNUEFJR05f", + "RklFTEQQDRIZChVJTlZBTElEX0NBTVBBSUdOX05BTUUQDhIqCiZJTlZBTElE", + "X0FEX1NFUlZJTkdfT1BUSU1JWkFUSU9OX1NUQVRVUxAPEhgKFElOVkFMSURf", + "VFJBQ0tJTkdfVVJMEBASPgo6Q0FOTk9UX1NFVF9CT1RIX1RSQUNLSU5HX1VS", + "TF9URU1QTEFURV9BTkRfVFJBQ0tJTkdfU0VUVElORxAREiAKHE1BWF9JTVBS", + "RVNTSU9OU19OT1RfSU5fUkFOR0UQEhIbChdUSU1FX1VOSVRfTk9UX1NVUFBP", + "UlRFRBATEjEKLUlOVkFMSURfT1BFUkFUSU9OX0lGX1NFUlZJTkdfU1RBVFVT", + "X0hBU19FTkRFRBAUEhsKF0JVREdFVF9DQU5OT1RfQkVfU0hBUkVEEBUSJQoh", + "Q0FNUEFJR05fQ0FOTk9UX1VTRV9TSEFSRURfQlVER0VUEBYSMAosQ0FOTk9U", + "X0NIQU5HRV9CVURHRVRfT05fQ0FNUEFJR05fV0lUSF9UUklBTFMQFxIhCh1D", + "QU1QQUlHTl9MQUJFTF9ET0VTX05PVF9FWElTVBAYEiEKHUNBTVBBSUdOX0xB", + "QkVMX0FMUkVBRFlfRVhJU1RTEBkSHAoYTUlTU0lOR19TSE9QUElOR19TRVRU", + "SU5HEBoSIgoeSU5WQUxJRF9TSE9QUElOR19TQUxFU19DT1VOVFJZEBsSOwo3", + "QURWRVJUSVNJTkdfQ0hBTk5FTF9UWVBFX05PVF9BVkFJTEFCTEVfRk9SX0FD", + "Q09VTlRfVFlQRRAfEigKJElOVkFMSURfQURWRVJUSVNJTkdfQ0hBTk5FTF9T", + "VUJfVFlQRRAgEiwKKEFUX0xFQVNUX09ORV9DT05WRVJTSU9OX01VU1RfQkVf", + "U0VMRUNURUQQIRIfChtDQU5OT1RfU0VUX0FEX1JPVEFUSU9OX01PREUQIhIv", + "CitDQU5OT1RfTU9ESUZZX1NUQVJUX0RBVEVfSUZfQUxSRUFEWV9TVEFSVEVE", + "ECMSGwoXQ0FOTk9UX1NFVF9EQVRFX1RPX1BBU1QQJBIfChtNSVNTSU5HX0hP", + "VEVMX0NVU1RPTUVSX0xJTksQJRIfChtJTlZBTElEX0hPVEVMX0NVU1RPTUVS", + "X0xJTksQJhIZChVNSVNTSU5HX0hPVEVMX1NFVFRJTkcQJxJCCj5DQU5OT1Rf", + "VVNFX1NIQVJFRF9DQU1QQUlHTl9CVURHRVRfV0hJTEVfUEFSVF9PRl9DQU1Q", + "QUlHTl9HUk9VUBAoEhEKDUFQUF9OT1RfRk9VTkQQKRI5CjVTSE9QUElOR19F", + "TkFCTEVfTE9DQUxfTk9UX1NVUFBPUlRFRF9GT1JfQ0FNUEFJR05fVFlQRRAq", + "EjMKL01FUkNIQU5UX05PVF9BTExPV0VEX0ZPUl9DT01QQVJJU09OX0xJU1RJ", + "TkdfQURTECsSIwofSU5TVUZGSUNJRU5UX0FQUF9JTlNUQUxMU19DT1VOVBAs", + "EhoKFlNFTlNJVElWRV9DQVRFR09SWV9BUFAQLULtAQoiY29tLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0ISQ2FtcGFpZ25FcnJvclByb3RvUAFa", + "RGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9lcnJvcnM7ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFkcy5H", + "b29nbGVBZHMuVjMuRXJyb3JzygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "RXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVycm9yc2IG", + "cHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CampaignErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignErrorEnum.Types.CampaignError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible campaign errors. + /// + public sealed partial class CampaignErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CampaignErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignErrorEnum(CampaignErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignErrorEnum Clone() { + return new CampaignErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible campaign errors. + /// + public enum CampaignError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Cannot target content network. + /// + [pbr::OriginalName("CANNOT_TARGET_CONTENT_NETWORK")] CannotTargetContentNetwork = 3, + /// + /// Cannot target search network. + /// + [pbr::OriginalName("CANNOT_TARGET_SEARCH_NETWORK")] CannotTargetSearchNetwork = 4, + /// + /// Cannot cover search network without google search network. + /// + [pbr::OriginalName("CANNOT_TARGET_SEARCH_NETWORK_WITHOUT_GOOGLE_SEARCH")] CannotTargetSearchNetworkWithoutGoogleSearch = 5, + /// + /// Cannot target Google Search network for a CPM campaign. + /// + [pbr::OriginalName("CANNOT_TARGET_GOOGLE_SEARCH_FOR_CPM_CAMPAIGN")] CannotTargetGoogleSearchForCpmCampaign = 6, + /// + /// Must target at least one network. + /// + [pbr::OriginalName("CAMPAIGN_MUST_TARGET_AT_LEAST_ONE_NETWORK")] CampaignMustTargetAtLeastOneNetwork = 7, + /// + /// Only some Google partners are allowed to target partner search network. + /// + [pbr::OriginalName("CANNOT_TARGET_PARTNER_SEARCH_NETWORK")] CannotTargetPartnerSearchNetwork = 8, + /// + /// Cannot target content network only as campaign has criteria-level bidding + /// strategy. + /// + [pbr::OriginalName("CANNOT_TARGET_CONTENT_NETWORK_ONLY_WITH_CRITERIA_LEVEL_BIDDING_STRATEGY")] CannotTargetContentNetworkOnlyWithCriteriaLevelBiddingStrategy = 9, + /// + /// Cannot modify the start or end date such that the campaign duration would + /// not contain the durations of all runnable trials. + /// + [pbr::OriginalName("CAMPAIGN_DURATION_MUST_CONTAIN_ALL_RUNNABLE_TRIALS")] CampaignDurationMustContainAllRunnableTrials = 10, + /// + /// Cannot modify dates, budget or campaign name of a trial campaign. + /// + [pbr::OriginalName("CANNOT_MODIFY_FOR_TRIAL_CAMPAIGN")] CannotModifyForTrialCampaign = 11, + /// + /// Trying to modify the name of an active or paused campaign, where the name + /// is already assigned to another active or paused campaign. + /// + [pbr::OriginalName("DUPLICATE_CAMPAIGN_NAME")] DuplicateCampaignName = 12, + /// + /// Two fields are in conflicting modes. + /// + [pbr::OriginalName("INCOMPATIBLE_CAMPAIGN_FIELD")] IncompatibleCampaignField = 13, + /// + /// Campaign name cannot be used. + /// + [pbr::OriginalName("INVALID_CAMPAIGN_NAME")] InvalidCampaignName = 14, + /// + /// Given status is invalid. + /// + [pbr::OriginalName("INVALID_AD_SERVING_OPTIMIZATION_STATUS")] InvalidAdServingOptimizationStatus = 15, + /// + /// Error in the campaign level tracking URL. + /// + [pbr::OriginalName("INVALID_TRACKING_URL")] InvalidTrackingUrl = 16, + /// + /// Cannot set both tracking URL template and tracking setting. A user has + /// to clear legacy tracking setting in order to add tracking URL template. + /// + [pbr::OriginalName("CANNOT_SET_BOTH_TRACKING_URL_TEMPLATE_AND_TRACKING_SETTING")] CannotSetBothTrackingUrlTemplateAndTrackingSetting = 17, + /// + /// The maximum number of impressions for Frequency Cap should be an integer + /// greater than 0. + /// + [pbr::OriginalName("MAX_IMPRESSIONS_NOT_IN_RANGE")] MaxImpressionsNotInRange = 18, + /// + /// Only the Day, Week and Month time units are supported. + /// + [pbr::OriginalName("TIME_UNIT_NOT_SUPPORTED")] TimeUnitNotSupported = 19, + /// + /// Operation not allowed on a campaign whose serving status has ended + /// + [pbr::OriginalName("INVALID_OPERATION_IF_SERVING_STATUS_HAS_ENDED")] InvalidOperationIfServingStatusHasEnded = 20, + /// + /// This budget is exclusively linked to a Campaign that is using experiments + /// so it cannot be shared. + /// + [pbr::OriginalName("BUDGET_CANNOT_BE_SHARED")] BudgetCannotBeShared = 21, + /// + /// Campaigns using experiments cannot use a shared budget. + /// + [pbr::OriginalName("CAMPAIGN_CANNOT_USE_SHARED_BUDGET")] CampaignCannotUseSharedBudget = 22, + /// + /// A different budget cannot be assigned to a campaign when there are + /// running or scheduled trials. + /// + [pbr::OriginalName("CANNOT_CHANGE_BUDGET_ON_CAMPAIGN_WITH_TRIALS")] CannotChangeBudgetOnCampaignWithTrials = 23, + /// + /// No link found between the campaign and the label. + /// + [pbr::OriginalName("CAMPAIGN_LABEL_DOES_NOT_EXIST")] CampaignLabelDoesNotExist = 24, + /// + /// The label has already been attached to the campaign. + /// + [pbr::OriginalName("CAMPAIGN_LABEL_ALREADY_EXISTS")] CampaignLabelAlreadyExists = 25, + /// + /// A ShoppingSetting was not found when creating a shopping campaign. + /// + [pbr::OriginalName("MISSING_SHOPPING_SETTING")] MissingShoppingSetting = 26, + /// + /// The country in shopping setting is not an allowed country. + /// + [pbr::OriginalName("INVALID_SHOPPING_SALES_COUNTRY")] InvalidShoppingSalesCountry = 27, + /// + /// The requested channel type is not available according to the customer's + /// account setting. + /// + [pbr::OriginalName("ADVERTISING_CHANNEL_TYPE_NOT_AVAILABLE_FOR_ACCOUNT_TYPE")] AdvertisingChannelTypeNotAvailableForAccountType = 31, + /// + /// The AdvertisingChannelSubType is not a valid subtype of the primary + /// channel type. + /// + [pbr::OriginalName("INVALID_ADVERTISING_CHANNEL_SUB_TYPE")] InvalidAdvertisingChannelSubType = 32, + /// + /// At least one conversion must be selected. + /// + [pbr::OriginalName("AT_LEAST_ONE_CONVERSION_MUST_BE_SELECTED")] AtLeastOneConversionMustBeSelected = 33, + /// + /// Setting ad rotation mode for a campaign is not allowed. Ad rotation mode + /// at campaign is deprecated. + /// + [pbr::OriginalName("CANNOT_SET_AD_ROTATION_MODE")] CannotSetAdRotationMode = 34, + /// + /// Trying to change start date on a campaign that has started. + /// + [pbr::OriginalName("CANNOT_MODIFY_START_DATE_IF_ALREADY_STARTED")] CannotModifyStartDateIfAlreadyStarted = 35, + /// + /// Trying to modify a date into the past. + /// + [pbr::OriginalName("CANNOT_SET_DATE_TO_PAST")] CannotSetDateToPast = 36, + /// + /// Hotel center id in the hotel setting does not match any customer links. + /// + [pbr::OriginalName("MISSING_HOTEL_CUSTOMER_LINK")] MissingHotelCustomerLink = 37, + /// + /// Hotel center id in the hotel setting must match an active customer link. + /// + [pbr::OriginalName("INVALID_HOTEL_CUSTOMER_LINK")] InvalidHotelCustomerLink = 38, + /// + /// Hotel setting was not found when creating a hotel ads campaign. + /// + [pbr::OriginalName("MISSING_HOTEL_SETTING")] MissingHotelSetting = 39, + /// + /// A Campaign cannot use shared campaign budgets and be part of a campaign + /// group. + /// + [pbr::OriginalName("CANNOT_USE_SHARED_CAMPAIGN_BUDGET_WHILE_PART_OF_CAMPAIGN_GROUP")] CannotUseSharedCampaignBudgetWhilePartOfCampaignGroup = 40, + /// + /// The app ID was not found. + /// + [pbr::OriginalName("APP_NOT_FOUND")] AppNotFound = 41, + /// + /// Campaign.shopping_setting.enable_local is not supported for the specified + /// campaign type. + /// + [pbr::OriginalName("SHOPPING_ENABLE_LOCAL_NOT_SUPPORTED_FOR_CAMPAIGN_TYPE")] ShoppingEnableLocalNotSupportedForCampaignType = 42, + /// + /// The merchant does not support the creation of campaigns for Shopping + /// Comparison Listing Ads. + /// + [pbr::OriginalName("MERCHANT_NOT_ALLOWED_FOR_COMPARISON_LISTING_ADS")] MerchantNotAllowedForComparisonListingAds = 43, + /// + /// The App campaign for engagement cannot be created because there aren't + /// enough installs. + /// + [pbr::OriginalName("INSUFFICIENT_APP_INSTALLS_COUNT")] InsufficientAppInstallsCount = 44, + /// + /// The App campaign for engagement cannot be created because the app is + /// sensitive. + /// + [pbr::OriginalName("SENSITIVE_CATEGORY_APP")] SensitiveCategoryApp = 45, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExperiment.cs b/src/V3/Stubs/CampaignExperiment.cs new file mode 100644 index 000000000..c020b90ae --- /dev/null +++ b/src/V3/Stubs/CampaignExperiment.cs @@ -0,0 +1,636 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_experiment.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_experiment.proto + public static partial class CampaignExperimentReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_experiment.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignExperimentReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "ZXhwZXJpbWVudC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWln", + "bl9leHBlcmltZW50X3N0YXR1cy5wcm90bxpKZ29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvZW51bXMvY2FtcGFpZ25fZXhwZXJpbWVudF90cmFmZmljX3NwbGl0", + "X3R5cGUucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8a", + "GWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93", + "cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKI", + "CAoSQ2FtcGFpZ25FeHBlcmltZW50EkoKDXJlc291cmNlX25hbWUYASABKAlC", + "M+BBBfpBLQorZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0NhbXBhaWduRXhw", + "ZXJpbWVudBIsCgJpZBgCIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZh", + "bHVlQgPgQQMSZAoOY2FtcGFpZ25fZHJhZnQYAyABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWVCLuBBBfpBKAomZ29vZ2xlYWRzLmdvb2dsZWFw", + "aXMuY29tL0NhbXBhaWduRHJhZnQSKgoEbmFtZRgEIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZRIxCgtkZXNjcmlwdGlvbhgFIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI/ChV0cmFmZmljX3NwbGl0X3Bl", + "cmNlbnQYBiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEF", + "EokBChJ0cmFmZmljX3NwbGl0X3R5cGUYByABKA4yaC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtcy5DYW1wYWlnbkV4cGVyaW1lbnRUcmFmZmljU3Bs", + "aXRUeXBlRW51bS5DYW1wYWlnbkV4cGVyaW1lbnRUcmFmZmljU3BsaXRUeXBl", + "QgPgQQUSZAoTZXhwZXJpbWVudF9jYW1wYWlnbhgIIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZUIp4EED+kEjCiFnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vQ2FtcGFpZ24SaQoGc3RhdHVzGAkgASgOMlQuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMuQ2FtcGFpZ25FeHBlcmltZW50U3RhdHVz", + "RW51bS5DYW1wYWlnbkV4cGVyaW1lbnRTdGF0dXNCA+BBAxJBChZsb25nX3J1", + "bm5pbmdfb3BlcmF0aW9uGAogASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlQgPgQQMSMAoKc3RhcnRfZGF0ZRgLIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZRIuCghlbmRfZGF0ZRgMIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZTpw6kFtCitnb29nbGVhZHMuZ29vZ2xlYXBp", + "cy5jb20vQ2FtcGFpZ25FeHBlcmltZW50Ej5jdXN0b21lcnMve2N1c3RvbWVy", + "fS9jYW1wYWlnbkV4cGVyaW1lbnRzL3tjYW1wYWlnbl9leHBlcmltZW50fUKE", + "AgolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IXQ2Ft", + "cGFpZ25FeHBlcmltZW50UHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2Vu", + "cHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlczty", + "ZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNv", + "dXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVH", + "b29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment), global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment.Parser, new[]{ "ResourceName", "Id", "CampaignDraft", "Name", "Description", "TrafficSplitPercent", "TrafficSplitType", "ExperimentCampaign", "Status", "LongRunningOperation", "StartDate", "EndDate" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An A/B experiment that compares the performance of the base campaign + /// (the control) and a variation of that campaign (the experiment). + /// + public sealed partial class CampaignExperiment : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignExperiment()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignExperimentReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperiment() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperiment(CampaignExperiment other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + CampaignDraft = other.CampaignDraft; + Name = other.Name; + Description = other.Description; + TrafficSplitPercent = other.TrafficSplitPercent; + trafficSplitType_ = other.trafficSplitType_; + ExperimentCampaign = other.ExperimentCampaign; + status_ = other.status_; + LongRunningOperation = other.LongRunningOperation; + StartDate = other.StartDate; + EndDate = other.EndDate; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperiment Clone() { + return new CampaignExperiment(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign experiment. + /// Campaign experiment resource names have the form: + /// + /// `customers/{customer_id}/campaignExperiments/{campaign_experiment_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the campaign experiment. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "campaign_draft" field. + public const int CampaignDraftFieldNumber = 3; + private static readonly pb::FieldCodec _single_campaignDraft_codec = pb::FieldCodec.ForClassWrapper(26); + private string campaignDraft_; + /// + /// Immutable. The campaign draft with staged changes to the base campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignDraft { + get { return campaignDraft_; } + set { + campaignDraft_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// The name of the campaign experiment. + /// + /// This field is required when creating new campaign experiments + /// and must not conflict with the name of another non-removed + /// campaign experiment or campaign. + /// + /// It must not contain any null (code point 0x0), NL line feed + /// (code point 0xA) or carriage return (code point 0xD) characters. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 5; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(42); + private string description_; + /// + /// The description of the experiment. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "traffic_split_percent" field. + public const int TrafficSplitPercentFieldNumber = 6; + private static readonly pb::FieldCodec _single_trafficSplitPercent_codec = pb::FieldCodec.ForStructWrapper(50); + private long? trafficSplitPercent_; + /// + /// Immutable. Share of traffic directed to experiment as a percent (must be between 1 and + /// 99 inclusive. Base campaign receives the remainder of the traffic + /// (100 - traffic_split_percent). Required for create. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TrafficSplitPercent { + get { return trafficSplitPercent_; } + set { + trafficSplitPercent_ = value; + } + } + + + /// Field number for the "traffic_split_type" field. + public const int TrafficSplitTypeFieldNumber = 7; + private global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeEnum.Types.CampaignExperimentTrafficSplitType trafficSplitType_ = 0; + /// + /// Immutable. Determines the behavior of the traffic split. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeEnum.Types.CampaignExperimentTrafficSplitType TrafficSplitType { + get { return trafficSplitType_; } + set { + trafficSplitType_ = value; + } + } + + /// Field number for the "experiment_campaign" field. + public const int ExperimentCampaignFieldNumber = 8; + private static readonly pb::FieldCodec _single_experimentCampaign_codec = pb::FieldCodec.ForClassWrapper(66); + private string experimentCampaign_; + /// + /// Output only. The experiment campaign, as opposed to the base campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ExperimentCampaign { + get { return experimentCampaign_; } + set { + experimentCampaign_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 9; + private global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentStatusEnum.Types.CampaignExperimentStatus status_ = 0; + /// + /// Output only. The status of the campaign experiment. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentStatusEnum.Types.CampaignExperimentStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "long_running_operation" field. + public const int LongRunningOperationFieldNumber = 10; + private static readonly pb::FieldCodec _single_longRunningOperation_codec = pb::FieldCodec.ForClassWrapper(82); + private string longRunningOperation_; + /// + /// Output only. The resource name of the long-running operation that can be used to poll + /// for completion of experiment create or promote. The most recent long + /// running operation is returned. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LongRunningOperation { + get { return longRunningOperation_; } + set { + longRunningOperation_ = value; + } + } + + + /// Field number for the "start_date" field. + public const int StartDateFieldNumber = 11; + private static readonly pb::FieldCodec _single_startDate_codec = pb::FieldCodec.ForClassWrapper(90); + private string startDate_; + /// + /// Date when the campaign experiment starts. By default, the experiment starts + /// now or on the campaign's start date, whichever is later. If this field is + /// set, then the experiment starts at the beginning of the specified date in + /// the customer's time zone. Cannot be changed once the experiment starts. + /// + /// Format: YYYY-MM-DD + /// Example: 2019-03-14 + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDate { + get { return startDate_; } + set { + startDate_ = value; + } + } + + + /// Field number for the "end_date" field. + public const int EndDateFieldNumber = 12; + private static readonly pb::FieldCodec _single_endDate_codec = pb::FieldCodec.ForClassWrapper(98); + private string endDate_; + /// + /// Date when the campaign experiment ends. By default, the experiment ends on + /// the campaign's end date. If this field is set, then the experiment ends at + /// the end of the specified date in the customer's time zone. + /// + /// Format: YYYY-MM-DD + /// Example: 2019-04-18 + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDate { + get { return endDate_; } + set { + endDate_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignExperiment); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignExperiment other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (CampaignDraft != other.CampaignDraft) return false; + if (Name != other.Name) return false; + if (Description != other.Description) return false; + if (TrafficSplitPercent != other.TrafficSplitPercent) return false; + if (TrafficSplitType != other.TrafficSplitType) return false; + if (ExperimentCampaign != other.ExperimentCampaign) return false; + if (Status != other.Status) return false; + if (LongRunningOperation != other.LongRunningOperation) return false; + if (StartDate != other.StartDate) return false; + if (EndDate != other.EndDate) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (campaignDraft_ != null) hash ^= CampaignDraft.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + if (trafficSplitPercent_ != null) hash ^= TrafficSplitPercent.GetHashCode(); + if (TrafficSplitType != 0) hash ^= TrafficSplitType.GetHashCode(); + if (experimentCampaign_ != null) hash ^= ExperimentCampaign.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (longRunningOperation_ != null) hash ^= LongRunningOperation.GetHashCode(); + if (startDate_ != null) hash ^= StartDate.GetHashCode(); + if (endDate_ != null) hash ^= EndDate.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (campaignDraft_ != null) { + _single_campaignDraft_codec.WriteTagAndValue(output, CampaignDraft); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + if (trafficSplitPercent_ != null) { + _single_trafficSplitPercent_codec.WriteTagAndValue(output, TrafficSplitPercent); + } + if (TrafficSplitType != 0) { + output.WriteRawTag(56); + output.WriteEnum((int) TrafficSplitType); + } + if (experimentCampaign_ != null) { + _single_experimentCampaign_codec.WriteTagAndValue(output, ExperimentCampaign); + } + if (Status != 0) { + output.WriteRawTag(72); + output.WriteEnum((int) Status); + } + if (longRunningOperation_ != null) { + _single_longRunningOperation_codec.WriteTagAndValue(output, LongRunningOperation); + } + if (startDate_ != null) { + _single_startDate_codec.WriteTagAndValue(output, StartDate); + } + if (endDate_ != null) { + _single_endDate_codec.WriteTagAndValue(output, EndDate); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (campaignDraft_ != null) { + size += _single_campaignDraft_codec.CalculateSizeWithTag(CampaignDraft); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + if (trafficSplitPercent_ != null) { + size += _single_trafficSplitPercent_codec.CalculateSizeWithTag(TrafficSplitPercent); + } + if (TrafficSplitType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) TrafficSplitType); + } + if (experimentCampaign_ != null) { + size += _single_experimentCampaign_codec.CalculateSizeWithTag(ExperimentCampaign); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (longRunningOperation_ != null) { + size += _single_longRunningOperation_codec.CalculateSizeWithTag(LongRunningOperation); + } + if (startDate_ != null) { + size += _single_startDate_codec.CalculateSizeWithTag(StartDate); + } + if (endDate_ != null) { + size += _single_endDate_codec.CalculateSizeWithTag(EndDate); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignExperiment other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.campaignDraft_ != null) { + if (campaignDraft_ == null || other.CampaignDraft != "") { + CampaignDraft = other.CampaignDraft; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + if (other.trafficSplitPercent_ != null) { + if (trafficSplitPercent_ == null || other.TrafficSplitPercent != 0L) { + TrafficSplitPercent = other.TrafficSplitPercent; + } + } + if (other.TrafficSplitType != 0) { + TrafficSplitType = other.TrafficSplitType; + } + if (other.experimentCampaign_ != null) { + if (experimentCampaign_ == null || other.ExperimentCampaign != "") { + ExperimentCampaign = other.ExperimentCampaign; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.longRunningOperation_ != null) { + if (longRunningOperation_ == null || other.LongRunningOperation != "") { + LongRunningOperation = other.LongRunningOperation; + } + } + if (other.startDate_ != null) { + if (startDate_ == null || other.StartDate != "") { + StartDate = other.StartDate; + } + } + if (other.endDate_ != null) { + if (endDate_ == null || other.EndDate != "") { + EndDate = other.EndDate; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 26: { + string value = _single_campaignDraft_codec.Read(input); + if (campaignDraft_ == null || value != "") { + CampaignDraft = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 42: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 50: { + long? value = _single_trafficSplitPercent_codec.Read(input); + if (trafficSplitPercent_ == null || value != 0L) { + TrafficSplitPercent = value; + } + break; + } + case 56: { + TrafficSplitType = (global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeEnum.Types.CampaignExperimentTrafficSplitType) input.ReadEnum(); + break; + } + case 66: { + string value = _single_experimentCampaign_codec.Read(input); + if (experimentCampaign_ == null || value != "") { + ExperimentCampaign = value; + } + break; + } + case 72: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentStatusEnum.Types.CampaignExperimentStatus) input.ReadEnum(); + break; + } + case 82: { + string value = _single_longRunningOperation_codec.Read(input); + if (longRunningOperation_ == null || value != "") { + LongRunningOperation = value; + } + break; + } + case 90: { + string value = _single_startDate_codec.Read(input); + if (startDate_ == null || value != "") { + StartDate = value; + } + break; + } + case 98: { + string value = _single_endDate_codec.Read(input); + if (endDate_ == null || value != "") { + EndDate = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExperimentError.cs b/src/V3/Stubs/CampaignExperimentError.cs new file mode 100644 index 000000000..3f988c06c --- /dev/null +++ b/src/V3/Stubs/CampaignExperimentError.cs @@ -0,0 +1,233 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/campaign_experiment_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/campaign_experiment_error.proto + public static partial class CampaignExperimentErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/campaign_experiment_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignExperimentErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2FtcGFpZ25fZXhw", + "ZXJpbWVudF9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZXJyb3JzGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIoAEChtDYW1w", + "YWlnbkV4cGVyaW1lbnRFcnJvckVudW0i4AMKF0NhbXBhaWduRXhwZXJpbWVu", + "dEVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhIKDkRVUExJ", + "Q0FURV9OQU1FEAISFgoSSU5WQUxJRF9UUkFOU0lUSU9OEAMSLworQ0FOTk9U", + "X0NSRUFURV9FWFBFUklNRU5UX1dJVEhfU0hBUkVEX0JVREdFVBAEEjYKMkNB", + "Tk5PVF9DUkVBVEVfRVhQRVJJTUVOVF9GT1JfUkVNT1ZFRF9CQVNFX0NBTVBB", + "SUdOEAUSMwovQ0FOTk9UX0NSRUFURV9FWFBFUklNRU5UX0ZPUl9OT05fUFJP", + "UE9TRURfRFJBRlQQBhIlCiFDVVNUT01FUl9DQU5OT1RfQ1JFQVRFX0VYUEVS", + "SU1FTlQQBxIlCiFDQU1QQUlHTl9DQU5OT1RfQ1JFQVRFX0VYUEVSSU1FTlQQ", + "CBIpCiVFWFBFUklNRU5UX0RVUkFUSU9OU19NVVNUX05PVF9PVkVSTEFQEAkS", + "OAo0RVhQRVJJTUVOVF9EVVJBVElPTl9NVVNUX0JFX1dJVEhJTl9DQU1QQUlH", + "Tl9EVVJBVElPThAKEioKJkNBTk5PVF9NVVRBVEVfRVhQRVJJTUVOVF9EVUVf", + "VE9fU1RBVFVTEAtC9wEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnNCHENhbXBhaWduRXhwZXJpbWVudEVycm9yUHJvdG9QAVpEZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPq", + "AiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignExperimentErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CampaignExperimentErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignExperimentErrorEnum.Types.CampaignExperimentError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible campaign experiment errors. + /// + public sealed partial class CampaignExperimentErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignExperimentErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CampaignExperimentErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentErrorEnum(CampaignExperimentErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentErrorEnum Clone() { + return new CampaignExperimentErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignExperimentErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignExperimentErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignExperimentErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignExperimentErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible campaign experiment errors. + /// + public enum CampaignExperimentError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// An active campaign or experiment with this name already exists. + /// + [pbr::OriginalName("DUPLICATE_NAME")] DuplicateName = 2, + /// + /// Experiment cannot be updated from the current state to the + /// requested target state. For example, an experiment can only graduate + /// if its status is ENABLED. + /// + [pbr::OriginalName("INVALID_TRANSITION")] InvalidTransition = 3, + /// + /// Cannot create an experiment from a campaign using an explicitly shared + /// budget. + /// + [pbr::OriginalName("CANNOT_CREATE_EXPERIMENT_WITH_SHARED_BUDGET")] CannotCreateExperimentWithSharedBudget = 4, + /// + /// Cannot create an experiment for a removed base campaign. + /// + [pbr::OriginalName("CANNOT_CREATE_EXPERIMENT_FOR_REMOVED_BASE_CAMPAIGN")] CannotCreateExperimentForRemovedBaseCampaign = 5, + /// + /// Cannot create an experiment from a draft, which has a status other than + /// proposed. + /// + [pbr::OriginalName("CANNOT_CREATE_EXPERIMENT_FOR_NON_PROPOSED_DRAFT")] CannotCreateExperimentForNonProposedDraft = 6, + /// + /// This customer is not allowed to create an experiment. + /// + [pbr::OriginalName("CUSTOMER_CANNOT_CREATE_EXPERIMENT")] CustomerCannotCreateExperiment = 7, + /// + /// This campaign is not allowed to create an experiment. + /// + [pbr::OriginalName("CAMPAIGN_CANNOT_CREATE_EXPERIMENT")] CampaignCannotCreateExperiment = 8, + /// + /// Trying to set an experiment duration which overlaps with another + /// experiment. + /// + [pbr::OriginalName("EXPERIMENT_DURATIONS_MUST_NOT_OVERLAP")] ExperimentDurationsMustNotOverlap = 9, + /// + /// All non-removed experiments must start and end within their campaign's + /// duration. + /// + [pbr::OriginalName("EXPERIMENT_DURATION_MUST_BE_WITHIN_CAMPAIGN_DURATION")] ExperimentDurationMustBeWithinCampaignDuration = 10, + /// + /// The experiment cannot be modified because its status is in a terminal + /// state, such as REMOVED. + /// + [pbr::OriginalName("CANNOT_MUTATE_EXPERIMENT_DUE_TO_STATUS")] CannotMutateExperimentDueToStatus = 11, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExperimentService.cs b/src/V3/Stubs/CampaignExperimentService.cs new file mode 100644 index 000000000..abe677c5a --- /dev/null +++ b/src/V3/Stubs/CampaignExperimentService.cs @@ -0,0 +1,2328 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_experiment_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_experiment_service.proto + public static partial class CampaignExperimentServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_experiment_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignExperimentServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9l", + "eHBlcmltZW50X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvY2FtcGFpZ25fZXhwZXJpbWVudC5wcm90bxocZ29vZ2xlL2FwaS9hbm5v", + "dGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2ds", + "ZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aI2dvb2dsZS9sb25ncnVubmlu", + "Zy9vcGVyYXRpb25zLnByb3RvGhtnb29nbGUvcHJvdG9idWYvZW1wdHkucHJv", + "dG8aIGdvb2dsZS9wcm90b2J1Zi9maWVsZF9tYXNrLnByb3RvGhdnb29nbGUv", + "cnBjL3N0YXR1cy5wcm90byI6ChxHZXRDYW1wYWlnbkV4cGVyaW1lbnRSZXF1", + "ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiLEAQogTXV0YXRlQ2Ft", + "cGFpZ25FeHBlcmltZW50c1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlC", + "A+BBAhJWCgpvcGVyYXRpb25zGAIgAygLMj0uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuQ2FtcGFpZ25FeHBlcmltZW50T3BlcmF0aW9uQgPg", + "QQISFwoPcGFydGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlkYXRlX29ubHkY", + "BCABKAgitgEKG0NhbXBhaWduRXhwZXJpbWVudE9wZXJhdGlvbhIvCgt1cGRh", + "dGVfbWFzaxgDIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5GaWVsZE1hc2sSRwoG", + "dXBkYXRlGAEgASgLMjUuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkNhbXBhaWduRXhwZXJpbWVudEgAEhAKBnJlbW92ZRgCIAEoCUgAQgsK", + "CW9wZXJhdGlvbiKpAQohTXV0YXRlQ2FtcGFpZ25FeHBlcmltZW50c1Jlc3Bv", + "bnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJvchgDIAEoCzISLmdvb2dsZS5y", + "cGMuU3RhdHVzElEKB3Jlc3VsdHMYAiADKAsyQC5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDYW1wYWlnbkV4cGVyaW1lbnRSZXN1", + "bHQiNwoeTXV0YXRlQ2FtcGFpZ25FeHBlcmltZW50UmVzdWx0EhUKDXJlc291", + "cmNlX25hbWUYASABKAkiqwEKH0NyZWF0ZUNhbXBhaWduRXhwZXJpbWVudFJl", + "cXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlCA+BBAhJXChNjYW1wYWlnbl9l", + "eHBlcmltZW50GAIgASgLMjUuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLkNhbXBhaWduRXhwZXJpbWVudEID4EECEhUKDXZhbGlkYXRlX29u", + "bHkYAyABKAgiPwogQ3JlYXRlQ2FtcGFpZ25FeHBlcmltZW50TWV0YWRhdGES", + "GwoTY2FtcGFpZ25fZXhwZXJpbWVudBgBIAEoCSJjCiFHcmFkdWF0ZUNhbXBh", + "aWduRXhwZXJpbWVudFJlcXVlc3QSIAoTY2FtcGFpZ25fZXhwZXJpbWVudBgB", + "IAEoCUID4EECEhwKD2NhbXBhaWduX2J1ZGdldBgCIAEoCUID4EECIkAKIkdy", + "YWR1YXRlQ2FtcGFpZ25FeHBlcmltZW50UmVzcG9uc2USGgoSZ3JhZHVhdGVk", + "X2NhbXBhaWduGAEgASgJIkQKIFByb21vdGVDYW1wYWlnbkV4cGVyaW1lbnRS", + "ZXF1ZXN0EiAKE2NhbXBhaWduX2V4cGVyaW1lbnQYASABKAlCA+BBAiJAChxF", + "bmRDYW1wYWlnbkV4cGVyaW1lbnRSZXF1ZXN0EiAKE2NhbXBhaWduX2V4cGVy", + "aW1lbnQYASABKAlCA+BBAiJtCihMaXN0Q2FtcGFpZ25FeHBlcmltZW50QXN5", + "bmNFcnJvcnNSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAhIS", + "CgpwYWdlX3Rva2VuGAIgASgJEhEKCXBhZ2Vfc2l6ZRgDIAEoBSJoCilMaXN0", + "Q2FtcGFpZ25FeHBlcmltZW50QXN5bmNFcnJvcnNSZXNwb25zZRIiCgZlcnJv", + "cnMYASADKAsyEi5nb29nbGUucnBjLlN0YXR1cxIXCg9uZXh0X3BhZ2VfdG9r", + "ZW4YAiABKAky9Q4KGUNhbXBhaWduRXhwZXJpbWVudFNlcnZpY2US3QEKFUdl", + "dENhbXBhaWduRXhwZXJpbWVudBI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLkdldENhbXBhaWduRXhwZXJpbWVudFJlcXVlc3QaNS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2FtcGFpZ25FeHBlcmlt", + "ZW50Ik2C0+STAjcSNS92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9j", + "YW1wYWlnbkV4cGVyaW1lbnRzLyp92kENcmVzb3VyY2VfbmFtZRLBAgoYQ3Jl", + "YXRlQ2FtcGFpZ25FeHBlcmltZW50EkEuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMuQ3JlYXRlQ2FtcGFpZ25FeHBlcmltZW50UmVxdWVzdBod", + "Lmdvb2dsZS5sb25ncnVubmluZy5PcGVyYXRpb24iwgGC0+STAj0iOC92My9j", + "dXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2NhbXBhaWduRXhwZXJpbWVudHM6", + "Y3JlYXRlOgEq2kEfY3VzdG9tZXJfaWQsY2FtcGFpZ25fZXhwZXJpbWVudMpB", + "WgoVZ29vZ2xlLnByb3RvYnVmLkVtcHR5EkFnb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5DcmVhdGVDYW1wYWlnbkV4cGVyaW1lbnRNZXRhZGF0", + "YRKCAgoZTXV0YXRlQ2FtcGFpZ25FeHBlcmltZW50cxJCLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUNhbXBhaWduRXhwZXJpbWVu", + "dHNSZXF1ZXN0GkMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "TXV0YXRlQ2FtcGFpZ25FeHBlcmltZW50c1Jlc3BvbnNlIlyC0+STAj0iOC92", + "My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2NhbXBhaWduRXhwZXJpbWVu", + "dHM6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9ucxKeAgoaR3Jh", + "ZHVhdGVDYW1wYWlnbkV4cGVyaW1lbnQSQy5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5HcmFkdWF0ZUNhbXBhaWduRXhwZXJpbWVudFJlcXVl", + "c3QaRC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HcmFkdWF0", + "ZUNhbXBhaWduRXhwZXJpbWVudFJlc3BvbnNlInWC0+STAkkiRC92My97Y2Ft", + "cGFpZ25fZXhwZXJpbWVudD1jdXN0b21lcnMvKi9jYW1wYWlnbkV4cGVyaW1l", + "bnRzLyp9OmdyYWR1YXRlOgEq2kEjY2FtcGFpZ25fZXhwZXJpbWVudCxjYW1w", + "YWlnbl9idWRnZXQS/gEKGVByb21vdGVDYW1wYWlnbkV4cGVyaW1lbnQSQi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5Qcm9tb3RlQ2FtcGFp", + "Z25FeHBlcmltZW50UmVxdWVzdBodLmdvb2dsZS5sb25ncnVubmluZy5PcGVy", + "YXRpb24ifoLT5JMCSCJDL3YzL3tjYW1wYWlnbl9leHBlcmltZW50PWN1c3Rv", + "bWVycy8qL2NhbXBhaWduRXhwZXJpbWVudHMvKn06cHJvbW90ZToBKtpBE2Nh", + "bXBhaWduX2V4cGVyaW1lbnTKQRcKFWdvb2dsZS5wcm90b2J1Zi5FbXB0eRLR", + "AQoVRW5kQ2FtcGFpZ25FeHBlcmltZW50Ej4uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuRW5kQ2FtcGFpZ25FeHBlcmltZW50UmVxdWVzdBoW", + "Lmdvb2dsZS5wcm90b2J1Zi5FbXB0eSJggtPkkwJEIj8vdjMve2NhbXBhaWdu", + "X2V4cGVyaW1lbnQ9Y3VzdG9tZXJzLyovY2FtcGFpZ25FeHBlcmltZW50cy8q", + "fTplbmQ6ASraQRNjYW1wYWlnbl9leHBlcmltZW50EpsCCiFMaXN0Q2FtcGFp", + "Z25FeHBlcmltZW50QXN5bmNFcnJvcnMSSi5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5MaXN0Q2FtcGFpZ25FeHBlcmltZW50QXN5bmNFcnJv", + "cnNSZXF1ZXN0GksuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "TGlzdENhbXBhaWduRXhwZXJpbWVudEFzeW5jRXJyb3JzUmVzcG9uc2UiXYLT", + "5JMCRxJFL3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2NhbXBhaWdu", + "RXhwZXJpbWVudHMvKn06bGlzdEFzeW5jRXJyb3Jz2kENcmVzb3VyY2VfbmFt", + "ZRobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQoUCCiRjb20uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCHkNhbXBhaWduRXhwZXJpbWVu", + "dFNlcnZpY2VQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9n", + "b29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOi", + "AgNHQUGqAiBHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdv", + "b2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignExperimentReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.LongRunning.OperationsReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.EmptyReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExperimentRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignExperimentRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentOperation.Parser, new[]{ "UpdateMask", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentResult.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentRequest), global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentRequest.Parser, new[]{ "CustomerId", "CampaignExperiment", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentMetadata), global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentMetadata.Parser, new[]{ "CampaignExperiment" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentRequest), global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentRequest.Parser, new[]{ "CampaignExperiment", "CampaignBudget" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentResponse), global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentResponse.Parser, new[]{ "GraduatedCampaign" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignExperimentRequest), global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignExperimentRequest.Parser, new[]{ "CampaignExperiment" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.EndCampaignExperimentRequest), global::Google.Ads.GoogleAds.V3.Services.EndCampaignExperimentRequest.Parser, new[]{ "CampaignExperiment" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsRequest), global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsRequest.Parser, new[]{ "ResourceName", "PageToken", "PageSize" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsResponse), global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsResponse.Parser, new[]{ "Errors", "NextPageToken" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignExperimentService.GetCampaignExperiment][google.ads.googleads.v3.services.CampaignExperimentService.GetCampaignExperiment]. + /// + public sealed partial class GetCampaignExperimentRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignExperimentRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignExperimentRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignExperimentRequest(GetCampaignExperimentRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignExperimentRequest Clone() { + return new GetCampaignExperimentRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign experiment to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignExperimentRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignExperimentRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignExperimentRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignExperimentService.MutateCampaignExperiments][google.ads.googleads.v3.services.CampaignExperimentService.MutateCampaignExperiments]. + /// + public sealed partial class MutateCampaignExperimentsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignExperimentsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentsRequest(MutateCampaignExperimentsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentsRequest Clone() { + return new MutateCampaignExperimentsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose campaign experiments are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual campaign experiments. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignExperimentsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignExperimentsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignExperimentsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single update operation on a campaign experiment. + /// + public sealed partial class CampaignExperimentOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignExperimentOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentOperation(CampaignExperimentOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentOperation Clone() { + return new CampaignExperimentOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 3; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 1; + /// + /// Update operation: The campaign experiment is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 2; + /// + /// Remove operation: The campaign experiment is expected to have a valid + /// resource name, in this format: + /// + /// `customers/{customer_id}/campaignExperiments/{campaign_experiment_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Update = 1, + Remove = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignExperimentOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignExperimentOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(10); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(18); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(26); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignExperimentOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 18: { + Remove = input.ReadString(); + break; + } + case 26: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for campaign experiment mutate. + /// + public sealed partial class MutateCampaignExperimentsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignExperimentsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentsResponse(MutateCampaignExperimentsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentsResponse Clone() { + return new MutateCampaignExperimentsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignExperimentsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignExperimentsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignExperimentsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the campaign experiment mutate. + /// + public sealed partial class MutateCampaignExperimentResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignExperimentResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentResult(MutateCampaignExperimentResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExperimentResult Clone() { + return new MutateCampaignExperimentResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignExperimentResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignExperimentResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignExperimentResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignExperimentService.CreateCampaignExperiment][google.ads.googleads.v3.services.CampaignExperimentService.CreateCampaignExperiment]. + /// + public sealed partial class CreateCampaignExperimentRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CreateCampaignExperimentRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCampaignExperimentRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCampaignExperimentRequest(CreateCampaignExperimentRequest other) : this() { + customerId_ = other.customerId_; + campaignExperiment_ = other.campaignExperiment_ != null ? other.campaignExperiment_.Clone() : null; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCampaignExperimentRequest Clone() { + return new CreateCampaignExperimentRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose campaign experiment is being created. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "campaign_experiment" field. + public const int CampaignExperimentFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment campaignExperiment_; + /// + /// Required. The campaign experiment to be created. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment CampaignExperiment { + get { return campaignExperiment_; } + set { + campaignExperiment_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 3; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CreateCampaignExperimentRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CreateCampaignExperimentRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (!object.Equals(CampaignExperiment, other.CampaignExperiment)) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (campaignExperiment_ != null) hash ^= CampaignExperiment.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (campaignExperiment_ != null) { + output.WriteRawTag(18); + output.WriteMessage(CampaignExperiment); + } + if (ValidateOnly != false) { + output.WriteRawTag(24); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (campaignExperiment_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignExperiment); + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CreateCampaignExperimentRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.campaignExperiment_ != null) { + if (campaignExperiment_ == null) { + CampaignExperiment = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment(); + } + CampaignExperiment.MergeFrom(other.CampaignExperiment); + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + if (campaignExperiment_ == null) { + CampaignExperiment = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment(); + } + input.ReadMessage(CampaignExperiment); + break; + } + case 24: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// Message used as metadata returned in Long Running Operations for + /// CreateCampaignExperimentRequest + /// + public sealed partial class CreateCampaignExperimentMetadata : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CreateCampaignExperimentMetadata()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCampaignExperimentMetadata() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCampaignExperimentMetadata(CreateCampaignExperimentMetadata other) : this() { + campaignExperiment_ = other.campaignExperiment_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCampaignExperimentMetadata Clone() { + return new CreateCampaignExperimentMetadata(this); + } + + /// Field number for the "campaign_experiment" field. + public const int CampaignExperimentFieldNumber = 1; + private string campaignExperiment_ = ""; + /// + /// Resource name of campaign experiment created. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignExperiment { + get { return campaignExperiment_; } + set { + campaignExperiment_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CreateCampaignExperimentMetadata); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CreateCampaignExperimentMetadata other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CampaignExperiment != other.CampaignExperiment) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CampaignExperiment.Length != 0) hash ^= CampaignExperiment.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CampaignExperiment.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CampaignExperiment); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CampaignExperiment.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CampaignExperiment); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CreateCampaignExperimentMetadata other) { + if (other == null) { + return; + } + if (other.CampaignExperiment.Length != 0) { + CampaignExperiment = other.CampaignExperiment; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CampaignExperiment = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignExperimentService.GraduateCampaignExperiment][google.ads.googleads.v3.services.CampaignExperimentService.GraduateCampaignExperiment]. + /// + public sealed partial class GraduateCampaignExperimentRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GraduateCampaignExperimentRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GraduateCampaignExperimentRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GraduateCampaignExperimentRequest(GraduateCampaignExperimentRequest other) : this() { + campaignExperiment_ = other.campaignExperiment_; + campaignBudget_ = other.campaignBudget_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GraduateCampaignExperimentRequest Clone() { + return new GraduateCampaignExperimentRequest(this); + } + + /// Field number for the "campaign_experiment" field. + public const int CampaignExperimentFieldNumber = 1; + private string campaignExperiment_ = ""; + /// + /// Required. The resource name of the campaign experiment to graduate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignExperiment { + get { return campaignExperiment_; } + set { + campaignExperiment_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "campaign_budget" field. + public const int CampaignBudgetFieldNumber = 2; + private string campaignBudget_ = ""; + /// + /// Required. Resource name of the budget to attach to the campaign graduated from the + /// experiment. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignBudget { + get { return campaignBudget_; } + set { + campaignBudget_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GraduateCampaignExperimentRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GraduateCampaignExperimentRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CampaignExperiment != other.CampaignExperiment) return false; + if (CampaignBudget != other.CampaignBudget) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CampaignExperiment.Length != 0) hash ^= CampaignExperiment.GetHashCode(); + if (CampaignBudget.Length != 0) hash ^= CampaignBudget.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CampaignExperiment.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CampaignExperiment); + } + if (CampaignBudget.Length != 0) { + output.WriteRawTag(18); + output.WriteString(CampaignBudget); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CampaignExperiment.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CampaignExperiment); + } + if (CampaignBudget.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CampaignBudget); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GraduateCampaignExperimentRequest other) { + if (other == null) { + return; + } + if (other.CampaignExperiment.Length != 0) { + CampaignExperiment = other.CampaignExperiment; + } + if (other.CampaignBudget.Length != 0) { + CampaignBudget = other.CampaignBudget; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CampaignExperiment = input.ReadString(); + break; + } + case 18: { + CampaignBudget = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for campaign experiment graduate. + /// + public sealed partial class GraduateCampaignExperimentResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GraduateCampaignExperimentResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GraduateCampaignExperimentResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GraduateCampaignExperimentResponse(GraduateCampaignExperimentResponse other) : this() { + graduatedCampaign_ = other.graduatedCampaign_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GraduateCampaignExperimentResponse Clone() { + return new GraduateCampaignExperimentResponse(this); + } + + /// Field number for the "graduated_campaign" field. + public const int GraduatedCampaignFieldNumber = 1; + private string graduatedCampaign_ = ""; + /// + /// The resource name of the campaign from the graduated experiment. + /// This campaign is the same one as CampaignExperiment.experiment_campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string GraduatedCampaign { + get { return graduatedCampaign_; } + set { + graduatedCampaign_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GraduateCampaignExperimentResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GraduateCampaignExperimentResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (GraduatedCampaign != other.GraduatedCampaign) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (GraduatedCampaign.Length != 0) hash ^= GraduatedCampaign.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (GraduatedCampaign.Length != 0) { + output.WriteRawTag(10); + output.WriteString(GraduatedCampaign); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (GraduatedCampaign.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(GraduatedCampaign); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GraduateCampaignExperimentResponse other) { + if (other == null) { + return; + } + if (other.GraduatedCampaign.Length != 0) { + GraduatedCampaign = other.GraduatedCampaign; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + GraduatedCampaign = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignExperimentService.PromoteCampaignExperiment][google.ads.googleads.v3.services.CampaignExperimentService.PromoteCampaignExperiment]. + /// + public sealed partial class PromoteCampaignExperimentRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PromoteCampaignExperimentRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[9]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromoteCampaignExperimentRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromoteCampaignExperimentRequest(PromoteCampaignExperimentRequest other) : this() { + campaignExperiment_ = other.campaignExperiment_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromoteCampaignExperimentRequest Clone() { + return new PromoteCampaignExperimentRequest(this); + } + + /// Field number for the "campaign_experiment" field. + public const int CampaignExperimentFieldNumber = 1; + private string campaignExperiment_ = ""; + /// + /// Required. The resource name of the campaign experiment to promote. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignExperiment { + get { return campaignExperiment_; } + set { + campaignExperiment_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PromoteCampaignExperimentRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PromoteCampaignExperimentRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CampaignExperiment != other.CampaignExperiment) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CampaignExperiment.Length != 0) hash ^= CampaignExperiment.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CampaignExperiment.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CampaignExperiment); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CampaignExperiment.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CampaignExperiment); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PromoteCampaignExperimentRequest other) { + if (other == null) { + return; + } + if (other.CampaignExperiment.Length != 0) { + CampaignExperiment = other.CampaignExperiment; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CampaignExperiment = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignExperimentService.EndCampaignExperiment][google.ads.googleads.v3.services.CampaignExperimentService.EndCampaignExperiment]. + /// + public sealed partial class EndCampaignExperimentRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new EndCampaignExperimentRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[10]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EndCampaignExperimentRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EndCampaignExperimentRequest(EndCampaignExperimentRequest other) : this() { + campaignExperiment_ = other.campaignExperiment_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EndCampaignExperimentRequest Clone() { + return new EndCampaignExperimentRequest(this); + } + + /// Field number for the "campaign_experiment" field. + public const int CampaignExperimentFieldNumber = 1; + private string campaignExperiment_ = ""; + /// + /// Required. The resource name of the campaign experiment to end. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignExperiment { + get { return campaignExperiment_; } + set { + campaignExperiment_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as EndCampaignExperimentRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(EndCampaignExperimentRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CampaignExperiment != other.CampaignExperiment) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CampaignExperiment.Length != 0) hash ^= CampaignExperiment.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CampaignExperiment.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CampaignExperiment); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CampaignExperiment.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CampaignExperiment); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(EndCampaignExperimentRequest other) { + if (other == null) { + return; + } + if (other.CampaignExperiment.Length != 0) { + CampaignExperiment = other.CampaignExperiment; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CampaignExperiment = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [CampaignExperimentService.ListCampaignExperimentAsyncErrors][google.ads.googleads.v3.services.CampaignExperimentService.ListCampaignExperimentAsyncErrors]. + /// + public sealed partial class ListCampaignExperimentAsyncErrorsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListCampaignExperimentAsyncErrorsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[11]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignExperimentAsyncErrorsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignExperimentAsyncErrorsRequest(ListCampaignExperimentAsyncErrorsRequest other) : this() { + resourceName_ = other.resourceName_; + pageToken_ = other.pageToken_; + pageSize_ = other.pageSize_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignExperimentAsyncErrorsRequest Clone() { + return new ListCampaignExperimentAsyncErrorsRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The name of the campaign experiment from which to retrieve the async + /// errors. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "page_token" field. + public const int PageTokenFieldNumber = 2; + private string pageToken_ = ""; + /// + /// Token of the page to retrieve. If not specified, the first + /// page of results will be returned. Use the value obtained from + /// `next_page_token` in the previous response in order to request + /// the next page of results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PageToken { + get { return pageToken_; } + set { + pageToken_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "page_size" field. + public const int PageSizeFieldNumber = 3; + private int pageSize_; + /// + /// Number of elements to retrieve in a single page. + /// When a page request is too large, the server may decide to + /// further limit the number of returned resources. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int PageSize { + get { return pageSize_; } + set { + pageSize_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListCampaignExperimentAsyncErrorsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListCampaignExperimentAsyncErrorsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (PageToken != other.PageToken) return false; + if (PageSize != other.PageSize) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (PageToken.Length != 0) hash ^= PageToken.GetHashCode(); + if (PageSize != 0) hash ^= PageSize.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (PageToken.Length != 0) { + output.WriteRawTag(18); + output.WriteString(PageToken); + } + if (PageSize != 0) { + output.WriteRawTag(24); + output.WriteInt32(PageSize); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (PageToken.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(PageToken); + } + if (PageSize != 0) { + size += 1 + pb::CodedOutputStream.ComputeInt32Size(PageSize); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListCampaignExperimentAsyncErrorsRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.PageToken.Length != 0) { + PageToken = other.PageToken; + } + if (other.PageSize != 0) { + PageSize = other.PageSize; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + PageToken = input.ReadString(); + break; + } + case 24: { + PageSize = input.ReadInt32(); + break; + } + } + } + } + + } + + /// + /// Response message for + /// [CampaignExperimentService.ListCampaignExperimentAsyncErrors][google.ads.googleads.v3.services.CampaignExperimentService.ListCampaignExperimentAsyncErrors]. + /// + public sealed partial class ListCampaignExperimentAsyncErrorsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListCampaignExperimentAsyncErrorsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.MessageTypes[12]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignExperimentAsyncErrorsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignExperimentAsyncErrorsResponse(ListCampaignExperimentAsyncErrorsResponse other) : this() { + errors_ = other.errors_.Clone(); + nextPageToken_ = other.nextPageToken_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListCampaignExperimentAsyncErrorsResponse Clone() { + return new ListCampaignExperimentAsyncErrorsResponse(this); + } + + /// Field number for the "errors" field. + public const int ErrorsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_errors_codec + = pb::FieldCodec.ForMessage(10, global::Google.Rpc.Status.Parser); + private readonly pbc::RepeatedField errors_ = new pbc::RepeatedField(); + /// + /// Details of the errors when performing the asynchronous operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Errors { + get { return errors_; } + } + + /// Field number for the "next_page_token" field. + public const int NextPageTokenFieldNumber = 2; + private string nextPageToken_ = ""; + /// + /// Pagination token used to retrieve the next page of results. + /// Pass the content of this string as the `page_token` attribute of + /// the next request. `next_page_token` is not returned for the last + /// page. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string NextPageToken { + get { return nextPageToken_; } + set { + nextPageToken_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListCampaignExperimentAsyncErrorsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListCampaignExperimentAsyncErrorsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!errors_.Equals(other.errors_)) return false; + if (NextPageToken != other.NextPageToken) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= errors_.GetHashCode(); + if (NextPageToken.Length != 0) hash ^= NextPageToken.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + errors_.WriteTo(output, _repeated_errors_codec); + if (NextPageToken.Length != 0) { + output.WriteRawTag(18); + output.WriteString(NextPageToken); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += errors_.CalculateSize(_repeated_errors_codec); + if (NextPageToken.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(NextPageToken); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListCampaignExperimentAsyncErrorsResponse other) { + if (other == null) { + return; + } + errors_.Add(other.errors_); + if (other.NextPageToken.Length != 0) { + NextPageToken = other.NextPageToken; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + errors_.AddEntriesFrom(input, _repeated_errors_codec); + break; + } + case 18: { + NextPageToken = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExperimentServiceClient.cs b/src/V3/Stubs/CampaignExperimentServiceClient.cs new file mode 100644 index 000000000..1effbc6c2 --- /dev/null +++ b/src/V3/Stubs/CampaignExperimentServiceClient.cs @@ -0,0 +1,2247 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using lro = Google.LongRunning; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using gr = Google.Rpc; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignExperimentServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignExperimentServiceSettings GetDefault() => new CampaignExperimentServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignExperimentServiceSettings() { } + + private CampaignExperimentServiceSettings(CampaignExperimentServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignExperimentSettings = existing.GetCampaignExperimentSettings; + CreateCampaignExperimentSettings = existing.CreateCampaignExperimentSettings; + CreateCampaignExperimentOperationsSettings = existing.CreateCampaignExperimentOperationsSettings?.Clone(); + MutateCampaignExperimentsSettings = existing.MutateCampaignExperimentsSettings; + GraduateCampaignExperimentSettings = existing.GraduateCampaignExperimentSettings; + PromoteCampaignExperimentSettings = existing.PromoteCampaignExperimentSettings; + PromoteCampaignExperimentOperationsSettings = existing.PromoteCampaignExperimentOperationsSettings?.Clone(); + EndCampaignExperimentSettings = existing.EndCampaignExperimentSettings; + ListCampaignExperimentAsyncErrorsSettings = existing.ListCampaignExperimentAsyncErrorsSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignExperimentServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignExperimentServiceClient.GetCampaignExperiment and CampaignExperimentServiceClient.GetCampaignExperimentAsync. + /// + /// + /// The default CampaignExperimentServiceClient.GetCampaignExperiment and + /// CampaignExperimentServiceClient.GetCampaignExperimentAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignExperimentSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignExperimentServiceClient.CreateCampaignExperiment and CampaignExperimentServiceClient.CreateCampaignExperimentAsync. + /// + /// + /// The default CampaignExperimentServiceClient.CreateCampaignExperiment and + /// CampaignExperimentServiceClient.CreateCampaignExperimentAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings CreateCampaignExperimentSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Long Running Operation settings for calls to CampaignExperimentServiceClient.CreateCampaignExperiment. + /// + /// + /// Uses default of: + /// + /// Initial delay: 500 milliseconds + /// Delay multiplier: 1.5 + /// Maximum delay: 5000 milliseconds + /// Total timeout: 300000 milliseconds + /// + /// + public lro::OperationsSettings CreateCampaignExperimentOperationsSettings { get; set; } = new lro::OperationsSettings + { + DefaultPollSettings = new gax::PollSettings( + gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(300000L)), + sys::TimeSpan.FromMilliseconds(500L), + 1.5, + sys::TimeSpan.FromMilliseconds(5000L)) + }; + + /// + /// for synchronous and asynchronous calls to + /// CampaignExperimentServiceClient.MutateCampaignExperiments and CampaignExperimentServiceClient.MutateCampaignExperimentsAsync. + /// + /// + /// The default CampaignExperimentServiceClient.MutateCampaignExperiments and + /// CampaignExperimentServiceClient.MutateCampaignExperimentsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignExperimentsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignExperimentServiceClient.GraduateCampaignExperiment and CampaignExperimentServiceClient.GraduateCampaignExperimentAsync. + /// + /// + /// The default CampaignExperimentServiceClient.GraduateCampaignExperiment and + /// CampaignExperimentServiceClient.GraduateCampaignExperimentAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GraduateCampaignExperimentSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignExperimentServiceClient.PromoteCampaignExperiment and CampaignExperimentServiceClient.PromoteCampaignExperimentAsync. + /// + /// + /// The default CampaignExperimentServiceClient.PromoteCampaignExperiment and + /// CampaignExperimentServiceClient.PromoteCampaignExperimentAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings PromoteCampaignExperimentSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Long Running Operation settings for calls to CampaignExperimentServiceClient.PromoteCampaignExperiment. + /// + /// + /// Uses default of: + /// + /// Initial delay: 500 milliseconds + /// Delay multiplier: 1.5 + /// Maximum delay: 5000 milliseconds + /// Total timeout: 300000 milliseconds + /// + /// + public lro::OperationsSettings PromoteCampaignExperimentOperationsSettings { get; set; } = new lro::OperationsSettings + { + DefaultPollSettings = new gax::PollSettings( + gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(300000L)), + sys::TimeSpan.FromMilliseconds(500L), + 1.5, + sys::TimeSpan.FromMilliseconds(5000L)) + }; + + /// + /// for synchronous and asynchronous calls to + /// CampaignExperimentServiceClient.EndCampaignExperiment and CampaignExperimentServiceClient.EndCampaignExperimentAsync. + /// + /// + /// The default CampaignExperimentServiceClient.EndCampaignExperiment and + /// CampaignExperimentServiceClient.EndCampaignExperimentAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings EndCampaignExperimentSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignExperimentServiceClient.ListCampaignExperimentAsyncErrors and CampaignExperimentServiceClient.ListCampaignExperimentAsyncErrorsAsync. + /// + /// + /// The default CampaignExperimentServiceClient.ListCampaignExperimentAsyncErrors and + /// CampaignExperimentServiceClient.ListCampaignExperimentAsyncErrorsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings ListCampaignExperimentAsyncErrorsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignExperimentServiceSettings Clone() => new CampaignExperimentServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignExperimentServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignExperimentServiceSettings Settings { get; set; } + + /// + public override CampaignExperimentServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignExperimentServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignExperimentServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignExperimentServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignExperimentServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignExperimentServiceClient.ChannelPool; + } + + /// + /// CampaignExperimentService client wrapper, for convenient use. + /// + public abstract partial class CampaignExperimentServiceClient + { + /// + /// The default endpoint for the CampaignExperimentService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignExperimentService scopes. + /// + /// + /// The default CampaignExperimentService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignExperimentServiceClient client = await CampaignExperimentServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignExperimentServiceClient.DefaultEndpoint.Host, CampaignExperimentServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignExperimentServiceClient client = CampaignExperimentServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignExperimentServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignExperimentServiceClient client = CampaignExperimentServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignExperimentServiceClient.DefaultEndpoint.Host, CampaignExperimentServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignExperimentServiceClient client = CampaignExperimentServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignExperimentServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignExperimentServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignExperimentServiceClient Create(grpccore::Channel channel, CampaignExperimentServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignExperimentServiceClient Create(grpccore::CallInvoker callInvoker, CampaignExperimentServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignExperimentService.CampaignExperimentServiceClient grpcClient = new CampaignExperimentService.CampaignExperimentServiceClient(callInvoker); + return new CampaignExperimentServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignExperimentService client. + /// + public virtual CampaignExperimentService.CampaignExperimentServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// + /// Required. The resource name of the campaign experiment to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignExperimentAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignExperimentAsync( + new GetCampaignExperimentRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// + /// Required. The resource name of the campaign experiment to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignExperimentAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignExperimentAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// + /// Required. The resource name of the campaign experiment to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignExperiment GetCampaignExperiment( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignExperiment( + new GetCampaignExperimentRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignExperimentAsync( + GetCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignExperimentAsync( + GetCampaignExperimentRequest request, + st::CancellationToken cancellationToken) => GetCampaignExperimentAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignExperiment GetCampaignExperiment( + GetCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// Required. The ID of the customer whose campaign experiment is being created. + /// + /// + /// Required. The campaign experiment to be created. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> CreateCampaignExperimentAsync( + string customerId, + gagvr::CampaignExperiment campaignExperiment, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => CreateCampaignExperimentAsync( + new CreateCampaignExperimentRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + CampaignExperiment = gax::GaxPreconditions.CheckNotNull(campaignExperiment, nameof(campaignExperiment)), + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// Required. The ID of the customer whose campaign experiment is being created. + /// + /// + /// Required. The campaign experiment to be created. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> CreateCampaignExperimentAsync( + string customerId, + gagvr::CampaignExperiment campaignExperiment, + bool? validateOnly, + st::CancellationToken cancellationToken) => CreateCampaignExperimentAsync( + customerId, + campaignExperiment, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// Required. The ID of the customer whose campaign experiment is being created. + /// + /// + /// Required. The campaign experiment to be created. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual lro::Operation CreateCampaignExperiment( + string customerId, + gagvr::CampaignExperiment campaignExperiment, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => CreateCampaignExperiment( + new CreateCampaignExperimentRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + CampaignExperiment = gax::GaxPreconditions.CheckNotNull(campaignExperiment, nameof(campaignExperiment)), + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// Required. The ID of the customer whose campaign experiment is being created. + /// + /// + /// Required. The campaign experiment to be created. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> CreateCampaignExperimentAsync( + string customerId, + gagvr::CampaignExperiment campaignExperiment, + gaxgrpc::CallSettings callSettings = null) => CreateCampaignExperimentAsync( + new CreateCampaignExperimentRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + CampaignExperiment = gax::GaxPreconditions.CheckNotNull(campaignExperiment, nameof(campaignExperiment)), + }, + callSettings); + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// Required. The ID of the customer whose campaign experiment is being created. + /// + /// + /// Required. The campaign experiment to be created. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> CreateCampaignExperimentAsync( + string customerId, + gagvr::CampaignExperiment campaignExperiment, + st::CancellationToken cancellationToken) => CreateCampaignExperimentAsync( + customerId, + campaignExperiment, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// Required. The ID of the customer whose campaign experiment is being created. + /// + /// + /// Required. The campaign experiment to be created. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual lro::Operation CreateCampaignExperiment( + string customerId, + gagvr::CampaignExperiment campaignExperiment, + gaxgrpc::CallSettings callSettings = null) => CreateCampaignExperiment( + new CreateCampaignExperimentRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + CampaignExperiment = gax::GaxPreconditions.CheckNotNull(campaignExperiment, nameof(campaignExperiment)), + }, + callSettings); + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> CreateCampaignExperimentAsync( + CreateCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Asynchronously poll an operation once, using an operationName from a previous invocation of CreateCampaignExperimentAsync. + /// + /// The name of a previously invoked operation. Must not be null or empty. + /// If not null, applies overrides to this RPC call. + /// A task representing the result of polling the operation. + public virtual stt::Task> PollOnceCreateCampaignExperimentAsync( + string operationName, + gaxgrpc::CallSettings callSettings = null) => lro::Operation.PollOnceFromNameAsync( + gax::GaxPreconditions.CheckNotNullOrEmpty(operationName, nameof(operationName)), + CreateCampaignExperimentOperationsClient, + callSettings); + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual lro::Operation CreateCampaignExperiment( + CreateCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// The long-running operations client for CreateCampaignExperiment. + /// + public virtual lro::OperationsClient CreateCampaignExperimentOperationsClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Poll an operation once, using an operationName from a previous invocation of CreateCampaignExperiment. + /// + /// The name of a previously invoked operation. Must not be null or empty. + /// If not null, applies overrides to this RPC call. + /// The result of polling the operation. + public virtual lro::Operation PollOnceCreateCampaignExperiment( + string operationName, + gaxgrpc::CallSettings callSettings = null) => lro::Operation.PollOnceFromName( + gax::GaxPreconditions.CheckNotNullOrEmpty(operationName, nameof(operationName)), + CreateCampaignExperimentOperationsClient, + callSettings); + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign experiments are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign experiments. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExperimentsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignExperimentsAsync( + new MutateCampaignExperimentsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign experiments are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign experiments. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExperimentsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignExperimentsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign experiments are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign experiments. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignExperimentsResponse MutateCampaignExperiments( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignExperiments( + new MutateCampaignExperimentsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign experiments are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign experiments. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExperimentsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignExperimentsAsync( + new MutateCampaignExperimentsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign experiments are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign experiments. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExperimentsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignExperimentsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign experiments are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign experiments. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignExperimentsResponse MutateCampaignExperiments( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignExperiments( + new MutateCampaignExperimentsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExperimentsAsync( + MutateCampaignExperimentsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExperimentsAsync( + MutateCampaignExperimentsRequest request, + st::CancellationToken cancellationToken) => MutateCampaignExperimentsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignExperimentsResponse MutateCampaignExperiments( + MutateCampaignExperimentsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// + /// Required. The resource name of the campaign experiment to graduate. + /// + /// + /// Required. Resource name of the budget to attach to the campaign graduated from the + /// experiment. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GraduateCampaignExperimentAsync( + string campaignExperiment, + string campaignBudget, + gaxgrpc::CallSettings callSettings = null) => GraduateCampaignExperimentAsync( + new GraduateCampaignExperimentRequest + { + CampaignExperiment = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignExperiment, nameof(campaignExperiment)), + CampaignBudget = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignBudget, nameof(campaignBudget)), + }, + callSettings); + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// + /// Required. The resource name of the campaign experiment to graduate. + /// + /// + /// Required. Resource name of the budget to attach to the campaign graduated from the + /// experiment. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GraduateCampaignExperimentAsync( + string campaignExperiment, + string campaignBudget, + st::CancellationToken cancellationToken) => GraduateCampaignExperimentAsync( + campaignExperiment, + campaignBudget, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// + /// Required. The resource name of the campaign experiment to graduate. + /// + /// + /// Required. Resource name of the budget to attach to the campaign graduated from the + /// experiment. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual GraduateCampaignExperimentResponse GraduateCampaignExperiment( + string campaignExperiment, + string campaignBudget, + gaxgrpc::CallSettings callSettings = null) => GraduateCampaignExperiment( + new GraduateCampaignExperimentRequest + { + CampaignExperiment = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignExperiment, nameof(campaignExperiment)), + CampaignBudget = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignBudget, nameof(campaignBudget)), + }, + callSettings); + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GraduateCampaignExperimentAsync( + GraduateCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GraduateCampaignExperimentAsync( + GraduateCampaignExperimentRequest request, + st::CancellationToken cancellationToken) => GraduateCampaignExperimentAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual GraduateCampaignExperimentResponse GraduateCampaignExperiment( + GraduateCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// + /// Required. The resource name of the campaign experiment to promote. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> PromoteCampaignExperimentAsync( + string campaignExperiment, + gaxgrpc::CallSettings callSettings = null) => PromoteCampaignExperimentAsync( + new PromoteCampaignExperimentRequest + { + CampaignExperiment = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignExperiment, nameof(campaignExperiment)), + }, + callSettings); + + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// + /// Required. The resource name of the campaign experiment to promote. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> PromoteCampaignExperimentAsync( + string campaignExperiment, + st::CancellationToken cancellationToken) => PromoteCampaignExperimentAsync( + campaignExperiment, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// + /// Required. The resource name of the campaign experiment to promote. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual lro::Operation PromoteCampaignExperiment( + string campaignExperiment, + gaxgrpc::CallSettings callSettings = null) => PromoteCampaignExperiment( + new PromoteCampaignExperimentRequest + { + CampaignExperiment = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignExperiment, nameof(campaignExperiment)), + }, + callSettings); + + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task> PromoteCampaignExperimentAsync( + PromoteCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Asynchronously poll an operation once, using an operationName from a previous invocation of PromoteCampaignExperimentAsync. + /// + /// The name of a previously invoked operation. Must not be null or empty. + /// If not null, applies overrides to this RPC call. + /// A task representing the result of polling the operation. + public virtual stt::Task> PollOncePromoteCampaignExperimentAsync( + string operationName, + gaxgrpc::CallSettings callSettings = null) => lro::Operation.PollOnceFromNameAsync( + gax::GaxPreconditions.CheckNotNullOrEmpty(operationName, nameof(operationName)), + PromoteCampaignExperimentOperationsClient, + callSettings); + + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual lro::Operation PromoteCampaignExperiment( + PromoteCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// The long-running operations client for PromoteCampaignExperiment. + /// + public virtual lro::OperationsClient PromoteCampaignExperimentOperationsClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Poll an operation once, using an operationName from a previous invocation of PromoteCampaignExperiment. + /// + /// The name of a previously invoked operation. Must not be null or empty. + /// If not null, applies overrides to this RPC call. + /// The result of polling the operation. + public virtual lro::Operation PollOncePromoteCampaignExperiment( + string operationName, + gaxgrpc::CallSettings callSettings = null) => lro::Operation.PollOnceFromName( + gax::GaxPreconditions.CheckNotNullOrEmpty(operationName, nameof(operationName)), + PromoteCampaignExperimentOperationsClient, + callSettings); + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// + /// Required. The resource name of the campaign experiment to end. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task that completes when the RPC has completed. + /// + public virtual stt::Task EndCampaignExperimentAsync( + string campaignExperiment, + gaxgrpc::CallSettings callSettings = null) => EndCampaignExperimentAsync( + new EndCampaignExperimentRequest + { + CampaignExperiment = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignExperiment, nameof(campaignExperiment)), + }, + callSettings); + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// + /// Required. The resource name of the campaign experiment to end. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task that completes when the RPC has completed. + /// + public virtual stt::Task EndCampaignExperimentAsync( + string campaignExperiment, + st::CancellationToken cancellationToken) => EndCampaignExperimentAsync( + campaignExperiment, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// + /// Required. The resource name of the campaign experiment to end. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + public virtual void EndCampaignExperiment( + string campaignExperiment, + gaxgrpc::CallSettings callSettings = null) => EndCampaignExperiment( + new EndCampaignExperimentRequest + { + CampaignExperiment = gax::GaxPreconditions.CheckNotNullOrEmpty(campaignExperiment, nameof(campaignExperiment)), + }, + callSettings); + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task that completes when the RPC has completed. + /// + public virtual stt::Task EndCampaignExperimentAsync( + EndCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task that completes when the RPC has completed. + /// + public virtual stt::Task EndCampaignExperimentAsync( + EndCampaignExperimentRequest request, + st::CancellationToken cancellationToken) => EndCampaignExperimentAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + public virtual void EndCampaignExperiment( + EndCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// + /// Required. The name of the campaign experiment from which to retrieve the async + /// errors. + /// + /// + /// The token returned from the previous request. + /// A value of null or an empty string retrieves the first page. + /// + /// + /// The size of page to request. The response will not be larger than this, but may be smaller. + /// A value of null or 0 uses a server-defined page size. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public virtual gax::PagedAsyncEnumerable ListCampaignExperimentAsyncErrorsAsync( + string resourceName, + string pageToken = null, + int? pageSize = null, + gaxgrpc::CallSettings callSettings = null) => ListCampaignExperimentAsyncErrorsAsync( + new ListCampaignExperimentAsyncErrorsRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + PageToken = pageToken ?? "", + PageSize = pageSize ?? 0, + }, + callSettings); + + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// + /// Required. The name of the campaign experiment from which to retrieve the async + /// errors. + /// + /// + /// The token returned from the previous request. + /// A value of null or an empty string retrieves the first page. + /// + /// + /// The size of page to request. The response will not be larger than this, but may be smaller. + /// A value of null or 0 uses a server-defined page size. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public virtual gax::PagedEnumerable ListCampaignExperimentAsyncErrors( + string resourceName, + string pageToken = null, + int? pageSize = null, + gaxgrpc::CallSettings callSettings = null) => ListCampaignExperimentAsyncErrors( + new ListCampaignExperimentAsyncErrorsRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + PageToken = pageToken ?? "", + PageSize = pageSize ?? 0, + }, + callSettings); + + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public virtual gax::PagedAsyncEnumerable ListCampaignExperimentAsyncErrorsAsync( + ListCampaignExperimentAsyncErrorsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public virtual gax::PagedEnumerable ListCampaignExperimentAsyncErrors( + ListCampaignExperimentAsyncErrorsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignExperimentService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignExperimentServiceClientImpl : CampaignExperimentServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignExperiment; + private readonly gaxgrpc::ApiCall _callCreateCampaignExperiment; + private readonly gaxgrpc::ApiCall _callMutateCampaignExperiments; + private readonly gaxgrpc::ApiCall _callGraduateCampaignExperiment; + private readonly gaxgrpc::ApiCall _callPromoteCampaignExperiment; + private readonly gaxgrpc::ApiCall _callEndCampaignExperiment; + private readonly gaxgrpc::ApiCall _callListCampaignExperimentAsyncErrors; + + /// + /// Constructs a client wrapper for the CampaignExperimentService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignExperimentServiceClientImpl(CampaignExperimentService.CampaignExperimentServiceClient grpcClient, CampaignExperimentServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignExperimentServiceSettings effectiveSettings = settings ?? CampaignExperimentServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + CreateCampaignExperimentOperationsClient = new lro::OperationsClientImpl( + grpcClient.CreateOperationsClient(), effectiveSettings.CreateCampaignExperimentOperationsSettings); + PromoteCampaignExperimentOperationsClient = new lro::OperationsClientImpl( + grpcClient.CreateOperationsClient(), effectiveSettings.PromoteCampaignExperimentOperationsSettings); + _callGetCampaignExperiment = clientHelper.BuildApiCall( + GrpcClient.GetCampaignExperimentAsync, GrpcClient.GetCampaignExperiment, effectiveSettings.GetCampaignExperimentSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callCreateCampaignExperiment = clientHelper.BuildApiCall( + GrpcClient.CreateCampaignExperimentAsync, GrpcClient.CreateCampaignExperiment, effectiveSettings.CreateCampaignExperimentSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callMutateCampaignExperiments = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignExperimentsAsync, GrpcClient.MutateCampaignExperiments, effectiveSettings.MutateCampaignExperimentsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callGraduateCampaignExperiment = clientHelper.BuildApiCall( + GrpcClient.GraduateCampaignExperimentAsync, GrpcClient.GraduateCampaignExperiment, effectiveSettings.GraduateCampaignExperimentSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"campaign_experiment={request.CampaignExperiment}")); + _callPromoteCampaignExperiment = clientHelper.BuildApiCall( + GrpcClient.PromoteCampaignExperimentAsync, GrpcClient.PromoteCampaignExperiment, effectiveSettings.PromoteCampaignExperimentSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"campaign_experiment={request.CampaignExperiment}")); + _callEndCampaignExperiment = clientHelper.BuildApiCall( + GrpcClient.EndCampaignExperimentAsync, GrpcClient.EndCampaignExperiment, effectiveSettings.EndCampaignExperimentSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"campaign_experiment={request.CampaignExperiment}")); + _callListCampaignExperimentAsyncErrors = clientHelper.BuildApiCall( + GrpcClient.ListCampaignExperimentAsyncErrorsAsync, GrpcClient.ListCampaignExperimentAsyncErrors, effectiveSettings.ListCampaignExperimentAsyncErrorsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetCampaignExperiment); + Modify_GetCampaignExperimentApiCall(ref _callGetCampaignExperiment); + Modify_ApiCall(ref _callCreateCampaignExperiment); + Modify_CreateCampaignExperimentApiCall(ref _callCreateCampaignExperiment); + Modify_ApiCall(ref _callMutateCampaignExperiments); + Modify_MutateCampaignExperimentsApiCall(ref _callMutateCampaignExperiments); + Modify_ApiCall(ref _callGraduateCampaignExperiment); + Modify_GraduateCampaignExperimentApiCall(ref _callGraduateCampaignExperiment); + Modify_ApiCall(ref _callPromoteCampaignExperiment); + Modify_PromoteCampaignExperimentApiCall(ref _callPromoteCampaignExperiment); + Modify_ApiCall(ref _callEndCampaignExperiment); + Modify_EndCampaignExperimentApiCall(ref _callEndCampaignExperiment); + Modify_ApiCall(ref _callListCampaignExperimentAsyncErrors); + Modify_ListCampaignExperimentAsyncErrorsApiCall(ref _callListCampaignExperimentAsyncErrors); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignExperimentApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_CreateCampaignExperimentApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignExperimentsApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_GraduateCampaignExperimentApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_PromoteCampaignExperimentApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_EndCampaignExperimentApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_ListCampaignExperimentAsyncErrorsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignExperimentService.CampaignExperimentServiceClient grpcClient, CampaignExperimentServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignExperimentService client. + /// + public override CampaignExperimentService.CampaignExperimentServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignExperimentRequest(ref GetCampaignExperimentRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_CreateCampaignExperimentRequest(ref CreateCampaignExperimentRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignExperimentsRequest(ref MutateCampaignExperimentsRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_GraduateCampaignExperimentRequest(ref GraduateCampaignExperimentRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_PromoteCampaignExperimentRequest(ref PromoteCampaignExperimentRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_EndCampaignExperimentRequest(ref EndCampaignExperimentRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_ListCampaignExperimentAsyncErrorsRequest(ref ListCampaignExperimentAsyncErrorsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignExperimentAsync( + GetCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignExperimentRequest(ref request, ref callSettings); + return _callGetCampaignExperiment.Async(request, callSettings); + } + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignExperiment GetCampaignExperiment( + GetCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignExperimentRequest(ref request, ref callSettings); + return _callGetCampaignExperiment.Sync(request, callSettings); + } + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override async stt::Task> CreateCampaignExperimentAsync( + CreateCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_CreateCampaignExperimentRequest(ref request, ref callSettings); + return new lro::Operation( + await _callCreateCampaignExperiment.Async(request, callSettings).ConfigureAwait(false), CreateCampaignExperimentOperationsClient); + } + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override lro::Operation CreateCampaignExperiment( + CreateCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_CreateCampaignExperimentRequest(ref request, ref callSettings); + return new lro::Operation( + _callCreateCampaignExperiment.Sync(request, callSettings), CreateCampaignExperimentOperationsClient); + } + + /// + /// The long-running operations client for CreateCampaignExperiment. + /// + public override lro::OperationsClient CreateCampaignExperimentOperationsClient { get; } + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignExperimentsAsync( + MutateCampaignExperimentsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignExperimentsRequest(ref request, ref callSettings); + return _callMutateCampaignExperiments.Async(request, callSettings); + } + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignExperimentsResponse MutateCampaignExperiments( + MutateCampaignExperimentsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignExperimentsRequest(ref request, ref callSettings); + return _callMutateCampaignExperiments.Sync(request, callSettings); + } + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GraduateCampaignExperimentAsync( + GraduateCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GraduateCampaignExperimentRequest(ref request, ref callSettings); + return _callGraduateCampaignExperiment.Async(request, callSettings); + } + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override GraduateCampaignExperimentResponse GraduateCampaignExperiment( + GraduateCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GraduateCampaignExperimentRequest(ref request, ref callSettings); + return _callGraduateCampaignExperiment.Sync(request, callSettings); + } + + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override async stt::Task> PromoteCampaignExperimentAsync( + PromoteCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_PromoteCampaignExperimentRequest(ref request, ref callSettings); + return new lro::Operation( + await _callPromoteCampaignExperiment.Async(request, callSettings).ConfigureAwait(false), PromoteCampaignExperimentOperationsClient); + } + + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override lro::Operation PromoteCampaignExperiment( + PromoteCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_PromoteCampaignExperimentRequest(ref request, ref callSettings); + return new lro::Operation( + _callPromoteCampaignExperiment.Sync(request, callSettings), PromoteCampaignExperimentOperationsClient); + } + + /// + /// The long-running operations client for PromoteCampaignExperiment. + /// + public override lro::OperationsClient PromoteCampaignExperimentOperationsClient { get; } + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task that completes when the RPC has completed. + /// + public override stt::Task EndCampaignExperimentAsync( + EndCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_EndCampaignExperimentRequest(ref request, ref callSettings); + return _callEndCampaignExperiment.Async(request, callSettings); + } + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + public override void EndCampaignExperiment( + EndCampaignExperimentRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_EndCampaignExperimentRequest(ref request, ref callSettings); + _callEndCampaignExperiment.Sync(request, callSettings); + } + + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public override gax::PagedAsyncEnumerable ListCampaignExperimentAsyncErrorsAsync( + ListCampaignExperimentAsyncErrorsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_ListCampaignExperimentAsyncErrorsRequest(ref request, ref callSettings); + return new gaxgrpc::GrpcPagedAsyncEnumerable(_callListCampaignExperimentAsyncErrors, request, callSettings); + } + + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public override gax::PagedEnumerable ListCampaignExperimentAsyncErrors( + ListCampaignExperimentAsyncErrorsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_ListCampaignExperimentAsyncErrorsRequest(ref request, ref callSettings); + return new gaxgrpc::GrpcPagedEnumerable(_callListCampaignExperimentAsyncErrors, request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + public partial class ListCampaignExperimentAsyncErrorsRequest : gaxgrpc::IPageRequest { } + public partial class ListCampaignExperimentAsyncErrorsResponse : gaxgrpc::IPageResponse + { + /// + /// Returns an enumerator that iterates through the resources in this response. + /// + public scg::IEnumerator GetEnumerator() => Errors.GetEnumerator(); + + /// + sc::IEnumerator sc::IEnumerable.GetEnumerator() => GetEnumerator(); + } + + // Partial Grpc class to enable LRO client creation + public static partial class CampaignExperimentService + { + public partial class CampaignExperimentServiceClient + { + /// + /// Creates a new instance of using the same call invoker as this client. + /// + /// A new Operations client for the same target as this client. + public virtual lro::Operations.OperationsClient CreateOperationsClient() => new lro::Operations.OperationsClient(CallInvoker); + } + } + + +} diff --git a/src/V3/Stubs/CampaignExperimentServiceGrpc.cs b/src/V3/Stubs/CampaignExperimentServiceGrpc.cs new file mode 100644 index 000000000..e1626d640 --- /dev/null +++ b/src/V3/Stubs/CampaignExperimentServiceGrpc.cs @@ -0,0 +1,657 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_experiment_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// CampaignExperimentService manages the life cycle of campaign experiments. + /// It is used to create new experiments from drafts, modify experiment + /// properties, promote changes in an experiment back to its base campaign, + /// graduate experiments into new stand-alone campaigns, and to remove an + /// experiment. + /// + /// An experiment consists of two variants or arms - the base campaign and the + /// experiment campaign, directing a fixed share of traffic to each arm. + /// A campaign experiment is created from a draft of changes to the base campaign + /// and will be a snapshot of changes in the draft at the time of creation. + /// + public static partial class CampaignExperimentService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignExperimentService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignExperimentRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignExperimentRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignExperiment = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_CreateCampaignExperimentRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_longrunning_Operation = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.LongRunning.Operation.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignExperimentsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignExperimentsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GraduateCampaignExperimentRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GraduateCampaignExperimentResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_PromoteCampaignExperimentRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignExperimentRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_EndCampaignExperimentRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.EndCampaignExperimentRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_protobuf_Empty = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Protobuf.WellKnownTypes.Empty.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_ListCampaignExperimentAsyncErrorsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_ListCampaignExperimentAsyncErrorsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignExperiment = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignExperiment", + __Marshaller_google_ads_googleads_v3_services_GetCampaignExperimentRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignExperiment); + + static readonly grpc::Method __Method_CreateCampaignExperiment = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "CreateCampaignExperiment", + __Marshaller_google_ads_googleads_v3_services_CreateCampaignExperimentRequest, + __Marshaller_google_longrunning_Operation); + + static readonly grpc::Method __Method_MutateCampaignExperiments = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignExperiments", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignExperimentsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignExperimentsResponse); + + static readonly grpc::Method __Method_GraduateCampaignExperiment = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GraduateCampaignExperiment", + __Marshaller_google_ads_googleads_v3_services_GraduateCampaignExperimentRequest, + __Marshaller_google_ads_googleads_v3_services_GraduateCampaignExperimentResponse); + + static readonly grpc::Method __Method_PromoteCampaignExperiment = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "PromoteCampaignExperiment", + __Marshaller_google_ads_googleads_v3_services_PromoteCampaignExperimentRequest, + __Marshaller_google_longrunning_Operation); + + static readonly grpc::Method __Method_EndCampaignExperiment = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "EndCampaignExperiment", + __Marshaller_google_ads_googleads_v3_services_EndCampaignExperimentRequest, + __Marshaller_google_protobuf_Empty); + + static readonly grpc::Method __Method_ListCampaignExperimentAsyncErrors = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "ListCampaignExperimentAsyncErrors", + __Marshaller_google_ads_googleads_v3_services_ListCampaignExperimentAsyncErrorsRequest, + __Marshaller_google_ads_googleads_v3_services_ListCampaignExperimentAsyncErrorsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignExperimentService + public abstract partial class CampaignExperimentServiceBase + { + /// + /// Returns the requested campaign experiment in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExperimentRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task CreateCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignExperiments(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GraduateCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task PromoteCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignExperimentRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task EndCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.EndCampaignExperimentRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task ListCampaignExperimentAsyncErrors(global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignExperimentService + public partial class CampaignExperimentServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignExperimentService + /// The channel to use to make remote calls. + public CampaignExperimentServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignExperimentService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignExperimentServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignExperimentServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignExperimentServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign experiment in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment GetCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignExperiment(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign experiment in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment GetCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignExperiment, null, options, request); + } + /// + /// Returns the requested campaign experiment in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignExperimentAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign experiment in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignExperiment, null, options, request); + } + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.LongRunning.Operation CreateCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return CreateCampaignExperiment(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.LongRunning.Operation CreateCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_CreateCampaignExperiment, null, options, request); + } + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall CreateCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return CreateCampaignExperimentAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates a campaign experiment based on a campaign draft. The draft campaign + /// will be forked into a real campaign (called the experiment campaign) that + /// will begin serving ads if successfully created. + /// + /// The campaign experiment is created immediately with status INITIALIZING. + /// This method return a long running operation that tracks the forking of the + /// draft campaign. If the forking fails, a list of errors can be retrieved + /// using the ListCampaignExperimentAsyncErrors method. The operation's + /// metadata will be a StringValue containing the resource name of the created + /// campaign experiment. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall CreateCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.CreateCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_CreateCampaignExperiment, null, options, request); + } + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsResponse MutateCampaignExperiments(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignExperiments(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsResponse MutateCampaignExperiments(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignExperiments, null, options, request); + } + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignExperimentsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignExperimentsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Updates campaign experiments. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignExperimentsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignExperiments, null, options, request); + } + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentResponse GraduateCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GraduateCampaignExperiment(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentResponse GraduateCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GraduateCampaignExperiment, null, options, request); + } + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GraduateCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GraduateCampaignExperimentAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Graduates a campaign experiment to a full campaign. The base and experiment + /// campaigns will start running independently with their own budgets. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GraduateCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.GraduateCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GraduateCampaignExperiment, null, options, request); + } + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.LongRunning.Operation PromoteCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return PromoteCampaignExperiment(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.LongRunning.Operation PromoteCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_PromoteCampaignExperiment, null, options, request); + } + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall PromoteCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return PromoteCampaignExperimentAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Promotes the changes in a experiment campaign back to the base campaign. + /// + /// The campaign experiment is updated immediately with status PROMOTING. + /// This method return a long running operation that tracks the promoting of + /// the experiment campaign. If the promoting fails, a list of errors can be + /// retrieved using the ListCampaignExperimentAsyncErrors method. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall PromoteCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.PromoteCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_PromoteCampaignExperiment, null, options, request); + } + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Protobuf.WellKnownTypes.Empty EndCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.EndCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return EndCampaignExperiment(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Protobuf.WellKnownTypes.Empty EndCampaignExperiment(global::Google.Ads.GoogleAds.V3.Services.EndCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_EndCampaignExperiment, null, options, request); + } + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall EndCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.EndCampaignExperimentRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return EndCampaignExperimentAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Immediately ends a campaign experiment, changing the experiment's scheduled + /// end date and without waiting for end of day. End date is updated to be the + /// time of the request. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall EndCampaignExperimentAsync(global::Google.Ads.GoogleAds.V3.Services.EndCampaignExperimentRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_EndCampaignExperiment, null, options, request); + } + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsResponse ListCampaignExperimentAsyncErrors(global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return ListCampaignExperimentAsyncErrors(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsResponse ListCampaignExperimentAsyncErrors(global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_ListCampaignExperimentAsyncErrors, null, options, request); + } + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall ListCampaignExperimentAsyncErrorsAsync(global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return ListCampaignExperimentAsyncErrorsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all errors that occurred during CampaignExperiment create or + /// promote (whichever occurred last). + /// Supports standard list paging. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall ListCampaignExperimentAsyncErrorsAsync(global::Google.Ads.GoogleAds.V3.Services.ListCampaignExperimentAsyncErrorsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_ListCampaignExperimentAsyncErrors, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignExperimentServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignExperimentServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignExperimentServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignExperiment, serviceImpl.GetCampaignExperiment) + .AddMethod(__Method_CreateCampaignExperiment, serviceImpl.CreateCampaignExperiment) + .AddMethod(__Method_MutateCampaignExperiments, serviceImpl.MutateCampaignExperiments) + .AddMethod(__Method_GraduateCampaignExperiment, serviceImpl.GraduateCampaignExperiment) + .AddMethod(__Method_PromoteCampaignExperiment, serviceImpl.PromoteCampaignExperiment) + .AddMethod(__Method_EndCampaignExperiment, serviceImpl.EndCampaignExperiment) + .AddMethod(__Method_ListCampaignExperimentAsyncErrors, serviceImpl.ListCampaignExperimentAsyncErrors).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignExperimentServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignExperiment, serviceImpl.GetCampaignExperiment); + serviceBinder.AddMethod(__Method_CreateCampaignExperiment, serviceImpl.CreateCampaignExperiment); + serviceBinder.AddMethod(__Method_MutateCampaignExperiments, serviceImpl.MutateCampaignExperiments); + serviceBinder.AddMethod(__Method_GraduateCampaignExperiment, serviceImpl.GraduateCampaignExperiment); + serviceBinder.AddMethod(__Method_PromoteCampaignExperiment, serviceImpl.PromoteCampaignExperiment); + serviceBinder.AddMethod(__Method_EndCampaignExperiment, serviceImpl.EndCampaignExperiment); + serviceBinder.AddMethod(__Method_ListCampaignExperimentAsyncErrors, serviceImpl.ListCampaignExperimentAsyncErrors); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignExperimentStatus.cs b/src/V3/Stubs/CampaignExperimentStatus.cs new file mode 100644 index 000000000..1abbef0d0 --- /dev/null +++ b/src/V3/Stubs/CampaignExperimentStatus.cs @@ -0,0 +1,222 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/campaign_experiment_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/campaign_experiment_status.proto + public static partial class CampaignExperimentStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/campaign_experiment_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignExperimentStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWlnbl9leHBl", + "cmltZW50X3N0YXR1cy5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i9gEKHENhbXBh", + "aWduRXhwZXJpbWVudFN0YXR1c0VudW0i1QEKGENhbXBhaWduRXhwZXJpbWVu", + "dFN0YXR1cxIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIQCgxJTklU", + "SUFMSVpJTkcQAhIZChVJTklUSUFMSVpBVElPTl9GQUlMRUQQCBILCgdFTkFC", + "TEVEEAMSDQoJR1JBRFVBVEVEEAQSCwoHUkVNT1ZFRBAFEg0KCVBST01PVElO", + "RxAGEhQKEFBST01PVElPTl9GQUlMRUQQCRIMCghQUk9NT1RFRBAHEhIKDkVO", + "REVEX01BTlVBTExZEApC8gEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtc0IdQ2FtcGFpZ25FeHBlcmltZW50U3RhdHVzUHJvdG9QAVpCZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVB", + "ZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oC", + "IUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentStatusEnum.Types.CampaignExperimentStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of a campaign experiment. + /// + public sealed partial class CampaignExperimentStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignExperimentStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentStatusEnum(CampaignExperimentStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentStatusEnum Clone() { + return new CampaignExperimentStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignExperimentStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignExperimentStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignExperimentStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignExperimentStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a campaign experiment. + /// + public enum CampaignExperimentStatus { + /// + /// The status has not been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The experiment campaign is being initialized. + /// + [pbr::OriginalName("INITIALIZING")] Initializing = 2, + /// + /// Initialization of the experiment campaign failed. + /// + [pbr::OriginalName("INITIALIZATION_FAILED")] InitializationFailed = 8, + /// + /// The experiment campaign is fully initialized. The experiment is currently + /// running, scheduled to run in the future or has ended based on its + /// end date. An experiment with the status INITIALIZING will be updated to + /// ENABLED when it is fully created. + /// + [pbr::OriginalName("ENABLED")] Enabled = 3, + /// + /// The experiment campaign was graduated to a stand-alone + /// campaign, existing independently of the experiment. + /// + [pbr::OriginalName("GRADUATED")] Graduated = 4, + /// + /// The experiment is removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 5, + /// + /// The experiment's changes are being applied to the original campaign. + /// The long running operation returned by the promote method can be polled + /// to see the status of the promotion. + /// + [pbr::OriginalName("PROMOTING")] Promoting = 6, + /// + /// Promote of the experiment campaign failed. + /// + [pbr::OriginalName("PROMOTION_FAILED")] PromotionFailed = 9, + /// + /// The changes of the experiment are promoted to their original campaign. + /// + [pbr::OriginalName("PROMOTED")] Promoted = 7, + /// + /// The experiment was ended manually. It did not end based on its end date. + /// + [pbr::OriginalName("ENDED_MANUALLY")] EndedManually = 10, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExperimentTrafficSplitType.cs b/src/V3/Stubs/CampaignExperimentTrafficSplitType.cs new file mode 100644 index 000000000..6b21de660 --- /dev/null +++ b/src/V3/Stubs/CampaignExperimentTrafficSplitType.cs @@ -0,0 +1,190 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/campaign_experiment_traffic_split_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/campaign_experiment_traffic_split_type.proto + public static partial class CampaignExperimentTrafficSplitTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/campaign_experiment_traffic_split_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignExperimentTrafficSplitTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWlnbl9leHBl", + "cmltZW50X3RyYWZmaWNfc3BsaXRfdHlwZS5wcm90bxIdZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJv", + "dG8iigEKJkNhbXBhaWduRXhwZXJpbWVudFRyYWZmaWNTcGxpdFR5cGVFbnVt", + "ImAKIkNhbXBhaWduRXhwZXJpbWVudFRyYWZmaWNTcGxpdFR5cGUSDwoLVU5T", + "UEVDSUZJRUQQABILCgdVTktOT1dOEAESEAoMUkFORE9NX1FVRVJZEAISCgoG", + "Q09PS0lFEANC/AEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "c0InQ2FtcGFpZ25FeHBlcmltZW50VHJhZmZpY1NwbGl0VHlwZVByb3RvUAFa", + "Qmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51", + "bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3Rv", + "Mw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeEnum.Types.CampaignExperimentTrafficSplitType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing campaign experiment traffic split type. + /// + public sealed partial class CampaignExperimentTrafficSplitTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignExperimentTrafficSplitTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTrafficSplitTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentTrafficSplitTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentTrafficSplitTypeEnum(CampaignExperimentTrafficSplitTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentTrafficSplitTypeEnum Clone() { + return new CampaignExperimentTrafficSplitTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignExperimentTrafficSplitTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignExperimentTrafficSplitTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignExperimentTrafficSplitTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignExperimentTrafficSplitTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum of strategies for splitting traffic between base and experiment + /// campaigns in campaign experiment. + /// + public enum CampaignExperimentTrafficSplitType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Traffic is randomly assigned to the base or experiment arm for each + /// query, independent of previous assignments for the same user. + /// + [pbr::OriginalName("RANDOM_QUERY")] RandomQuery = 2, + /// + /// Traffic is split using cookies to keep users in the same arm (base or + /// experiment) of the experiment. + /// + [pbr::OriginalName("COOKIE")] Cookie = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExperimentType.cs b/src/V3/Stubs/CampaignExperimentType.cs new file mode 100644 index 000000000..3e6bd61bd --- /dev/null +++ b/src/V3/Stubs/CampaignExperimentType.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/campaign_experiment_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/campaign_experiment_type.proto + public static partial class CampaignExperimentTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/campaign_experiment_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignExperimentTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWlnbl9leHBl", + "cmltZW50X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvInkKGkNhbXBhaWdu", + "RXhwZXJpbWVudFR5cGVFbnVtIlsKFkNhbXBhaWduRXhwZXJpbWVudFR5cGUS", + "DwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESCAoEQkFTRRACEgkKBURS", + "QUZUEAMSDgoKRVhQRVJJTUVOVBAEQvABCiFjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXNCG0NhbXBhaWduRXhwZXJpbWVudFR5cGVQcm90b1AB", + "WkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVu", + "dW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTypeEnum.Types.CampaignExperimentType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing campaign experiment type. + /// + public sealed partial class CampaignExperimentTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignExperimentTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CampaignExperimentTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentTypeEnum(CampaignExperimentTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExperimentTypeEnum Clone() { + return new CampaignExperimentTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignExperimentTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignExperimentTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignExperimentTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignExperimentTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Indicates if this campaign is a normal campaign, + /// a draft campaign, or an experiment campaign. + /// + public enum CampaignExperimentType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// This is a regular campaign. + /// + [pbr::OriginalName("BASE")] Base = 2, + /// + /// This is a draft version of a campaign. + /// It has some modifications from a base campaign, + /// but it does not serve or accrue metrics. + /// + [pbr::OriginalName("DRAFT")] Draft = 3, + /// + /// This is an experiment version of a campaign. + /// It has some modifications from a base campaign, + /// and a percentage of traffic is being diverted + /// from the BASE campaign to this experiment campaign. + /// + [pbr::OriginalName("EXPERIMENT")] Experiment = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExtensionSetting.cs b/src/V3/Stubs/CampaignExtensionSetting.cs new file mode 100644 index 000000000..689f0e1a2 --- /dev/null +++ b/src/V3/Stubs/CampaignExtensionSetting.cs @@ -0,0 +1,336 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_extension_setting.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_extension_setting.proto + public static partial class CampaignExtensionSettingReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_extension_setting.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignExtensionSettingReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "ZXh0ZW5zaW9uX3NldHRpbmcucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMv", + "ZXh0ZW5zaW9uX3NldHRpbmdfZGV2aWNlLnByb3RvGjJnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcy9leHRlbnNpb25fdHlwZS5wcm90bxofZ29vZ2xl", + "L2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJj", + "ZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvoEChhDYW1wYWlnbkV4dGVuc2lv", + "blNldHRpbmcSUAoNcmVzb3VyY2VfbmFtZRgBIAEoCUI54EEF+kEzCjFnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2FtcGFpZ25FeHRlbnNpb25TZXR0aW5n", + "ElsKDmV4dGVuc2lvbl90eXBlGAIgASgOMj4uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZW51bXMuRXh0ZW5zaW9uVHlwZUVudW0uRXh0ZW5zaW9uVHlwZUID", + "4EEFElkKCGNhbXBhaWduGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlQingQQX6QSMKIWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9DYW1w", + "YWlnbhJrChRleHRlbnNpb25fZmVlZF9pdGVtcxgEIAMoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZUIv+kEsCipnb29nbGVhZHMuZ29vZ2xlYXBp", + "cy5jb20vRXh0ZW5zaW9uRmVlZEl0ZW0SYAoGZGV2aWNlGAUgASgOMlAuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuRXh0ZW5zaW9uU2V0dGluZ0Rl", + "dmljZUVudW0uRXh0ZW5zaW9uU2V0dGluZ0RldmljZTqEAepBgAEKMWdvb2ds", + "ZWFkcy5nb29nbGVhcGlzLmNvbS9DYW1wYWlnbkV4dGVuc2lvblNldHRpbmcS", + "S2N1c3RvbWVycy97Y3VzdG9tZXJ9L2NhbXBhaWduRXh0ZW5zaW9uU2V0dGlu", + "Z3Mve2NhbXBhaWduX2V4dGVuc2lvbl9zZXR0aW5nfUKKAgolY29tLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IdQ2FtcGFpZ25FeHRlbnNp", + "b25TZXR0aW5nUHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8v", + "Z29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJj", + "ZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPK", + "AiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting), global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting.Parser, new[]{ "ResourceName", "ExtensionType", "Campaign", "ExtensionFeedItems", "Device" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A campaign extension setting. + /// + public sealed partial class CampaignExtensionSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignExtensionSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSettingReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExtensionSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExtensionSetting(CampaignExtensionSetting other) : this() { + resourceName_ = other.resourceName_; + extensionType_ = other.extensionType_; + Campaign = other.Campaign; + extensionFeedItems_ = other.extensionFeedItems_.Clone(); + device_ = other.device_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExtensionSetting Clone() { + return new CampaignExtensionSetting(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign extension setting. + /// CampaignExtensionSetting resource names have the form: + /// + /// `customers/{customer_id}/campaignExtensionSettings/{campaign_id}~{extension_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "extension_type" field. + public const int ExtensionTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType extensionType_ = 0; + /// + /// Immutable. The extension type of the customer extension setting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType ExtensionType { + get { return extensionType_; } + set { + extensionType_ = value; + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 3; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(26); + private string campaign_; + /// + /// Immutable. The resource name of the campaign. The linked extension feed items will + /// serve under this campaign. + /// Campaign resource names have the form: + /// + /// `customers/{customer_id}/campaigns/{campaign_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "extension_feed_items" field. + public const int ExtensionFeedItemsFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_extensionFeedItems_codec + = pb::FieldCodec.ForClassWrapper(34); + private readonly pbc::RepeatedField extensionFeedItems_ = new pbc::RepeatedField(); + /// + /// The resource names of the extension feed items to serve under the campaign. + /// ExtensionFeedItem resource names have the form: + /// + /// `customers/{customer_id}/extensionFeedItems/{feed_item_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ExtensionFeedItems { + get { return extensionFeedItems_; } + } + + /// Field number for the "device" field. + public const int DeviceFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice device_ = 0; + /// + /// The device for which the extensions will serve. Optional. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice Device { + get { return device_; } + set { + device_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignExtensionSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignExtensionSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (ExtensionType != other.ExtensionType) return false; + if (Campaign != other.Campaign) return false; + if(!extensionFeedItems_.Equals(other.extensionFeedItems_)) return false; + if (Device != other.Device) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (ExtensionType != 0) hash ^= ExtensionType.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + hash ^= extensionFeedItems_.GetHashCode(); + if (Device != 0) hash ^= Device.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (ExtensionType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) ExtensionType); + } + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + extensionFeedItems_.WriteTo(output, _repeated_extensionFeedItems_codec); + if (Device != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Device); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (ExtensionType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ExtensionType); + } + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + size += extensionFeedItems_.CalculateSize(_repeated_extensionFeedItems_codec); + if (Device != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Device); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignExtensionSetting other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.ExtensionType != 0) { + ExtensionType = other.ExtensionType; + } + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + extensionFeedItems_.Add(other.extensionFeedItems_); + if (other.Device != 0) { + Device = other.Device; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 16: { + ExtensionType = (global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType) input.ReadEnum(); + break; + } + case 26: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 34: { + extensionFeedItems_.AddEntriesFrom(input, _repeated_extensionFeedItems_codec); + break; + } + case 40: { + Device = (global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExtensionSettingService.cs b/src/V3/Stubs/CampaignExtensionSettingService.cs new file mode 100644 index 000000000..aa5939117 --- /dev/null +++ b/src/V3/Stubs/CampaignExtensionSettingService.cs @@ -0,0 +1,1044 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_extension_setting_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_extension_setting_service.proto + public static partial class CampaignExtensionSettingServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_extension_setting_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignExtensionSettingServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cklnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9l", + "eHRlbnNpb25fc2V0dGluZ19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcxpCZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "cmVzb3VyY2VzL2NhbXBhaWduX2V4dGVuc2lvbl9zZXR0aW5nLnByb3RvGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVu", + "dC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29v", + "Z2xlL3Byb3RvYnVmL2ZpZWxkX21hc2sucHJvdG8aF2dvb2dsZS9ycGMvc3Rh", + "dHVzLnByb3RvIkAKIkdldENhbXBhaWduRXh0ZW5zaW9uU2V0dGluZ1JlcXVl", + "c3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEoCUID4EECItABCiZNdXRhdGVDYW1w", + "YWlnbkV4dGVuc2lvblNldHRpbmdzUmVxdWVzdBIYCgtjdXN0b21lcl9pZBgB", + "IAEoCUID4EECElwKCm9wZXJhdGlvbnMYAiADKAsyQy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcy5DYW1wYWlnbkV4dGVuc2lvblNldHRpbmdP", + "cGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyABKAgSFQoNdmFs", + "aWRhdGVfb25seRgEIAEoCCKRAgohQ2FtcGFpZ25FeHRlbnNpb25TZXR0aW5n", + "T3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAQgASgLMhouZ29vZ2xlLnByb3Rv", + "YnVmLkZpZWxkTWFzaxJNCgZjcmVhdGUYASABKAsyOy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5yZXNvdXJjZXMuQ2FtcGFpZ25FeHRlbnNpb25TZXR0aW5n", + "SAASTQoGdXBkYXRlGAIgASgLMjsuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzLkNhbXBhaWduRXh0ZW5zaW9uU2V0dGluZ0gAEhAKBnJlbW92", + "ZRgDIAEoCUgAQgsKCW9wZXJhdGlvbiK1AQonTXV0YXRlQ2FtcGFpZ25FeHRl", + "bnNpb25TZXR0aW5nc1Jlc3BvbnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJv", + "chgDIAEoCzISLmdvb2dsZS5ycGMuU3RhdHVzElcKB3Jlc3VsdHMYAiADKAsy", + "Ri5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDYW1w", + "YWlnbkV4dGVuc2lvblNldHRpbmdSZXN1bHQiPQokTXV0YXRlQ2FtcGFpZ25F", + "eHRlbnNpb25TZXR0aW5nUmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAky", + "0wQKH0NhbXBhaWduRXh0ZW5zaW9uU2V0dGluZ1NlcnZpY2US9QEKG0dldENh", + "bXBhaWduRXh0ZW5zaW9uU2V0dGluZxJELmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLkdldENhbXBhaWduRXh0ZW5zaW9uU2V0dGluZ1JlcXVl", + "c3QaOy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2FtcGFp", + "Z25FeHRlbnNpb25TZXR0aW5nIlOC0+STAj0SOy92My97cmVzb3VyY2VfbmFt", + "ZT1jdXN0b21lcnMvKi9jYW1wYWlnbkV4dGVuc2lvblNldHRpbmdzLyp92kEN", + "cmVzb3VyY2VfbmFtZRKaAgofTXV0YXRlQ2FtcGFpZ25FeHRlbnNpb25TZXR0", + "aW5ncxJILmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0", + "ZUNhbXBhaWduRXh0ZW5zaW9uU2V0dGluZ3NSZXF1ZXN0GkkuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ2FtcGFpZ25FeHRlbnNp", + "b25TZXR0aW5nc1Jlc3BvbnNlImKC0+STAkMiPi92My9jdXN0b21lcnMve2N1", + "c3RvbWVyX2lkPSp9L2NhbXBhaWduRXh0ZW5zaW9uU2V0dGluZ3M6bXV0YXRl", + "OgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9ucxobykEYZ29vZ2xlYWRzLmdv", + "b2dsZWFwaXMuY29tQosCCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXNCJENhbXBhaWduRXh0ZW5zaW9uU2V0dGluZ1NlcnZpY2VQcm90", + "b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSettingReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExtensionSettingRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignExtensionSettingRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [CampaignExtensionSettingService.GetCampaignExtensionSetting][google.ads.googleads.v3.services.CampaignExtensionSettingService.GetCampaignExtensionSetting]. + /// + public sealed partial class GetCampaignExtensionSettingRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignExtensionSettingRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignExtensionSettingRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignExtensionSettingRequest(GetCampaignExtensionSettingRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignExtensionSettingRequest Clone() { + return new GetCampaignExtensionSettingRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign extension setting to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignExtensionSettingRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignExtensionSettingRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignExtensionSettingRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [CampaignExtensionSettingService.MutateCampaignExtensionSettings][google.ads.googleads.v3.services.CampaignExtensionSettingService.MutateCampaignExtensionSettings]. + /// + public sealed partial class MutateCampaignExtensionSettingsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignExtensionSettingsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingsRequest(MutateCampaignExtensionSettingsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingsRequest Clone() { + return new MutateCampaignExtensionSettingsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose campaign extension settings are being + /// modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual campaign extension + /// settings. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignExtensionSettingsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignExtensionSettingsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignExtensionSettingsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a campaign extension setting. + /// + public sealed partial class CampaignExtensionSettingOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignExtensionSettingOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExtensionSettingOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExtensionSettingOperation(CampaignExtensionSettingOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignExtensionSettingOperation Clone() { + return new CampaignExtensionSettingOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new campaign + /// extension setting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The campaign extension setting is expected to have a + /// valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed campaign extension + /// setting is expected, in this format: + /// + /// `customers/{customer_id}/campaignExtensionSettings/{campaign_id}~{extension_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignExtensionSettingOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignExtensionSettingOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignExtensionSettingOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a campaign extension setting mutate. + /// + public sealed partial class MutateCampaignExtensionSettingsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignExtensionSettingsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingsResponse(MutateCampaignExtensionSettingsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingsResponse Clone() { + return new MutateCampaignExtensionSettingsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignExtensionSettingsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignExtensionSettingsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignExtensionSettingsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the campaign extension setting mutate. + /// + public sealed partial class MutateCampaignExtensionSettingResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignExtensionSettingResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingResult(MutateCampaignExtensionSettingResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignExtensionSettingResult Clone() { + return new MutateCampaignExtensionSettingResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignExtensionSettingResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignExtensionSettingResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignExtensionSettingResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignExtensionSettingServiceClient.cs b/src/V3/Stubs/CampaignExtensionSettingServiceClient.cs new file mode 100644 index 000000000..483f9f0d0 --- /dev/null +++ b/src/V3/Stubs/CampaignExtensionSettingServiceClient.cs @@ -0,0 +1,910 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignExtensionSettingServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignExtensionSettingServiceSettings GetDefault() => new CampaignExtensionSettingServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignExtensionSettingServiceSettings() { } + + private CampaignExtensionSettingServiceSettings(CampaignExtensionSettingServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignExtensionSettingSettings = existing.GetCampaignExtensionSettingSettings; + MutateCampaignExtensionSettingsSettings = existing.MutateCampaignExtensionSettingsSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignExtensionSettingServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignExtensionSettingServiceClient.GetCampaignExtensionSetting and CampaignExtensionSettingServiceClient.GetCampaignExtensionSettingAsync. + /// + /// + /// The default CampaignExtensionSettingServiceClient.GetCampaignExtensionSetting and + /// CampaignExtensionSettingServiceClient.GetCampaignExtensionSettingAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignExtensionSettingSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignExtensionSettingServiceClient.MutateCampaignExtensionSettings and CampaignExtensionSettingServiceClient.MutateCampaignExtensionSettingsAsync. + /// + /// + /// The default CampaignExtensionSettingServiceClient.MutateCampaignExtensionSettings and + /// CampaignExtensionSettingServiceClient.MutateCampaignExtensionSettingsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignExtensionSettingsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignExtensionSettingServiceSettings Clone() => new CampaignExtensionSettingServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignExtensionSettingServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignExtensionSettingServiceSettings Settings { get; set; } + + /// + public override CampaignExtensionSettingServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignExtensionSettingServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignExtensionSettingServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignExtensionSettingServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignExtensionSettingServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignExtensionSettingServiceClient.ChannelPool; + } + + /// + /// CampaignExtensionSettingService client wrapper, for convenient use. + /// + public abstract partial class CampaignExtensionSettingServiceClient + { + /// + /// The default endpoint for the CampaignExtensionSettingService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignExtensionSettingService scopes. + /// + /// + /// The default CampaignExtensionSettingService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignExtensionSettingServiceClient client = await CampaignExtensionSettingServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignExtensionSettingServiceClient.DefaultEndpoint.Host, CampaignExtensionSettingServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignExtensionSettingServiceClient client = CampaignExtensionSettingServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignExtensionSettingServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignExtensionSettingServiceClient client = CampaignExtensionSettingServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignExtensionSettingServiceClient.DefaultEndpoint.Host, CampaignExtensionSettingServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignExtensionSettingServiceClient client = CampaignExtensionSettingServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignExtensionSettingServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignExtensionSettingServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignExtensionSettingServiceClient Create(grpccore::Channel channel, CampaignExtensionSettingServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignExtensionSettingServiceClient Create(grpccore::CallInvoker callInvoker, CampaignExtensionSettingServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignExtensionSettingService.CampaignExtensionSettingServiceClient grpcClient = new CampaignExtensionSettingService.CampaignExtensionSettingServiceClient(callInvoker); + return new CampaignExtensionSettingServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignExtensionSettingService client. + /// + public virtual CampaignExtensionSettingService.CampaignExtensionSettingServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// + /// Required. The resource name of the campaign extension setting to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignExtensionSettingAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignExtensionSettingAsync( + new GetCampaignExtensionSettingRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// + /// Required. The resource name of the campaign extension setting to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignExtensionSettingAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignExtensionSettingAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// + /// Required. The resource name of the campaign extension setting to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignExtensionSetting GetCampaignExtensionSetting( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignExtensionSetting( + new GetCampaignExtensionSettingRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignExtensionSettingAsync( + GetCampaignExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignExtensionSettingAsync( + GetCampaignExtensionSettingRequest request, + st::CancellationToken cancellationToken) => GetCampaignExtensionSettingAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignExtensionSetting GetCampaignExtensionSetting( + GetCampaignExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual campaign extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignExtensionSettingsAsync( + new MutateCampaignExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual campaign extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignExtensionSettingsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual campaign extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignExtensionSettingsResponse MutateCampaignExtensionSettings( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignExtensionSettings( + new MutateCampaignExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual campaign extension + /// settings. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignExtensionSettingsAsync( + new MutateCampaignExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual campaign extension + /// settings. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignExtensionSettingsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual campaign extension + /// settings. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignExtensionSettingsResponse MutateCampaignExtensionSettings( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignExtensionSettings( + new MutateCampaignExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExtensionSettingsAsync( + MutateCampaignExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignExtensionSettingsAsync( + MutateCampaignExtensionSettingsRequest request, + st::CancellationToken cancellationToken) => MutateCampaignExtensionSettingsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignExtensionSettingsResponse MutateCampaignExtensionSettings( + MutateCampaignExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignExtensionSettingService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignExtensionSettingServiceClientImpl : CampaignExtensionSettingServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignExtensionSetting; + private readonly gaxgrpc::ApiCall _callMutateCampaignExtensionSettings; + + /// + /// Constructs a client wrapper for the CampaignExtensionSettingService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignExtensionSettingServiceClientImpl(CampaignExtensionSettingService.CampaignExtensionSettingServiceClient grpcClient, CampaignExtensionSettingServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignExtensionSettingServiceSettings effectiveSettings = settings ?? CampaignExtensionSettingServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignExtensionSetting = clientHelper.BuildApiCall( + GrpcClient.GetCampaignExtensionSettingAsync, GrpcClient.GetCampaignExtensionSetting, effectiveSettings.GetCampaignExtensionSettingSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaignExtensionSettings = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignExtensionSettingsAsync, GrpcClient.MutateCampaignExtensionSettings, effectiveSettings.MutateCampaignExtensionSettingsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCampaignExtensionSetting); + Modify_GetCampaignExtensionSettingApiCall(ref _callGetCampaignExtensionSetting); + Modify_ApiCall(ref _callMutateCampaignExtensionSettings); + Modify_MutateCampaignExtensionSettingsApiCall(ref _callMutateCampaignExtensionSettings); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignExtensionSettingApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignExtensionSettingsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignExtensionSettingService.CampaignExtensionSettingServiceClient grpcClient, CampaignExtensionSettingServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignExtensionSettingService client. + /// + public override CampaignExtensionSettingService.CampaignExtensionSettingServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignExtensionSettingRequest(ref GetCampaignExtensionSettingRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignExtensionSettingsRequest(ref MutateCampaignExtensionSettingsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignExtensionSettingAsync( + GetCampaignExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignExtensionSettingRequest(ref request, ref callSettings); + return _callGetCampaignExtensionSetting.Async(request, callSettings); + } + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignExtensionSetting GetCampaignExtensionSetting( + GetCampaignExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignExtensionSettingRequest(ref request, ref callSettings); + return _callGetCampaignExtensionSetting.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignExtensionSettingsAsync( + MutateCampaignExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignExtensionSettingsRequest(ref request, ref callSettings); + return _callMutateCampaignExtensionSettings.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignExtensionSettingsResponse MutateCampaignExtensionSettings( + MutateCampaignExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignExtensionSettingsRequest(ref request, ref callSettings); + return _callMutateCampaignExtensionSettings.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignExtensionSettingServiceGrpc.cs b/src/V3/Stubs/CampaignExtensionSettingServiceGrpc.cs new file mode 100644 index 000000000..e1aa5f962 --- /dev/null +++ b/src/V3/Stubs/CampaignExtensionSettingServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_extension_setting_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaign extension settings. + /// + public static partial class CampaignExtensionSettingService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignExtensionSettingService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignExtensionSettingRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignExtensionSettingRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignExtensionSetting = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignExtensionSettingsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignExtensionSettingsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignExtensionSetting = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignExtensionSetting", + __Marshaller_google_ads_googleads_v3_services_GetCampaignExtensionSettingRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignExtensionSetting); + + static readonly grpc::Method __Method_MutateCampaignExtensionSettings = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignExtensionSettings", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignExtensionSettingsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignExtensionSettingsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignExtensionSettingService + public abstract partial class CampaignExtensionSettingServiceBase + { + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExtensionSettingRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignExtensionSettingService + public partial class CampaignExtensionSettingServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignExtensionSettingService + /// The channel to use to make remote calls. + public CampaignExtensionSettingServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignExtensionSettingService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignExtensionSettingServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignExtensionSettingServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignExtensionSettingServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting GetCampaignExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExtensionSettingRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignExtensionSetting(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting GetCampaignExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExtensionSettingRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignExtensionSetting, null, options, request); + } + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignExtensionSettingAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExtensionSettingRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignExtensionSettingAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign extension setting in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignExtensionSettingAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignExtensionSettingRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignExtensionSetting, null, options, request); + } + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsResponse MutateCampaignExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignExtensionSettings(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsResponse MutateCampaignExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignExtensionSettings, null, options, request); + } + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignExtensionSettingsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignExtensionSettingsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignExtensionSettingsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignExtensionSettings, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignExtensionSettingServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignExtensionSettingServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignExtensionSettingServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignExtensionSetting, serviceImpl.GetCampaignExtensionSetting) + .AddMethod(__Method_MutateCampaignExtensionSettings, serviceImpl.MutateCampaignExtensionSettings).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignExtensionSettingServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignExtensionSetting, serviceImpl.GetCampaignExtensionSetting); + serviceBinder.AddMethod(__Method_MutateCampaignExtensionSettings, serviceImpl.MutateCampaignExtensionSettings); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignFeed.cs b/src/V3/Stubs/CampaignFeed.cs new file mode 100644 index 000000000..9fa9a9ebd --- /dev/null +++ b/src/V3/Stubs/CampaignFeed.cs @@ -0,0 +1,377 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_feed.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_feed.proto + public static partial class CampaignFeedReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_feed.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignFeedReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "ZmVlZC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "GjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vbWF0Y2hpbmdfZnVu", + "Y3Rpb24ucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2Zl", + "ZWRfbGlua19zdGF0dXMucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL3BsYWNlaG9sZGVyX3R5cGUucHJvdG8aH2dvb2dsZS9hcGkvZmll", + "bGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8a", + "Hmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9h", + "bm5vdGF0aW9ucy5wcm90byLlBAoMQ2FtcGFpZ25GZWVkEkQKDXJlc291cmNl", + "X25hbWUYASABKAlCLeBBBfpBJwolZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29t", + "L0NhbXBhaWduRmVlZBJRCgRmZWVkGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlQiXgQQX6QR8KHWdvb2dsZWFkcy5nb29nbGVhcGlzLmNv", + "bS9GZWVkElkKCGNhbXBhaWduGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlQingQQX6QSMKIWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9D", + "YW1wYWlnbhJdChFwbGFjZWhvbGRlcl90eXBlcxgEIAMoDjJCLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVudW1zLlBsYWNlaG9sZGVyVHlwZUVudW0uUGxh", + "Y2Vob2xkZXJUeXBlEksKEW1hdGNoaW5nX2Z1bmN0aW9uGAUgASgLMjAuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLk1hdGNoaW5nRnVuY3Rpb24S", + "VQoGc3RhdHVzGAYgASgOMkAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMuRmVlZExpbmtTdGF0dXNFbnVtLkZlZWRMaW5rU3RhdHVzQgPgQQM6XupB", + "WwolZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0NhbXBhaWduRmVlZBIyY3Vz", + "dG9tZXJzL3tjdXN0b21lcn0vY2FtcGFpZ25GZWVkcy97Y2FtcGFpZ25fZmVl", + "ZH1C/gEKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNC", + "EUNhbXBhaWduRmVlZFByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnBy", + "b3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVz", + "b3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3Vy", + "Y2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29v", + "Z2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.MatchingFunctionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed), global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed.Parser, new[]{ "ResourceName", "Feed", "Campaign", "PlaceholderTypes", "MatchingFunction", "Status" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A campaign feed. + /// + public sealed partial class CampaignFeed : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignFeed()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignFeedReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeed() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeed(CampaignFeed other) : this() { + resourceName_ = other.resourceName_; + Feed = other.Feed; + Campaign = other.Campaign; + placeholderTypes_ = other.placeholderTypes_.Clone(); + matchingFunction_ = other.matchingFunction_ != null ? other.matchingFunction_.Clone() : null; + status_ = other.status_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeed Clone() { + return new CampaignFeed(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign feed. + /// Campaign feed resource names have the form: + /// + /// `customers/{customer_id}/campaignFeeds/{campaign_id}~{feed_id} + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "feed" field. + public const int FeedFieldNumber = 2; + private static readonly pb::FieldCodec _single_feed_codec = pb::FieldCodec.ForClassWrapper(18); + private string feed_; + /// + /// Immutable. The feed to which the CampaignFeed belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Feed { + get { return feed_; } + set { + feed_ = value; + } + } + + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 3; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(26); + private string campaign_; + /// + /// Immutable. The campaign to which the CampaignFeed belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "placeholder_types" field. + public const int PlaceholderTypesFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_placeholderTypes_codec + = pb::FieldCodec.ForEnum(34, x => (int) x, x => (global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType) x); + private readonly pbc::RepeatedField placeholderTypes_ = new pbc::RepeatedField(); + /// + /// Indicates which placeholder types the feed may populate under the connected + /// campaign. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PlaceholderTypes { + get { return placeholderTypes_; } + } + + /// Field number for the "matching_function" field. + public const int MatchingFunctionFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Common.MatchingFunction matchingFunction_; + /// + /// Matching function associated with the CampaignFeed. + /// The matching function is used to filter the set of feed items selected. + /// Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MatchingFunction MatchingFunction { + get { return matchingFunction_; } + set { + matchingFunction_ = value; + } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus status_ = 0; + /// + /// Output only. Status of the campaign feed. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignFeed); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignFeed other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Feed != other.Feed) return false; + if (Campaign != other.Campaign) return false; + if(!placeholderTypes_.Equals(other.placeholderTypes_)) return false; + if (!object.Equals(MatchingFunction, other.MatchingFunction)) return false; + if (Status != other.Status) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (feed_ != null) hash ^= Feed.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + hash ^= placeholderTypes_.GetHashCode(); + if (matchingFunction_ != null) hash ^= MatchingFunction.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (feed_ != null) { + _single_feed_codec.WriteTagAndValue(output, Feed); + } + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + placeholderTypes_.WriteTo(output, _repeated_placeholderTypes_codec); + if (matchingFunction_ != null) { + output.WriteRawTag(42); + output.WriteMessage(MatchingFunction); + } + if (Status != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) Status); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (feed_ != null) { + size += _single_feed_codec.CalculateSizeWithTag(Feed); + } + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + size += placeholderTypes_.CalculateSize(_repeated_placeholderTypes_codec); + if (matchingFunction_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MatchingFunction); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignFeed other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.feed_ != null) { + if (feed_ == null || other.Feed != "") { + Feed = other.Feed; + } + } + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + placeholderTypes_.Add(other.placeholderTypes_); + if (other.matchingFunction_ != null) { + if (matchingFunction_ == null) { + MatchingFunction = new global::Google.Ads.GoogleAds.V3.Common.MatchingFunction(); + } + MatchingFunction.MergeFrom(other.MatchingFunction); + } + if (other.Status != 0) { + Status = other.Status; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_feed_codec.Read(input); + if (feed_ == null || value != "") { + Feed = value; + } + break; + } + case 26: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 34: + case 32: { + placeholderTypes_.AddEntriesFrom(input, _repeated_placeholderTypes_codec); + break; + } + case 42: { + if (matchingFunction_ == null) { + MatchingFunction = new global::Google.Ads.GoogleAds.V3.Common.MatchingFunction(); + } + input.ReadMessage(MatchingFunction); + break; + } + case 48: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignFeedError.cs b/src/V3/Stubs/CampaignFeedError.cs new file mode 100644 index 000000000..253571788 --- /dev/null +++ b/src/V3/Stubs/CampaignFeedError.cs @@ -0,0 +1,213 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/campaign_feed_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/campaign_feed_error.proto + public static partial class CampaignFeedErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/campaign_feed_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignFeedErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2FtcGFpZ25fZmVl", + "ZF9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIuwCChVDYW1wYWlnbkZl", + "ZWRFcnJvckVudW0i0gIKEUNhbXBhaWduRmVlZEVycm9yEg8KC1VOU1BFQ0lG", + "SUVEEAASCwoHVU5LTk9XThABEiwKKEZFRURfQUxSRUFEWV9FWElTVFNfRk9S", + "X1BMQUNFSE9MREVSX1RZUEUQAhIiCh5DQU5OT1RfQ1JFQVRFX0ZPUl9SRU1P", + "VkVEX0ZFRUQQBBIwCixDQU5OT1RfQ1JFQVRFX0FMUkVBRFlfRVhJU1RJTkdf", + "Q0FNUEFJR05fRkVFRBAFEicKI0NBTk5PVF9NT0RJRllfUkVNT1ZFRF9DQU1Q", + "QUlHTl9GRUVEEAYSHAoYSU5WQUxJRF9QTEFDRUhPTERFUl9UWVBFEAcSLAoo", + "TUlTU0lOR19GRUVETUFQUElOR19GT1JfUExBQ0VIT0xERVJfVFlQRRAIEiYK", + "Ik5PX0VYSVNUSU5HX0xPQ0FUSU9OX0NVU1RPTUVSX0ZFRUQQCULxAQoiY29t", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IWQ2FtcGFpZ25GZWVk", + "RXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29n", + "bGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoC", + "Hkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNc", + "R29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignFeedErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CampaignFeedErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignFeedErrorEnum.Types.CampaignFeedError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible campaign feed errors. + /// + public sealed partial class CampaignFeedErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignFeedErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CampaignFeedErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeedErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeedErrorEnum(CampaignFeedErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeedErrorEnum Clone() { + return new CampaignFeedErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignFeedErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignFeedErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignFeedErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignFeedErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible campaign feed errors. + /// + public enum CampaignFeedError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// An active feed already exists for this campaign and placeholder type. + /// + [pbr::OriginalName("FEED_ALREADY_EXISTS_FOR_PLACEHOLDER_TYPE")] FeedAlreadyExistsForPlaceholderType = 2, + /// + /// The specified feed is removed. + /// + [pbr::OriginalName("CANNOT_CREATE_FOR_REMOVED_FEED")] CannotCreateForRemovedFeed = 4, + /// + /// The CampaignFeed already exists. UPDATE should be used to modify the + /// existing CampaignFeed. + /// + [pbr::OriginalName("CANNOT_CREATE_ALREADY_EXISTING_CAMPAIGN_FEED")] CannotCreateAlreadyExistingCampaignFeed = 5, + /// + /// Cannot update removed campaign feed. + /// + [pbr::OriginalName("CANNOT_MODIFY_REMOVED_CAMPAIGN_FEED")] CannotModifyRemovedCampaignFeed = 6, + /// + /// Invalid placeholder type. + /// + [pbr::OriginalName("INVALID_PLACEHOLDER_TYPE")] InvalidPlaceholderType = 7, + /// + /// Feed mapping for this placeholder type does not exist. + /// + [pbr::OriginalName("MISSING_FEEDMAPPING_FOR_PLACEHOLDER_TYPE")] MissingFeedmappingForPlaceholderType = 8, + /// + /// Location CampaignFeeds cannot be created unless there is a location + /// CustomerFeed for the specified feed. + /// + [pbr::OriginalName("NO_EXISTING_LOCATION_CUSTOMER_FEED")] NoExistingLocationCustomerFeed = 9, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignFeedService.cs b/src/V3/Stubs/CampaignFeedService.cs new file mode 100644 index 000000000..82f8f2866 --- /dev/null +++ b/src/V3/Stubs/CampaignFeedService.cs @@ -0,0 +1,1033 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_feed_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_feed_service.proto + public static partial class CampaignFeedServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_feed_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignFeedServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9m", + "ZWVkX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzGjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2Ft", + "cGFpZ25fZmVlZC5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRf", + "YmVoYXZpb3IucHJvdG8aIGdvb2dsZS9wcm90b2J1Zi9maWVsZF9tYXNrLnBy", + "b3RvGhdnb29nbGUvcnBjL3N0YXR1cy5wcm90byI0ChZHZXRDYW1wYWlnbkZl", + "ZWRSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiK4AQoaTXV0", + "YXRlQ2FtcGFpZ25GZWVkc1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlC", + "A+BBAhJQCgpvcGVyYXRpb25zGAIgAygLMjcuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuQ2FtcGFpZ25GZWVkT3BlcmF0aW9uQgPgQQISFwoP", + "cGFydGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlkYXRlX29ubHkYBCABKAgi", + "7QEKFUNhbXBhaWduRmVlZE9wZXJhdGlvbhIvCgt1cGRhdGVfbWFzaxgEIAEo", + "CzIaLmdvb2dsZS5wcm90b2J1Zi5GaWVsZE1hc2sSQQoGY3JlYXRlGAEgASgL", + "Mi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWdu", + "RmVlZEgAEkEKBnVwZGF0ZRgCIAEoCzIvLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5DYW1wYWlnbkZlZWRIABIQCgZyZW1vdmUYAyABKAlI", + "AEILCglvcGVyYXRpb24inQEKG011dGF0ZUNhbXBhaWduRmVlZHNSZXNwb25z", + "ZRIxChVwYXJ0aWFsX2ZhaWx1cmVfZXJyb3IYAyABKAsyEi5nb29nbGUucnBj", + "LlN0YXR1cxJLCgdyZXN1bHRzGAIgAygLMjouZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuTXV0YXRlQ2FtcGFpZ25GZWVkUmVzdWx0IjEKGE11", + "dGF0ZUNhbXBhaWduRmVlZFJlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJ", + "MucDChNDYW1wYWlnbkZlZWRTZXJ2aWNlEsUBCg9HZXRDYW1wYWlnbkZlZWQS", + "OC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXRDYW1wYWln", + "bkZlZWRSZXF1ZXN0Gi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkNhbXBhaWduRmVlZCJHgtPkkwIxEi8vdjMve3Jlc291cmNlX25hbWU9", + "Y3VzdG9tZXJzLyovY2FtcGFpZ25GZWVkcy8qfdpBDXJlc291cmNlX25hbWUS", + "6gEKE011dGF0ZUNhbXBhaWduRmVlZHMSPC5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5NdXRhdGVDYW1wYWlnbkZlZWRzUmVxdWVzdBo9Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUNhbXBhaWdu", + "RmVlZHNSZXNwb25zZSJWgtPkkwI3IjIvdjMvY3VzdG9tZXJzL3tjdXN0b21l", + "cl9pZD0qfS9jYW1wYWlnbkZlZWRzOm11dGF0ZToBKtpBFmN1c3RvbWVyX2lk", + "LG9wZXJhdGlvbnMaG8pBGGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbUL/AQok", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzQhhDYW1wYWln", + "bkZlZWRTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZp", + "Y2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPK", + "AiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignFeedReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignFeedRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignFeedRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignFeedOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignFeedOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignFeedService.GetCampaignFeed][google.ads.googleads.v3.services.CampaignFeedService.GetCampaignFeed]. + /// + public sealed partial class GetCampaignFeedRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignFeedRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignFeedServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignFeedRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignFeedRequest(GetCampaignFeedRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignFeedRequest Clone() { + return new GetCampaignFeedRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign feed to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignFeedRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignFeedRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignFeedRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignFeedService.MutateCampaignFeeds][google.ads.googleads.v3.services.CampaignFeedService.MutateCampaignFeeds]. + /// + public sealed partial class MutateCampaignFeedsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignFeedsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignFeedServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedsRequest(MutateCampaignFeedsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedsRequest Clone() { + return new MutateCampaignFeedsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose campaign feeds are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignFeedOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual campaign feeds. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignFeedsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignFeedsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignFeedsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a campaign feed. + /// + public sealed partial class CampaignFeedOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignFeedOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignFeedServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeedOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeedOperation(CampaignFeedOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignFeedOperation Clone() { + return new CampaignFeedOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new campaign feed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The campaign feed is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed campaign feed is + /// expected, in this format: + /// + /// `customers/{customer_id}/campaignFeeds/{campaign_id}~{feed_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignFeedOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignFeedOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignFeedOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a campaign feed mutate. + /// + public sealed partial class MutateCampaignFeedsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignFeedsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignFeedServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedsResponse(MutateCampaignFeedsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedsResponse Clone() { + return new MutateCampaignFeedsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignFeedsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignFeedsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignFeedsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the campaign feed mutate. + /// + public sealed partial class MutateCampaignFeedResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignFeedResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignFeedServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedResult(MutateCampaignFeedResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignFeedResult Clone() { + return new MutateCampaignFeedResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignFeedResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignFeedResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignFeedResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignFeedServiceClient.cs b/src/V3/Stubs/CampaignFeedServiceClient.cs new file mode 100644 index 000000000..2c103a6ee --- /dev/null +++ b/src/V3/Stubs/CampaignFeedServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignFeedServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignFeedServiceSettings GetDefault() => new CampaignFeedServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignFeedServiceSettings() { } + + private CampaignFeedServiceSettings(CampaignFeedServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignFeedSettings = existing.GetCampaignFeedSettings; + MutateCampaignFeedsSettings = existing.MutateCampaignFeedsSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignFeedServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignFeedServiceClient.GetCampaignFeed and CampaignFeedServiceClient.GetCampaignFeedAsync. + /// + /// + /// The default CampaignFeedServiceClient.GetCampaignFeed and + /// CampaignFeedServiceClient.GetCampaignFeedAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignFeedSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignFeedServiceClient.MutateCampaignFeeds and CampaignFeedServiceClient.MutateCampaignFeedsAsync. + /// + /// + /// The default CampaignFeedServiceClient.MutateCampaignFeeds and + /// CampaignFeedServiceClient.MutateCampaignFeedsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignFeedsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignFeedServiceSettings Clone() => new CampaignFeedServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignFeedServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignFeedServiceSettings Settings { get; set; } + + /// + public override CampaignFeedServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignFeedServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignFeedServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignFeedServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignFeedServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignFeedServiceClient.ChannelPool; + } + + /// + /// CampaignFeedService client wrapper, for convenient use. + /// + public abstract partial class CampaignFeedServiceClient + { + /// + /// The default endpoint for the CampaignFeedService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignFeedService scopes. + /// + /// + /// The default CampaignFeedService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignFeedServiceClient client = await CampaignFeedServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignFeedServiceClient.DefaultEndpoint.Host, CampaignFeedServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignFeedServiceClient client = CampaignFeedServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignFeedServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignFeedServiceClient client = CampaignFeedServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignFeedServiceClient.DefaultEndpoint.Host, CampaignFeedServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignFeedServiceClient client = CampaignFeedServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignFeedServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignFeedServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignFeedServiceClient Create(grpccore::Channel channel, CampaignFeedServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignFeedServiceClient Create(grpccore::CallInvoker callInvoker, CampaignFeedServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignFeedService.CampaignFeedServiceClient grpcClient = new CampaignFeedService.CampaignFeedServiceClient(callInvoker); + return new CampaignFeedServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignFeedService client. + /// + public virtual CampaignFeedService.CampaignFeedServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign feed in full detail. + /// + /// + /// Required. The resource name of the campaign feed to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignFeedAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignFeedAsync( + new GetCampaignFeedRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign feed in full detail. + /// + /// + /// Required. The resource name of the campaign feed to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignFeedAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignFeedAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign feed in full detail. + /// + /// + /// Required. The resource name of the campaign feed to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignFeed GetCampaignFeed( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignFeed( + new GetCampaignFeedRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignFeedAsync( + GetCampaignFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignFeedAsync( + GetCampaignFeedRequest request, + st::CancellationToken cancellationToken) => GetCampaignFeedAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignFeed GetCampaignFeed( + GetCampaignFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignFeedsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignFeedsAsync( + new MutateCampaignFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignFeedsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignFeedsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignFeedsResponse MutateCampaignFeeds( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignFeeds( + new MutateCampaignFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign feeds. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignFeedsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignFeedsAsync( + new MutateCampaignFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign feeds. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignFeedsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignFeedsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose campaign feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign feeds. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignFeedsResponse MutateCampaignFeeds( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignFeeds( + new MutateCampaignFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignFeedsAsync( + MutateCampaignFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignFeedsAsync( + MutateCampaignFeedsRequest request, + st::CancellationToken cancellationToken) => MutateCampaignFeedsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignFeedsResponse MutateCampaignFeeds( + MutateCampaignFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignFeedService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignFeedServiceClientImpl : CampaignFeedServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignFeed; + private readonly gaxgrpc::ApiCall _callMutateCampaignFeeds; + + /// + /// Constructs a client wrapper for the CampaignFeedService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignFeedServiceClientImpl(CampaignFeedService.CampaignFeedServiceClient grpcClient, CampaignFeedServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignFeedServiceSettings effectiveSettings = settings ?? CampaignFeedServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignFeed = clientHelper.BuildApiCall( + GrpcClient.GetCampaignFeedAsync, GrpcClient.GetCampaignFeed, effectiveSettings.GetCampaignFeedSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaignFeeds = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignFeedsAsync, GrpcClient.MutateCampaignFeeds, effectiveSettings.MutateCampaignFeedsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCampaignFeed); + Modify_GetCampaignFeedApiCall(ref _callGetCampaignFeed); + Modify_ApiCall(ref _callMutateCampaignFeeds); + Modify_MutateCampaignFeedsApiCall(ref _callMutateCampaignFeeds); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignFeedApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignFeedsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignFeedService.CampaignFeedServiceClient grpcClient, CampaignFeedServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignFeedService client. + /// + public override CampaignFeedService.CampaignFeedServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignFeedRequest(ref GetCampaignFeedRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignFeedsRequest(ref MutateCampaignFeedsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignFeedAsync( + GetCampaignFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignFeedRequest(ref request, ref callSettings); + return _callGetCampaignFeed.Async(request, callSettings); + } + + /// + /// Returns the requested campaign feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignFeed GetCampaignFeed( + GetCampaignFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignFeedRequest(ref request, ref callSettings); + return _callGetCampaignFeed.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignFeedsAsync( + MutateCampaignFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignFeedsRequest(ref request, ref callSettings); + return _callMutateCampaignFeeds.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignFeedsResponse MutateCampaignFeeds( + MutateCampaignFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignFeedsRequest(ref request, ref callSettings); + return _callMutateCampaignFeeds.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignFeedServiceGrpc.cs b/src/V3/Stubs/CampaignFeedServiceGrpc.cs new file mode 100644 index 000000000..6f816eff9 --- /dev/null +++ b/src/V3/Stubs/CampaignFeedServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_feed_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaign feeds. + /// + public static partial class CampaignFeedService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignFeedService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignFeedRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignFeedRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignFeed = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignFeedsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignFeedsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignFeed = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignFeed", + __Marshaller_google_ads_googleads_v3_services_GetCampaignFeedRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignFeed); + + static readonly grpc::Method __Method_MutateCampaignFeeds = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignFeeds", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignFeedsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignFeedsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignFeedServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignFeedService + public abstract partial class CampaignFeedServiceBase + { + /// + /// Returns the requested campaign feed in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignFeed(global::Google.Ads.GoogleAds.V3.Services.GetCampaignFeedRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignFeedService + public partial class CampaignFeedServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignFeedService + /// The channel to use to make remote calls. + public CampaignFeedServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignFeedService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignFeedServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignFeedServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignFeedServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign feed in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed GetCampaignFeed(global::Google.Ads.GoogleAds.V3.Services.GetCampaignFeedRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignFeed(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign feed in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed GetCampaignFeed(global::Google.Ads.GoogleAds.V3.Services.GetCampaignFeedRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignFeed, null, options, request); + } + /// + /// Returns the requested campaign feed in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignFeedAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignFeedRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignFeedAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign feed in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignFeedAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignFeedRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignFeed, null, options, request); + } + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsResponse MutateCampaignFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignFeeds(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsResponse MutateCampaignFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignFeeds, null, options, request); + } + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignFeedsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignFeedsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaign feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignFeedsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignFeeds, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignFeedServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignFeedServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignFeedServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignFeed, serviceImpl.GetCampaignFeed) + .AddMethod(__Method_MutateCampaignFeeds, serviceImpl.MutateCampaignFeeds).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignFeedServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignFeed, serviceImpl.GetCampaignFeed); + serviceBinder.AddMethod(__Method_MutateCampaignFeeds, serviceImpl.MutateCampaignFeeds); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignLabel.cs b/src/V3/Stubs/CampaignLabel.cs new file mode 100644 index 000000000..903b4f17a --- /dev/null +++ b/src/V3/Stubs/CampaignLabel.cs @@ -0,0 +1,271 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_label.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_label.proto + public static partial class CampaignLabelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_label.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignLabelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "bGFiZWwucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2Fw", + "aS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnBy", + "b3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIukCCg1DYW1wYWln", + "bkxhYmVsEkUKDXJlc291cmNlX25hbWUYASABKAlCLuBBBfpBKAomZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tL0NhbXBhaWduTGFiZWwSWQoIY2FtcGFpZ24Y", + "AiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCKeBBBfpBIwoh", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0NhbXBhaWduElMKBWxhYmVsGAMg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQibgQQX6QSAKHmdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbS9MYWJlbDph6kFeCiZnb29nbGVhZHMu", + "Z29vZ2xlYXBpcy5jb20vQ2FtcGFpZ25MYWJlbBI0Y3VzdG9tZXJzL3tjdXN0", + "b21lcn0vY2FtcGFpZ25MYWJlbHMve2NhbXBhaWduX2xhYmVsfUL/AQolY29t", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0ISQ2FtcGFpZ25M", + "YWJlbFByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogID", + "R0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel), global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel.Parser, new[]{ "ResourceName", "Campaign", "Label" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents a relationship between a campaign and a label. + /// + public sealed partial class CampaignLabel : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignLabel()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignLabelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignLabel() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignLabel(CampaignLabel other) : this() { + resourceName_ = other.resourceName_; + Campaign = other.Campaign; + Label = other.Label; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignLabel Clone() { + return new CampaignLabel(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. Name of the resource. + /// Campaign label resource names have the form: + /// `customers/{customer_id}/campaignLabels/{campaign_id}~{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 2; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(18); + private string campaign_; + /// + /// Immutable. The campaign to which the label is attached. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "label" field. + public const int LabelFieldNumber = 3; + private static readonly pb::FieldCodec _single_label_codec = pb::FieldCodec.ForClassWrapper(26); + private string label_; + /// + /// Immutable. The label assigned to the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Label { + get { return label_; } + set { + label_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignLabel); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignLabel other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Campaign != other.Campaign) return false; + if (Label != other.Label) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + if (label_ != null) hash ^= Label.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + if (label_ != null) { + _single_label_codec.WriteTagAndValue(output, Label); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + if (label_ != null) { + size += _single_label_codec.CalculateSizeWithTag(Label); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignLabel other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + if (other.label_ != null) { + if (label_ == null || other.Label != "") { + Label = other.Label; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 26: { + string value = _single_label_codec.Read(input); + if (label_ == null || value != "") { + Label = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignLabelService.cs b/src/V3/Stubs/CampaignLabelService.cs new file mode 100644 index 000000000..31a68a110 --- /dev/null +++ b/src/V3/Stubs/CampaignLabelService.cs @@ -0,0 +1,951 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_label_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_label_service.proto + public static partial class CampaignLabelServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_label_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignLabelServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9s", + "YWJlbF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2Nh", + "bXBhaWduX2xhYmVsLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVs", + "ZF9iZWhhdmlvci5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8iNQoX", + "R2V0Q2FtcGFpZ25MYWJlbFJlcXVlc3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEo", + "CUID4EECIroBChtNdXRhdGVDYW1wYWlnbkxhYmVsc1JlcXVlc3QSGAoLY3Vz", + "dG9tZXJfaWQYASABKAlCA+BBAhJRCgpvcGVyYXRpb25zGAIgAygLMjguZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ2FtcGFpZ25MYWJlbE9w", + "ZXJhdGlvbkID4EECEhcKD3BhcnRpYWxfZmFpbHVyZRgDIAEoCBIVCg12YWxp", + "ZGF0ZV9vbmx5GAQgASgIInsKFkNhbXBhaWduTGFiZWxPcGVyYXRpb24SQgoG", + "Y3JlYXRlGAEgASgLMjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkNhbXBhaWduTGFiZWxIABIQCgZyZW1vdmUYAiABKAlIAEILCglvcGVy", + "YXRpb24inwEKHE11dGF0ZUNhbXBhaWduTGFiZWxzUmVzcG9uc2USMQoVcGFy", + "dGlhbF9mYWlsdXJlX2Vycm9yGAMgASgLMhIuZ29vZ2xlLnJwYy5TdGF0dXMS", + "TAoHcmVzdWx0cxgCIAMoCzI7Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzLk11dGF0ZUNhbXBhaWduTGFiZWxSZXN1bHQiMgoZTXV0YXRlQ2Ft", + "cGFpZ25MYWJlbFJlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJMvADChRD", + "YW1wYWlnbkxhYmVsU2VydmljZRLJAQoQR2V0Q2FtcGFpZ25MYWJlbBI5Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldENhbXBhaWduTGFi", + "ZWxSZXF1ZXN0GjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "LkNhbXBhaWduTGFiZWwiSILT5JMCMhIwL3YzL3tyZXNvdXJjZV9uYW1lPWN1", + "c3RvbWVycy8qL2NhbXBhaWduTGFiZWxzLyp92kENcmVzb3VyY2VfbmFtZRLu", + "AQoUTXV0YXRlQ2FtcGFpZ25MYWJlbHMSPS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5NdXRhdGVDYW1wYWlnbkxhYmVsc1JlcXVlc3QaPi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDYW1wYWln", + "bkxhYmVsc1Jlc3BvbnNlIleC0+STAjgiMy92My9jdXN0b21lcnMve2N1c3Rv", + "bWVyX2lkPSp9L2NhbXBhaWduTGFiZWxzOm11dGF0ZToBKtpBFmN1c3RvbWVy", + "X2lkLG9wZXJhdGlvbnMaG8pBGGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbUKA", + "AgokY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzQhlDYW1w", + "YWlnbkxhYmVsU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztz", + "ZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZp", + "Y2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignLabelReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignLabelRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignLabelRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignLabelOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignLabelOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignLabelService.GetCampaignLabel][google.ads.googleads.v3.services.CampaignLabelService.GetCampaignLabel]. + /// + public sealed partial class GetCampaignLabelRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignLabelRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignLabelServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignLabelRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignLabelRequest(GetCampaignLabelRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignLabelRequest Clone() { + return new GetCampaignLabelRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign-label relationship to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignLabelRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignLabelRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignLabelRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignLabelService.MutateCampaignLabels][google.ads.googleads.v3.services.CampaignLabelService.MutateCampaignLabels]. + /// + public sealed partial class MutateCampaignLabelsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignLabelsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignLabelServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelsRequest(MutateCampaignLabelsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelsRequest Clone() { + return new MutateCampaignLabelsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. ID of the customer whose campaign-label relationships are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignLabelOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on campaign-label relationships. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignLabelsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignLabelsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignLabelsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove) on a campaign-label relationship. + /// + public sealed partial class CampaignLabelOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignLabelOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignLabelServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignLabelOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignLabelOperation(CampaignLabelOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignLabelOperation Clone() { + return new CampaignLabelOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new campaign-label + /// relationship. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 2; + /// + /// Remove operation: A resource name for the campaign-label relationship + /// being removed, in this format: + /// + /// `customers/{customer_id}/campaignLabels/{campaign_id}~{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignLabelOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignLabelOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(18); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignLabelOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for a campaign labels mutate. + /// + public sealed partial class MutateCampaignLabelsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignLabelsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignLabelServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelsResponse(MutateCampaignLabelsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelsResponse Clone() { + return new MutateCampaignLabelsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignLabelsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignLabelsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignLabelsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for a campaign label mutate. + /// + public sealed partial class MutateCampaignLabelResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignLabelResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignLabelServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelResult(MutateCampaignLabelResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignLabelResult Clone() { + return new MutateCampaignLabelResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignLabelResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignLabelResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignLabelResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignLabelServiceClient.cs b/src/V3/Stubs/CampaignLabelServiceClient.cs new file mode 100644 index 000000000..ea2cc5e86 --- /dev/null +++ b/src/V3/Stubs/CampaignLabelServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignLabelServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignLabelServiceSettings GetDefault() => new CampaignLabelServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignLabelServiceSettings() { } + + private CampaignLabelServiceSettings(CampaignLabelServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignLabelSettings = existing.GetCampaignLabelSettings; + MutateCampaignLabelsSettings = existing.MutateCampaignLabelsSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignLabelServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignLabelServiceClient.GetCampaignLabel and CampaignLabelServiceClient.GetCampaignLabelAsync. + /// + /// + /// The default CampaignLabelServiceClient.GetCampaignLabel and + /// CampaignLabelServiceClient.GetCampaignLabelAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignLabelSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignLabelServiceClient.MutateCampaignLabels and CampaignLabelServiceClient.MutateCampaignLabelsAsync. + /// + /// + /// The default CampaignLabelServiceClient.MutateCampaignLabels and + /// CampaignLabelServiceClient.MutateCampaignLabelsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignLabelsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignLabelServiceSettings Clone() => new CampaignLabelServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignLabelServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignLabelServiceSettings Settings { get; set; } + + /// + public override CampaignLabelServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignLabelServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignLabelServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignLabelServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignLabelServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignLabelServiceClient.ChannelPool; + } + + /// + /// CampaignLabelService client wrapper, for convenient use. + /// + public abstract partial class CampaignLabelServiceClient + { + /// + /// The default endpoint for the CampaignLabelService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignLabelService scopes. + /// + /// + /// The default CampaignLabelService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignLabelServiceClient client = await CampaignLabelServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignLabelServiceClient.DefaultEndpoint.Host, CampaignLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignLabelServiceClient client = CampaignLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignLabelServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignLabelServiceClient client = CampaignLabelServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignLabelServiceClient.DefaultEndpoint.Host, CampaignLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignLabelServiceClient client = CampaignLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignLabelServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignLabelServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignLabelServiceClient Create(grpccore::Channel channel, CampaignLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignLabelServiceClient Create(grpccore::CallInvoker callInvoker, CampaignLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignLabelService.CampaignLabelServiceClient grpcClient = new CampaignLabelService.CampaignLabelServiceClient(callInvoker); + return new CampaignLabelServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignLabelService client. + /// + public virtual CampaignLabelService.CampaignLabelServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// + /// Required. The resource name of the campaign-label relationship to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignLabelAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignLabelAsync( + new GetCampaignLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// + /// Required. The resource name of the campaign-label relationship to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignLabelAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignLabelAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// + /// Required. The resource name of the campaign-label relationship to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignLabel GetCampaignLabel( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignLabel( + new GetCampaignLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignLabelAsync( + GetCampaignLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignLabelAsync( + GetCampaignLabelRequest request, + st::CancellationToken cancellationToken) => GetCampaignLabelAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignLabel GetCampaignLabel( + GetCampaignLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on campaign-label relationships. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignLabelsAsync( + new MutateCampaignLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on campaign-label relationships. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignLabelsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on campaign-label relationships. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignLabelsResponse MutateCampaignLabels( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignLabels( + new MutateCampaignLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on campaign-label relationships. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignLabelsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignLabelsAsync( + new MutateCampaignLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on campaign-label relationships. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignLabelsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignLabelsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose campaign-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on campaign-label relationships. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignLabelsResponse MutateCampaignLabels( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignLabels( + new MutateCampaignLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignLabelsAsync( + MutateCampaignLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignLabelsAsync( + MutateCampaignLabelsRequest request, + st::CancellationToken cancellationToken) => MutateCampaignLabelsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignLabelsResponse MutateCampaignLabels( + MutateCampaignLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignLabelService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignLabelServiceClientImpl : CampaignLabelServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignLabel; + private readonly gaxgrpc::ApiCall _callMutateCampaignLabels; + + /// + /// Constructs a client wrapper for the CampaignLabelService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignLabelServiceClientImpl(CampaignLabelService.CampaignLabelServiceClient grpcClient, CampaignLabelServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignLabelServiceSettings effectiveSettings = settings ?? CampaignLabelServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignLabel = clientHelper.BuildApiCall( + GrpcClient.GetCampaignLabelAsync, GrpcClient.GetCampaignLabel, effectiveSettings.GetCampaignLabelSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaignLabels = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignLabelsAsync, GrpcClient.MutateCampaignLabels, effectiveSettings.MutateCampaignLabelsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCampaignLabel); + Modify_GetCampaignLabelApiCall(ref _callGetCampaignLabel); + Modify_ApiCall(ref _callMutateCampaignLabels); + Modify_MutateCampaignLabelsApiCall(ref _callMutateCampaignLabels); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignLabelApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignLabelsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignLabelService.CampaignLabelServiceClient grpcClient, CampaignLabelServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignLabelService client. + /// + public override CampaignLabelService.CampaignLabelServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignLabelRequest(ref GetCampaignLabelRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignLabelsRequest(ref MutateCampaignLabelsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignLabelAsync( + GetCampaignLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignLabelRequest(ref request, ref callSettings); + return _callGetCampaignLabel.Async(request, callSettings); + } + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignLabel GetCampaignLabel( + GetCampaignLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignLabelRequest(ref request, ref callSettings); + return _callGetCampaignLabel.Sync(request, callSettings); + } + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignLabelsAsync( + MutateCampaignLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignLabelsRequest(ref request, ref callSettings); + return _callMutateCampaignLabels.Async(request, callSettings); + } + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignLabelsResponse MutateCampaignLabels( + MutateCampaignLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignLabelsRequest(ref request, ref callSettings); + return _callMutateCampaignLabels.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignLabelServiceGrpc.cs b/src/V3/Stubs/CampaignLabelServiceGrpc.cs new file mode 100644 index 000000000..bea781e04 --- /dev/null +++ b/src/V3/Stubs/CampaignLabelServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_label_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage labels on campaigns. + /// + public static partial class CampaignLabelService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignLabelService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignLabelRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignLabelRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignLabel = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignLabelsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignLabelsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignLabel = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignLabel", + __Marshaller_google_ads_googleads_v3_services_GetCampaignLabelRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignLabel); + + static readonly grpc::Method __Method_MutateCampaignLabels = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignLabels", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignLabelsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignLabelsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignLabelServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignLabelService + public abstract partial class CampaignLabelServiceBase + { + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignLabel(global::Google.Ads.GoogleAds.V3.Services.GetCampaignLabelRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignLabels(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignLabelService + public partial class CampaignLabelServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignLabelService + /// The channel to use to make remote calls. + public CampaignLabelServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignLabelService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignLabelServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignLabelServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignLabelServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel GetCampaignLabel(global::Google.Ads.GoogleAds.V3.Services.GetCampaignLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignLabel(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel GetCampaignLabel(global::Google.Ads.GoogleAds.V3.Services.GetCampaignLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignLabel, null, options, request); + } + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignLabelAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign-label relationship in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignLabel, null, options, request); + } + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsResponse MutateCampaignLabels(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignLabels(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsResponse MutateCampaignLabels(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignLabels, null, options, request); + } + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignLabelsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes campaign-label relationships. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignLabels, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignLabelServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignLabelServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignLabelServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignLabel, serviceImpl.GetCampaignLabel) + .AddMethod(__Method_MutateCampaignLabels, serviceImpl.MutateCampaignLabels).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignLabelServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignLabel, serviceImpl.GetCampaignLabel); + serviceBinder.AddMethod(__Method_MutateCampaignLabels, serviceImpl.MutateCampaignLabels); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignService.cs b/src/V3/Stubs/CampaignService.cs new file mode 100644 index 000000000..131c7b584 --- /dev/null +++ b/src/V3/Stubs/CampaignService.cs @@ -0,0 +1,1031 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_service.proto + public static partial class CampaignServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9z", + "ZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cxowZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2NhbXBhaWdu", + "LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUv", + "YXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5w", + "cm90bxogZ29vZ2xlL3Byb3RvYnVmL2ZpZWxkX21hc2sucHJvdG8aF2dvb2ds", + "ZS9ycGMvc3RhdHVzLnByb3RvIjAKEkdldENhbXBhaWduUmVxdWVzdBIaCg1y", + "ZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIisAEKFk11dGF0ZUNhbXBhaWduc1Jl", + "cXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlCA+BBAhJMCgpvcGVyYXRpb25z", + "GAIgAygLMjMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ2Ft", + "cGFpZ25PcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyABKAgS", + "FQoNdmFsaWRhdGVfb25seRgEIAEoCCLhAQoRQ2FtcGFpZ25PcGVyYXRpb24S", + "LwoLdXBkYXRlX21hc2sYBCABKAsyGi5nb29nbGUucHJvdG9idWYuRmllbGRN", + "YXNrEj0KBmNyZWF0ZRgBIAEoCzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlcy5DYW1wYWlnbkgAEj0KBnVwZGF0ZRgCIAEoCzIrLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DYW1wYWlnbkgAEhAKBnJl", + "bW92ZRgDIAEoCUgAQgsKCW9wZXJhdGlvbiKVAQoXTXV0YXRlQ2FtcGFpZ25z", + "UmVzcG9uc2USMQoVcGFydGlhbF9mYWlsdXJlX2Vycm9yGAMgASgLMhIuZ29v", + "Z2xlLnJwYy5TdGF0dXMSRwoHcmVzdWx0cxgCIAMoCzI2Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUNhbXBhaWduUmVzdWx0Ii0K", + "FE11dGF0ZUNhbXBhaWduUmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAky", + "wwMKD0NhbXBhaWduU2VydmljZRK1AQoLR2V0Q2FtcGFpZ24SNC5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXRDYW1wYWlnblJlcXVlc3Qa", + "Ky5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2FtcGFpZ24i", + "Q4LT5JMCLRIrL3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2NhbXBh", + "aWducy8qfdpBDXJlc291cmNlX25hbWUS2gEKD011dGF0ZUNhbXBhaWducxI4", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUNhbXBh", + "aWduc1JlcXVlc3QaOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5NdXRhdGVDYW1wYWlnbnNSZXNwb25zZSJSgtPkkwIzIi4vdjMvY3VzdG9t", + "ZXJzL3tjdXN0b21lcl9pZD0qfS9jYW1wYWlnbnM6bXV0YXRlOgEq2kEWY3Vz", + "dG9tZXJfaWQsb3BlcmF0aW9ucxobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMu", + "Y29tQvsBCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNC", + "FENhbXBhaWduU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztz", + "ZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZp", + "Y2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignService.GetCampaign][google.ads.googleads.v3.services.CampaignService.GetCampaign]. + /// + public sealed partial class GetCampaignRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignRequest(GetCampaignRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignRequest Clone() { + return new GetCampaignRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignService.MutateCampaigns][google.ads.googleads.v3.services.CampaignService.MutateCampaigns]. + /// + public sealed partial class MutateCampaignsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignsRequest(MutateCampaignsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignsRequest Clone() { + return new MutateCampaignsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose campaigns are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a campaign. + /// + public sealed partial class CampaignOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignOperation(CampaignOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignOperation Clone() { + return new CampaignOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.Campaign) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The campaign is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.Campaign) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed campaign is + /// expected, in this format: + /// + /// `customers/{customer_id}/campaigns/{campaign_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.Campaign(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.Campaign(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.Campaign subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.Campaign(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.Campaign subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.Campaign(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for campaign mutate. + /// + public sealed partial class MutateCampaignsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignsResponse(MutateCampaignsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignsResponse Clone() { + return new MutateCampaignsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the campaign mutate. + /// + public sealed partial class MutateCampaignResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignResult(MutateCampaignResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignResult Clone() { + return new MutateCampaignResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignServiceClient.cs b/src/V3/Stubs/CampaignServiceClient.cs new file mode 100644 index 000000000..bacfc4cee --- /dev/null +++ b/src/V3/Stubs/CampaignServiceClient.cs @@ -0,0 +1,887 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignServiceSettings GetDefault() => new CampaignServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignServiceSettings() { } + + private CampaignServiceSettings(CampaignServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignSettings = existing.GetCampaignSettings; + MutateCampaignsSettings = existing.MutateCampaignsSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignServiceClient.GetCampaign and CampaignServiceClient.GetCampaignAsync. + /// + /// + /// The default CampaignServiceClient.GetCampaign and + /// CampaignServiceClient.GetCampaignAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignServiceClient.MutateCampaigns and CampaignServiceClient.MutateCampaignsAsync. + /// + /// + /// The default CampaignServiceClient.MutateCampaigns and + /// CampaignServiceClient.MutateCampaignsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignServiceSettings Clone() => new CampaignServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignServiceSettings Settings { get; set; } + + /// + public override CampaignServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignServiceClient.ChannelPool; + } + + /// + /// CampaignService client wrapper, for convenient use. + /// + public abstract partial class CampaignServiceClient + { + /// + /// The default endpoint for the CampaignService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignService scopes. + /// + /// + /// The default CampaignService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignServiceClient client = await CampaignServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignServiceClient.DefaultEndpoint.Host, CampaignServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignServiceClient client = CampaignServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignServiceClient client = CampaignServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignServiceClient.DefaultEndpoint.Host, CampaignServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignServiceClient client = CampaignServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignServiceClient Create(grpccore::Channel channel, CampaignServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignServiceClient Create(grpccore::CallInvoker callInvoker, CampaignServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignService.CampaignServiceClient grpcClient = new CampaignService.CampaignServiceClient(callInvoker); + return new CampaignServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignService client. + /// + public virtual CampaignService.CampaignServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign in full detail. + /// + /// + /// Required. The resource name of the campaign to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignAsync( + new GetCampaignRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign in full detail. + /// + /// + /// Required. The resource name of the campaign to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign in full detail. + /// + /// + /// Required. The resource name of the campaign to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Campaign GetCampaign( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaign( + new GetCampaignRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignAsync( + GetCampaignRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignAsync( + GetCampaignRequest request, + st::CancellationToken cancellationToken) => GetCampaignAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Campaign GetCampaign( + GetCampaignRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaigns. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignsAsync( + new MutateCampaignsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaigns. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaigns. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignsResponse MutateCampaigns( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaigns( + new MutateCampaignsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaigns. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignsAsync( + new MutateCampaignsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaigns. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaigns. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignsResponse MutateCampaigns( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaigns( + new MutateCampaignsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignsAsync( + MutateCampaignsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignsAsync( + MutateCampaignsRequest request, + st::CancellationToken cancellationToken) => MutateCampaignsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignsResponse MutateCampaigns( + MutateCampaignsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignServiceClientImpl : CampaignServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaign; + private readonly gaxgrpc::ApiCall _callMutateCampaigns; + + /// + /// Constructs a client wrapper for the CampaignService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignServiceClientImpl(CampaignService.CampaignServiceClient grpcClient, CampaignServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignServiceSettings effectiveSettings = settings ?? CampaignServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaign = clientHelper.BuildApiCall( + GrpcClient.GetCampaignAsync, GrpcClient.GetCampaign, effectiveSettings.GetCampaignSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaigns = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignsAsync, GrpcClient.MutateCampaigns, effectiveSettings.MutateCampaignsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCampaign); + Modify_GetCampaignApiCall(ref _callGetCampaign); + Modify_ApiCall(ref _callMutateCampaigns); + Modify_MutateCampaignsApiCall(ref _callMutateCampaigns); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignService.CampaignServiceClient grpcClient, CampaignServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignService client. + /// + public override CampaignService.CampaignServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignRequest(ref GetCampaignRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignsRequest(ref MutateCampaignsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignAsync( + GetCampaignRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignRequest(ref request, ref callSettings); + return _callGetCampaign.Async(request, callSettings); + } + + /// + /// Returns the requested campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::Campaign GetCampaign( + GetCampaignRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignRequest(ref request, ref callSettings); + return _callGetCampaign.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignsAsync( + MutateCampaignsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignsRequest(ref request, ref callSettings); + return _callMutateCampaigns.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignsResponse MutateCampaigns( + MutateCampaignsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignsRequest(ref request, ref callSettings); + return _callMutateCampaigns.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignServiceGrpc.cs b/src/V3/Stubs/CampaignServiceGrpc.cs new file mode 100644 index 000000000..801616c5c --- /dev/null +++ b/src/V3/Stubs/CampaignServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaigns. + /// + public static partial class CampaignService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_Campaign = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.Campaign.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaign = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaign", + __Marshaller_google_ads_googleads_v3_services_GetCampaignRequest, + __Marshaller_google_ads_googleads_v3_resources_Campaign); + + static readonly grpc::Method __Method_MutateCampaigns = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaigns", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignService + public abstract partial class CampaignServiceBase + { + /// + /// Returns the requested campaign in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaign(global::Google.Ads.GoogleAds.V3.Services.GetCampaignRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaigns(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignService + public partial class CampaignServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignService + /// The channel to use to make remote calls. + public CampaignServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Campaign GetCampaign(global::Google.Ads.GoogleAds.V3.Services.GetCampaignRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaign(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Campaign GetCampaign(global::Google.Ads.GoogleAds.V3.Services.GetCampaignRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaign, null, options, request); + } + /// + /// Returns the requested campaign in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaign, null, options, request); + } + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsResponse MutateCampaigns(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaigns(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsResponse MutateCampaigns(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaigns, null, options, request); + } + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes campaigns. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaigns, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaign, serviceImpl.GetCampaign) + .AddMethod(__Method_MutateCampaigns, serviceImpl.MutateCampaigns).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaign, serviceImpl.GetCampaign); + serviceBinder.AddMethod(__Method_MutateCampaigns, serviceImpl.MutateCampaigns); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignServingStatus.cs b/src/V3/Stubs/CampaignServingStatus.cs new file mode 100644 index 000000000..147acd9be --- /dev/null +++ b/src/V3/Stubs/CampaignServingStatus.cs @@ -0,0 +1,200 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/campaign_serving_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/campaign_serving_status.proto + public static partial class CampaignServingStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/campaign_serving_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignServingStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWlnbl9zZXJ2", + "aW5nX3N0YXR1cy5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ikAEKGUNhbXBhaWdu", + "U2VydmluZ1N0YXR1c0VudW0icwoVQ2FtcGFpZ25TZXJ2aW5nU3RhdHVzEg8K", + "C1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB1NFUlZJTkcQAhIICgRO", + "T05FEAMSCQoFRU5ERUQQBBILCgdQRU5ESU5HEAUSDQoJU1VTUEVOREVEEAZC", + "7wEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IaQ2FtcGFp", + "Z25TZXJ2aW5nU3RhdHVzUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2Vu", + "cHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1z", + "ogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29n", + "bGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignServingStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.CampaignServingStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignServingStatusEnum.Types.CampaignServingStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing Campaign serving statuses. + /// + public sealed partial class CampaignServingStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignServingStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CampaignServingStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignServingStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignServingStatusEnum(CampaignServingStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignServingStatusEnum Clone() { + return new CampaignServingStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignServingStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignServingStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignServingStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignServingStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible serving statuses of a campaign. + /// + public enum CampaignServingStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Serving. + /// + [pbr::OriginalName("SERVING")] Serving = 2, + /// + /// None. + /// + [pbr::OriginalName("NONE")] None = 3, + /// + /// Ended. + /// + [pbr::OriginalName("ENDED")] Ended = 4, + /// + /// Pending. + /// + [pbr::OriginalName("PENDING")] Pending = 5, + /// + /// Suspended. + /// + [pbr::OriginalName("SUSPENDED")] Suspended = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignSharedSet.cs b/src/V3/Stubs/CampaignSharedSet.cs new file mode 100644 index 000000000..f93f5a131 --- /dev/null +++ b/src/V3/Stubs/CampaignSharedSet.cs @@ -0,0 +1,314 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/campaign_shared_set.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/campaign_shared_set.proto + public static partial class CampaignSharedSetReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/campaign_shared_set.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignSharedSetReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25f", + "c2hhcmVkX3NldC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWln", + "bl9zaGFyZWRfc2V0X3N0YXR1cy5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9i", + "ZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJjZS5wcm90bxoeZ29v", + "Z2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90", + "YXRpb25zLnByb3RvIvADChFDYW1wYWlnblNoYXJlZFNldBJJCg1yZXNvdXJj", + "ZV9uYW1lGAEgASgJQjLgQQX6QSwKKmdvb2dsZWFkcy5nb29nbGVhcGlzLmNv", + "bS9DYW1wYWlnblNoYXJlZFNldBJZCghjYW1wYWlnbhgDIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIp4EEF+kEjCiFnb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb20vQ2FtcGFpZ24SXAoKc2hhcmVkX3NldBgEIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIq4EEF+kEkCiJnb29nbGVhZHMu", + "Z29vZ2xlYXBpcy5jb20vU2hhcmVkU2V0EmcKBnN0YXR1cxgCIAEoDjJSLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkNhbXBhaWduU2hhcmVkU2V0", + "U3RhdHVzRW51bS5DYW1wYWlnblNoYXJlZFNldFN0YXR1c0ID4EEDOm7qQWsK", + "Kmdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9DYW1wYWlnblNoYXJlZFNldBI9", + "Y3VzdG9tZXJzL3tjdXN0b21lcn0vY2FtcGFpZ25TaGFyZWRTZXRzL3tjYW1w", + "YWlnbl9zaGFyZWRfc2V0fUKDAgolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlc0IWQ2FtcGFpZ25TaGFyZWRTZXRQcm90b1ABWkpnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRz", + "XFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpS", + "ZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.CampaignSharedSetStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet), global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet.Parser, new[]{ "ResourceName", "Campaign", "SharedSet", "Status" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// CampaignSharedSets are used for managing the shared sets associated with a + /// campaign. + /// + public sealed partial class CampaignSharedSet : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignSharedSet()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSetReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSet() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSet(CampaignSharedSet other) : this() { + resourceName_ = other.resourceName_; + Campaign = other.Campaign; + SharedSet = other.SharedSet; + status_ = other.status_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSet Clone() { + return new CampaignSharedSet(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the campaign shared set. + /// Campaign shared set resource names have the form: + /// + /// `customers/{customer_id}/campaignSharedSets/{campaign_id}~{shared_set_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 3; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(26); + private string campaign_; + /// + /// Immutable. The campaign to which the campaign shared set belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "shared_set" field. + public const int SharedSetFieldNumber = 4; + private static readonly pb::FieldCodec _single_sharedSet_codec = pb::FieldCodec.ForClassWrapper(34); + private string sharedSet_; + /// + /// Immutable. The shared set associated with the campaign. This may be a negative keyword + /// shared set of another customer. This customer should be a manager of the + /// other customer, otherwise the campaign shared set will exist but have no + /// serving effect. Only negative keyword shared sets can be associated with + /// Shopping campaigns. Only negative placement shared sets can be associated + /// with Display mobile app campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string SharedSet { + get { return sharedSet_; } + set { + sharedSet_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.CampaignSharedSetStatusEnum.Types.CampaignSharedSetStatus status_ = 0; + /// + /// Output only. The status of this campaign shared set. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CampaignSharedSetStatusEnum.Types.CampaignSharedSetStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignSharedSet); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignSharedSet other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Campaign != other.Campaign) return false; + if (SharedSet != other.SharedSet) return false; + if (Status != other.Status) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + if (sharedSet_ != null) hash ^= SharedSet.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (Status != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) Status); + } + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + if (sharedSet_ != null) { + _single_sharedSet_codec.WriteTagAndValue(output, SharedSet); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + if (sharedSet_ != null) { + size += _single_sharedSet_codec.CalculateSizeWithTag(SharedSet); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignSharedSet other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + if (other.sharedSet_ != null) { + if (sharedSet_ == null || other.SharedSet != "") { + SharedSet = other.SharedSet; + } + } + if (other.Status != 0) { + Status = other.Status; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 16: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.CampaignSharedSetStatusEnum.Types.CampaignSharedSetStatus) input.ReadEnum(); + break; + } + case 26: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 34: { + string value = _single_sharedSet_codec.Read(input); + if (sharedSet_ == null || value != "") { + SharedSet = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignSharedSetError.cs b/src/V3/Stubs/CampaignSharedSetError.cs new file mode 100644 index 000000000..6eef22b14 --- /dev/null +++ b/src/V3/Stubs/CampaignSharedSetError.cs @@ -0,0 +1,182 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/campaign_shared_set_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/campaign_shared_set_error.proto + public static partial class CampaignSharedSetErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/campaign_shared_set_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignSharedSetErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2FtcGFpZ25fc2hh", + "cmVkX3NldF9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZXJyb3JzGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvInIKGkNhbXBh", + "aWduU2hhcmVkU2V0RXJyb3JFbnVtIlQKFkNhbXBhaWduU2hhcmVkU2V0RXJy", + "b3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESHAoYU0hBUkVEX1NF", + "VF9BQ0NFU1NfREVOSUVEEAJC9gEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lcnJvcnNCG0NhbXBhaWduU2hhcmVkU2V0RXJyb3JQcm90b1ABWkRn", + "b29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29n", + "bGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVy", + "cm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignSharedSetErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CampaignSharedSetErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CampaignSharedSetErrorEnum.Types.CampaignSharedSetError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible campaign shared set errors. + /// + public sealed partial class CampaignSharedSetErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignSharedSetErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CampaignSharedSetErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetErrorEnum(CampaignSharedSetErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetErrorEnum Clone() { + return new CampaignSharedSetErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignSharedSetErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignSharedSetErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignSharedSetErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignSharedSetErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible campaign shared set errors. + /// + public enum CampaignSharedSetError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The shared set belongs to another customer and permission isn't granted. + /// + [pbr::OriginalName("SHARED_SET_ACCESS_DENIED")] SharedSetAccessDenied = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignSharedSetService.cs b/src/V3/Stubs/CampaignSharedSetService.cs new file mode 100644 index 000000000..82a6ff9a9 --- /dev/null +++ b/src/V3/Stubs/CampaignSharedSetService.cs @@ -0,0 +1,953 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_shared_set_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/campaign_shared_set_service.proto + public static partial class CampaignSharedSetServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/campaign_shared_set_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignSharedSetServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9z", + "aGFyZWRfc2V0X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvY2FtcGFpZ25fc2hhcmVkX3NldC5wcm90bxocZ29vZ2xlL2FwaS9hbm5v", + "dGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2ds", + "ZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aF2dvb2dsZS9ycGMvc3RhdHVz", + "LnByb3RvIjkKG0dldENhbXBhaWduU2hhcmVkU2V0UmVxdWVzdBIaCg1yZXNv", + "dXJjZV9uYW1lGAEgASgJQgPgQQIiwgEKH011dGF0ZUNhbXBhaWduU2hhcmVk", + "U2V0c1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlCA+BBAhJVCgpvcGVy", + "YXRpb25zGAIgAygLMjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuQ2FtcGFpZ25TaGFyZWRTZXRPcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFs", + "X2ZhaWx1cmUYAyABKAgSFQoNdmFsaWRhdGVfb25seRgEIAEoCCKDAQoaQ2Ft", + "cGFpZ25TaGFyZWRTZXRPcGVyYXRpb24SRgoGY3JlYXRlGAEgASgLMjQuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduU2hhcmVk", + "U2V0SAASEAoGcmVtb3ZlGAMgASgJSABCCwoJb3BlcmF0aW9uIqcBCiBNdXRh", + "dGVDYW1wYWlnblNoYXJlZFNldHNSZXNwb25zZRIxChVwYXJ0aWFsX2ZhaWx1", + "cmVfZXJyb3IYAyABKAsyEi5nb29nbGUucnBjLlN0YXR1cxJQCgdyZXN1bHRz", + "GAIgAygLMj8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0", + "YXRlQ2FtcGFpZ25TaGFyZWRTZXRSZXN1bHQiNgodTXV0YXRlQ2FtcGFpZ25T", + "aGFyZWRTZXRSZXN1bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTKUBAoYQ2Ft", + "cGFpZ25TaGFyZWRTZXRTZXJ2aWNlEtkBChRHZXRDYW1wYWlnblNoYXJlZFNl", + "dBI9Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldENhbXBh", + "aWduU2hhcmVkU2V0UmVxdWVzdBo0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlcy5DYW1wYWlnblNoYXJlZFNldCJMgtPkkwI2EjQvdjMve3Jl", + "c291cmNlX25hbWU9Y3VzdG9tZXJzLyovY2FtcGFpZ25TaGFyZWRTZXRzLyp9", + "2kENcmVzb3VyY2VfbmFtZRL+AQoYTXV0YXRlQ2FtcGFpZ25TaGFyZWRTZXRz", + "EkEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ2Ft", + "cGFpZ25TaGFyZWRTZXRzUmVxdWVzdBpCLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLk11dGF0ZUNhbXBhaWduU2hhcmVkU2V0c1Jlc3BvbnNl", + "IluC0+STAjwiNy92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2NhbXBh", + "aWduU2hhcmVkU2V0czptdXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVyYXRp", + "b25zGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21ChAIKJGNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0IdQ2FtcGFpZ25TaGFyZWRT", + "ZXRTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8v", + "Z29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2Vz", + "ogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBH", + "b29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSetReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCampaignSharedSetRequest), global::Google.Ads.GoogleAds.V3.Services.GetCampaignSharedSetRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetOperation), global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetResult), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CampaignSharedSetService.GetCampaignSharedSet][google.ads.googleads.v3.services.CampaignSharedSetService.GetCampaignSharedSet]. + /// + public sealed partial class GetCampaignSharedSetRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCampaignSharedSetRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignSharedSetRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignSharedSetRequest(GetCampaignSharedSetRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCampaignSharedSetRequest Clone() { + return new GetCampaignSharedSetRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the campaign shared set to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCampaignSharedSetRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCampaignSharedSetRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCampaignSharedSetRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CampaignSharedSetService.MutateCampaignSharedSets][google.ads.googleads.v3.services.CampaignSharedSetService.MutateCampaignSharedSets]. + /// + public sealed partial class MutateCampaignSharedSetsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignSharedSetsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetsRequest(MutateCampaignSharedSetsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetsRequest Clone() { + return new MutateCampaignSharedSetsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose campaign shared sets are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual campaign shared sets. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignSharedSetsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignSharedSetsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignSharedSetsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove) on an campaign shared set. + /// + public sealed partial class CampaignSharedSetOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignSharedSetOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetOperation(CampaignSharedSetOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetOperation Clone() { + return new CampaignSharedSetOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new campaign + /// shared set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed campaign shared set is + /// expected, in this format: + /// + /// `customers/{customer_id}/campaignSharedSets/{campaign_id}~{shared_set_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignSharedSetOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignSharedSetOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignSharedSetOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for a campaign shared set mutate. + /// + public sealed partial class MutateCampaignSharedSetsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignSharedSetsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetsResponse(MutateCampaignSharedSetsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetsResponse Clone() { + return new MutateCampaignSharedSetsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignSharedSetsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignSharedSetsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignSharedSetsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the campaign shared set mutate. + /// + public sealed partial class MutateCampaignSharedSetResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCampaignSharedSetResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetResult(MutateCampaignSharedSetResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCampaignSharedSetResult Clone() { + return new MutateCampaignSharedSetResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCampaignSharedSetResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCampaignSharedSetResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCampaignSharedSetResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignSharedSetServiceClient.cs b/src/V3/Stubs/CampaignSharedSetServiceClient.cs new file mode 100644 index 000000000..40b76a380 --- /dev/null +++ b/src/V3/Stubs/CampaignSharedSetServiceClient.cs @@ -0,0 +1,887 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CampaignSharedSetServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CampaignSharedSetServiceSettings GetDefault() => new CampaignSharedSetServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CampaignSharedSetServiceSettings() { } + + private CampaignSharedSetServiceSettings(CampaignSharedSetServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCampaignSharedSetSettings = existing.GetCampaignSharedSetSettings; + MutateCampaignSharedSetsSettings = existing.MutateCampaignSharedSetsSettings; + OnCopy(existing); + } + + partial void OnCopy(CampaignSharedSetServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CampaignSharedSetServiceClient.GetCampaignSharedSet and CampaignSharedSetServiceClient.GetCampaignSharedSetAsync. + /// + /// + /// The default CampaignSharedSetServiceClient.GetCampaignSharedSet and + /// CampaignSharedSetServiceClient.GetCampaignSharedSetAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCampaignSharedSetSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CampaignSharedSetServiceClient.MutateCampaignSharedSets and CampaignSharedSetServiceClient.MutateCampaignSharedSetsAsync. + /// + /// + /// The default CampaignSharedSetServiceClient.MutateCampaignSharedSets and + /// CampaignSharedSetServiceClient.MutateCampaignSharedSetsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCampaignSharedSetsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CampaignSharedSetServiceSettings Clone() => new CampaignSharedSetServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CampaignSharedSetServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CampaignSharedSetServiceSettings Settings { get; set; } + + /// + public override CampaignSharedSetServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CampaignSharedSetServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CampaignSharedSetServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CampaignSharedSetServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CampaignSharedSetServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CampaignSharedSetServiceClient.ChannelPool; + } + + /// + /// CampaignSharedSetService client wrapper, for convenient use. + /// + public abstract partial class CampaignSharedSetServiceClient + { + /// + /// The default endpoint for the CampaignSharedSetService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CampaignSharedSetService scopes. + /// + /// + /// The default CampaignSharedSetService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignSharedSetServiceClient client = await CampaignSharedSetServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignSharedSetServiceClient.DefaultEndpoint.Host, CampaignSharedSetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignSharedSetServiceClient client = CampaignSharedSetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CampaignSharedSetServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CampaignSharedSetServiceClient client = CampaignSharedSetServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CampaignSharedSetServiceClient.DefaultEndpoint.Host, CampaignSharedSetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CampaignSharedSetServiceClient client = CampaignSharedSetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CampaignSharedSetServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CampaignSharedSetServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignSharedSetServiceClient Create(grpccore::Channel channel, CampaignSharedSetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CampaignSharedSetServiceClient Create(grpccore::CallInvoker callInvoker, CampaignSharedSetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CampaignSharedSetService.CampaignSharedSetServiceClient grpcClient = new CampaignSharedSetService.CampaignSharedSetServiceClient(callInvoker); + return new CampaignSharedSetServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CampaignSharedSetService client. + /// + public virtual CampaignSharedSetService.CampaignSharedSetServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// + /// Required. The resource name of the campaign shared set to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignSharedSetAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignSharedSetAsync( + new GetCampaignSharedSetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// + /// Required. The resource name of the campaign shared set to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignSharedSetAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCampaignSharedSetAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// + /// Required. The resource name of the campaign shared set to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignSharedSet GetCampaignSharedSet( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCampaignSharedSet( + new GetCampaignSharedSetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignSharedSetAsync( + GetCampaignSharedSetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCampaignSharedSetAsync( + GetCampaignSharedSetRequest request, + st::CancellationToken cancellationToken) => GetCampaignSharedSetAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CampaignSharedSet GetCampaignSharedSet( + GetCampaignSharedSetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign shared sets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign shared sets. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignSharedSetsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignSharedSetsAsync( + new MutateCampaignSharedSetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign shared sets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign shared sets. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignSharedSetsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCampaignSharedSetsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign shared sets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign shared sets. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignSharedSetsResponse MutateCampaignSharedSets( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignSharedSets( + new MutateCampaignSharedSetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign shared sets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign shared sets. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignSharedSetsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignSharedSetsAsync( + new MutateCampaignSharedSetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign shared sets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign shared sets. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignSharedSetsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCampaignSharedSetsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose campaign shared sets are being modified. + /// + /// + /// Required. The list of operations to perform on individual campaign shared sets. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignSharedSetsResponse MutateCampaignSharedSets( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCampaignSharedSets( + new MutateCampaignSharedSetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignSharedSetsAsync( + MutateCampaignSharedSetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCampaignSharedSetsAsync( + MutateCampaignSharedSetsRequest request, + st::CancellationToken cancellationToken) => MutateCampaignSharedSetsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCampaignSharedSetsResponse MutateCampaignSharedSets( + MutateCampaignSharedSetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CampaignSharedSetService client wrapper implementation, for convenient use. + /// + public sealed partial class CampaignSharedSetServiceClientImpl : CampaignSharedSetServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCampaignSharedSet; + private readonly gaxgrpc::ApiCall _callMutateCampaignSharedSets; + + /// + /// Constructs a client wrapper for the CampaignSharedSetService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CampaignSharedSetServiceClientImpl(CampaignSharedSetService.CampaignSharedSetServiceClient grpcClient, CampaignSharedSetServiceSettings settings) + { + GrpcClient = grpcClient; + CampaignSharedSetServiceSettings effectiveSettings = settings ?? CampaignSharedSetServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCampaignSharedSet = clientHelper.BuildApiCall( + GrpcClient.GetCampaignSharedSetAsync, GrpcClient.GetCampaignSharedSet, effectiveSettings.GetCampaignSharedSetSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCampaignSharedSets = clientHelper.BuildApiCall( + GrpcClient.MutateCampaignSharedSetsAsync, GrpcClient.MutateCampaignSharedSets, effectiveSettings.MutateCampaignSharedSetsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCampaignSharedSet); + Modify_GetCampaignSharedSetApiCall(ref _callGetCampaignSharedSet); + Modify_ApiCall(ref _callMutateCampaignSharedSets); + Modify_MutateCampaignSharedSetsApiCall(ref _callMutateCampaignSharedSets); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCampaignSharedSetApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCampaignSharedSetsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CampaignSharedSetService.CampaignSharedSetServiceClient grpcClient, CampaignSharedSetServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CampaignSharedSetService client. + /// + public override CampaignSharedSetService.CampaignSharedSetServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCampaignSharedSetRequest(ref GetCampaignSharedSetRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCampaignSharedSetsRequest(ref MutateCampaignSharedSetsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCampaignSharedSetAsync( + GetCampaignSharedSetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignSharedSetRequest(ref request, ref callSettings); + return _callGetCampaignSharedSet.Async(request, callSettings); + } + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CampaignSharedSet GetCampaignSharedSet( + GetCampaignSharedSetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCampaignSharedSetRequest(ref request, ref callSettings); + return _callGetCampaignSharedSet.Sync(request, callSettings); + } + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCampaignSharedSetsAsync( + MutateCampaignSharedSetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignSharedSetsRequest(ref request, ref callSettings); + return _callMutateCampaignSharedSets.Async(request, callSettings); + } + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCampaignSharedSetsResponse MutateCampaignSharedSets( + MutateCampaignSharedSetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCampaignSharedSetsRequest(ref request, ref callSettings); + return _callMutateCampaignSharedSets.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CampaignSharedSetServiceGrpc.cs b/src/V3/Stubs/CampaignSharedSetServiceGrpc.cs new file mode 100644 index 000000000..06a43c4a8 --- /dev/null +++ b/src/V3/Stubs/CampaignSharedSetServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/campaign_shared_set_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage campaign shared sets. + /// + public static partial class CampaignSharedSetService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CampaignSharedSetService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCampaignSharedSetRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCampaignSharedSetRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CampaignSharedSet = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignSharedSetsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCampaignSharedSetsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCampaignSharedSet = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCampaignSharedSet", + __Marshaller_google_ads_googleads_v3_services_GetCampaignSharedSetRequest, + __Marshaller_google_ads_googleads_v3_resources_CampaignSharedSet); + + static readonly grpc::Method __Method_MutateCampaignSharedSets = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCampaignSharedSets", + __Marshaller_google_ads_googleads_v3_services_MutateCampaignSharedSetsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCampaignSharedSetsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CampaignSharedSetService + public abstract partial class CampaignSharedSetServiceBase + { + /// + /// Returns the requested campaign shared set in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCampaignSharedSet(global::Google.Ads.GoogleAds.V3.Services.GetCampaignSharedSetRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCampaignSharedSets(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CampaignSharedSetService + public partial class CampaignSharedSetServiceClient : grpc::ClientBase + { + /// Creates a new client for CampaignSharedSetService + /// The channel to use to make remote calls. + public CampaignSharedSetServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CampaignSharedSetService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CampaignSharedSetServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CampaignSharedSetServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CampaignSharedSetServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested campaign shared set in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet GetCampaignSharedSet(global::Google.Ads.GoogleAds.V3.Services.GetCampaignSharedSetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignSharedSet(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign shared set in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet GetCampaignSharedSet(global::Google.Ads.GoogleAds.V3.Services.GetCampaignSharedSetRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCampaignSharedSet, null, options, request); + } + /// + /// Returns the requested campaign shared set in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignSharedSetAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignSharedSetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCampaignSharedSetAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested campaign shared set in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCampaignSharedSetAsync(global::Google.Ads.GoogleAds.V3.Services.GetCampaignSharedSetRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCampaignSharedSet, null, options, request); + } + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsResponse MutateCampaignSharedSets(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignSharedSets(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsResponse MutateCampaignSharedSets(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCampaignSharedSets, null, options, request); + } + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignSharedSetsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCampaignSharedSetsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or removes campaign shared sets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCampaignSharedSetsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCampaignSharedSets, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CampaignSharedSetServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CampaignSharedSetServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CampaignSharedSetServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCampaignSharedSet, serviceImpl.GetCampaignSharedSet) + .AddMethod(__Method_MutateCampaignSharedSets, serviceImpl.MutateCampaignSharedSets).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CampaignSharedSetServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCampaignSharedSet, serviceImpl.GetCampaignSharedSet); + serviceBinder.AddMethod(__Method_MutateCampaignSharedSets, serviceImpl.MutateCampaignSharedSets); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CampaignSharedSetStatus.cs b/src/V3/Stubs/CampaignSharedSetStatus.cs new file mode 100644 index 000000000..4147eccaf --- /dev/null +++ b/src/V3/Stubs/CampaignSharedSetStatus.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/campaign_shared_set_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/campaign_shared_set_status.proto + public static partial class CampaignSharedSetStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/campaign_shared_set_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignSharedSetStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWlnbl9zaGFy", + "ZWRfc2V0X3N0YXR1cy5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8icAobQ2FtcGFp", + "Z25TaGFyZWRTZXRTdGF0dXNFbnVtIlEKF0NhbXBhaWduU2hhcmVkU2V0U3Rh", + "dHVzEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB0VOQUJMRUQQ", + "AhILCgdSRU1PVkVEEANC8QEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtc0IcQ2FtcGFpZ25TaGFyZWRTZXRTdGF0dXNQcm90b1ABWkJnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIh", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignSharedSetStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.CampaignSharedSetStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignSharedSetStatusEnum.Types.CampaignSharedSetStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing types of campaign shared set statuses. + /// + public sealed partial class CampaignSharedSetStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignSharedSetStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CampaignSharedSetStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetStatusEnum(CampaignSharedSetStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignSharedSetStatusEnum Clone() { + return new CampaignSharedSetStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignSharedSetStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignSharedSetStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignSharedSetStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignSharedSetStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum listing the possible campaign shared set statuses. + /// + public enum CampaignSharedSetStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The campaign shared set is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// The campaign shared set is removed and can no longer be used. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CampaignStatus.cs b/src/V3/Stubs/CampaignStatus.cs new file mode 100644 index 000000000..e7d1460a7 --- /dev/null +++ b/src/V3/Stubs/CampaignStatus.cs @@ -0,0 +1,189 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/campaign_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/campaign_status.proto + public static partial class CampaignStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/campaign_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CampaignStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYW1wYWlnbl9zdGF0", + "dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvImoKEkNhbXBhaWduU3RhdHVzRW51", + "bSJUCg5DYW1wYWlnblN0YXR1cxIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05P", + "V04QARILCgdFTkFCTEVEEAISCgoGUEFVU0VEEAMSCwoHUkVNT1ZFRBAEQugB", + "CiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCE0NhbXBhaWdu", + "U3RhdHVzUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgId", + "R29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYz", + "OjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CampaignStatusEnum.Types.CampaignStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of a campaign. + /// + public sealed partial class CampaignStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CampaignStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CampaignStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignStatusEnum(CampaignStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CampaignStatusEnum Clone() { + return new CampaignStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CampaignStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CampaignStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CampaignStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CampaignStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a campaign. + /// + public enum CampaignStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Campaign is currently serving ads depending on budget information. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Campaign has been paused by the user. + /// + [pbr::OriginalName("PAUSED")] Paused = 3, + /// + /// Campaign has been removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CarrierConstant.cs b/src/V3/Stubs/CarrierConstant.cs new file mode 100644 index 000000000..0338950b3 --- /dev/null +++ b/src/V3/Stubs/CarrierConstant.cs @@ -0,0 +1,310 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/carrier_constant.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/carrier_constant.proto + public static partial class CarrierConstantReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/carrier_constant.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CarrierConstantReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2Fycmllcl9j", + "b25zdGFudC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29nbGUv", + "YXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMu", + "cHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ixgIKD0NhcnJp", + "ZXJDb25zdGFudBJHCg1yZXNvdXJjZV9uYW1lGAEgASgJQjDgQQX6QSoKKGdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbS9DYXJyaWVyQ29uc3RhbnQSLAoCaWQY", + "AiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEi8KBG5h", + "bWUYAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxI3", + "Cgxjb3VudHJ5X2NvZGUYBCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5n", + "VmFsdWVCA+BBAzpS6kFPCihnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2Fy", + "cmllckNvbnN0YW50EiNjYXJyaWVyQ29uc3RhbnRzL3tjYXJyaWVyX2NvbnN0", + "YW50fUKBAgolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "c0IUQ2FycmllckNvbnN0YW50UHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNl", + "cztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5S", + "ZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPq", + "AiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant), global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant.Parser, new[]{ "ResourceName", "Id", "Name", "CountryCode" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A carrier criterion that can be used in campaign targeting. + /// + public sealed partial class CarrierConstant : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CarrierConstant()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CarrierConstantReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CarrierConstant() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CarrierConstant(CarrierConstant other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + CountryCode = other.CountryCode; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CarrierConstant Clone() { + return new CarrierConstant(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the carrier criterion. + /// Carrier criterion resource names have the form: + /// + /// `carrierConstants/{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the carrier criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 3; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(26); + private string name_; + /// + /// Output only. The full name of the carrier in English. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 4; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(34); + private string countryCode_; + /// + /// Output only. The country code of the country where the carrier is located, e.g., "AR", + /// "FR", etc. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CarrierConstant); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CarrierConstant other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (CountryCode != other.CountryCode) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CarrierConstant other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 26: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 34: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CarrierConstantService.cs b/src/V3/Stubs/CarrierConstantService.cs new file mode 100644 index 000000000..874200185 --- /dev/null +++ b/src/V3/Stubs/CarrierConstantService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/carrier_constant_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/carrier_constant_service.proto + public static partial class CarrierConstantServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/carrier_constant_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CarrierConstantServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYXJyaWVyX2Nv", + "bnN0YW50X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "Y2Fycmllcl9jb25zdGFudC5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkv", + "ZmllbGRfYmVoYXZpb3IucHJvdG8iNwoZR2V0Q2FycmllckNvbnN0YW50UmVx", + "dWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIy/QEKFkNhcnJpZXJD", + "b25zdGFudFNlcnZpY2USxQEKEkdldENhcnJpZXJDb25zdGFudBI7Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldENhcnJpZXJDb25zdGFu", + "dFJlcXVlc3QaMi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMu", + "Q2FycmllckNvbnN0YW50Ij6C0+STAigSJi92My97cmVzb3VyY2VfbmFtZT1j", + "YXJyaWVyQ29uc3RhbnRzLyp92kENcmVzb3VyY2VfbmFtZRobykEYZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tQoICCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXNCG0NhcnJpZXJDb25zdGFudFNlcnZpY2VQcm90b1AB", + "Wkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xl", + "QWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6", + "OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CarrierConstantReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCarrierConstantRequest), global::Google.Ads.GoogleAds.V3.Services.GetCarrierConstantRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CarrierConstantService.GetCarrierConstant][google.ads.googleads.v3.services.CarrierConstantService.GetCarrierConstant]. + /// + public sealed partial class GetCarrierConstantRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCarrierConstantRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CarrierConstantServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCarrierConstantRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCarrierConstantRequest(GetCarrierConstantRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCarrierConstantRequest Clone() { + return new GetCarrierConstantRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. Resource name of the carrier constant to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCarrierConstantRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCarrierConstantRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCarrierConstantRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CarrierConstantServiceClient.cs b/src/V3/Stubs/CarrierConstantServiceClient.cs new file mode 100644 index 000000000..a0e6b7609 --- /dev/null +++ b/src/V3/Stubs/CarrierConstantServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CarrierConstantServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CarrierConstantServiceSettings GetDefault() => new CarrierConstantServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CarrierConstantServiceSettings() { } + + private CarrierConstantServiceSettings(CarrierConstantServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCarrierConstantSettings = existing.GetCarrierConstantSettings; + OnCopy(existing); + } + + partial void OnCopy(CarrierConstantServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CarrierConstantServiceClient.GetCarrierConstant and CarrierConstantServiceClient.GetCarrierConstantAsync. + /// + /// + /// The default CarrierConstantServiceClient.GetCarrierConstant and + /// CarrierConstantServiceClient.GetCarrierConstantAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCarrierConstantSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CarrierConstantServiceSettings Clone() => new CarrierConstantServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CarrierConstantServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CarrierConstantServiceSettings Settings { get; set; } + + /// + public override CarrierConstantServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CarrierConstantServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CarrierConstantServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CarrierConstantServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CarrierConstantServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CarrierConstantServiceClient.ChannelPool; + } + + /// + /// CarrierConstantService client wrapper, for convenient use. + /// + public abstract partial class CarrierConstantServiceClient + { + /// + /// The default endpoint for the CarrierConstantService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CarrierConstantService scopes. + /// + /// + /// The default CarrierConstantService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CarrierConstantServiceClient client = await CarrierConstantServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CarrierConstantServiceClient.DefaultEndpoint.Host, CarrierConstantServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CarrierConstantServiceClient client = CarrierConstantServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CarrierConstantServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CarrierConstantServiceClient client = CarrierConstantServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CarrierConstantServiceClient.DefaultEndpoint.Host, CarrierConstantServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CarrierConstantServiceClient client = CarrierConstantServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CarrierConstantServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CarrierConstantServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CarrierConstantServiceClient Create(grpccore::Channel channel, CarrierConstantServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CarrierConstantServiceClient Create(grpccore::CallInvoker callInvoker, CarrierConstantServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CarrierConstantService.CarrierConstantServiceClient grpcClient = new CarrierConstantService.CarrierConstantServiceClient(callInvoker); + return new CarrierConstantServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CarrierConstantService client. + /// + public virtual CarrierConstantService.CarrierConstantServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested carrier constant in full detail. + /// + /// + /// Required. Resource name of the carrier constant to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCarrierConstantAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCarrierConstantAsync( + new GetCarrierConstantRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested carrier constant in full detail. + /// + /// + /// Required. Resource name of the carrier constant to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCarrierConstantAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCarrierConstantAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested carrier constant in full detail. + /// + /// + /// Required. Resource name of the carrier constant to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CarrierConstant GetCarrierConstant( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCarrierConstant( + new GetCarrierConstantRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested carrier constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCarrierConstantAsync( + GetCarrierConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested carrier constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCarrierConstantAsync( + GetCarrierConstantRequest request, + st::CancellationToken cancellationToken) => GetCarrierConstantAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested carrier constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CarrierConstant GetCarrierConstant( + GetCarrierConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CarrierConstantService client wrapper implementation, for convenient use. + /// + public sealed partial class CarrierConstantServiceClientImpl : CarrierConstantServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCarrierConstant; + + /// + /// Constructs a client wrapper for the CarrierConstantService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CarrierConstantServiceClientImpl(CarrierConstantService.CarrierConstantServiceClient grpcClient, CarrierConstantServiceSettings settings) + { + GrpcClient = grpcClient; + CarrierConstantServiceSettings effectiveSettings = settings ?? CarrierConstantServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCarrierConstant = clientHelper.BuildApiCall( + GrpcClient.GetCarrierConstantAsync, GrpcClient.GetCarrierConstant, effectiveSettings.GetCarrierConstantSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetCarrierConstant); + Modify_GetCarrierConstantApiCall(ref _callGetCarrierConstant); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCarrierConstantApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CarrierConstantService.CarrierConstantServiceClient grpcClient, CarrierConstantServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CarrierConstantService client. + /// + public override CarrierConstantService.CarrierConstantServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCarrierConstantRequest(ref GetCarrierConstantRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested carrier constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCarrierConstantAsync( + GetCarrierConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCarrierConstantRequest(ref request, ref callSettings); + return _callGetCarrierConstant.Async(request, callSettings); + } + + /// + /// Returns the requested carrier constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CarrierConstant GetCarrierConstant( + GetCarrierConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCarrierConstantRequest(ref request, ref callSettings); + return _callGetCarrierConstant.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CarrierConstantServiceGrpc.cs b/src/V3/Stubs/CarrierConstantServiceGrpc.cs new file mode 100644 index 000000000..15ccda2ef --- /dev/null +++ b/src/V3/Stubs/CarrierConstantServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/carrier_constant_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch carrier constants. + /// + public static partial class CarrierConstantService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CarrierConstantService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCarrierConstantRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCarrierConstantRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CarrierConstant = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCarrierConstant = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCarrierConstant", + __Marshaller_google_ads_googleads_v3_services_GetCarrierConstantRequest, + __Marshaller_google_ads_googleads_v3_resources_CarrierConstant); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CarrierConstantServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CarrierConstantService + public abstract partial class CarrierConstantServiceBase + { + /// + /// Returns the requested carrier constant in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCarrierConstant(global::Google.Ads.GoogleAds.V3.Services.GetCarrierConstantRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CarrierConstantService + public partial class CarrierConstantServiceClient : grpc::ClientBase + { + /// Creates a new client for CarrierConstantService + /// The channel to use to make remote calls. + public CarrierConstantServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CarrierConstantService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CarrierConstantServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CarrierConstantServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CarrierConstantServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested carrier constant in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant GetCarrierConstant(global::Google.Ads.GoogleAds.V3.Services.GetCarrierConstantRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCarrierConstant(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested carrier constant in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant GetCarrierConstant(global::Google.Ads.GoogleAds.V3.Services.GetCarrierConstantRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCarrierConstant, null, options, request); + } + /// + /// Returns the requested carrier constant in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCarrierConstantAsync(global::Google.Ads.GoogleAds.V3.Services.GetCarrierConstantRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCarrierConstantAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested carrier constant in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCarrierConstantAsync(global::Google.Ads.GoogleAds.V3.Services.GetCarrierConstantRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCarrierConstant, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CarrierConstantServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CarrierConstantServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CarrierConstantServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCarrierConstant, serviceImpl.GetCarrierConstant).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CarrierConstantServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCarrierConstant, serviceImpl.GetCarrierConstant); + } + + } +} +#endregion diff --git a/src/V3/Stubs/ChangeStatus.cs b/src/V3/Stubs/ChangeStatus.cs new file mode 100644 index 000000000..fa404ed3e --- /dev/null +++ b/src/V3/Stubs/ChangeStatus.cs @@ -0,0 +1,696 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/change_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/change_status.proto + public static partial class ChangeStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/change_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ChangeStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2hhbmdlX3N0", + "YXR1cy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "Gjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jaGFuZ2Vfc3RhdHVz", + "X29wZXJhdGlvbi5wcm90bxo/Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXMvY2hhbmdlX3N0YXR1c19yZXNvdXJjZV90eXBlLnByb3RvGh9nb29nbGUv", + "YXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29nbGUvYXBpL3Jlc291cmNl", + "LnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2ds", + "ZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8irAsKDENoYW5nZVN0YXR1cxJECg1y", + "ZXNvdXJjZV9uYW1lGAEgASgJQi3gQQX6QScKJWdvb2dsZWFkcy5nb29nbGVh", + "cGlzLmNvbS9DaGFuZ2VTdGF0dXMSQAoVbGFzdF9jaGFuZ2VfZGF0ZV90aW1l", + "GAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMScAoN", + "cmVzb3VyY2VfdHlwZRgEIAEoDjJULmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zLkNoYW5nZVN0YXR1c1Jlc291cmNlVHlwZUVudW0uQ2hhbmdlU3Rh", + "dHVzUmVzb3VyY2VUeXBlQgPgQQMSWQoIY2FtcGFpZ24YBSABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWVCKeBBA/pBIwohZ29vZ2xlYWRzLmdv", + "b2dsZWFwaXMuY29tL0NhbXBhaWduElgKCGFkX2dyb3VwGAYgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQijgQQP6QSIKIGdvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbS9BZEdyb3VwEmwKD3Jlc291cmNlX3N0YXR1cxgIIAEo", + "DjJOLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkNoYW5nZVN0YXR1", + "c09wZXJhdGlvbkVudW0uQ2hhbmdlU3RhdHVzT3BlcmF0aW9uQgPgQQMSXQoL", + "YWRfZ3JvdXBfYWQYCSABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFs", + "dWVCKuBBA/pBJAoiZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0FkR3JvdXBB", + "ZBJrChJhZF9ncm91cF9jcml0ZXJpb24YCiABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWVCMeBBA/pBKwopZ29vZ2xlYWRzLmdvb2dsZWFwaXMu", + "Y29tL0FkR3JvdXBDcml0ZXJpb24SbAoSY2FtcGFpZ25fY3JpdGVyaW9uGAsg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQjLgQQP6QSwKKmdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbS9DYW1wYWlnbkNyaXRlcmlvbhJRCgRm", + "ZWVkGAwgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQiXgQQP6", + "QR8KHWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9GZWVkEloKCWZlZWRfaXRl", + "bRgNIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIp4EED+kEj", + "CiFnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRmVlZEl0ZW0SYQoNYWRfZ3Jv", + "dXBfZmVlZBgOIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIs", + "4EED+kEmCiRnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91cEZlZWQS", + "YgoNY2FtcGFpZ25fZmVlZBgPIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZUIt4EED+kEnCiVnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2Ft", + "cGFpZ25GZWVkEnAKFWFkX2dyb3VwX2JpZF9tb2RpZmllchgQIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIz4EED+kEtCitnb29nbGVhZHMu", + "Z29vZ2xlYXBpcy5jb20vQWRHcm91cEJpZE1vZGlmaWVyOl3qQVoKJWdvb2ds", + "ZWFkcy5nb29nbGVhcGlzLmNvbS9DaGFuZ2VTdGF0dXMSMWN1c3RvbWVycy97", + "Y3VzdG9tZXJ9L2NoYW5nZVN0YXR1cy97Y2hhbmdlX3N0YXR1c31C/gEKJWNv", + "bS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNCEUNoYW5nZVN0", + "YXR1c1Byb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogID", + "R0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusOperationReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus), global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus.Parser, new[]{ "ResourceName", "LastChangeDateTime", "ResourceType", "Campaign", "AdGroup", "ResourceStatus", "AdGroupAd", "AdGroupCriterion", "CampaignCriterion", "Feed", "FeedItem", "AdGroupFeed", "CampaignFeed", "AdGroupBidModifier" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Describes the status of returned resource. + /// + public sealed partial class ChangeStatus : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ChangeStatus()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.ChangeStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatus() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatus(ChangeStatus other) : this() { + resourceName_ = other.resourceName_; + LastChangeDateTime = other.LastChangeDateTime; + resourceType_ = other.resourceType_; + Campaign = other.Campaign; + AdGroup = other.AdGroup; + resourceStatus_ = other.resourceStatus_; + AdGroupAd = other.AdGroupAd; + AdGroupCriterion = other.AdGroupCriterion; + CampaignCriterion = other.CampaignCriterion; + Feed = other.Feed; + FeedItem = other.FeedItem; + AdGroupFeed = other.AdGroupFeed; + CampaignFeed = other.CampaignFeed; + AdGroupBidModifier = other.AdGroupBidModifier; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatus Clone() { + return new ChangeStatus(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the change status. + /// Change status resource names have the form: + /// + /// `customers/{customer_id}/changeStatus/{change_status_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "last_change_date_time" field. + public const int LastChangeDateTimeFieldNumber = 3; + private static readonly pb::FieldCodec _single_lastChangeDateTime_codec = pb::FieldCodec.ForClassWrapper(26); + private string lastChangeDateTime_; + /// + /// Output only. Time at which the most recent change has occurred on this resource. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LastChangeDateTime { + get { return lastChangeDateTime_; } + set { + lastChangeDateTime_ = value; + } + } + + + /// Field number for the "resource_type" field. + public const int ResourceTypeFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeEnum.Types.ChangeStatusResourceType resourceType_ = 0; + /// + /// Output only. Represents the type of the changed resource. This dictates what fields + /// will be set. For example, for AD_GROUP, campaign and ad_group fields will + /// be set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeEnum.Types.ChangeStatusResourceType ResourceType { + get { return resourceType_; } + set { + resourceType_ = value; + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 5; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(42); + private string campaign_; + /// + /// Output only. The Campaign affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 6; + private static readonly pb::FieldCodec _single_adGroup_codec = pb::FieldCodec.ForClassWrapper(50); + private string adGroup_; + /// + /// Output only. The AdGroup affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroup { + get { return adGroup_; } + set { + adGroup_ = value; + } + } + + + /// Field number for the "resource_status" field. + public const int ResourceStatusFieldNumber = 8; + private global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusOperationEnum.Types.ChangeStatusOperation resourceStatus_ = 0; + /// + /// Output only. Represents the status of the changed resource. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusOperationEnum.Types.ChangeStatusOperation ResourceStatus { + get { return resourceStatus_; } + set { + resourceStatus_ = value; + } + } + + /// Field number for the "ad_group_ad" field. + public const int AdGroupAdFieldNumber = 9; + private static readonly pb::FieldCodec _single_adGroupAd_codec = pb::FieldCodec.ForClassWrapper(74); + private string adGroupAd_; + /// + /// Output only. The AdGroupAd affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupAd { + get { return adGroupAd_; } + set { + adGroupAd_ = value; + } + } + + + /// Field number for the "ad_group_criterion" field. + public const int AdGroupCriterionFieldNumber = 10; + private static readonly pb::FieldCodec _single_adGroupCriterion_codec = pb::FieldCodec.ForClassWrapper(82); + private string adGroupCriterion_; + /// + /// Output only. The AdGroupCriterion affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupCriterion { + get { return adGroupCriterion_; } + set { + adGroupCriterion_ = value; + } + } + + + /// Field number for the "campaign_criterion" field. + public const int CampaignCriterionFieldNumber = 11; + private static readonly pb::FieldCodec _single_campaignCriterion_codec = pb::FieldCodec.ForClassWrapper(90); + private string campaignCriterion_; + /// + /// Output only. The CampaignCriterion affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignCriterion { + get { return campaignCriterion_; } + set { + campaignCriterion_ = value; + } + } + + + /// Field number for the "feed" field. + public const int FeedFieldNumber = 12; + private static readonly pb::FieldCodec _single_feed_codec = pb::FieldCodec.ForClassWrapper(98); + private string feed_; + /// + /// Output only. The Feed affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Feed { + get { return feed_; } + set { + feed_ = value; + } + } + + + /// Field number for the "feed_item" field. + public const int FeedItemFieldNumber = 13; + private static readonly pb::FieldCodec _single_feedItem_codec = pb::FieldCodec.ForClassWrapper(106); + private string feedItem_; + /// + /// Output only. The FeedItem affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FeedItem { + get { return feedItem_; } + set { + feedItem_ = value; + } + } + + + /// Field number for the "ad_group_feed" field. + public const int AdGroupFeedFieldNumber = 14; + private static readonly pb::FieldCodec _single_adGroupFeed_codec = pb::FieldCodec.ForClassWrapper(114); + private string adGroupFeed_; + /// + /// Output only. The AdGroupFeed affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupFeed { + get { return adGroupFeed_; } + set { + adGroupFeed_ = value; + } + } + + + /// Field number for the "campaign_feed" field. + public const int CampaignFeedFieldNumber = 15; + private static readonly pb::FieldCodec _single_campaignFeed_codec = pb::FieldCodec.ForClassWrapper(122); + private string campaignFeed_; + /// + /// Output only. The CampaignFeed affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CampaignFeed { + get { return campaignFeed_; } + set { + campaignFeed_ = value; + } + } + + + /// Field number for the "ad_group_bid_modifier" field. + public const int AdGroupBidModifierFieldNumber = 16; + private static readonly pb::FieldCodec _single_adGroupBidModifier_codec = pb::FieldCodec.ForClassWrapper(130); + private string adGroupBidModifier_; + /// + /// Output only. The AdGroupBidModifier affected by this change. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupBidModifier { + get { return adGroupBidModifier_; } + set { + adGroupBidModifier_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ChangeStatus); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ChangeStatus other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (LastChangeDateTime != other.LastChangeDateTime) return false; + if (ResourceType != other.ResourceType) return false; + if (Campaign != other.Campaign) return false; + if (AdGroup != other.AdGroup) return false; + if (ResourceStatus != other.ResourceStatus) return false; + if (AdGroupAd != other.AdGroupAd) return false; + if (AdGroupCriterion != other.AdGroupCriterion) return false; + if (CampaignCriterion != other.CampaignCriterion) return false; + if (Feed != other.Feed) return false; + if (FeedItem != other.FeedItem) return false; + if (AdGroupFeed != other.AdGroupFeed) return false; + if (CampaignFeed != other.CampaignFeed) return false; + if (AdGroupBidModifier != other.AdGroupBidModifier) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (lastChangeDateTime_ != null) hash ^= LastChangeDateTime.GetHashCode(); + if (ResourceType != 0) hash ^= ResourceType.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + if (adGroup_ != null) hash ^= AdGroup.GetHashCode(); + if (ResourceStatus != 0) hash ^= ResourceStatus.GetHashCode(); + if (adGroupAd_ != null) hash ^= AdGroupAd.GetHashCode(); + if (adGroupCriterion_ != null) hash ^= AdGroupCriterion.GetHashCode(); + if (campaignCriterion_ != null) hash ^= CampaignCriterion.GetHashCode(); + if (feed_ != null) hash ^= Feed.GetHashCode(); + if (feedItem_ != null) hash ^= FeedItem.GetHashCode(); + if (adGroupFeed_ != null) hash ^= AdGroupFeed.GetHashCode(); + if (campaignFeed_ != null) hash ^= CampaignFeed.GetHashCode(); + if (adGroupBidModifier_ != null) hash ^= AdGroupBidModifier.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (lastChangeDateTime_ != null) { + _single_lastChangeDateTime_codec.WriteTagAndValue(output, LastChangeDateTime); + } + if (ResourceType != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) ResourceType); + } + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + if (adGroup_ != null) { + _single_adGroup_codec.WriteTagAndValue(output, AdGroup); + } + if (ResourceStatus != 0) { + output.WriteRawTag(64); + output.WriteEnum((int) ResourceStatus); + } + if (adGroupAd_ != null) { + _single_adGroupAd_codec.WriteTagAndValue(output, AdGroupAd); + } + if (adGroupCriterion_ != null) { + _single_adGroupCriterion_codec.WriteTagAndValue(output, AdGroupCriterion); + } + if (campaignCriterion_ != null) { + _single_campaignCriterion_codec.WriteTagAndValue(output, CampaignCriterion); + } + if (feed_ != null) { + _single_feed_codec.WriteTagAndValue(output, Feed); + } + if (feedItem_ != null) { + _single_feedItem_codec.WriteTagAndValue(output, FeedItem); + } + if (adGroupFeed_ != null) { + _single_adGroupFeed_codec.WriteTagAndValue(output, AdGroupFeed); + } + if (campaignFeed_ != null) { + _single_campaignFeed_codec.WriteTagAndValue(output, CampaignFeed); + } + if (adGroupBidModifier_ != null) { + _single_adGroupBidModifier_codec.WriteTagAndValue(output, AdGroupBidModifier); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (lastChangeDateTime_ != null) { + size += _single_lastChangeDateTime_codec.CalculateSizeWithTag(LastChangeDateTime); + } + if (ResourceType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ResourceType); + } + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + if (adGroup_ != null) { + size += _single_adGroup_codec.CalculateSizeWithTag(AdGroup); + } + if (ResourceStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ResourceStatus); + } + if (adGroupAd_ != null) { + size += _single_adGroupAd_codec.CalculateSizeWithTag(AdGroupAd); + } + if (adGroupCriterion_ != null) { + size += _single_adGroupCriterion_codec.CalculateSizeWithTag(AdGroupCriterion); + } + if (campaignCriterion_ != null) { + size += _single_campaignCriterion_codec.CalculateSizeWithTag(CampaignCriterion); + } + if (feed_ != null) { + size += _single_feed_codec.CalculateSizeWithTag(Feed); + } + if (feedItem_ != null) { + size += _single_feedItem_codec.CalculateSizeWithTag(FeedItem); + } + if (adGroupFeed_ != null) { + size += _single_adGroupFeed_codec.CalculateSizeWithTag(AdGroupFeed); + } + if (campaignFeed_ != null) { + size += _single_campaignFeed_codec.CalculateSizeWithTag(CampaignFeed); + } + if (adGroupBidModifier_ != null) { + size += _single_adGroupBidModifier_codec.CalculateSizeWithTag(AdGroupBidModifier); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ChangeStatus other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.lastChangeDateTime_ != null) { + if (lastChangeDateTime_ == null || other.LastChangeDateTime != "") { + LastChangeDateTime = other.LastChangeDateTime; + } + } + if (other.ResourceType != 0) { + ResourceType = other.ResourceType; + } + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + if (other.adGroup_ != null) { + if (adGroup_ == null || other.AdGroup != "") { + AdGroup = other.AdGroup; + } + } + if (other.ResourceStatus != 0) { + ResourceStatus = other.ResourceStatus; + } + if (other.adGroupAd_ != null) { + if (adGroupAd_ == null || other.AdGroupAd != "") { + AdGroupAd = other.AdGroupAd; + } + } + if (other.adGroupCriterion_ != null) { + if (adGroupCriterion_ == null || other.AdGroupCriterion != "") { + AdGroupCriterion = other.AdGroupCriterion; + } + } + if (other.campaignCriterion_ != null) { + if (campaignCriterion_ == null || other.CampaignCriterion != "") { + CampaignCriterion = other.CampaignCriterion; + } + } + if (other.feed_ != null) { + if (feed_ == null || other.Feed != "") { + Feed = other.Feed; + } + } + if (other.feedItem_ != null) { + if (feedItem_ == null || other.FeedItem != "") { + FeedItem = other.FeedItem; + } + } + if (other.adGroupFeed_ != null) { + if (adGroupFeed_ == null || other.AdGroupFeed != "") { + AdGroupFeed = other.AdGroupFeed; + } + } + if (other.campaignFeed_ != null) { + if (campaignFeed_ == null || other.CampaignFeed != "") { + CampaignFeed = other.CampaignFeed; + } + } + if (other.adGroupBidModifier_ != null) { + if (adGroupBidModifier_ == null || other.AdGroupBidModifier != "") { + AdGroupBidModifier = other.AdGroupBidModifier; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + string value = _single_lastChangeDateTime_codec.Read(input); + if (lastChangeDateTime_ == null || value != "") { + LastChangeDateTime = value; + } + break; + } + case 32: { + ResourceType = (global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeEnum.Types.ChangeStatusResourceType) input.ReadEnum(); + break; + } + case 42: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 50: { + string value = _single_adGroup_codec.Read(input); + if (adGroup_ == null || value != "") { + AdGroup = value; + } + break; + } + case 64: { + ResourceStatus = (global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusOperationEnum.Types.ChangeStatusOperation) input.ReadEnum(); + break; + } + case 74: { + string value = _single_adGroupAd_codec.Read(input); + if (adGroupAd_ == null || value != "") { + AdGroupAd = value; + } + break; + } + case 82: { + string value = _single_adGroupCriterion_codec.Read(input); + if (adGroupCriterion_ == null || value != "") { + AdGroupCriterion = value; + } + break; + } + case 90: { + string value = _single_campaignCriterion_codec.Read(input); + if (campaignCriterion_ == null || value != "") { + CampaignCriterion = value; + } + break; + } + case 98: { + string value = _single_feed_codec.Read(input); + if (feed_ == null || value != "") { + Feed = value; + } + break; + } + case 106: { + string value = _single_feedItem_codec.Read(input); + if (feedItem_ == null || value != "") { + FeedItem = value; + } + break; + } + case 114: { + string value = _single_adGroupFeed_codec.Read(input); + if (adGroupFeed_ == null || value != "") { + AdGroupFeed = value; + } + break; + } + case 122: { + string value = _single_campaignFeed_codec.Read(input); + if (campaignFeed_ == null || value != "") { + CampaignFeed = value; + } + break; + } + case 130: { + string value = _single_adGroupBidModifier_codec.Read(input); + if (adGroupBidModifier_ == null || value != "") { + AdGroupBidModifier = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ChangeStatusError.cs b/src/V3/Stubs/ChangeStatusError.cs new file mode 100644 index 000000000..50f8bc6e1 --- /dev/null +++ b/src/V3/Stubs/ChangeStatusError.cs @@ -0,0 +1,181 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/change_status_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/change_status_error.proto + public static partial class ChangeStatusErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/change_status_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ChangeStatusErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2hhbmdlX3N0YXR1", + "c19lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvImIKFUNoYW5nZVN0YXR1", + "c0Vycm9yRW51bSJJChFDaGFuZ2VTdGF0dXNFcnJvchIPCgtVTlNQRUNJRklF", + "RBAAEgsKB1VOS05PV04QARIWChJTVEFSVF9EQVRFX1RPT19PTEQQA0LxAQoi", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IWQ2hhbmdlU3Rh", + "dHVzRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9n", + "b29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dB", + "QaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxB", + "ZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVB", + "ZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ChangeStatusErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.ChangeStatusErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.ChangeStatusErrorEnum.Types.ChangeStatusError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible change status errors. + /// + public sealed partial class ChangeStatusErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ChangeStatusErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ChangeStatusErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusErrorEnum(ChangeStatusErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusErrorEnum Clone() { + return new ChangeStatusErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ChangeStatusErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ChangeStatusErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ChangeStatusErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ChangeStatusErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible change status errors. + /// + public enum ChangeStatusError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The requested start date is too old. + /// + [pbr::OriginalName("START_DATE_TOO_OLD")] StartDateTooOld = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ChangeStatusOperation.cs b/src/V3/Stubs/ChangeStatusOperation.cs new file mode 100644 index 000000000..995def486 --- /dev/null +++ b/src/V3/Stubs/ChangeStatusOperation.cs @@ -0,0 +1,190 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/change_status_operation.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/change_status_operation.proto + public static partial class ChangeStatusOperationReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/change_status_operation.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ChangeStatusOperationReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jaGFuZ2Vfc3RhdHVz", + "X29wZXJhdGlvbi5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8idwoZQ2hhbmdlU3Rh", + "dHVzT3BlcmF0aW9uRW51bSJaChVDaGFuZ2VTdGF0dXNPcGVyYXRpb24SDwoL", + "VU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESCQoFQURERUQQAhILCgdDSEFO", + "R0VEEAMSCwoHUkVNT1ZFRBAEQu8BCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZW51bXNCGkNoYW5nZVN0YXR1c09wZXJhdGlvblByb3RvUAFaQmdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xl", + "QWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPq", + "AiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusOperationEnum), global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusOperationEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusOperationEnum.Types.ChangeStatusOperation) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing operations for the ChangeStatus resource. + /// + public sealed partial class ChangeStatusOperationEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ChangeStatusOperationEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusOperationReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusOperationEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusOperationEnum(ChangeStatusOperationEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusOperationEnum Clone() { + return new ChangeStatusOperationEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ChangeStatusOperationEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ChangeStatusOperationEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ChangeStatusOperationEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ChangeStatusOperationEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Status of the changed resource + /// + public enum ChangeStatusOperation { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents an unclassified resource unknown + /// in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The resource was created. + /// + [pbr::OriginalName("ADDED")] Added = 2, + /// + /// The resource was modified. + /// + [pbr::OriginalName("CHANGED")] Changed = 3, + /// + /// The resource was removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ChangeStatusResourceType.cs b/src/V3/Stubs/ChangeStatusResourceType.cs new file mode 100644 index 000000000..be581cce3 --- /dev/null +++ b/src/V3/Stubs/ChangeStatusResourceType.cs @@ -0,0 +1,223 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/change_status_resource_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/change_status_resource_type.proto + public static partial class ChangeStatusResourceTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/change_status_resource_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ChangeStatusResourceTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jaGFuZ2Vfc3RhdHVz", + "X3Jlc291cmNlX3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIpACChxDaGFu", + "Z2VTdGF0dXNSZXNvdXJjZVR5cGVFbnVtIu8BChhDaGFuZ2VTdGF0dXNSZXNv", + "dXJjZVR5cGUSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESDAoIQURf", + "R1JPVVAQAxIPCgtBRF9HUk9VUF9BRBAEEhYKEkFEX0dST1VQX0NSSVRFUklP", + "ThAFEgwKCENBTVBBSUdOEAYSFgoSQ0FNUEFJR05fQ1JJVEVSSU9OEAcSCAoE", + "RkVFRBAJEg0KCUZFRURfSVRFTRAKEhEKDUFEX0dST1VQX0ZFRUQQCxIRCg1D", + "QU1QQUlHTl9GRUVEEAwSGQoVQURfR1JPVVBfQklEX01PRElGSUVSEA1C8gEK", + "IWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IdQ2hhbmdlU3Rh", + "dHVzUmVzb3VyY2VUeXBlUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2Vu", + "cHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1z", + "ogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29n", + "bGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeEnum.Types.ChangeStatusResourceType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing supported resource types for the ChangeStatus + /// resource. + /// + public sealed partial class ChangeStatusResourceTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ChangeStatusResourceTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ChangeStatusResourceTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusResourceTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusResourceTypeEnum(ChangeStatusResourceTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ChangeStatusResourceTypeEnum Clone() { + return new ChangeStatusResourceTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ChangeStatusResourceTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ChangeStatusResourceTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ChangeStatusResourceTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ChangeStatusResourceTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum listing the resource types support by the ChangeStatus resource. + /// + public enum ChangeStatusResourceType { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents an unclassified resource unknown + /// in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// An AdGroup resource change. + /// + [pbr::OriginalName("AD_GROUP")] AdGroup = 3, + /// + /// An AdGroupAd resource change. + /// + [pbr::OriginalName("AD_GROUP_AD")] AdGroupAd = 4, + /// + /// An AdGroupCriterion resource change. + /// + [pbr::OriginalName("AD_GROUP_CRITERION")] AdGroupCriterion = 5, + /// + /// A Campaign resource change. + /// + [pbr::OriginalName("CAMPAIGN")] Campaign = 6, + /// + /// A CampaignCriterion resource change. + /// + [pbr::OriginalName("CAMPAIGN_CRITERION")] CampaignCriterion = 7, + /// + /// A Feed resource change. + /// + [pbr::OriginalName("FEED")] Feed = 9, + /// + /// A FeedItem resource change. + /// + [pbr::OriginalName("FEED_ITEM")] FeedItem = 10, + /// + /// An AdGroupFeed resource change. + /// + [pbr::OriginalName("AD_GROUP_FEED")] AdGroupFeed = 11, + /// + /// A CampaignFeed resource change. + /// + [pbr::OriginalName("CAMPAIGN_FEED")] CampaignFeed = 12, + /// + /// An AdGroupBidModifier resource change. + /// + [pbr::OriginalName("AD_GROUP_BID_MODIFIER")] AdGroupBidModifier = 13, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ChangeStatusService.cs b/src/V3/Stubs/ChangeStatusService.cs new file mode 100644 index 000000000..0ef97517d --- /dev/null +++ b/src/V3/Stubs/ChangeStatusService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/change_status_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/change_status_service.proto + public static partial class ChangeStatusServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/change_status_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ChangeStatusServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jaGFuZ2Vfc3Rh", + "dHVzX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzGjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2hh", + "bmdlX3N0YXR1cy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRf", + "YmVoYXZpb3IucHJvdG8iNAoWR2V0Q2hhbmdlU3RhdHVzUmVxdWVzdBIaCg1y", + "ZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIy+QEKE0NoYW5nZVN0YXR1c1NlcnZp", + "Y2USxAEKD0dldENoYW5nZVN0YXR1cxI4Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLkdldENoYW5nZVN0YXR1c1JlcXVlc3QaLy5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2hhbmdlU3RhdHVzIkaC0+ST", + "AjASLi92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9jaGFuZ2VTdGF0", + "dXMvKn3aQQ1yZXNvdXJjZV9uYW1lGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBp", + "cy5jb21C/wEKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "c0IYQ2hhbmdlU3RhdHVzU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcu", + "b3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2", + "aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPq", + "AiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3Rv", + "Mw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.ChangeStatusReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetChangeStatusRequest), global::Google.Ads.GoogleAds.V3.Services.GetChangeStatusRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for '[ChangeStatusService.GetChangeStatus][google.ads.googleads.v3.services.ChangeStatusService.GetChangeStatus]'. + /// + public sealed partial class GetChangeStatusRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetChangeStatusRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ChangeStatusServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetChangeStatusRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetChangeStatusRequest(GetChangeStatusRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetChangeStatusRequest Clone() { + return new GetChangeStatusRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the change status to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetChangeStatusRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetChangeStatusRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetChangeStatusRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ChangeStatusServiceClient.cs b/src/V3/Stubs/ChangeStatusServiceClient.cs new file mode 100644 index 000000000..2c21412bd --- /dev/null +++ b/src/V3/Stubs/ChangeStatusServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class ChangeStatusServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static ChangeStatusServiceSettings GetDefault() => new ChangeStatusServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public ChangeStatusServiceSettings() { } + + private ChangeStatusServiceSettings(ChangeStatusServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetChangeStatusSettings = existing.GetChangeStatusSettings; + OnCopy(existing); + } + + partial void OnCopy(ChangeStatusServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// ChangeStatusServiceClient.GetChangeStatus and ChangeStatusServiceClient.GetChangeStatusAsync. + /// + /// + /// The default ChangeStatusServiceClient.GetChangeStatus and + /// ChangeStatusServiceClient.GetChangeStatusAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetChangeStatusSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public ChangeStatusServiceSettings Clone() => new ChangeStatusServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class ChangeStatusServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public ChangeStatusServiceSettings Settings { get; set; } + + /// + public override ChangeStatusServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return ChangeStatusServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return ChangeStatusServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => ChangeStatusServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => ChangeStatusServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => ChangeStatusServiceClient.ChannelPool; + } + + /// + /// ChangeStatusService client wrapper, for convenient use. + /// + public abstract partial class ChangeStatusServiceClient + { + /// + /// The default endpoint for the ChangeStatusService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default ChangeStatusService scopes. + /// + /// + /// The default ChangeStatusService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ChangeStatusServiceClient client = await ChangeStatusServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ChangeStatusServiceClient.DefaultEndpoint.Host, ChangeStatusServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ChangeStatusServiceClient client = ChangeStatusServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, ChangeStatusServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ChangeStatusServiceClient client = ChangeStatusServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ChangeStatusServiceClient.DefaultEndpoint.Host, ChangeStatusServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ChangeStatusServiceClient client = ChangeStatusServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static ChangeStatusServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, ChangeStatusServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ChangeStatusServiceClient Create(grpccore::Channel channel, ChangeStatusServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ChangeStatusServiceClient Create(grpccore::CallInvoker callInvoker, ChangeStatusServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + ChangeStatusService.ChangeStatusServiceClient grpcClient = new ChangeStatusService.ChangeStatusServiceClient(callInvoker); + return new ChangeStatusServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC ChangeStatusService client. + /// + public virtual ChangeStatusService.ChangeStatusServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested change status in full detail. + /// + /// + /// Required. The resource name of the change status to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetChangeStatusAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetChangeStatusAsync( + new GetChangeStatusRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested change status in full detail. + /// + /// + /// Required. The resource name of the change status to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetChangeStatusAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetChangeStatusAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested change status in full detail. + /// + /// + /// Required. The resource name of the change status to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ChangeStatus GetChangeStatus( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetChangeStatus( + new GetChangeStatusRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested change status in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetChangeStatusAsync( + GetChangeStatusRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested change status in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetChangeStatusAsync( + GetChangeStatusRequest request, + st::CancellationToken cancellationToken) => GetChangeStatusAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested change status in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ChangeStatus GetChangeStatus( + GetChangeStatusRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// ChangeStatusService client wrapper implementation, for convenient use. + /// + public sealed partial class ChangeStatusServiceClientImpl : ChangeStatusServiceClient + { + private readonly gaxgrpc::ApiCall _callGetChangeStatus; + + /// + /// Constructs a client wrapper for the ChangeStatusService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public ChangeStatusServiceClientImpl(ChangeStatusService.ChangeStatusServiceClient grpcClient, ChangeStatusServiceSettings settings) + { + GrpcClient = grpcClient; + ChangeStatusServiceSettings effectiveSettings = settings ?? ChangeStatusServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetChangeStatus = clientHelper.BuildApiCall( + GrpcClient.GetChangeStatusAsync, GrpcClient.GetChangeStatus, effectiveSettings.GetChangeStatusSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetChangeStatus); + Modify_GetChangeStatusApiCall(ref _callGetChangeStatus); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetChangeStatusApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(ChangeStatusService.ChangeStatusServiceClient grpcClient, ChangeStatusServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC ChangeStatusService client. + /// + public override ChangeStatusService.ChangeStatusServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetChangeStatusRequest(ref GetChangeStatusRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested change status in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetChangeStatusAsync( + GetChangeStatusRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetChangeStatusRequest(ref request, ref callSettings); + return _callGetChangeStatus.Async(request, callSettings); + } + + /// + /// Returns the requested change status in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::ChangeStatus GetChangeStatus( + GetChangeStatusRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetChangeStatusRequest(ref request, ref callSettings); + return _callGetChangeStatus.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/ChangeStatusServiceGrpc.cs b/src/V3/Stubs/ChangeStatusServiceGrpc.cs new file mode 100644 index 000000000..5a2cad79c --- /dev/null +++ b/src/V3/Stubs/ChangeStatusServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/change_status_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch change statuses. + /// + public static partial class ChangeStatusService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.ChangeStatusService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetChangeStatusRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetChangeStatusRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_ChangeStatus = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetChangeStatus = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetChangeStatus", + __Marshaller_google_ads_googleads_v3_services_GetChangeStatusRequest, + __Marshaller_google_ads_googleads_v3_resources_ChangeStatus); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.ChangeStatusServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of ChangeStatusService + public abstract partial class ChangeStatusServiceBase + { + /// + /// Returns the requested change status in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetChangeStatus(global::Google.Ads.GoogleAds.V3.Services.GetChangeStatusRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for ChangeStatusService + public partial class ChangeStatusServiceClient : grpc::ClientBase + { + /// Creates a new client for ChangeStatusService + /// The channel to use to make remote calls. + public ChangeStatusServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for ChangeStatusService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public ChangeStatusServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected ChangeStatusServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected ChangeStatusServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested change status in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus GetChangeStatus(global::Google.Ads.GoogleAds.V3.Services.GetChangeStatusRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetChangeStatus(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested change status in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus GetChangeStatus(global::Google.Ads.GoogleAds.V3.Services.GetChangeStatusRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetChangeStatus, null, options, request); + } + /// + /// Returns the requested change status in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetChangeStatusAsync(global::Google.Ads.GoogleAds.V3.Services.GetChangeStatusRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetChangeStatusAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested change status in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetChangeStatusAsync(global::Google.Ads.GoogleAds.V3.Services.GetChangeStatusRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetChangeStatus, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override ChangeStatusServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new ChangeStatusServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(ChangeStatusServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetChangeStatus, serviceImpl.GetChangeStatus).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, ChangeStatusServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetChangeStatus, serviceImpl.GetChangeStatus); + } + + } +} +#endregion diff --git a/src/V3/Stubs/ClickLocation.cs b/src/V3/Stubs/ClickLocation.cs new file mode 100644 index 000000000..5e3a5ee69 --- /dev/null +++ b/src/V3/Stubs/ClickLocation.cs @@ -0,0 +1,345 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/click_location.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/click_location.proto + public static partial class ClickLocationReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/click_location.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ClickLocationReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vY2xpY2tfbG9jYXRp", + "b24ucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbhoeZ29v", + "Z2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90", + "YXRpb25zLnByb3RvIvoBCg1DbGlja0xvY2F0aW9uEioKBGNpdHkYASABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSLQoHY291bnRyeRgCIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIrCgVtZXRybxgDIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIzCg1tb3N0X3NwZWNp", + "ZmljGAQgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEiwKBnJl", + "Z2lvbhgFIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZULtAQoi", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbkISQ2xpY2tMb2Nh", + "dGlvblByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9jb21tb247Y29tbW9uogIDR0FBqgIe", + "R29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuQ29tbW9uygIeR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcQ29tbW9u6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OkNvbW1vbmIGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ClickLocation), global::Google.Ads.GoogleAds.V3.Common.ClickLocation.Parser, new[]{ "City", "Country", "Metro", "MostSpecific", "Region" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Location criteria associated with a click. + /// + public sealed partial class ClickLocation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ClickLocation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ClickLocationReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickLocation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickLocation(ClickLocation other) : this() { + City = other.City; + Country = other.Country; + Metro = other.Metro; + MostSpecific = other.MostSpecific; + Region = other.Region; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickLocation Clone() { + return new ClickLocation(this); + } + + /// Field number for the "city" field. + public const int CityFieldNumber = 1; + private static readonly pb::FieldCodec _single_city_codec = pb::FieldCodec.ForClassWrapper(10); + private string city_; + /// + /// The city location criterion associated with the impression. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string City { + get { return city_; } + set { + city_ = value; + } + } + + + /// Field number for the "country" field. + public const int CountryFieldNumber = 2; + private static readonly pb::FieldCodec _single_country_codec = pb::FieldCodec.ForClassWrapper(18); + private string country_; + /// + /// The country location criterion associated with the impression. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Country { + get { return country_; } + set { + country_ = value; + } + } + + + /// Field number for the "metro" field. + public const int MetroFieldNumber = 3; + private static readonly pb::FieldCodec _single_metro_codec = pb::FieldCodec.ForClassWrapper(26); + private string metro_; + /// + /// The metro location criterion associated with the impression. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Metro { + get { return metro_; } + set { + metro_ = value; + } + } + + + /// Field number for the "most_specific" field. + public const int MostSpecificFieldNumber = 4; + private static readonly pb::FieldCodec _single_mostSpecific_codec = pb::FieldCodec.ForClassWrapper(34); + private string mostSpecific_; + /// + /// The most specific location criterion associated with the impression. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MostSpecific { + get { return mostSpecific_; } + set { + mostSpecific_ = value; + } + } + + + /// Field number for the "region" field. + public const int RegionFieldNumber = 5; + private static readonly pb::FieldCodec _single_region_codec = pb::FieldCodec.ForClassWrapper(42); + private string region_; + /// + /// The region location criterion associated with the impression. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Region { + get { return region_; } + set { + region_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ClickLocation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ClickLocation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (City != other.City) return false; + if (Country != other.Country) return false; + if (Metro != other.Metro) return false; + if (MostSpecific != other.MostSpecific) return false; + if (Region != other.Region) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (city_ != null) hash ^= City.GetHashCode(); + if (country_ != null) hash ^= Country.GetHashCode(); + if (metro_ != null) hash ^= Metro.GetHashCode(); + if (mostSpecific_ != null) hash ^= MostSpecific.GetHashCode(); + if (region_ != null) hash ^= Region.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (city_ != null) { + _single_city_codec.WriteTagAndValue(output, City); + } + if (country_ != null) { + _single_country_codec.WriteTagAndValue(output, Country); + } + if (metro_ != null) { + _single_metro_codec.WriteTagAndValue(output, Metro); + } + if (mostSpecific_ != null) { + _single_mostSpecific_codec.WriteTagAndValue(output, MostSpecific); + } + if (region_ != null) { + _single_region_codec.WriteTagAndValue(output, Region); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (city_ != null) { + size += _single_city_codec.CalculateSizeWithTag(City); + } + if (country_ != null) { + size += _single_country_codec.CalculateSizeWithTag(Country); + } + if (metro_ != null) { + size += _single_metro_codec.CalculateSizeWithTag(Metro); + } + if (mostSpecific_ != null) { + size += _single_mostSpecific_codec.CalculateSizeWithTag(MostSpecific); + } + if (region_ != null) { + size += _single_region_codec.CalculateSizeWithTag(Region); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ClickLocation other) { + if (other == null) { + return; + } + if (other.city_ != null) { + if (city_ == null || other.City != "") { + City = other.City; + } + } + if (other.country_ != null) { + if (country_ == null || other.Country != "") { + Country = other.Country; + } + } + if (other.metro_ != null) { + if (metro_ == null || other.Metro != "") { + Metro = other.Metro; + } + } + if (other.mostSpecific_ != null) { + if (mostSpecific_ == null || other.MostSpecific != "") { + MostSpecific = other.MostSpecific; + } + } + if (other.region_ != null) { + if (region_ == null || other.Region != "") { + Region = other.Region; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_city_codec.Read(input); + if (city_ == null || value != "") { + City = value; + } + break; + } + case 18: { + string value = _single_country_codec.Read(input); + if (country_ == null || value != "") { + Country = value; + } + break; + } + case 26: { + string value = _single_metro_codec.Read(input); + if (metro_ == null || value != "") { + Metro = value; + } + break; + } + case 34: { + string value = _single_mostSpecific_codec.Read(input); + if (mostSpecific_ == null || value != "") { + MostSpecific = value; + } + break; + } + case 42: { + string value = _single_region_codec.Read(input); + if (region_ == null || value != "") { + Region = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ClickType.cs b/src/V3/Stubs/ClickType.cs new file mode 100644 index 000000000..d57408c6a --- /dev/null +++ b/src/V3/Stubs/ClickType.cs @@ -0,0 +1,421 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/click_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/click_type.proto + public static partial class ClickTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/click_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ClickTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jbGlja190eXBlLnBy", + "b3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90byKmDAoNQ2xpY2tUeXBlRW51bSKUDAoJQ2xp", + "Y2tUeXBlEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhAKDEFQUF9E", + "RUVQTElOSxACEg8KC0JSRUFEQ1JVTUJTEAMSEgoOQlJPQURCQU5EX1BMQU4Q", + "BBIRCg1DQUxMX1RSQUNLSU5HEAUSCQoFQ0FMTFMQBhIaChZDTElDS19PTl9F", + "TkdBR0VNRU5UX0FEEAcSEgoOR0VUX0RJUkVDVElPTlMQCBIWChJMT0NBVElP", + "Tl9FWFBBTlNJT04QCRIYChRMT0NBVElPTl9GT1JNQVRfQ0FMTBAKEh4KGkxP", + "Q0FUSU9OX0ZPUk1BVF9ESVJFQ1RJT05TEAsSGQoVTE9DQVRJT05fRk9STUFU", + "X0lNQUdFEAwSIAocTE9DQVRJT05fRk9STUFUX0xBTkRJTkdfUEFHRRANEhcK", + "E0xPQ0FUSU9OX0ZPUk1BVF9NQVAQDhIeChpMT0NBVElPTl9GT1JNQVRfU1RP", + "UkVfSU5GTxAPEhgKFExPQ0FUSU9OX0ZPUk1BVF9URVhUEBASGAoUTU9CSUxF", + "X0NBTExfVFJBQ0tJTkcQERIQCgxPRkZFUl9QUklOVFMQEhIJCgVPVEhFUhAT", + "EhwKGFBST0RVQ1RfRVhURU5TSU9OX0NMSUNLUxAUEh0KGVBST0RVQ1RfTElT", + "VElOR19BRF9DTElDS1MQFRINCglTSVRFTElOS1MQFhIRCg1TVE9SRV9MT0NB", + "VE9SEBcSDgoKVVJMX0NMSUNLUxAZEhoKFlZJREVPX0FQUF9TVE9SRV9DTElD", + "S1MQGhIfChtWSURFT19DQUxMX1RPX0FDVElPTl9DTElDS1MQGxIlCiFWSURF", + "T19DQVJEX0FDVElPTl9IRUFETElORV9DTElDS1MQHBIYChRWSURFT19FTkRf", + "Q0FQX0NMSUNLUxAdEhgKFFZJREVPX1dFQlNJVEVfQ0xJQ0tTEB4SFAoQVklT", + "VUFMX1NJVEVMSU5LUxAfEhEKDVdJUkVMRVNTX1BMQU4QIBIcChhQUk9EVUNU", + "X0xJU1RJTkdfQURfTE9DQUwQIRIpCiVQUk9EVUNUX0xJU1RJTkdfQURfTVVM", + "VElDSEFOTkVMX0xPQ0FMECISKgomUFJPRFVDVF9MSVNUSU5HX0FEX01VTFRJ", + "Q0hBTk5FTF9PTkxJTkUQIxIeChpQUk9EVUNUX0xJU1RJTkdfQURTX0NPVVBP", + "ThAkEiMKH1BST0RVQ1RfTElTVElOR19BRF9UUkFOU0FDVEFCTEUQJRIbChdQ", + "Uk9EVUNUX0FEX0FQUF9ERUVQTElOSxAmEh0KGVNIT1dDQVNFX0FEX0NBVEVH", + "T1JZX0xJTksQJxIlCiFTSE9XQ0FTRV9BRF9MT0NBTF9TVE9SRUZST05UX0xJ", + "TksQKBIjCh9TSE9XQ0FTRV9BRF9PTkxJTkVfUFJPRFVDVF9MSU5LECoSIgoe", + "U0hPV0NBU0VfQURfTE9DQUxfUFJPRFVDVF9MSU5LECsSFwoTUFJPTU9USU9O", + "X0VYVEVOU0lPThAsEiEKHVNXSVBFQUJMRV9HQUxMRVJZX0FEX0hFQURMSU5F", + "EC0SHwobU1dJUEVBQkxFX0dBTExFUllfQURfU1dJUEVTEC4SIQodU1dJUEVB", + "QkxFX0dBTExFUllfQURfU0VFX01PUkUQLxIlCiFTV0lQRUFCTEVfR0FMTEVS", + "WV9BRF9TSVRFTElOS19PTkUQMBIlCiFTV0lQRUFCTEVfR0FMTEVSWV9BRF9T", + "SVRFTElOS19UV08QMRInCiNTV0lQRUFCTEVfR0FMTEVSWV9BRF9TSVRFTElO", + "S19USFJFRRAyEiYKIlNXSVBFQUJMRV9HQUxMRVJZX0FEX1NJVEVMSU5LX0ZP", + "VVIQMxImCiJTV0lQRUFCTEVfR0FMTEVSWV9BRF9TSVRFTElOS19GSVZFEDQS", + "DwoLSE9URUxfUFJJQ0UQNRITCg9QUklDRV9FWFRFTlNJT04QNhInCiNIT1RF", + "TF9CT09LX09OX0dPT0dMRV9ST09NX1NFTEVDVElPThA3Eh8KG1NIT1BQSU5H", + "X0NPTVBBUklTT05fTElTVElORxA4QuMBCiFjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXNCDkNsaWNrVHlwZVByb3RvUAFaQmdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9l", + "bnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVu", + "dW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ClickTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.ClickTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ClickTypeEnum.Types.ClickType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enumeration of Google Ads click types. + /// + public sealed partial class ClickTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ClickTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ClickTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickTypeEnum(ClickTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickTypeEnum Clone() { + return new ClickTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ClickTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ClickTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ClickTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ClickTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates Google Ads click types. + /// + public enum ClickType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// App engagement ad deep link. + /// + [pbr::OriginalName("APP_DEEPLINK")] AppDeeplink = 2, + /// + /// Breadcrumbs. + /// + [pbr::OriginalName("BREADCRUMBS")] Breadcrumbs = 3, + /// + /// Broadband Plan. + /// + [pbr::OriginalName("BROADBAND_PLAN")] BroadbandPlan = 4, + /// + /// Manually dialed phone calls. + /// + [pbr::OriginalName("CALL_TRACKING")] CallTracking = 5, + /// + /// Phone calls. + /// + [pbr::OriginalName("CALLS")] Calls = 6, + /// + /// Click on engagement ad. + /// + [pbr::OriginalName("CLICK_ON_ENGAGEMENT_AD")] ClickOnEngagementAd = 7, + /// + /// Driving direction. + /// + [pbr::OriginalName("GET_DIRECTIONS")] GetDirections = 8, + /// + /// Get location details. + /// + [pbr::OriginalName("LOCATION_EXPANSION")] LocationExpansion = 9, + /// + /// Call. + /// + [pbr::OriginalName("LOCATION_FORMAT_CALL")] LocationFormatCall = 10, + /// + /// Directions. + /// + [pbr::OriginalName("LOCATION_FORMAT_DIRECTIONS")] LocationFormatDirections = 11, + /// + /// Image(s). + /// + [pbr::OriginalName("LOCATION_FORMAT_IMAGE")] LocationFormatImage = 12, + /// + /// Go to landing page. + /// + [pbr::OriginalName("LOCATION_FORMAT_LANDING_PAGE")] LocationFormatLandingPage = 13, + /// + /// Map. + /// + [pbr::OriginalName("LOCATION_FORMAT_MAP")] LocationFormatMap = 14, + /// + /// Go to store info. + /// + [pbr::OriginalName("LOCATION_FORMAT_STORE_INFO")] LocationFormatStoreInfo = 15, + /// + /// Text. + /// + [pbr::OriginalName("LOCATION_FORMAT_TEXT")] LocationFormatText = 16, + /// + /// Mobile phone calls. + /// + [pbr::OriginalName("MOBILE_CALL_TRACKING")] MobileCallTracking = 17, + /// + /// Print offer. + /// + [pbr::OriginalName("OFFER_PRINTS")] OfferPrints = 18, + /// + /// Other. + /// + [pbr::OriginalName("OTHER")] Other = 19, + /// + /// Product plusbox offer. + /// + [pbr::OriginalName("PRODUCT_EXTENSION_CLICKS")] ProductExtensionClicks = 20, + /// + /// Shopping - Product - Online. + /// + [pbr::OriginalName("PRODUCT_LISTING_AD_CLICKS")] ProductListingAdClicks = 21, + /// + /// Sitelink. + /// + [pbr::OriginalName("SITELINKS")] Sitelinks = 22, + /// + /// Show nearby locations. + /// + [pbr::OriginalName("STORE_LOCATOR")] StoreLocator = 23, + /// + /// Headline. + /// + [pbr::OriginalName("URL_CLICKS")] UrlClicks = 25, + /// + /// App store. + /// + [pbr::OriginalName("VIDEO_APP_STORE_CLICKS")] VideoAppStoreClicks = 26, + /// + /// Call-to-Action overlay. + /// + [pbr::OriginalName("VIDEO_CALL_TO_ACTION_CLICKS")] VideoCallToActionClicks = 27, + /// + /// Cards. + /// + [pbr::OriginalName("VIDEO_CARD_ACTION_HEADLINE_CLICKS")] VideoCardActionHeadlineClicks = 28, + /// + /// End cap. + /// + [pbr::OriginalName("VIDEO_END_CAP_CLICKS")] VideoEndCapClicks = 29, + /// + /// Website. + /// + [pbr::OriginalName("VIDEO_WEBSITE_CLICKS")] VideoWebsiteClicks = 30, + /// + /// Visual Sitelinks. + /// + [pbr::OriginalName("VISUAL_SITELINKS")] VisualSitelinks = 31, + /// + /// Wireless Plan. + /// + [pbr::OriginalName("WIRELESS_PLAN")] WirelessPlan = 32, + /// + /// Shopping - Product - Local. + /// + [pbr::OriginalName("PRODUCT_LISTING_AD_LOCAL")] ProductListingAdLocal = 33, + /// + /// Shopping - Product - MultiChannel Local. + /// + [pbr::OriginalName("PRODUCT_LISTING_AD_MULTICHANNEL_LOCAL")] ProductListingAdMultichannelLocal = 34, + /// + /// Shopping - Product - MultiChannel Online. + /// + [pbr::OriginalName("PRODUCT_LISTING_AD_MULTICHANNEL_ONLINE")] ProductListingAdMultichannelOnline = 35, + /// + /// Shopping - Product - Coupon. + /// + [pbr::OriginalName("PRODUCT_LISTING_ADS_COUPON")] ProductListingAdsCoupon = 36, + /// + /// Shopping - Product - Sell on Google. + /// + [pbr::OriginalName("PRODUCT_LISTING_AD_TRANSACTABLE")] ProductListingAdTransactable = 37, + /// + /// Shopping - Product - App engagement ad deep link. + /// + [pbr::OriginalName("PRODUCT_AD_APP_DEEPLINK")] ProductAdAppDeeplink = 38, + /// + /// Shopping - Showcase - Category. + /// + [pbr::OriginalName("SHOWCASE_AD_CATEGORY_LINK")] ShowcaseAdCategoryLink = 39, + /// + /// Shopping - Showcase - Local storefront. + /// + [pbr::OriginalName("SHOWCASE_AD_LOCAL_STOREFRONT_LINK")] ShowcaseAdLocalStorefrontLink = 40, + /// + /// Shopping - Showcase - Online product. + /// + [pbr::OriginalName("SHOWCASE_AD_ONLINE_PRODUCT_LINK")] ShowcaseAdOnlineProductLink = 42, + /// + /// Shopping - Showcase - Local product. + /// + [pbr::OriginalName("SHOWCASE_AD_LOCAL_PRODUCT_LINK")] ShowcaseAdLocalProductLink = 43, + /// + /// Promotion Extension. + /// + [pbr::OriginalName("PROMOTION_EXTENSION")] PromotionExtension = 44, + /// + /// Ad Headline. + /// + [pbr::OriginalName("SWIPEABLE_GALLERY_AD_HEADLINE")] SwipeableGalleryAdHeadline = 45, + /// + /// Swipes. + /// + [pbr::OriginalName("SWIPEABLE_GALLERY_AD_SWIPES")] SwipeableGalleryAdSwipes = 46, + /// + /// See More. + /// + [pbr::OriginalName("SWIPEABLE_GALLERY_AD_SEE_MORE")] SwipeableGalleryAdSeeMore = 47, + /// + /// Sitelink 1. + /// + [pbr::OriginalName("SWIPEABLE_GALLERY_AD_SITELINK_ONE")] SwipeableGalleryAdSitelinkOne = 48, + /// + /// Sitelink 2. + /// + [pbr::OriginalName("SWIPEABLE_GALLERY_AD_SITELINK_TWO")] SwipeableGalleryAdSitelinkTwo = 49, + /// + /// Sitelink 3. + /// + [pbr::OriginalName("SWIPEABLE_GALLERY_AD_SITELINK_THREE")] SwipeableGalleryAdSitelinkThree = 50, + /// + /// Sitelink 4. + /// + [pbr::OriginalName("SWIPEABLE_GALLERY_AD_SITELINK_FOUR")] SwipeableGalleryAdSitelinkFour = 51, + /// + /// Sitelink 5. + /// + [pbr::OriginalName("SWIPEABLE_GALLERY_AD_SITELINK_FIVE")] SwipeableGalleryAdSitelinkFive = 52, + /// + /// Hotel price. + /// + [pbr::OriginalName("HOTEL_PRICE")] HotelPrice = 53, + /// + /// Price Extension. + /// + [pbr::OriginalName("PRICE_EXTENSION")] PriceExtension = 54, + /// + /// Book on Google hotel room selection. + /// + [pbr::OriginalName("HOTEL_BOOK_ON_GOOGLE_ROOM_SELECTION")] HotelBookOnGoogleRoomSelection = 55, + /// + /// Shopping - Comparison Listing. + /// + [pbr::OriginalName("SHOPPING_COMPARISON_LISTING")] ShoppingComparisonListing = 56, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ClickView.cs b/src/V3/Stubs/ClickView.cs new file mode 100644 index 000000000..c749bcb7b --- /dev/null +++ b/src/V3/Stubs/ClickView.cs @@ -0,0 +1,395 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/click_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/click_view.proto + public static partial class ClickViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/click_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ClickViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2xpY2tfdmll", + "dy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzGjNn", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vY2xpY2tfbG9jYXRpb24u", + "cHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2ds", + "ZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVy", + "cy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKNBAoJQ2xp", + "Y2tWaWV3EkEKDXJlc291cmNlX25hbWUYASABKAlCKuBBBfpBJAoiZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tL0NsaWNrVmlldxIwCgVnY2xpZBgCIAEoCzIc", + "Lmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEkwKEGFyZWFfb2Zf", + "aW50ZXJlc3QYAyABKAsyLS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21t", + "b24uQ2xpY2tMb2NhdGlvbkID4EEDElAKFGxvY2F0aW9uX29mX3ByZXNlbmNl", + "GAQgASgLMi0uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkNsaWNr", + "TG9jYXRpb25CA+BBAxI1CgtwYWdlX251bWJlchgFIAEoCzIbLmdvb2dsZS5w", + "cm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSXQoLYWRfZ3JvdXBfYWQYByABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCKuBBA/pBJAoiZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tL0FkR3JvdXBBZDpV6kFSCiJnb29nbGVhZHMu", + "Z29vZ2xlYXBpcy5jb20vQ2xpY2tWaWV3EixjdXN0b21lcnMve2N1c3RvbWVy", + "fS9jbGlja1ZpZXdzL3tjbGlja192aWV3fUL7AQolY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnJlc291cmNlc0IOQ2xpY2tWaWV3UHJvdG9QAVpKZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRz", + "Lkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFk", + "c1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6", + "UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.ClickLocationReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.ClickView), global::Google.Ads.GoogleAds.V3.Resources.ClickView.Parser, new[]{ "ResourceName", "Gclid", "AreaOfInterest", "LocationOfPresence", "PageNumber", "AdGroupAd" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A click view with metrics aggregated at each click level, including both + /// valid and invalid clicks. For non-Search campaigns, metrics.clicks + /// represents the number of valid and invalid interactions. + /// Queries including ClickView must have a filter limiting the results to one + /// day and can be requested for dates back to 90 days before the time of the + /// request. + /// + public sealed partial class ClickView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ClickView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.ClickViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickView(ClickView other) : this() { + resourceName_ = other.resourceName_; + Gclid = other.Gclid; + areaOfInterest_ = other.areaOfInterest_ != null ? other.areaOfInterest_.Clone() : null; + locationOfPresence_ = other.locationOfPresence_ != null ? other.locationOfPresence_.Clone() : null; + PageNumber = other.PageNumber; + AdGroupAd = other.AdGroupAd; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickView Clone() { + return new ClickView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the click view. + /// Click view resource names have the form: + /// + /// `customers/{customer_id}/clickViews/{date (yyyy-MM-dd)}~{gclid}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "gclid" field. + public const int GclidFieldNumber = 2; + private static readonly pb::FieldCodec _single_gclid_codec = pb::FieldCodec.ForClassWrapper(18); + private string gclid_; + /// + /// Output only. The Google Click ID. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Gclid { + get { return gclid_; } + set { + gclid_ = value; + } + } + + + /// Field number for the "area_of_interest" field. + public const int AreaOfInterestFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Common.ClickLocation areaOfInterest_; + /// + /// Output only. The location criteria matching the area of interest associated with the + /// impression. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ClickLocation AreaOfInterest { + get { return areaOfInterest_; } + set { + areaOfInterest_ = value; + } + } + + /// Field number for the "location_of_presence" field. + public const int LocationOfPresenceFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Common.ClickLocation locationOfPresence_; + /// + /// Output only. The location criteria matching the location of presence associated with the + /// impression. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ClickLocation LocationOfPresence { + get { return locationOfPresence_; } + set { + locationOfPresence_ = value; + } + } + + /// Field number for the "page_number" field. + public const int PageNumberFieldNumber = 5; + private static readonly pb::FieldCodec _single_pageNumber_codec = pb::FieldCodec.ForStructWrapper(42); + private long? pageNumber_; + /// + /// Output only. Page number in search results where the ad was shown. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PageNumber { + get { return pageNumber_; } + set { + pageNumber_ = value; + } + } + + + /// Field number for the "ad_group_ad" field. + public const int AdGroupAdFieldNumber = 7; + private static readonly pb::FieldCodec _single_adGroupAd_codec = pb::FieldCodec.ForClassWrapper(58); + private string adGroupAd_; + /// + /// Output only. The associated ad. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroupAd { + get { return adGroupAd_; } + set { + adGroupAd_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ClickView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ClickView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Gclid != other.Gclid) return false; + if (!object.Equals(AreaOfInterest, other.AreaOfInterest)) return false; + if (!object.Equals(LocationOfPresence, other.LocationOfPresence)) return false; + if (PageNumber != other.PageNumber) return false; + if (AdGroupAd != other.AdGroupAd) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (gclid_ != null) hash ^= Gclid.GetHashCode(); + if (areaOfInterest_ != null) hash ^= AreaOfInterest.GetHashCode(); + if (locationOfPresence_ != null) hash ^= LocationOfPresence.GetHashCode(); + if (pageNumber_ != null) hash ^= PageNumber.GetHashCode(); + if (adGroupAd_ != null) hash ^= AdGroupAd.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (gclid_ != null) { + _single_gclid_codec.WriteTagAndValue(output, Gclid); + } + if (areaOfInterest_ != null) { + output.WriteRawTag(26); + output.WriteMessage(AreaOfInterest); + } + if (locationOfPresence_ != null) { + output.WriteRawTag(34); + output.WriteMessage(LocationOfPresence); + } + if (pageNumber_ != null) { + _single_pageNumber_codec.WriteTagAndValue(output, PageNumber); + } + if (adGroupAd_ != null) { + _single_adGroupAd_codec.WriteTagAndValue(output, AdGroupAd); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (gclid_ != null) { + size += _single_gclid_codec.CalculateSizeWithTag(Gclid); + } + if (areaOfInterest_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AreaOfInterest); + } + if (locationOfPresence_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(LocationOfPresence); + } + if (pageNumber_ != null) { + size += _single_pageNumber_codec.CalculateSizeWithTag(PageNumber); + } + if (adGroupAd_ != null) { + size += _single_adGroupAd_codec.CalculateSizeWithTag(AdGroupAd); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ClickView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.gclid_ != null) { + if (gclid_ == null || other.Gclid != "") { + Gclid = other.Gclid; + } + } + if (other.areaOfInterest_ != null) { + if (areaOfInterest_ == null) { + AreaOfInterest = new global::Google.Ads.GoogleAds.V3.Common.ClickLocation(); + } + AreaOfInterest.MergeFrom(other.AreaOfInterest); + } + if (other.locationOfPresence_ != null) { + if (locationOfPresence_ == null) { + LocationOfPresence = new global::Google.Ads.GoogleAds.V3.Common.ClickLocation(); + } + LocationOfPresence.MergeFrom(other.LocationOfPresence); + } + if (other.pageNumber_ != null) { + if (pageNumber_ == null || other.PageNumber != 0L) { + PageNumber = other.PageNumber; + } + } + if (other.adGroupAd_ != null) { + if (adGroupAd_ == null || other.AdGroupAd != "") { + AdGroupAd = other.AdGroupAd; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_gclid_codec.Read(input); + if (gclid_ == null || value != "") { + Gclid = value; + } + break; + } + case 26: { + if (areaOfInterest_ == null) { + AreaOfInterest = new global::Google.Ads.GoogleAds.V3.Common.ClickLocation(); + } + input.ReadMessage(AreaOfInterest); + break; + } + case 34: { + if (locationOfPresence_ == null) { + LocationOfPresence = new global::Google.Ads.GoogleAds.V3.Common.ClickLocation(); + } + input.ReadMessage(LocationOfPresence); + break; + } + case 42: { + long? value = _single_pageNumber_codec.Read(input); + if (pageNumber_ == null || value != 0L) { + PageNumber = value; + } + break; + } + case 58: { + string value = _single_adGroupAd_codec.Read(input); + if (adGroupAd_ == null || value != "") { + AdGroupAd = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ClickViewService.cs b/src/V3/Stubs/ClickViewService.cs new file mode 100644 index 000000000..50a11483b --- /dev/null +++ b/src/V3/Stubs/ClickViewService.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/click_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/click_view_service.proto + public static partial class ClickViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/click_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ClickViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jbGlja192aWV3", + "X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzGjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2xpY2tf", + "dmlldy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90bxoXZ29v", + "Z2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZp", + "b3IucHJvdG8iMQoTR2V0Q2xpY2tWaWV3UmVxdWVzdBIaCg1yZXNvdXJjZV9u", + "YW1lGAEgASgJQgPgQQIy6wEKEENsaWNrVmlld1NlcnZpY2USuQEKDEdldENs", + "aWNrVmlldxI1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdl", + "dENsaWNrVmlld1JlcXVlc3QaLC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMuQ2xpY2tWaWV3IkSC0+STAi4SLC92My97cmVzb3VyY2VfbmFt", + "ZT1jdXN0b21lcnMvKi9jbGlja1ZpZXdzLyp92kENcmVzb3VyY2VfbmFtZRob", + "ykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQvwBCiRjb20uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXNCFUNsaWNrVmlld1NlcnZpY2VQcm90", + "b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.ClickViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetClickViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetClickViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [ClickViewService.GetClickView][google.ads.googleads.v3.services.ClickViewService.GetClickView]. + /// + public sealed partial class GetClickViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetClickViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ClickViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetClickViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetClickViewRequest(GetClickViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetClickViewRequest Clone() { + return new GetClickViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the click view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetClickViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetClickViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetClickViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ClickViewServiceClient.cs b/src/V3/Stubs/ClickViewServiceClient.cs new file mode 100644 index 000000000..7cf1bddd3 --- /dev/null +++ b/src/V3/Stubs/ClickViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class ClickViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static ClickViewServiceSettings GetDefault() => new ClickViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public ClickViewServiceSettings() { } + + private ClickViewServiceSettings(ClickViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetClickViewSettings = existing.GetClickViewSettings; + OnCopy(existing); + } + + partial void OnCopy(ClickViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// ClickViewServiceClient.GetClickView and ClickViewServiceClient.GetClickViewAsync. + /// + /// + /// The default ClickViewServiceClient.GetClickView and + /// ClickViewServiceClient.GetClickViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetClickViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public ClickViewServiceSettings Clone() => new ClickViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class ClickViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public ClickViewServiceSettings Settings { get; set; } + + /// + public override ClickViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return ClickViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return ClickViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => ClickViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => ClickViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => ClickViewServiceClient.ChannelPool; + } + + /// + /// ClickViewService client wrapper, for convenient use. + /// + public abstract partial class ClickViewServiceClient + { + /// + /// The default endpoint for the ClickViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default ClickViewService scopes. + /// + /// + /// The default ClickViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ClickViewServiceClient client = await ClickViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ClickViewServiceClient.DefaultEndpoint.Host, ClickViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ClickViewServiceClient client = ClickViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, ClickViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ClickViewServiceClient client = ClickViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ClickViewServiceClient.DefaultEndpoint.Host, ClickViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ClickViewServiceClient client = ClickViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static ClickViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, ClickViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ClickViewServiceClient Create(grpccore::Channel channel, ClickViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ClickViewServiceClient Create(grpccore::CallInvoker callInvoker, ClickViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + ClickViewService.ClickViewServiceClient grpcClient = new ClickViewService.ClickViewServiceClient(callInvoker); + return new ClickViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC ClickViewService client. + /// + public virtual ClickViewService.ClickViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested click view in full detail. + /// + /// + /// Required. The resource name of the click view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetClickViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetClickViewAsync( + new GetClickViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested click view in full detail. + /// + /// + /// Required. The resource name of the click view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetClickViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetClickViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested click view in full detail. + /// + /// + /// Required. The resource name of the click view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ClickView GetClickView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetClickView( + new GetClickViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested click view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetClickViewAsync( + GetClickViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested click view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetClickViewAsync( + GetClickViewRequest request, + st::CancellationToken cancellationToken) => GetClickViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested click view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ClickView GetClickView( + GetClickViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// ClickViewService client wrapper implementation, for convenient use. + /// + public sealed partial class ClickViewServiceClientImpl : ClickViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetClickView; + + /// + /// Constructs a client wrapper for the ClickViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public ClickViewServiceClientImpl(ClickViewService.ClickViewServiceClient grpcClient, ClickViewServiceSettings settings) + { + GrpcClient = grpcClient; + ClickViewServiceSettings effectiveSettings = settings ?? ClickViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetClickView = clientHelper.BuildApiCall( + GrpcClient.GetClickViewAsync, GrpcClient.GetClickView, effectiveSettings.GetClickViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetClickView); + Modify_GetClickViewApiCall(ref _callGetClickView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetClickViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(ClickViewService.ClickViewServiceClient grpcClient, ClickViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC ClickViewService client. + /// + public override ClickViewService.ClickViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetClickViewRequest(ref GetClickViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested click view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetClickViewAsync( + GetClickViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetClickViewRequest(ref request, ref callSettings); + return _callGetClickView.Async(request, callSettings); + } + + /// + /// Returns the requested click view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::ClickView GetClickView( + GetClickViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetClickViewRequest(ref request, ref callSettings); + return _callGetClickView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/ClickViewServiceGrpc.cs b/src/V3/Stubs/ClickViewServiceGrpc.cs new file mode 100644 index 000000000..9db4d9a87 --- /dev/null +++ b/src/V3/Stubs/ClickViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/click_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch click views. + /// + public static partial class ClickViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.ClickViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetClickViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetClickViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_ClickView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.ClickView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetClickView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetClickView", + __Marshaller_google_ads_googleads_v3_services_GetClickViewRequest, + __Marshaller_google_ads_googleads_v3_resources_ClickView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.ClickViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of ClickViewService + public abstract partial class ClickViewServiceBase + { + /// + /// Returns the requested click view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetClickView(global::Google.Ads.GoogleAds.V3.Services.GetClickViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for ClickViewService + public partial class ClickViewServiceClient : grpc::ClientBase + { + /// Creates a new client for ClickViewService + /// The channel to use to make remote calls. + public ClickViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for ClickViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public ClickViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected ClickViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected ClickViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested click view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ClickView GetClickView(global::Google.Ads.GoogleAds.V3.Services.GetClickViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetClickView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested click view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ClickView GetClickView(global::Google.Ads.GoogleAds.V3.Services.GetClickViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetClickView, null, options, request); + } + /// + /// Returns the requested click view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetClickViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetClickViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetClickViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested click view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetClickViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetClickViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetClickView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override ClickViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new ClickViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(ClickViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetClickView, serviceImpl.GetClickView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, ClickViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetClickView, serviceImpl.GetClickView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CollectionSizeError.cs b/src/V3/Stubs/CollectionSizeError.cs new file mode 100644 index 000000000..2de67c6cc --- /dev/null +++ b/src/V3/Stubs/CollectionSizeError.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/collection_size_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/collection_size_error.proto + public static partial class CollectionSizeErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/collection_size_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CollectionSizeErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY29sbGVjdGlvbl9z", + "aXplX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJv", + "cnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iaQoXQ29sbGVjdGlv", + "blNpemVFcnJvckVudW0iTgoTQ29sbGVjdGlvblNpemVFcnJvchIPCgtVTlNQ", + "RUNJRklFRBAAEgsKB1VOS05PV04QARILCgdUT09fRkVXEAISDAoIVE9PX01B", + "TlkQA0LzAQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IY", + "Q29sbGVjdGlvblNpemVFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7", + "ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3Jz", + "ygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CollectionSizeErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CollectionSizeErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CollectionSizeErrorEnum.Types.CollectionSizeError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible collection size errors. + /// + public sealed partial class CollectionSizeErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CollectionSizeErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CollectionSizeErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CollectionSizeErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CollectionSizeErrorEnum(CollectionSizeErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CollectionSizeErrorEnum Clone() { + return new CollectionSizeErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CollectionSizeErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CollectionSizeErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CollectionSizeErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CollectionSizeErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible collection size errors. + /// + public enum CollectionSizeError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Too few. + /// + [pbr::OriginalName("TOO_FEW")] TooFew = 2, + /// + /// Too many. + /// + [pbr::OriginalName("TOO_MANY")] TooMany = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ContentLabelType.cs b/src/V3/Stubs/ContentLabelType.cs new file mode 100644 index 000000000..d2d37b323 --- /dev/null +++ b/src/V3/Stubs/ContentLabelType.cs @@ -0,0 +1,243 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/content_label_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/content_label_type.proto + public static partial class ContentLabelTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/content_label_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ContentLabelTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb250ZW50X2xhYmVs", + "X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvYCChRDb250ZW50TGFiZWxU", + "eXBlRW51bSLdAgoQQ29udGVudExhYmVsVHlwZRIPCgtVTlNQRUNJRklFRBAA", + "EgsKB1VOS05PV04QARIXChNTRVhVQUxMWV9TVUdHRVNUSVZFEAISEgoOQkVM", + "T1dfVEhFX0ZPTEQQAxIRCg1QQVJLRURfRE9NQUlOEAQSDAoISlVWRU5JTEUQ", + "BhINCglQUk9GQU5JVFkQBxILCgdUUkFHRURZEAgSCQoFVklERU8QCRIVChFW", + "SURFT19SQVRJTkdfRFZfRxAKEhYKElZJREVPX1JBVElOR19EVl9QRxALEhUK", + "EVZJREVPX1JBVElOR19EVl9UEAwSFgoSVklERU9fUkFUSU5HX0RWX01BEA0S", + "FwoTVklERU9fTk9UX1lFVF9SQVRFRBAOEhIKDkVNQkVEREVEX1ZJREVPEA8S", + "GAoUTElWRV9TVFJFQU1JTkdfVklERU8QEBIRCg1TT0NJQUxfSVNTVUVTEBFC", + "6gEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IVQ29udGVu", + "dExhYmVsVHlwZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3Rv", + "L2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dB", + "QaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFk", + "c1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeEnum.Types.ContentLabelType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing content label types in ContentLabel. + /// + public sealed partial class ContentLabelTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ContentLabelTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContentLabelTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContentLabelTypeEnum(ContentLabelTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContentLabelTypeEnum Clone() { + return new ContentLabelTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ContentLabelTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ContentLabelTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ContentLabelTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ContentLabelTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum listing the content label types supported by ContentLabel criterion. + /// + public enum ContentLabelType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Sexually suggestive content. + /// + [pbr::OriginalName("SEXUALLY_SUGGESTIVE")] SexuallySuggestive = 2, + /// + /// Below the fold placement. + /// + [pbr::OriginalName("BELOW_THE_FOLD")] BelowTheFold = 3, + /// + /// Parked domain. + /// + [pbr::OriginalName("PARKED_DOMAIN")] ParkedDomain = 4, + /// + /// Juvenile, gross & bizarre content. + /// + [pbr::OriginalName("JUVENILE")] Juvenile = 6, + /// + /// Profanity & rough language. + /// + [pbr::OriginalName("PROFANITY")] Profanity = 7, + /// + /// Death & tragedy. + /// + [pbr::OriginalName("TRAGEDY")] Tragedy = 8, + /// + /// Video. + /// + [pbr::OriginalName("VIDEO")] Video = 9, + /// + /// Content rating: G. + /// + [pbr::OriginalName("VIDEO_RATING_DV_G")] VideoRatingDvG = 10, + /// + /// Content rating: PG. + /// + [pbr::OriginalName("VIDEO_RATING_DV_PG")] VideoRatingDvPg = 11, + /// + /// Content rating: T. + /// + [pbr::OriginalName("VIDEO_RATING_DV_T")] VideoRatingDvT = 12, + /// + /// Content rating: MA. + /// + [pbr::OriginalName("VIDEO_RATING_DV_MA")] VideoRatingDvMa = 13, + /// + /// Content rating: not yet rated. + /// + [pbr::OriginalName("VIDEO_NOT_YET_RATED")] VideoNotYetRated = 14, + /// + /// Embedded video. + /// + [pbr::OriginalName("EMBEDDED_VIDEO")] EmbeddedVideo = 15, + /// + /// Live streaming video. + /// + [pbr::OriginalName("LIVE_STREAMING_VIDEO")] LiveStreamingVideo = 16, + /// + /// Sensitive social issues. + /// + [pbr::OriginalName("SOCIAL_ISSUES")] SocialIssues = 17, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ContextError.cs b/src/V3/Stubs/ContextError.cs new file mode 100644 index 000000000..805172728 --- /dev/null +++ b/src/V3/Stubs/ContextError.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/context_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/context_error.proto + public static partial class ContextErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/context_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ContextErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY29udGV4dF9lcnJv", + "ci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvIpwBChBDb250ZXh0RXJyb3JFbnVt", + "IocBCgxDb250ZXh0RXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dO", + "EAESJwojT1BFUkFUSU9OX05PVF9QRVJNSVRURURfRk9SX0NPTlRFWFQQAhIw", + "CixPUEVSQVRJT05fTk9UX1BFUk1JVFRFRF9GT1JfUkVNT1ZFRF9SRVNPVVJD", + "RRADQuwBCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQhFD", + "b250ZXh0RXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90", + "by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6IC", + "A0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2ds", + "ZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29n", + "bGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ContextErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.ContextErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.ContextErrorEnum.Types.ContextError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible context errors. + /// + public sealed partial class ContextErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ContextErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ContextErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContextErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContextErrorEnum(ContextErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContextErrorEnum Clone() { + return new ContextErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ContextErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ContextErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ContextErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ContextErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible context errors. + /// + public enum ContextError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The operation is not allowed for the given context. + /// + [pbr::OriginalName("OPERATION_NOT_PERMITTED_FOR_CONTEXT")] OperationNotPermittedForContext = 2, + /// + /// The operation is not allowed for removed resources. + /// + [pbr::OriginalName("OPERATION_NOT_PERMITTED_FOR_REMOVED_RESOURCE")] OperationNotPermittedForRemovedResource = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionAction.cs b/src/V3/Stubs/ConversionAction.cs new file mode 100644 index 000000000..4fd369c4d --- /dev/null +++ b/src/V3/Stubs/ConversionAction.cs @@ -0,0 +1,1165 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/conversion_action.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/conversion_action.proto + public static partial class ConversionActionReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/conversion_action.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionActionReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY29udmVyc2lv", + "bl9hY3Rpb24ucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291", + "cmNlcxowZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL3RhZ19zbmlw", + "cGV0LnByb3RvGjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hdHRy", + "aWJ1dGlvbl9tb2RlbC5wcm90bxo+Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "ZW51bXMvY29udmVyc2lvbl9hY3Rpb25fY2F0ZWdvcnkucHJvdG8aQ2dvb2ds", + "ZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2NvbnZlcnNpb25fYWN0aW9uX2Nv", + "dW50aW5nX3R5cGUucHJvdG8aPGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vu", + "dW1zL2NvbnZlcnNpb25fYWN0aW9uX3N0YXR1cy5wcm90bxo6Z29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZW51bXMvY29udmVyc2lvbl9hY3Rpb25fdHlwZS5w", + "cm90bxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvZGF0YV9kcml2", + "ZW5fbW9kZWxfc3RhdHVzLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2", + "aW9yLnByb3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUv", + "cHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlv", + "bnMucHJvdG8ijA4KEENvbnZlcnNpb25BY3Rpb24SSAoNcmVzb3VyY2VfbmFt", + "ZRgBIAEoCUIx4EEF+kErCilnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ29u", + "dmVyc2lvbkFjdGlvbhIsCgJpZBgCIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5J", + "bnQ2NFZhbHVlQgPgQQMSKgoEbmFtZRgDIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZRJgCgZzdGF0dXMYBCABKA4yUC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtcy5Db252ZXJzaW9uQWN0aW9uU3RhdHVzRW51bS5D", + "b252ZXJzaW9uQWN0aW9uU3RhdHVzEl8KBHR5cGUYBSABKA4yTC5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtcy5Db252ZXJzaW9uQWN0aW9uVHlwZUVu", + "dW0uQ29udmVyc2lvbkFjdGlvblR5cGVCA+BBBRJmCghjYXRlZ29yeRgGIAEo", + "DjJULmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkNvbnZlcnNpb25B", + "Y3Rpb25DYXRlZ29yeUVudW0uQ29udmVyc2lvbkFjdGlvbkNhdGVnb3J5EjkK", + "Dm93bmVyX2N1c3RvbWVyGAcgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlQgPgQQMSQQodaW5jbHVkZV9pbl9jb252ZXJzaW9uc19tZXRyaWMY", + "CCABKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlEkcKImNsaWNrX3Ro", + "cm91Z2hfbG9va2JhY2tfd2luZG93X2RheXMYCSABKAsyGy5nb29nbGUucHJv", + "dG9idWYuSW50NjRWYWx1ZRJGCiF2aWV3X3Rocm91Z2hfbG9va2JhY2tfd2lu", + "ZG93X2RheXMYCiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZRJZ", + "Cg52YWx1ZV9zZXR0aW5ncxgLIAEoCzJBLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5Db252ZXJzaW9uQWN0aW9uLlZhbHVlU2V0dGluZ3MS", + "cwoNY291bnRpbmdfdHlwZRgMIAEoDjJcLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zLkNvbnZlcnNpb25BY3Rpb25Db3VudGluZ1R5cGVFbnVtLkNv", + "bnZlcnNpb25BY3Rpb25Db3VudGluZ1R5cGUScAoaYXR0cmlidXRpb25fbW9k", + "ZWxfc2V0dGluZ3MYDSABKAsyTC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMuQ29udmVyc2lvbkFjdGlvbi5BdHRyaWJ1dGlvbk1vZGVsU2V0", + "dGluZ3MSRQoMdGFnX3NuaXBwZXRzGA4gAygLMiouZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLlRhZ1NuaXBwZXRCA+BBAxJAChtwaG9uZV9jYWxs", + "X2R1cmF0aW9uX3NlY29uZHMYDyABKAsyGy5nb29nbGUucHJvdG9idWYuSW50", + "NjRWYWx1ZRIsCgZhcHBfaWQYECABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWUa8gEKGEF0dHJpYnV0aW9uTW9kZWxTZXR0aW5ncxJfChFhdHRy", + "aWJ1dGlvbl9tb2RlbBgBIAEoDjJELmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zLkF0dHJpYnV0aW9uTW9kZWxFbnVtLkF0dHJpYnV0aW9uTW9kZWwS", + "dQoYZGF0YV9kcml2ZW5fbW9kZWxfc3RhdHVzGAIgASgOMk4uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMuRGF0YURyaXZlbk1vZGVsU3RhdHVzRW51", + "bS5EYXRhRHJpdmVuTW9kZWxTdGF0dXNCA+BBAxq/AQoNVmFsdWVTZXR0aW5n", + "cxIzCg1kZWZhdWx0X3ZhbHVlGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLkRv", + "dWJsZVZhbHVlEjsKFWRlZmF1bHRfY3VycmVuY3lfY29kZRgCIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI8ChhhbHdheXNfdXNlX2RlZmF1", + "bHRfdmFsdWUYAyABKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlOmrq", + "QWcKKWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9Db252ZXJzaW9uQWN0aW9u", + "EjpjdXN0b21lcnMve2N1c3RvbWVyfS9jb252ZXJzaW9uQWN0aW9ucy97Y29u", + "dmVyc2lvbl9hY3Rpb259QoICCiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzQhVDb252ZXJzaW9uQWN0aW9uUHJvdG9QAVpKZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xW", + "M1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVz", + "b3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.TagSnippetReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AttributionModelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCountingTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.DataDrivenModelStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.ConversionAction), global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Parser, new[]{ "ResourceName", "Id", "Name", "Status", "Type", "Category", "OwnerCustomer", "IncludeInConversionsMetric", "ClickThroughLookbackWindowDays", "ViewThroughLookbackWindowDays", "ValueSettings", "CountingType", "AttributionModelSettings", "TagSnippets", "PhoneCallDurationSeconds", "AppId" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.AttributionModelSettings), global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.AttributionModelSettings.Parser, new[]{ "AttributionModel", "DataDrivenModelStatus" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.ValueSettings), global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.ValueSettings.Parser, new[]{ "DefaultValue", "DefaultCurrencyCode", "AlwaysUseDefaultValue" }, null, null, null)}) + })); + } + #endregion + + } + #region Messages + /// + /// A conversion action. + /// + public sealed partial class ConversionAction : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionAction()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.ConversionActionReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAction() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAction(ConversionAction other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + status_ = other.status_; + type_ = other.type_; + category_ = other.category_; + OwnerCustomer = other.OwnerCustomer; + IncludeInConversionsMetric = other.IncludeInConversionsMetric; + ClickThroughLookbackWindowDays = other.ClickThroughLookbackWindowDays; + ViewThroughLookbackWindowDays = other.ViewThroughLookbackWindowDays; + valueSettings_ = other.valueSettings_ != null ? other.valueSettings_.Clone() : null; + countingType_ = other.countingType_; + attributionModelSettings_ = other.attributionModelSettings_ != null ? other.attributionModelSettings_.Clone() : null; + tagSnippets_ = other.tagSnippets_.Clone(); + PhoneCallDurationSeconds = other.PhoneCallDurationSeconds; + AppId = other.AppId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAction Clone() { + return new ConversionAction(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the conversion action. + /// Conversion action resource names have the form: + /// + /// `customers/{customer_id}/conversionActions/{conversion_action_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 3; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(26); + private string name_; + /// + /// The name of the conversion action. + /// + /// This field is required and should not be empty when creating new + /// conversion actions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusEnum.Types.ConversionActionStatus status_ = 0; + /// + /// The status of this conversion action for conversion event accrual. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusEnum.Types.ConversionActionStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeEnum.Types.ConversionActionType type_ = 0; + /// + /// Immutable. The type of this conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeEnum.Types.ConversionActionType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "category" field. + public const int CategoryFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryEnum.Types.ConversionActionCategory category_ = 0; + /// + /// The category of conversions reported for this conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryEnum.Types.ConversionActionCategory Category { + get { return category_; } + set { + category_ = value; + } + } + + /// Field number for the "owner_customer" field. + public const int OwnerCustomerFieldNumber = 7; + private static readonly pb::FieldCodec _single_ownerCustomer_codec = pb::FieldCodec.ForClassWrapper(58); + private string ownerCustomer_; + /// + /// Output only. The resource name of the conversion action owner customer, or null if this + /// is a system-defined conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string OwnerCustomer { + get { return ownerCustomer_; } + set { + ownerCustomer_ = value; + } + } + + + /// Field number for the "include_in_conversions_metric" field. + public const int IncludeInConversionsMetricFieldNumber = 8; + private static readonly pb::FieldCodec _single_includeInConversionsMetric_codec = pb::FieldCodec.ForStructWrapper(66); + private bool? includeInConversionsMetric_; + /// + /// Whether this conversion action should be included in the "conversions" + /// metric. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? IncludeInConversionsMetric { + get { return includeInConversionsMetric_; } + set { + includeInConversionsMetric_ = value; + } + } + + + /// Field number for the "click_through_lookback_window_days" field. + public const int ClickThroughLookbackWindowDaysFieldNumber = 9; + private static readonly pb::FieldCodec _single_clickThroughLookbackWindowDays_codec = pb::FieldCodec.ForStructWrapper(74); + private long? clickThroughLookbackWindowDays_; + /// + /// The maximum number of days that may elapse between an interaction + /// (e.g., a click) and a conversion event. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ClickThroughLookbackWindowDays { + get { return clickThroughLookbackWindowDays_; } + set { + clickThroughLookbackWindowDays_ = value; + } + } + + + /// Field number for the "view_through_lookback_window_days" field. + public const int ViewThroughLookbackWindowDaysFieldNumber = 10; + private static readonly pb::FieldCodec _single_viewThroughLookbackWindowDays_codec = pb::FieldCodec.ForStructWrapper(82); + private long? viewThroughLookbackWindowDays_; + /// + /// The maximum number of days which may elapse between an impression and a + /// conversion without an interaction. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ViewThroughLookbackWindowDays { + get { return viewThroughLookbackWindowDays_; } + set { + viewThroughLookbackWindowDays_ = value; + } + } + + + /// Field number for the "value_settings" field. + public const int ValueSettingsFieldNumber = 11; + private global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.ValueSettings valueSettings_; + /// + /// Settings related to the value for conversion events associated with this + /// conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.ValueSettings ValueSettings { + get { return valueSettings_; } + set { + valueSettings_ = value; + } + } + + /// Field number for the "counting_type" field. + public const int CountingTypeFieldNumber = 12; + private global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCountingTypeEnum.Types.ConversionActionCountingType countingType_ = 0; + /// + /// How to count conversion events for the conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCountingTypeEnum.Types.ConversionActionCountingType CountingType { + get { return countingType_; } + set { + countingType_ = value; + } + } + + /// Field number for the "attribution_model_settings" field. + public const int AttributionModelSettingsFieldNumber = 13; + private global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.AttributionModelSettings attributionModelSettings_; + /// + /// Settings related to this conversion action's attribution model. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.AttributionModelSettings AttributionModelSettings { + get { return attributionModelSettings_; } + set { + attributionModelSettings_ = value; + } + } + + /// Field number for the "tag_snippets" field. + public const int TagSnippetsFieldNumber = 14; + private static readonly pb::FieldCodec _repeated_tagSnippets_codec + = pb::FieldCodec.ForMessage(114, global::Google.Ads.GoogleAds.V3.Common.TagSnippet.Parser); + private readonly pbc::RepeatedField tagSnippets_ = new pbc::RepeatedField(); + /// + /// Output only. The snippets used for tracking conversions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField TagSnippets { + get { return tagSnippets_; } + } + + /// Field number for the "phone_call_duration_seconds" field. + public const int PhoneCallDurationSecondsFieldNumber = 15; + private static readonly pb::FieldCodec _single_phoneCallDurationSeconds_codec = pb::FieldCodec.ForStructWrapper(122); + private long? phoneCallDurationSeconds_; + /// + /// The phone call duration in seconds after which a conversion should be + /// reported for this conversion action. + /// + /// The value must be between 0 and 10000, inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PhoneCallDurationSeconds { + get { return phoneCallDurationSeconds_; } + set { + phoneCallDurationSeconds_ = value; + } + } + + + /// Field number for the "app_id" field. + public const int AppIdFieldNumber = 16; + private static readonly pb::FieldCodec _single_appId_codec = pb::FieldCodec.ForClassWrapper(130); + private string appId_; + /// + /// App ID for an app conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AppId { + get { return appId_; } + set { + appId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionAction); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionAction other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (Status != other.Status) return false; + if (Type != other.Type) return false; + if (Category != other.Category) return false; + if (OwnerCustomer != other.OwnerCustomer) return false; + if (IncludeInConversionsMetric != other.IncludeInConversionsMetric) return false; + if (ClickThroughLookbackWindowDays != other.ClickThroughLookbackWindowDays) return false; + if (ViewThroughLookbackWindowDays != other.ViewThroughLookbackWindowDays) return false; + if (!object.Equals(ValueSettings, other.ValueSettings)) return false; + if (CountingType != other.CountingType) return false; + if (!object.Equals(AttributionModelSettings, other.AttributionModelSettings)) return false; + if(!tagSnippets_.Equals(other.tagSnippets_)) return false; + if (PhoneCallDurationSeconds != other.PhoneCallDurationSeconds) return false; + if (AppId != other.AppId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (Category != 0) hash ^= Category.GetHashCode(); + if (ownerCustomer_ != null) hash ^= OwnerCustomer.GetHashCode(); + if (includeInConversionsMetric_ != null) hash ^= IncludeInConversionsMetric.GetHashCode(); + if (clickThroughLookbackWindowDays_ != null) hash ^= ClickThroughLookbackWindowDays.GetHashCode(); + if (viewThroughLookbackWindowDays_ != null) hash ^= ViewThroughLookbackWindowDays.GetHashCode(); + if (valueSettings_ != null) hash ^= ValueSettings.GetHashCode(); + if (CountingType != 0) hash ^= CountingType.GetHashCode(); + if (attributionModelSettings_ != null) hash ^= AttributionModelSettings.GetHashCode(); + hash ^= tagSnippets_.GetHashCode(); + if (phoneCallDurationSeconds_ != null) hash ^= PhoneCallDurationSeconds.GetHashCode(); + if (appId_ != null) hash ^= AppId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (Status != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) Status); + } + if (Type != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Type); + } + if (Category != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) Category); + } + if (ownerCustomer_ != null) { + _single_ownerCustomer_codec.WriteTagAndValue(output, OwnerCustomer); + } + if (includeInConversionsMetric_ != null) { + _single_includeInConversionsMetric_codec.WriteTagAndValue(output, IncludeInConversionsMetric); + } + if (clickThroughLookbackWindowDays_ != null) { + _single_clickThroughLookbackWindowDays_codec.WriteTagAndValue(output, ClickThroughLookbackWindowDays); + } + if (viewThroughLookbackWindowDays_ != null) { + _single_viewThroughLookbackWindowDays_codec.WriteTagAndValue(output, ViewThroughLookbackWindowDays); + } + if (valueSettings_ != null) { + output.WriteRawTag(90); + output.WriteMessage(ValueSettings); + } + if (CountingType != 0) { + output.WriteRawTag(96); + output.WriteEnum((int) CountingType); + } + if (attributionModelSettings_ != null) { + output.WriteRawTag(106); + output.WriteMessage(AttributionModelSettings); + } + tagSnippets_.WriteTo(output, _repeated_tagSnippets_codec); + if (phoneCallDurationSeconds_ != null) { + _single_phoneCallDurationSeconds_codec.WriteTagAndValue(output, PhoneCallDurationSeconds); + } + if (appId_ != null) { + _single_appId_codec.WriteTagAndValue(output, AppId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (Category != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Category); + } + if (ownerCustomer_ != null) { + size += _single_ownerCustomer_codec.CalculateSizeWithTag(OwnerCustomer); + } + if (includeInConversionsMetric_ != null) { + size += _single_includeInConversionsMetric_codec.CalculateSizeWithTag(IncludeInConversionsMetric); + } + if (clickThroughLookbackWindowDays_ != null) { + size += _single_clickThroughLookbackWindowDays_codec.CalculateSizeWithTag(ClickThroughLookbackWindowDays); + } + if (viewThroughLookbackWindowDays_ != null) { + size += _single_viewThroughLookbackWindowDays_codec.CalculateSizeWithTag(ViewThroughLookbackWindowDays); + } + if (valueSettings_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ValueSettings); + } + if (CountingType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) CountingType); + } + if (attributionModelSettings_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AttributionModelSettings); + } + size += tagSnippets_.CalculateSize(_repeated_tagSnippets_codec); + if (phoneCallDurationSeconds_ != null) { + size += _single_phoneCallDurationSeconds_codec.CalculateSizeWithTag(PhoneCallDurationSeconds); + } + if (appId_ != null) { + size += _single_appId_codec.CalculateSizeWithTag(AppId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionAction other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.Category != 0) { + Category = other.Category; + } + if (other.ownerCustomer_ != null) { + if (ownerCustomer_ == null || other.OwnerCustomer != "") { + OwnerCustomer = other.OwnerCustomer; + } + } + if (other.includeInConversionsMetric_ != null) { + if (includeInConversionsMetric_ == null || other.IncludeInConversionsMetric != false) { + IncludeInConversionsMetric = other.IncludeInConversionsMetric; + } + } + if (other.clickThroughLookbackWindowDays_ != null) { + if (clickThroughLookbackWindowDays_ == null || other.ClickThroughLookbackWindowDays != 0L) { + ClickThroughLookbackWindowDays = other.ClickThroughLookbackWindowDays; + } + } + if (other.viewThroughLookbackWindowDays_ != null) { + if (viewThroughLookbackWindowDays_ == null || other.ViewThroughLookbackWindowDays != 0L) { + ViewThroughLookbackWindowDays = other.ViewThroughLookbackWindowDays; + } + } + if (other.valueSettings_ != null) { + if (valueSettings_ == null) { + ValueSettings = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.ValueSettings(); + } + ValueSettings.MergeFrom(other.ValueSettings); + } + if (other.CountingType != 0) { + CountingType = other.CountingType; + } + if (other.attributionModelSettings_ != null) { + if (attributionModelSettings_ == null) { + AttributionModelSettings = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.AttributionModelSettings(); + } + AttributionModelSettings.MergeFrom(other.AttributionModelSettings); + } + tagSnippets_.Add(other.tagSnippets_); + if (other.phoneCallDurationSeconds_ != null) { + if (phoneCallDurationSeconds_ == null || other.PhoneCallDurationSeconds != 0L) { + PhoneCallDurationSeconds = other.PhoneCallDurationSeconds; + } + } + if (other.appId_ != null) { + if (appId_ == null || other.AppId != "") { + AppId = other.AppId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 26: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 32: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusEnum.Types.ConversionActionStatus) input.ReadEnum(); + break; + } + case 40: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeEnum.Types.ConversionActionType) input.ReadEnum(); + break; + } + case 48: { + Category = (global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryEnum.Types.ConversionActionCategory) input.ReadEnum(); + break; + } + case 58: { + string value = _single_ownerCustomer_codec.Read(input); + if (ownerCustomer_ == null || value != "") { + OwnerCustomer = value; + } + break; + } + case 66: { + bool? value = _single_includeInConversionsMetric_codec.Read(input); + if (includeInConversionsMetric_ == null || value != false) { + IncludeInConversionsMetric = value; + } + break; + } + case 74: { + long? value = _single_clickThroughLookbackWindowDays_codec.Read(input); + if (clickThroughLookbackWindowDays_ == null || value != 0L) { + ClickThroughLookbackWindowDays = value; + } + break; + } + case 82: { + long? value = _single_viewThroughLookbackWindowDays_codec.Read(input); + if (viewThroughLookbackWindowDays_ == null || value != 0L) { + ViewThroughLookbackWindowDays = value; + } + break; + } + case 90: { + if (valueSettings_ == null) { + ValueSettings = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.ValueSettings(); + } + input.ReadMessage(ValueSettings); + break; + } + case 96: { + CountingType = (global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCountingTypeEnum.Types.ConversionActionCountingType) input.ReadEnum(); + break; + } + case 106: { + if (attributionModelSettings_ == null) { + AttributionModelSettings = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Types.AttributionModelSettings(); + } + input.ReadMessage(AttributionModelSettings); + break; + } + case 114: { + tagSnippets_.AddEntriesFrom(input, _repeated_tagSnippets_codec); + break; + } + case 122: { + long? value = _single_phoneCallDurationSeconds_codec.Read(input); + if (phoneCallDurationSeconds_ == null || value != 0L) { + PhoneCallDurationSeconds = value; + } + break; + } + case 130: { + string value = _single_appId_codec.Read(input); + if (appId_ == null || value != "") { + AppId = value; + } + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionAction message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Settings related to this conversion action's attribution model. + /// + public sealed partial class AttributionModelSettings : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AttributionModelSettings()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributionModelSettings() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributionModelSettings(AttributionModelSettings other) : this() { + attributionModel_ = other.attributionModel_; + dataDrivenModelStatus_ = other.dataDrivenModelStatus_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributionModelSettings Clone() { + return new AttributionModelSettings(this); + } + + /// Field number for the "attribution_model" field. + public const int AttributionModelFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.AttributionModelEnum.Types.AttributionModel attributionModel_ = 0; + /// + /// The attribution model type of this conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AttributionModelEnum.Types.AttributionModel AttributionModel { + get { return attributionModel_; } + set { + attributionModel_ = value; + } + } + + /// Field number for the "data_driven_model_status" field. + public const int DataDrivenModelStatusFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.DataDrivenModelStatusEnum.Types.DataDrivenModelStatus dataDrivenModelStatus_ = 0; + /// + /// Output only. The status of the data-driven attribution model for the conversion + /// action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DataDrivenModelStatusEnum.Types.DataDrivenModelStatus DataDrivenModelStatus { + get { return dataDrivenModelStatus_; } + set { + dataDrivenModelStatus_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AttributionModelSettings); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AttributionModelSettings other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (AttributionModel != other.AttributionModel) return false; + if (DataDrivenModelStatus != other.DataDrivenModelStatus) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (AttributionModel != 0) hash ^= AttributionModel.GetHashCode(); + if (DataDrivenModelStatus != 0) hash ^= DataDrivenModelStatus.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (AttributionModel != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) AttributionModel); + } + if (DataDrivenModelStatus != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) DataDrivenModelStatus); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (AttributionModel != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AttributionModel); + } + if (DataDrivenModelStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DataDrivenModelStatus); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AttributionModelSettings other) { + if (other == null) { + return; + } + if (other.AttributionModel != 0) { + AttributionModel = other.AttributionModel; + } + if (other.DataDrivenModelStatus != 0) { + DataDrivenModelStatus = other.DataDrivenModelStatus; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + AttributionModel = (global::Google.Ads.GoogleAds.V3.Enums.AttributionModelEnum.Types.AttributionModel) input.ReadEnum(); + break; + } + case 16: { + DataDrivenModelStatus = (global::Google.Ads.GoogleAds.V3.Enums.DataDrivenModelStatusEnum.Types.DataDrivenModelStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Settings related to the value for conversion events associated with this + /// conversion action. + /// + public sealed partial class ValueSettings : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ValueSettings()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Descriptor.NestedTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ValueSettings() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ValueSettings(ValueSettings other) : this() { + DefaultValue = other.DefaultValue; + DefaultCurrencyCode = other.DefaultCurrencyCode; + AlwaysUseDefaultValue = other.AlwaysUseDefaultValue; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ValueSettings Clone() { + return new ValueSettings(this); + } + + /// Field number for the "default_value" field. + public const int DefaultValueFieldNumber = 1; + private static readonly pb::FieldCodec _single_defaultValue_codec = pb::FieldCodec.ForStructWrapper(10); + private double? defaultValue_; + /// + /// The value to use when conversion events for this conversion action are + /// sent with an invalid, disallowed or missing value, or when + /// this conversion action is configured to always use the default value. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? DefaultValue { + get { return defaultValue_; } + set { + defaultValue_ = value; + } + } + + + /// Field number for the "default_currency_code" field. + public const int DefaultCurrencyCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_defaultCurrencyCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string defaultCurrencyCode_; + /// + /// The currency code to use when conversion events for this conversion + /// action are sent with an invalid or missing currency code, or when this + /// conversion action is configured to always use the default value. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DefaultCurrencyCode { + get { return defaultCurrencyCode_; } + set { + defaultCurrencyCode_ = value; + } + } + + + /// Field number for the "always_use_default_value" field. + public const int AlwaysUseDefaultValueFieldNumber = 3; + private static readonly pb::FieldCodec _single_alwaysUseDefaultValue_codec = pb::FieldCodec.ForStructWrapper(26); + private bool? alwaysUseDefaultValue_; + /// + /// Controls whether the default value and default currency code are used in + /// place of the value and currency code specified in conversion events for + /// this conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? AlwaysUseDefaultValue { + get { return alwaysUseDefaultValue_; } + set { + alwaysUseDefaultValue_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ValueSettings); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ValueSettings other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(DefaultValue, other.DefaultValue)) return false; + if (DefaultCurrencyCode != other.DefaultCurrencyCode) return false; + if (AlwaysUseDefaultValue != other.AlwaysUseDefaultValue) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (defaultValue_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(DefaultValue); + if (defaultCurrencyCode_ != null) hash ^= DefaultCurrencyCode.GetHashCode(); + if (alwaysUseDefaultValue_ != null) hash ^= AlwaysUseDefaultValue.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (defaultValue_ != null) { + _single_defaultValue_codec.WriteTagAndValue(output, DefaultValue); + } + if (defaultCurrencyCode_ != null) { + _single_defaultCurrencyCode_codec.WriteTagAndValue(output, DefaultCurrencyCode); + } + if (alwaysUseDefaultValue_ != null) { + _single_alwaysUseDefaultValue_codec.WriteTagAndValue(output, AlwaysUseDefaultValue); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (defaultValue_ != null) { + size += _single_defaultValue_codec.CalculateSizeWithTag(DefaultValue); + } + if (defaultCurrencyCode_ != null) { + size += _single_defaultCurrencyCode_codec.CalculateSizeWithTag(DefaultCurrencyCode); + } + if (alwaysUseDefaultValue_ != null) { + size += _single_alwaysUseDefaultValue_codec.CalculateSizeWithTag(AlwaysUseDefaultValue); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ValueSettings other) { + if (other == null) { + return; + } + if (other.defaultValue_ != null) { + if (defaultValue_ == null || other.DefaultValue != 0D) { + DefaultValue = other.DefaultValue; + } + } + if (other.defaultCurrencyCode_ != null) { + if (defaultCurrencyCode_ == null || other.DefaultCurrencyCode != "") { + DefaultCurrencyCode = other.DefaultCurrencyCode; + } + } + if (other.alwaysUseDefaultValue_ != null) { + if (alwaysUseDefaultValue_ == null || other.AlwaysUseDefaultValue != false) { + AlwaysUseDefaultValue = other.AlwaysUseDefaultValue; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + double? value = _single_defaultValue_codec.Read(input); + if (defaultValue_ == null || value != 0D) { + DefaultValue = value; + } + break; + } + case 18: { + string value = _single_defaultCurrencyCode_codec.Read(input); + if (defaultCurrencyCode_ == null || value != "") { + DefaultCurrencyCode = value; + } + break; + } + case 26: { + bool? value = _single_alwaysUseDefaultValue_codec.Read(input); + if (alwaysUseDefaultValue_ == null || value != false) { + AlwaysUseDefaultValue = value; + } + break; + } + } + } + } + + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionActionCategory.cs b/src/V3/Stubs/ConversionActionCategory.cs new file mode 100644 index 000000000..b1509ed29 --- /dev/null +++ b/src/V3/Stubs/ConversionActionCategory.cs @@ -0,0 +1,204 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/conversion_action_category.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/conversion_action_category.proto + public static partial class ConversionActionCategoryReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/conversion_action_category.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionActionCategoryReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb252ZXJzaW9uX2Fj", + "dGlvbl9jYXRlZ29yeS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ipwEKHENvbnZl", + "cnNpb25BY3Rpb25DYXRlZ29yeUVudW0ihgEKGENvbnZlcnNpb25BY3Rpb25D", + "YXRlZ29yeRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARILCgdERUZB", + "VUxUEAISDQoJUEFHRV9WSUVXEAMSDAoIUFVSQ0hBU0UQBBIKCgZTSUdOVVAQ", + "BRIICgRMRUFEEAYSDAoIRE9XTkxPQUQQB0LyAQohY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zQh1Db252ZXJzaW9uQWN0aW9uQ2F0ZWdvcnlQ", + "cm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlz", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRz", + "XFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1z", + "YgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryEnum), global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryEnum.Types.ConversionActionCategory) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the category of conversions that are associated + /// with a ConversionAction. + /// + public sealed partial class ConversionActionCategoryEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionActionCategoryEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCategoryReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionCategoryEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionCategoryEnum(ConversionActionCategoryEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionCategoryEnum Clone() { + return new ConversionActionCategoryEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionActionCategoryEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionActionCategoryEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionActionCategoryEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionActionCategoryEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The category of conversions that are associated with a ConversionAction. + /// + public enum ConversionActionCategory { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Default category. + /// + [pbr::OriginalName("DEFAULT")] Default = 2, + /// + /// User visiting a page. + /// + [pbr::OriginalName("PAGE_VIEW")] PageView = 3, + /// + /// Purchase, sales, or "order placed" event. + /// + [pbr::OriginalName("PURCHASE")] Purchase = 4, + /// + /// Signup user action. + /// + [pbr::OriginalName("SIGNUP")] Signup = 5, + /// + /// Lead-generating action. + /// + [pbr::OriginalName("LEAD")] Lead = 6, + /// + /// Software download action (as for an app). + /// + [pbr::OriginalName("DOWNLOAD")] Download = 7, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionActionCountingType.cs b/src/V3/Stubs/ConversionActionCountingType.cs new file mode 100644 index 000000000..f8af23ec9 --- /dev/null +++ b/src/V3/Stubs/ConversionActionCountingType.cs @@ -0,0 +1,188 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/conversion_action_counting_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/conversion_action_counting_type.proto + public static partial class ConversionActionCountingTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/conversion_action_counting_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionActionCountingTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb252ZXJzaW9uX2Fj", + "dGlvbl9jb3VudGluZ190eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKHAQog", + "Q29udmVyc2lvbkFjdGlvbkNvdW50aW5nVHlwZUVudW0iYwocQ29udmVyc2lv", + "bkFjdGlvbkNvdW50aW5nVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05P", + "V04QARIRCg1PTkVfUEVSX0NMSUNLEAISEgoOTUFOWV9QRVJfQ0xJQ0sQA0L2", + "AQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQiFDb252ZXJz", + "aW9uQWN0aW9uQ291bnRpbmdUeXBlUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5v", + "cmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1z", + "O2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPK", + "Ah1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCountingTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCountingTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCountingTypeEnum.Types.ConversionActionCountingType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the conversion deduplication mode for + /// conversion optimizer. + /// + public sealed partial class ConversionActionCountingTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionActionCountingTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ConversionActionCountingTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionCountingTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionCountingTypeEnum(ConversionActionCountingTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionCountingTypeEnum Clone() { + return new ConversionActionCountingTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionActionCountingTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionActionCountingTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionActionCountingTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionActionCountingTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Indicates how conversions for this action will be counted. For more + /// information, see https://support.google.com/google-ads/answer/3438531. + /// + public enum ConversionActionCountingType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Count only one conversion per click. + /// + [pbr::OriginalName("ONE_PER_CLICK")] OnePerClick = 2, + /// + /// Count all conversions per click. + /// + [pbr::OriginalName("MANY_PER_CLICK")] ManyPerClick = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionActionError.cs b/src/V3/Stubs/ConversionActionError.cs new file mode 100644 index 000000000..6c7b6f5cc --- /dev/null +++ b/src/V3/Stubs/ConversionActionError.cs @@ -0,0 +1,222 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/conversion_action_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/conversion_action_error.proto + public static partial class ConversionActionErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/conversion_action_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionActionErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY29udmVyc2lvbl9h", + "Y3Rpb25fZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLvAgoZQ29udmVy", + "c2lvbkFjdGlvbkVycm9yRW51bSLRAgoVQ29udmVyc2lvbkFjdGlvbkVycm9y", + "Eg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhIKDkRVUExJQ0FURV9O", + "QU1FEAISFAoQRFVQTElDQVRFX0FQUF9JRBADEjcKM1RXT19DT05WRVJTSU9O", + "X0FDVElPTlNfQklERElOR19PTl9TQU1FX0FQUF9ET1dOTE9BRBAEEjEKLUJJ", + "RERJTkdfT05fU0FNRV9BUFBfRE9XTkxPQURfQVNfR0xPQkFMX0FDVElPThAF", + "EikKJURBVEFfRFJJVkVOX01PREVMX1dBU19ORVZFUl9HRU5FUkFURUQQBhId", + "ChlEQVRBX0RSSVZFTl9NT0RFTF9FWFBJUkVEEAcSGwoXREFUQV9EUklWRU5f", + "TU9ERUxfU1RBTEUQCBIdChlEQVRBX0RSSVZFTl9NT0RFTF9VTktOT1dOEAlC", + "9QEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNCGkNvbnZl", + "cnNpb25BY3Rpb25FcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJy", + "b3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIe", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ConversionActionErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.ConversionActionErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.ConversionActionErrorEnum.Types.ConversionActionError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible conversion action errors. + /// + public sealed partial class ConversionActionErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionActionErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ConversionActionErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionErrorEnum(ConversionActionErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionErrorEnum Clone() { + return new ConversionActionErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionActionErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionActionErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionActionErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionActionErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible conversion action errors. + /// + public enum ConversionActionError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The specified conversion action name already exists. + /// + [pbr::OriginalName("DUPLICATE_NAME")] DuplicateName = 2, + /// + /// Another conversion action with the specified app id already exists. + /// + [pbr::OriginalName("DUPLICATE_APP_ID")] DuplicateAppId = 3, + /// + /// Android first open action conflicts with Google play codeless download + /// action tracking the same app. + /// + [pbr::OriginalName("TWO_CONVERSION_ACTIONS_BIDDING_ON_SAME_APP_DOWNLOAD")] TwoConversionActionsBiddingOnSameAppDownload = 4, + /// + /// Android first open action conflicts with Google play codeless download + /// action tracking the same app. + /// + [pbr::OriginalName("BIDDING_ON_SAME_APP_DOWNLOAD_AS_GLOBAL_ACTION")] BiddingOnSameAppDownloadAsGlobalAction = 5, + /// + /// The attribution model cannot be set to DATA_DRIVEN because a data-driven + /// model has never been generated. + /// + [pbr::OriginalName("DATA_DRIVEN_MODEL_WAS_NEVER_GENERATED")] DataDrivenModelWasNeverGenerated = 6, + /// + /// The attribution model cannot be set to DATA_DRIVEN because the + /// data-driven model is expired. + /// + [pbr::OriginalName("DATA_DRIVEN_MODEL_EXPIRED")] DataDrivenModelExpired = 7, + /// + /// The attribution model cannot be set to DATA_DRIVEN because the + /// data-driven model is stale. + /// + [pbr::OriginalName("DATA_DRIVEN_MODEL_STALE")] DataDrivenModelStale = 8, + /// + /// The attribution model cannot be set to DATA_DRIVEN because the + /// data-driven model is unavailable or the conversion action was newly + /// added. + /// + [pbr::OriginalName("DATA_DRIVEN_MODEL_UNKNOWN")] DataDrivenModelUnknown = 9, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionActionService.cs b/src/V3/Stubs/ConversionActionService.cs new file mode 100644 index 000000000..12e773f4a --- /dev/null +++ b/src/V3/Stubs/ConversionActionService.cs @@ -0,0 +1,1036 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/conversion_action_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/conversion_action_service.proto + public static partial class ConversionActionServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/conversion_action_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionActionServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jb252ZXJzaW9u", + "X2FjdGlvbl9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2Vz", + "L2NvbnZlcnNpb25fYWN0aW9uLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2Fw", + "aS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29vZ2xlL3Byb3RvYnVmL2ZpZWxk", + "X21hc2sucHJvdG8aF2dvb2dsZS9ycGMvc3RhdHVzLnByb3RvIjgKGkdldENv", + "bnZlcnNpb25BY3Rpb25SZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlC", + "A+BBAiLAAQoeTXV0YXRlQ29udmVyc2lvbkFjdGlvbnNSZXF1ZXN0EhgKC2N1", + "c3RvbWVyX2lkGAEgASgJQgPgQQISVAoKb3BlcmF0aW9ucxgCIAMoCzI7Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkNvbnZlcnNpb25BY3Rp", + "b25PcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyABKAgSFQoN", + "dmFsaWRhdGVfb25seRgEIAEoCCL5AQoZQ29udmVyc2lvbkFjdGlvbk9wZXJh", + "dGlvbhIvCgt1cGRhdGVfbWFzaxgEIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5G", + "aWVsZE1hc2sSRQoGY3JlYXRlGAEgASgLMjMuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMucmVzb3VyY2VzLkNvbnZlcnNpb25BY3Rpb25IABJFCgZ1cGRhdGUY", + "AiABKAsyMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ29u", + "dmVyc2lvbkFjdGlvbkgAEhAKBnJlbW92ZRgDIAEoCUgAQgsKCW9wZXJhdGlv", + "biKlAQofTXV0YXRlQ29udmVyc2lvbkFjdGlvbnNSZXNwb25zZRIxChVwYXJ0", + "aWFsX2ZhaWx1cmVfZXJyb3IYAyABKAsyEi5nb29nbGUucnBjLlN0YXR1cxJP", + "CgdyZXN1bHRzGAIgAygLMj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuTXV0YXRlQ29udmVyc2lvbkFjdGlvblJlc3VsdCI1ChxNdXRhdGVD", + "b252ZXJzaW9uQWN0aW9uUmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAky", + "iwQKF0NvbnZlcnNpb25BY3Rpb25TZXJ2aWNlEtUBChNHZXRDb252ZXJzaW9u", + "QWN0aW9uEjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR2V0", + "Q29udmVyc2lvbkFjdGlvblJlcXVlc3QaMy5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXMuQ29udmVyc2lvbkFjdGlvbiJLgtPkkwI1EjMvdjMv", + "e3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovY29udmVyc2lvbkFjdGlvbnMv", + "Kn3aQQ1yZXNvdXJjZV9uYW1lEvoBChdNdXRhdGVDb252ZXJzaW9uQWN0aW9u", + "cxJALmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUNv", + "bnZlcnNpb25BY3Rpb25zUmVxdWVzdBpBLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLk11dGF0ZUNvbnZlcnNpb25BY3Rpb25zUmVzcG9uc2Ui", + "WoLT5JMCOyI2L3YzL2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn0vY29udmVy", + "c2lvbkFjdGlvbnM6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9u", + "cxobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQoMCCiRjb20uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCHENvbnZlcnNpb25BY3Rpb25T", + "ZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogID", + "R0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.ConversionActionReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetConversionActionRequest), global::Google.Ads.GoogleAds.V3.Services.GetConversionActionRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ConversionActionOperation), global::Google.Ads.GoogleAds.V3.Services.ConversionActionOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionResult), global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [ConversionActionService.GetConversionAction][google.ads.googleads.v3.services.ConversionActionService.GetConversionAction]. + /// + public sealed partial class GetConversionActionRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetConversionActionRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionActionServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetConversionActionRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetConversionActionRequest(GetConversionActionRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetConversionActionRequest Clone() { + return new GetConversionActionRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the conversion action to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetConversionActionRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetConversionActionRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetConversionActionRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [ConversionActionService.MutateConversionActions][google.ads.googleads.v3.services.ConversionActionService.MutateConversionActions]. + /// + public sealed partial class MutateConversionActionsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateConversionActionsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionActionServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionsRequest(MutateConversionActionsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionsRequest Clone() { + return new MutateConversionActionsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose conversion actions are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.ConversionActionOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual conversion actions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateConversionActionsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateConversionActionsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateConversionActionsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a conversion action. + /// + public sealed partial class ConversionActionOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionActionOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionActionServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionOperation(ConversionActionOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionOperation Clone() { + return new ConversionActionOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new conversion + /// action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ConversionAction Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.ConversionAction) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The conversion action is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ConversionAction Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.ConversionAction) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed conversion action is + /// expected, in this format: + /// + /// `customers/{customer_id}/conversionActions/{conversion_action_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionActionOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionActionOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionActionOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.ConversionAction subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.ConversionAction subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for [ConversionActionService.MutateConversionActions][google.ads.googleads.v3.services.ConversionActionService.MutateConversionActions]. + /// + public sealed partial class MutateConversionActionsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateConversionActionsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionActionServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionsResponse(MutateConversionActionsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionsResponse Clone() { + return new MutateConversionActionsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateConversionActionsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateConversionActionsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateConversionActionsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the conversion action mutate. + /// + public sealed partial class MutateConversionActionResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateConversionActionResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionActionServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionResult(MutateConversionActionResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateConversionActionResult Clone() { + return new MutateConversionActionResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateConversionActionResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateConversionActionResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateConversionActionResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionActionServiceClient.cs b/src/V3/Stubs/ConversionActionServiceClient.cs new file mode 100644 index 000000000..e764e68ba --- /dev/null +++ b/src/V3/Stubs/ConversionActionServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class ConversionActionServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static ConversionActionServiceSettings GetDefault() => new ConversionActionServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public ConversionActionServiceSettings() { } + + private ConversionActionServiceSettings(ConversionActionServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetConversionActionSettings = existing.GetConversionActionSettings; + MutateConversionActionsSettings = existing.MutateConversionActionsSettings; + OnCopy(existing); + } + + partial void OnCopy(ConversionActionServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// ConversionActionServiceClient.GetConversionAction and ConversionActionServiceClient.GetConversionActionAsync. + /// + /// + /// The default ConversionActionServiceClient.GetConversionAction and + /// ConversionActionServiceClient.GetConversionActionAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetConversionActionSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// ConversionActionServiceClient.MutateConversionActions and ConversionActionServiceClient.MutateConversionActionsAsync. + /// + /// + /// The default ConversionActionServiceClient.MutateConversionActions and + /// ConversionActionServiceClient.MutateConversionActionsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateConversionActionsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public ConversionActionServiceSettings Clone() => new ConversionActionServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class ConversionActionServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public ConversionActionServiceSettings Settings { get; set; } + + /// + public override ConversionActionServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return ConversionActionServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return ConversionActionServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => ConversionActionServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => ConversionActionServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => ConversionActionServiceClient.ChannelPool; + } + + /// + /// ConversionActionService client wrapper, for convenient use. + /// + public abstract partial class ConversionActionServiceClient + { + /// + /// The default endpoint for the ConversionActionService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default ConversionActionService scopes. + /// + /// + /// The default ConversionActionService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ConversionActionServiceClient client = await ConversionActionServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ConversionActionServiceClient.DefaultEndpoint.Host, ConversionActionServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ConversionActionServiceClient client = ConversionActionServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, ConversionActionServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ConversionActionServiceClient client = ConversionActionServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ConversionActionServiceClient.DefaultEndpoint.Host, ConversionActionServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ConversionActionServiceClient client = ConversionActionServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static ConversionActionServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, ConversionActionServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ConversionActionServiceClient Create(grpccore::Channel channel, ConversionActionServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ConversionActionServiceClient Create(grpccore::CallInvoker callInvoker, ConversionActionServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + ConversionActionService.ConversionActionServiceClient grpcClient = new ConversionActionService.ConversionActionServiceClient(callInvoker); + return new ConversionActionServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC ConversionActionService client. + /// + public virtual ConversionActionService.ConversionActionServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested conversion action. + /// + /// + /// Required. The resource name of the conversion action to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetConversionActionAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetConversionActionAsync( + new GetConversionActionRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested conversion action. + /// + /// + /// Required. The resource name of the conversion action to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetConversionActionAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetConversionActionAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested conversion action. + /// + /// + /// Required. The resource name of the conversion action to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ConversionAction GetConversionAction( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetConversionAction( + new GetConversionActionRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested conversion action. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetConversionActionAsync( + GetConversionActionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested conversion action. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetConversionActionAsync( + GetConversionActionRequest request, + st::CancellationToken cancellationToken) => GetConversionActionAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested conversion action. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ConversionAction GetConversionAction( + GetConversionActionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose conversion actions are being modified. + /// + /// + /// Required. The list of operations to perform on individual conversion actions. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateConversionActionsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateConversionActionsAsync( + new MutateConversionActionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose conversion actions are being modified. + /// + /// + /// Required. The list of operations to perform on individual conversion actions. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateConversionActionsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateConversionActionsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose conversion actions are being modified. + /// + /// + /// Required. The list of operations to perform on individual conversion actions. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateConversionActionsResponse MutateConversionActions( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateConversionActions( + new MutateConversionActionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose conversion actions are being modified. + /// + /// + /// Required. The list of operations to perform on individual conversion actions. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateConversionActionsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateConversionActionsAsync( + new MutateConversionActionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose conversion actions are being modified. + /// + /// + /// Required. The list of operations to perform on individual conversion actions. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateConversionActionsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateConversionActionsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose conversion actions are being modified. + /// + /// + /// Required. The list of operations to perform on individual conversion actions. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateConversionActionsResponse MutateConversionActions( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateConversionActions( + new MutateConversionActionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateConversionActionsAsync( + MutateConversionActionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateConversionActionsAsync( + MutateConversionActionsRequest request, + st::CancellationToken cancellationToken) => MutateConversionActionsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateConversionActionsResponse MutateConversionActions( + MutateConversionActionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// ConversionActionService client wrapper implementation, for convenient use. + /// + public sealed partial class ConversionActionServiceClientImpl : ConversionActionServiceClient + { + private readonly gaxgrpc::ApiCall _callGetConversionAction; + private readonly gaxgrpc::ApiCall _callMutateConversionActions; + + /// + /// Constructs a client wrapper for the ConversionActionService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public ConversionActionServiceClientImpl(ConversionActionService.ConversionActionServiceClient grpcClient, ConversionActionServiceSettings settings) + { + GrpcClient = grpcClient; + ConversionActionServiceSettings effectiveSettings = settings ?? ConversionActionServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetConversionAction = clientHelper.BuildApiCall( + GrpcClient.GetConversionActionAsync, GrpcClient.GetConversionAction, effectiveSettings.GetConversionActionSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateConversionActions = clientHelper.BuildApiCall( + GrpcClient.MutateConversionActionsAsync, GrpcClient.MutateConversionActions, effectiveSettings.MutateConversionActionsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetConversionAction); + Modify_GetConversionActionApiCall(ref _callGetConversionAction); + Modify_ApiCall(ref _callMutateConversionActions); + Modify_MutateConversionActionsApiCall(ref _callMutateConversionActions); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetConversionActionApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateConversionActionsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(ConversionActionService.ConversionActionServiceClient grpcClient, ConversionActionServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC ConversionActionService client. + /// + public override ConversionActionService.ConversionActionServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetConversionActionRequest(ref GetConversionActionRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateConversionActionsRequest(ref MutateConversionActionsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested conversion action. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetConversionActionAsync( + GetConversionActionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetConversionActionRequest(ref request, ref callSettings); + return _callGetConversionAction.Async(request, callSettings); + } + + /// + /// Returns the requested conversion action. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::ConversionAction GetConversionAction( + GetConversionActionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetConversionActionRequest(ref request, ref callSettings); + return _callGetConversionAction.Sync(request, callSettings); + } + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateConversionActionsAsync( + MutateConversionActionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateConversionActionsRequest(ref request, ref callSettings); + return _callMutateConversionActions.Async(request, callSettings); + } + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateConversionActionsResponse MutateConversionActions( + MutateConversionActionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateConversionActionsRequest(ref request, ref callSettings); + return _callMutateConversionActions.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/ConversionActionServiceGrpc.cs b/src/V3/Stubs/ConversionActionServiceGrpc.cs new file mode 100644 index 000000000..a055c0e56 --- /dev/null +++ b/src/V3/Stubs/ConversionActionServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/conversion_action_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage conversion actions. + /// + public static partial class ConversionActionService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.ConversionActionService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetConversionActionRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetConversionActionRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_ConversionAction = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.ConversionAction.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateConversionActionsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateConversionActionsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetConversionAction = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetConversionAction", + __Marshaller_google_ads_googleads_v3_services_GetConversionActionRequest, + __Marshaller_google_ads_googleads_v3_resources_ConversionAction); + + static readonly grpc::Method __Method_MutateConversionActions = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateConversionActions", + __Marshaller_google_ads_googleads_v3_services_MutateConversionActionsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateConversionActionsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionActionServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of ConversionActionService + public abstract partial class ConversionActionServiceBase + { + /// + /// Returns the requested conversion action. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetConversionAction(global::Google.Ads.GoogleAds.V3.Services.GetConversionActionRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateConversionActions(global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for ConversionActionService + public partial class ConversionActionServiceClient : grpc::ClientBase + { + /// Creates a new client for ConversionActionService + /// The channel to use to make remote calls. + public ConversionActionServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for ConversionActionService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public ConversionActionServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected ConversionActionServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected ConversionActionServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested conversion action. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ConversionAction GetConversionAction(global::Google.Ads.GoogleAds.V3.Services.GetConversionActionRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetConversionAction(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested conversion action. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ConversionAction GetConversionAction(global::Google.Ads.GoogleAds.V3.Services.GetConversionActionRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetConversionAction, null, options, request); + } + /// + /// Returns the requested conversion action. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetConversionActionAsync(global::Google.Ads.GoogleAds.V3.Services.GetConversionActionRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetConversionActionAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested conversion action. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetConversionActionAsync(global::Google.Ads.GoogleAds.V3.Services.GetConversionActionRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetConversionAction, null, options, request); + } + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsResponse MutateConversionActions(global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateConversionActions(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsResponse MutateConversionActions(global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateConversionActions, null, options, request); + } + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateConversionActionsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateConversionActionsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates or removes conversion actions. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateConversionActionsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateConversionActions, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override ConversionActionServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new ConversionActionServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(ConversionActionServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetConversionAction, serviceImpl.GetConversionAction) + .AddMethod(__Method_MutateConversionActions, serviceImpl.MutateConversionActions).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, ConversionActionServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetConversionAction, serviceImpl.GetConversionAction); + serviceBinder.AddMethod(__Method_MutateConversionActions, serviceImpl.MutateConversionActions); + } + + } +} +#endregion diff --git a/src/V3/Stubs/ConversionActionStatus.cs b/src/V3/Stubs/ConversionActionStatus.cs new file mode 100644 index 000000000..40deb8b9c --- /dev/null +++ b/src/V3/Stubs/ConversionActionStatus.cs @@ -0,0 +1,191 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/conversion_action_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/conversion_action_status.proto + public static partial class ConversionActionStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/conversion_action_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionActionStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb252ZXJzaW9uX2Fj", + "dGlvbl9zdGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvInoKGkNvbnZlcnNp", + "b25BY3Rpb25TdGF0dXNFbnVtIlwKFkNvbnZlcnNpb25BY3Rpb25TdGF0dXMS", + "DwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESCwoHRU5BQkxFRBACEgsK", + "B1JFTU9WRUQQAxIKCgZISURERU4QBELwAQohY29tLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVudW1zQhtDb252ZXJzaW9uQWN0aW9uU3RhdHVzUHJvdG9Q", + "AVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMv", + "Z29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5H", + "b29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xF", + "bnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJv", + "dG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusEnum.Types.ConversionActionStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of a conversion action. + /// + public sealed partial class ConversionActionStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionActionStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ConversionActionStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionStatusEnum(ConversionActionStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionStatusEnum Clone() { + return new ConversionActionStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionActionStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionActionStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionActionStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionActionStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a conversion action. + /// + public enum ConversionActionStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Conversions will be recorded. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Conversions will not be recorded. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + /// + /// Conversions will not be recorded and the conversion action will not + /// appear in the UI. + /// + [pbr::OriginalName("HIDDEN")] Hidden = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionActionType.cs b/src/V3/Stubs/ConversionActionType.cs new file mode 100644 index 000000000..8b57187c3 --- /dev/null +++ b/src/V3/Stubs/ConversionActionType.cs @@ -0,0 +1,217 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/conversion_action_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/conversion_action_type.proto + public static partial class ConversionActionTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/conversion_action_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionActionTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb252ZXJzaW9uX2Fj", + "dGlvbl90eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLwAQoYQ29udmVyc2lv", + "bkFjdGlvblR5cGVFbnVtItMBChRDb252ZXJzaW9uQWN0aW9uVHlwZRIPCgtV", + "TlNQRUNJRklFRBAAEgsKB1VOS05PV04QARILCgdBRF9DQUxMEAISEQoNQ0xJ", + "Q0tfVE9fQ0FMTBADEhgKFEdPT0dMRV9QTEFZX0RPV05MT0FEEAQSHwobR09P", + "R0xFX1BMQVlfSU5fQVBQX1BVUkNIQVNFEAUSEAoMVVBMT0FEX0NBTExTEAYS", + "EQoNVVBMT0FEX0NMSUNLUxAHEgsKB1dFQlBBR0UQCBIQCgxXRUJTSVRFX0NB", + "TEwQCULuAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhlD", + "b252ZXJzaW9uQWN0aW9uVHlwZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztl", + "bnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygId", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeEnum.Types.ConversionActionType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible types of a conversion action. + /// + public sealed partial class ConversionActionTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionActionTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ConversionActionTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionTypeEnum(ConversionActionTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionActionTypeEnum Clone() { + return new ConversionActionTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionActionTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionActionTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionActionTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionActionTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible types of a conversion action. + /// + public enum ConversionActionType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Conversions that occur when a user clicks on an ad's call extension. + /// + [pbr::OriginalName("AD_CALL")] AdCall = 2, + /// + /// Conversions that occur when a user on a mobile device clicks a phone + /// number. + /// + [pbr::OriginalName("CLICK_TO_CALL")] ClickToCall = 3, + /// + /// Conversions that occur when a user downloads a mobile app from the Google + /// Play Store. + /// + [pbr::OriginalName("GOOGLE_PLAY_DOWNLOAD")] GooglePlayDownload = 4, + /// + /// Conversions that occur when a user makes a purchase in an app through + /// Android billing. + /// + [pbr::OriginalName("GOOGLE_PLAY_IN_APP_PURCHASE")] GooglePlayInAppPurchase = 5, + /// + /// Call conversions that are tracked by the advertiser and uploaded. + /// + [pbr::OriginalName("UPLOAD_CALLS")] UploadCalls = 6, + /// + /// Conversions that are tracked by the advertiser and uploaded with + /// attributed clicks. + /// + [pbr::OriginalName("UPLOAD_CLICKS")] UploadClicks = 7, + /// + /// Conversions that occur on a webpage. + /// + [pbr::OriginalName("WEBPAGE")] Webpage = 8, + /// + /// Conversions that occur when a user calls a dynamically-generated phone + /// number from an advertiser's website. + /// + [pbr::OriginalName("WEBSITE_CALL")] WebsiteCall = 9, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionAdjustmentType.cs b/src/V3/Stubs/ConversionAdjustmentType.cs new file mode 100644 index 000000000..6e5fd9e90 --- /dev/null +++ b/src/V3/Stubs/ConversionAdjustmentType.cs @@ -0,0 +1,188 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/conversion_adjustment_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/conversion_adjustment_type.proto + public static partial class ConversionAdjustmentTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/conversion_adjustment_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionAdjustmentTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb252ZXJzaW9uX2Fk", + "anVzdG1lbnRfdHlwZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ieQocQ29udmVy", + "c2lvbkFkanVzdG1lbnRUeXBlRW51bSJZChhDb252ZXJzaW9uQWRqdXN0bWVu", + "dFR5cGUSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESDgoKUkVUUkFD", + "VElPThACEg8KC1JFU1RBVEVNRU5UEANC8gEKIWNvbS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtc0IdQ29udmVyc2lvbkFkanVzdG1lbnRUeXBlUHJv", + "dG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9h", + "ZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFk", + "cy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xW", + "M1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IG", + "cHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Types.ConversionAdjustmentType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing conversion adjustment types. + /// + public sealed partial class ConversionAdjustmentTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionAdjustmentTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentTypeEnum(ConversionAdjustmentTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentTypeEnum Clone() { + return new ConversionAdjustmentTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionAdjustmentTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionAdjustmentTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionAdjustmentTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionAdjustmentTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The different actions advertisers can take to adjust the conversions that + /// they already reported. Retractions negate a conversion. Restatements change + /// the value of a conversion. + /// + public enum ConversionAdjustmentType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Negates a conversion so that its total value and count are both zero. + /// + [pbr::OriginalName("RETRACTION")] Retraction = 2, + /// + /// Changes the value of a conversion. + /// + [pbr::OriginalName("RESTATEMENT")] Restatement = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionAdjustmentUploadError.cs b/src/V3/Stubs/ConversionAdjustmentUploadError.cs new file mode 100644 index 000000000..7566128c7 --- /dev/null +++ b/src/V3/Stubs/ConversionAdjustmentUploadError.cs @@ -0,0 +1,238 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/conversion_adjustment_upload_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/conversion_adjustment_upload_error.proto + public static partial class ConversionAdjustmentUploadErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/conversion_adjustment_upload_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionAdjustmentUploadErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY29udmVyc2lvbl9h", + "ZGp1c3RtZW50X3VwbG9hZF9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZXJyb3JzGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3Rv", + "Iu0DCiNDb252ZXJzaW9uQWRqdXN0bWVudFVwbG9hZEVycm9yRW51bSLFAwof", + "Q29udmVyc2lvbkFkanVzdG1lbnRVcGxvYWRFcnJvchIPCgtVTlNQRUNJRklF", + "RBAAEgsKB1VOS05PV04QARIgChxUT09fUkVDRU5UX0NPTlZFUlNJT05fQUNU", + "SU9OEAISHQoZSU5WQUxJRF9DT05WRVJTSU9OX0FDVElPThADEiAKHENPTlZF", + "UlNJT05fQUxSRUFEWV9SRVRSQUNURUQQBBIYChRDT05WRVJTSU9OX05PVF9G", + "T1VORBAFEhYKEkNPTlZFUlNJT05fRVhQSVJFRBAGEiIKHkFESlVTVE1FTlRf", + "UFJFQ0VERVNfQ09OVkVSU0lPThAHEiEKHU1PUkVfUkVDRU5UX1JFU1RBVEVN", + "RU5UX0ZPVU5EEAgSGQoVVE9PX1JFQ0VOVF9DT05WRVJTSU9OEAkSTgpKQ0FO", + "Tk9UX1JFU1RBVEVfQ09OVkVSU0lPTl9BQ1RJT05fVEhBVF9BTFdBWVNfVVNF", + "U19ERUZBVUxUX0NPTlZFUlNJT05fVkFMVUUQChIjCh9UT09fTUFOWV9BREpV", + "U1RNRU5UU19JTl9SRVFVRVNUEAsSGAoUVE9PX01BTllfQURKVVNUTUVOVFMQ", + "DEL/AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IkQ29u", + "dmVyc2lvbkFkanVzdG1lbnRVcGxvYWRFcnJvclByb3RvUAFaRGdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9lcnJvcnM7ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMu", + "VjMuRXJyb3JzygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIi", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ConversionAdjustmentUploadErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.ConversionAdjustmentUploadErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.ConversionAdjustmentUploadErrorEnum.Types.ConversionAdjustmentUploadError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible conversion adjustment upload errors. + /// + public sealed partial class ConversionAdjustmentUploadErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionAdjustmentUploadErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ConversionAdjustmentUploadErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentUploadErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentUploadErrorEnum(ConversionAdjustmentUploadErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentUploadErrorEnum Clone() { + return new ConversionAdjustmentUploadErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionAdjustmentUploadErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionAdjustmentUploadErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionAdjustmentUploadErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionAdjustmentUploadErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible conversion adjustment upload errors. + /// + public enum ConversionAdjustmentUploadError { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The specified conversion action was created too recently. + /// Please try the upload again after 4-6 hours have passed since the + /// conversion action was created. + /// + [pbr::OriginalName("TOO_RECENT_CONVERSION_ACTION")] TooRecentConversionAction = 2, + /// + /// No conversion action of a supported ConversionActionType that matches the + /// provided information can be found for the customer. + /// + [pbr::OriginalName("INVALID_CONVERSION_ACTION")] InvalidConversionAction = 3, + /// + /// A retraction was already reported for this conversion. + /// + [pbr::OriginalName("CONVERSION_ALREADY_RETRACTED")] ConversionAlreadyRetracted = 4, + /// + /// A conversion for the supplied combination of conversion + /// action and conversion identifier could not be found. + /// + [pbr::OriginalName("CONVERSION_NOT_FOUND")] ConversionNotFound = 5, + /// + /// The specified conversion has already expired. Conversions expire after 55 + /// days, after which adjustments cannot be reported against them. + /// + [pbr::OriginalName("CONVERSION_EXPIRED")] ConversionExpired = 6, + /// + /// The supplied adjustment date time precedes that of the original + /// conversion. + /// + [pbr::OriginalName("ADJUSTMENT_PRECEDES_CONVERSION")] AdjustmentPrecedesConversion = 7, + /// + /// A restatement with a more recent adjustment date time was already + /// reported for this conversion. + /// + [pbr::OriginalName("MORE_RECENT_RESTATEMENT_FOUND")] MoreRecentRestatementFound = 8, + /// + /// The conversion was created too recently. + /// + [pbr::OriginalName("TOO_RECENT_CONVERSION")] TooRecentConversion = 9, + /// + /// Restatements cannot be reported for a conversion action that always uses + /// the default value. + /// + [pbr::OriginalName("CANNOT_RESTATE_CONVERSION_ACTION_THAT_ALWAYS_USES_DEFAULT_CONVERSION_VALUE")] CannotRestateConversionActionThatAlwaysUsesDefaultConversionValue = 10, + /// + /// The request contained more than 2000 adjustments. + /// + [pbr::OriginalName("TOO_MANY_ADJUSTMENTS_IN_REQUEST")] TooManyAdjustmentsInRequest = 11, + /// + /// The conversion has been adjusted too many times. + /// + [pbr::OriginalName("TOO_MANY_ADJUSTMENTS")] TooManyAdjustments = 12, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionAdjustmentUploadService.cs b/src/V3/Stubs/ConversionAdjustmentUploadService.cs new file mode 100644 index 000000000..3000ff1ed --- /dev/null +++ b/src/V3/Stubs/ConversionAdjustmentUploadService.cs @@ -0,0 +1,1532 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/conversion_adjustment_upload_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/conversion_adjustment_upload_service.proto + public static partial class ConversionAdjustmentUploadServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/conversion_adjustment_upload_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionAdjustmentUploadServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cktnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jb252ZXJzaW9u", + "X2FkanVzdG1lbnRfdXBsb2FkX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9jb252ZXJzaW9uX2FkanVzdG1lbnRfdHlwZS5wcm90bxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQu", + "cHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aHmdvb2ds", + "ZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMu", + "cHJvdG8iywEKIlVwbG9hZENvbnZlcnNpb25BZGp1c3RtZW50c1JlcXVlc3QS", + "GAoLY3VzdG9tZXJfaWQYASABKAlCA+BBAhJbChZjb252ZXJzaW9uX2FkanVz", + "dG1lbnRzGAIgAygLMjYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuQ29udmVyc2lvbkFkanVzdG1lbnRCA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1", + "cmUYAyABKAgSFQoNdmFsaWRhdGVfb25seRgEIAEoCCKnAQojVXBsb2FkQ29u", + "dmVyc2lvbkFkanVzdG1lbnRzUmVzcG9uc2USMQoVcGFydGlhbF9mYWlsdXJl", + "X2Vycm9yGAEgASgLMhIuZ29vZ2xlLnJwYy5TdGF0dXMSTQoHcmVzdWx0cxgC", + "IAMoCzI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkNvbnZl", + "cnNpb25BZGp1c3RtZW50UmVzdWx0IukDChRDb252ZXJzaW9uQWRqdXN0bWVu", + "dBI3ChFjb252ZXJzaW9uX2FjdGlvbhgDIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZRI6ChRhZGp1c3RtZW50X2RhdGVfdGltZRgEIAEoCzIc", + "Lmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJtCg9hZGp1c3RtZW50X3R5", + "cGUYBSABKA4yVC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5Db252", + "ZXJzaW9uQWRqdXN0bWVudFR5cGVFbnVtLkNvbnZlcnNpb25BZGp1c3RtZW50", + "VHlwZRJNChFyZXN0YXRlbWVudF92YWx1ZRgGIAEoCzIyLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLlJlc3RhdGVtZW50VmFsdWUSUwoUZ2Ns", + "aWRfZGF0ZV90aW1lX3BhaXIYASABKAsyMy5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5HY2xpZERhdGVUaW1lUGFpckgAEjAKCG9yZGVyX2lk", + "GAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlSABCFwoVY29u", + "dmVyc2lvbl9pZGVudGlmaWVyIn0KEFJlc3RhdGVtZW50VmFsdWUSNAoOYWRq", + "dXN0ZWRfdmFsdWUYASABKAsyHC5nb29nbGUucHJvdG9idWYuRG91YmxlVmFs", + "dWUSMwoNY3VycmVuY3lfY29kZRgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZSJ8ChFHY2xpZERhdGVUaW1lUGFpchIrCgVnY2xpZBgBIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI6ChRjb252ZXJzaW9u", + "X2RhdGVfdGltZRgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZSKgAwoaQ29udmVyc2lvbkFkanVzdG1lbnRSZXN1bHQSNwoRY29udmVyc2lv", + "bl9hY3Rpb24YAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUS", + "OgoUYWRqdXN0bWVudF9kYXRlX3RpbWUYBCABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWUSbQoPYWRqdXN0bWVudF90eXBlGAUgASgOMlQuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQ29udmVyc2lvbkFkanVzdG1l", + "bnRUeXBlRW51bS5Db252ZXJzaW9uQWRqdXN0bWVudFR5cGUSUwoUZ2NsaWRf", + "ZGF0ZV90aW1lX3BhaXIYASABKAsyMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5HY2xpZERhdGVUaW1lUGFpckgAEjAKCG9yZGVyX2lkGAIg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlSABCFwoVY29udmVy", + "c2lvbl9pZGVudGlmaWVyMtgCCiFDb252ZXJzaW9uQWRqdXN0bWVudFVwbG9h", + "ZFNlcnZpY2USlQIKG1VwbG9hZENvbnZlcnNpb25BZGp1c3RtZW50cxJELmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLlVwbG9hZENvbnZlcnNp", + "b25BZGp1c3RtZW50c1JlcXVlc3QaRS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5VcGxvYWRDb252ZXJzaW9uQWRqdXN0bWVudHNSZXNwb25z", + "ZSJpgtPkkwI+IjkvdjMvY3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfTp1cGxv", + "YWRDb252ZXJzaW9uQWRqdXN0bWVudHM6ASraQSJjdXN0b21lcl9pZCxjb252", + "ZXJzaW9uX2FkanVzdG1lbnRzGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b21CjQIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0Im", + "Q29udmVyc2lvbkFkanVzdG1lbnRVcGxvYWRTZXJ2aWNlUHJvdG9QAVpIZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5H", + "b29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xW", + "M1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2", + "aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsRequest), global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsRequest.Parser, new[]{ "CustomerId", "ConversionAdjustments", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsResponse), global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustment), global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustment.Parser, new[]{ "ConversionAction", "AdjustmentDateTime", "AdjustmentType", "RestatementValue", "GclidDateTimePair", "OrderId" }, new[]{ "ConversionIdentifier" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.RestatementValue), global::Google.Ads.GoogleAds.V3.Services.RestatementValue.Parser, new[]{ "AdjustedValue", "CurrencyCode" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair), global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair.Parser, new[]{ "Gclid", "ConversionDateTime" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentResult), global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentResult.Parser, new[]{ "ConversionAction", "AdjustmentDateTime", "AdjustmentType", "GclidDateTimePair", "OrderId" }, new[]{ "ConversionIdentifier" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [ConversionAdjustmentUploadService.UploadConversionAdjustments][google.ads.googleads.v3.services.ConversionAdjustmentUploadService.UploadConversionAdjustments]. + /// + public sealed partial class UploadConversionAdjustmentsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UploadConversionAdjustmentsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentUploadServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadConversionAdjustmentsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadConversionAdjustmentsRequest(UploadConversionAdjustmentsRequest other) : this() { + customerId_ = other.customerId_; + conversionAdjustments_ = other.conversionAdjustments_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadConversionAdjustmentsRequest Clone() { + return new UploadConversionAdjustmentsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer performing the upload. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "conversion_adjustments" field. + public const int ConversionAdjustmentsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_conversionAdjustments_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustment.Parser); + private readonly pbc::RepeatedField conversionAdjustments_ = new pbc::RepeatedField(); + /// + /// Required. The conversion adjustments that are being uploaded. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ConversionAdjustments { + get { return conversionAdjustments_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried out + /// in one transaction if and only if they are all valid. This should always be + /// set to true. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UploadConversionAdjustmentsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UploadConversionAdjustmentsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!conversionAdjustments_.Equals(other.conversionAdjustments_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= conversionAdjustments_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + conversionAdjustments_.WriteTo(output, _repeated_conversionAdjustments_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += conversionAdjustments_.CalculateSize(_repeated_conversionAdjustments_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UploadConversionAdjustmentsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + conversionAdjustments_.Add(other.conversionAdjustments_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + conversionAdjustments_.AddEntriesFrom(input, _repeated_conversionAdjustments_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// Response message for + /// [ConversionAdjustmentUploadService.UploadConversionAdjustments][google.ads.googleads.v3.services.ConversionAdjustmentUploadService.UploadConversionAdjustments]. + /// + public sealed partial class UploadConversionAdjustmentsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UploadConversionAdjustmentsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentUploadServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadConversionAdjustmentsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadConversionAdjustmentsResponse(UploadConversionAdjustmentsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadConversionAdjustmentsResponse Clone() { + return new UploadConversionAdjustmentsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 1; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to conversion adjustment failures in the partial + /// failure mode. Returned when all errors occur inside the adjustments. If any + /// errors occur outside the adjustments (e.g. auth errors), we return an RPC + /// level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// Returned for successfully processed conversion adjustments. Proto will be + /// empty for rows that received an error. Results are not returned when + /// validate_only is true. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UploadConversionAdjustmentsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UploadConversionAdjustmentsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (partialFailureError_ != null) { + output.WriteRawTag(10); + output.WriteMessage(PartialFailureError); + } + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UploadConversionAdjustmentsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// A conversion adjustment. + /// + public sealed partial class ConversionAdjustment : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionAdjustment()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentUploadServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustment() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustment(ConversionAdjustment other) : this() { + ConversionAction = other.ConversionAction; + AdjustmentDateTime = other.AdjustmentDateTime; + adjustmentType_ = other.adjustmentType_; + restatementValue_ = other.restatementValue_ != null ? other.restatementValue_.Clone() : null; + switch (other.ConversionIdentifierCase) { + case ConversionIdentifierOneofCase.GclidDateTimePair: + GclidDateTimePair = other.GclidDateTimePair.Clone(); + break; + case ConversionIdentifierOneofCase.OrderId: + OrderId = other.OrderId; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustment Clone() { + return new ConversionAdjustment(this); + } + + /// Field number for the "conversion_action" field. + public const int ConversionActionFieldNumber = 3; + private static readonly pb::FieldCodec _single_conversionAction_codec = pb::FieldCodec.ForClassWrapper(26); + private string conversionAction_; + /// + /// Resource name of the conversion action associated with this conversion + /// adjustment. Note: Although this resource name consists of a customer id and + /// a conversion action id, validation will ignore the customer id and use the + /// conversion action id as the sole identifier of the conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionAction { + get { return conversionAction_; } + set { + conversionAction_ = value; + } + } + + + /// Field number for the "adjustment_date_time" field. + public const int AdjustmentDateTimeFieldNumber = 4; + private static readonly pb::FieldCodec _single_adjustmentDateTime_codec = pb::FieldCodec.ForClassWrapper(34); + private string adjustmentDateTime_; + /// + /// The date time at which the adjustment occurred. Must be after the + /// conversion_date_time. The timezone must be specified. The format is + /// "yyyy-mm-dd hh:mm:ss+|-hh:mm", e.g. "2019-01-01 12:32:45-08:00". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdjustmentDateTime { + get { return adjustmentDateTime_; } + set { + adjustmentDateTime_ = value; + } + } + + + /// Field number for the "adjustment_type" field. + public const int AdjustmentTypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Types.ConversionAdjustmentType adjustmentType_ = 0; + /// + /// The adjustment type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Types.ConversionAdjustmentType AdjustmentType { + get { return adjustmentType_; } + set { + adjustmentType_ = value; + } + } + + /// Field number for the "restatement_value" field. + public const int RestatementValueFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Services.RestatementValue restatementValue_; + /// + /// Information needed to restate the conversion's value. + /// Required for restatements. Should not be supplied for retractions. An error + /// will be returned if provided for a retraction. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.RestatementValue RestatementValue { + get { return restatementValue_; } + set { + restatementValue_ = value; + } + } + + /// Field number for the "gclid_date_time_pair" field. + public const int GclidDateTimePairFieldNumber = 1; + /// + /// Uniquely identifies a conversion that was reported without an order ID + /// specified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair GclidDateTimePair { + get { return conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair ? (global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair) conversionIdentifier_ : null; } + set { + conversionIdentifier_ = value; + conversionIdentifierCase_ = value == null ? ConversionIdentifierOneofCase.None : ConversionIdentifierOneofCase.GclidDateTimePair; + } + } + + /// Field number for the "order_id" field. + public const int OrderIdFieldNumber = 2; + private static readonly pb::FieldCodec _oneof_orderId_codec = pb::FieldCodec.ForClassWrapper(18); + /// + /// The order ID of the conversion to be adjusted. If the conversion was + /// reported with an order ID specified, that order ID must be used as the + /// identifier here. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string OrderId { + get { return conversionIdentifierCase_ == ConversionIdentifierOneofCase.OrderId ? (string) conversionIdentifier_ : (string) null; } + set { + conversionIdentifier_ = value; + conversionIdentifierCase_ = value == null ? ConversionIdentifierOneofCase.None : ConversionIdentifierOneofCase.OrderId; + } + } + + private object conversionIdentifier_; + /// Enum of possible cases for the "conversion_identifier" oneof. + public enum ConversionIdentifierOneofCase { + None = 0, + GclidDateTimePair = 1, + OrderId = 2, + } + private ConversionIdentifierOneofCase conversionIdentifierCase_ = ConversionIdentifierOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionIdentifierOneofCase ConversionIdentifierCase { + get { return conversionIdentifierCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearConversionIdentifier() { + conversionIdentifierCase_ = ConversionIdentifierOneofCase.None; + conversionIdentifier_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionAdjustment); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionAdjustment other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ConversionAction != other.ConversionAction) return false; + if (AdjustmentDateTime != other.AdjustmentDateTime) return false; + if (AdjustmentType != other.AdjustmentType) return false; + if (!object.Equals(RestatementValue, other.RestatementValue)) return false; + if (!object.Equals(GclidDateTimePair, other.GclidDateTimePair)) return false; + if (OrderId != other.OrderId) return false; + if (ConversionIdentifierCase != other.ConversionIdentifierCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (conversionAction_ != null) hash ^= ConversionAction.GetHashCode(); + if (adjustmentDateTime_ != null) hash ^= AdjustmentDateTime.GetHashCode(); + if (AdjustmentType != 0) hash ^= AdjustmentType.GetHashCode(); + if (restatementValue_ != null) hash ^= RestatementValue.GetHashCode(); + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair) hash ^= GclidDateTimePair.GetHashCode(); + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.OrderId) hash ^= OrderId.GetHashCode(); + hash ^= (int) conversionIdentifierCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair) { + output.WriteRawTag(10); + output.WriteMessage(GclidDateTimePair); + } + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.OrderId) { + _oneof_orderId_codec.WriteTagAndValue(output, (string) conversionIdentifier_); + } + if (conversionAction_ != null) { + _single_conversionAction_codec.WriteTagAndValue(output, ConversionAction); + } + if (adjustmentDateTime_ != null) { + _single_adjustmentDateTime_codec.WriteTagAndValue(output, AdjustmentDateTime); + } + if (AdjustmentType != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) AdjustmentType); + } + if (restatementValue_ != null) { + output.WriteRawTag(50); + output.WriteMessage(RestatementValue); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (conversionAction_ != null) { + size += _single_conversionAction_codec.CalculateSizeWithTag(ConversionAction); + } + if (adjustmentDateTime_ != null) { + size += _single_adjustmentDateTime_codec.CalculateSizeWithTag(AdjustmentDateTime); + } + if (AdjustmentType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdjustmentType); + } + if (restatementValue_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(RestatementValue); + } + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(GclidDateTimePair); + } + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.OrderId) { + size += _oneof_orderId_codec.CalculateSizeWithTag(OrderId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionAdjustment other) { + if (other == null) { + return; + } + if (other.conversionAction_ != null) { + if (conversionAction_ == null || other.ConversionAction != "") { + ConversionAction = other.ConversionAction; + } + } + if (other.adjustmentDateTime_ != null) { + if (adjustmentDateTime_ == null || other.AdjustmentDateTime != "") { + AdjustmentDateTime = other.AdjustmentDateTime; + } + } + if (other.AdjustmentType != 0) { + AdjustmentType = other.AdjustmentType; + } + if (other.restatementValue_ != null) { + if (restatementValue_ == null) { + RestatementValue = new global::Google.Ads.GoogleAds.V3.Services.RestatementValue(); + } + RestatementValue.MergeFrom(other.RestatementValue); + } + switch (other.ConversionIdentifierCase) { + case ConversionIdentifierOneofCase.GclidDateTimePair: + if (GclidDateTimePair == null) { + GclidDateTimePair = new global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair(); + } + GclidDateTimePair.MergeFrom(other.GclidDateTimePair); + break; + case ConversionIdentifierOneofCase.OrderId: + OrderId = other.OrderId; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair subBuilder = new global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair(); + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair) { + subBuilder.MergeFrom(GclidDateTimePair); + } + input.ReadMessage(subBuilder); + GclidDateTimePair = subBuilder; + break; + } + case 18: { + OrderId = _oneof_orderId_codec.Read(input); + break; + } + case 26: { + string value = _single_conversionAction_codec.Read(input); + if (conversionAction_ == null || value != "") { + ConversionAction = value; + } + break; + } + case 34: { + string value = _single_adjustmentDateTime_codec.Read(input); + if (adjustmentDateTime_ == null || value != "") { + AdjustmentDateTime = value; + } + break; + } + case 40: { + AdjustmentType = (global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Types.ConversionAdjustmentType) input.ReadEnum(); + break; + } + case 50: { + if (restatementValue_ == null) { + RestatementValue = new global::Google.Ads.GoogleAds.V3.Services.RestatementValue(); + } + input.ReadMessage(RestatementValue); + break; + } + } + } + } + + } + + /// + /// Contains information needed to restate a conversion's value. + /// + public sealed partial class RestatementValue : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new RestatementValue()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentUploadServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public RestatementValue() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public RestatementValue(RestatementValue other) : this() { + AdjustedValue = other.AdjustedValue; + CurrencyCode = other.CurrencyCode; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public RestatementValue Clone() { + return new RestatementValue(this); + } + + /// Field number for the "adjusted_value" field. + public const int AdjustedValueFieldNumber = 1; + private static readonly pb::FieldCodec _single_adjustedValue_codec = pb::FieldCodec.ForStructWrapper(10); + private double? adjustedValue_; + /// + /// The restated conversion value. This is the value of the conversion after + /// restatement. For example, to change the value of a conversion from 100 to + /// 70, an adjusted value of 70 should be reported. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? AdjustedValue { + get { return adjustedValue_; } + set { + adjustedValue_ = value; + } + } + + + /// Field number for the "currency_code" field. + public const int CurrencyCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_currencyCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string currencyCode_; + /// + /// The currency of the restated value. If not provided, then the default + /// currency from the conversion action is used, and if that is not set then + /// the account currency is used. This is the ISO 4217 3-character currency + /// code e.g. USD or EUR. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CurrencyCode { + get { return currencyCode_; } + set { + currencyCode_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as RestatementValue); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(RestatementValue other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(AdjustedValue, other.AdjustedValue)) return false; + if (CurrencyCode != other.CurrencyCode) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (adjustedValue_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(AdjustedValue); + if (currencyCode_ != null) hash ^= CurrencyCode.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (adjustedValue_ != null) { + _single_adjustedValue_codec.WriteTagAndValue(output, AdjustedValue); + } + if (currencyCode_ != null) { + _single_currencyCode_codec.WriteTagAndValue(output, CurrencyCode); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (adjustedValue_ != null) { + size += _single_adjustedValue_codec.CalculateSizeWithTag(AdjustedValue); + } + if (currencyCode_ != null) { + size += _single_currencyCode_codec.CalculateSizeWithTag(CurrencyCode); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(RestatementValue other) { + if (other == null) { + return; + } + if (other.adjustedValue_ != null) { + if (adjustedValue_ == null || other.AdjustedValue != 0D) { + AdjustedValue = other.AdjustedValue; + } + } + if (other.currencyCode_ != null) { + if (currencyCode_ == null || other.CurrencyCode != "") { + CurrencyCode = other.CurrencyCode; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + double? value = _single_adjustedValue_codec.Read(input); + if (adjustedValue_ == null || value != 0D) { + AdjustedValue = value; + } + break; + } + case 18: { + string value = _single_currencyCode_codec.Read(input); + if (currencyCode_ == null || value != "") { + CurrencyCode = value; + } + break; + } + } + } + } + + } + + /// + /// Uniquely identifies a conversion that was reported without an order ID + /// specified. + /// + public sealed partial class GclidDateTimePair : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GclidDateTimePair()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentUploadServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GclidDateTimePair() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GclidDateTimePair(GclidDateTimePair other) : this() { + Gclid = other.Gclid; + ConversionDateTime = other.ConversionDateTime; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GclidDateTimePair Clone() { + return new GclidDateTimePair(this); + } + + /// Field number for the "gclid" field. + public const int GclidFieldNumber = 1; + private static readonly pb::FieldCodec _single_gclid_codec = pb::FieldCodec.ForClassWrapper(10); + private string gclid_; + /// + /// Google click ID (gclid) associated with the original conversion for this + /// adjustment. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Gclid { + get { return gclid_; } + set { + gclid_ = value; + } + } + + + /// Field number for the "conversion_date_time" field. + public const int ConversionDateTimeFieldNumber = 2; + private static readonly pb::FieldCodec _single_conversionDateTime_codec = pb::FieldCodec.ForClassWrapper(18); + private string conversionDateTime_; + /// + /// The date time at which the original conversion for this adjustment + /// occurred. The timezone must be specified. The format is "yyyy-mm-dd + /// hh:mm:ss+|-hh:mm", e.g. "2019-01-01 12:32:45-08:00". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionDateTime { + get { return conversionDateTime_; } + set { + conversionDateTime_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GclidDateTimePair); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GclidDateTimePair other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Gclid != other.Gclid) return false; + if (ConversionDateTime != other.ConversionDateTime) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (gclid_ != null) hash ^= Gclid.GetHashCode(); + if (conversionDateTime_ != null) hash ^= ConversionDateTime.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (gclid_ != null) { + _single_gclid_codec.WriteTagAndValue(output, Gclid); + } + if (conversionDateTime_ != null) { + _single_conversionDateTime_codec.WriteTagAndValue(output, ConversionDateTime); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (gclid_ != null) { + size += _single_gclid_codec.CalculateSizeWithTag(Gclid); + } + if (conversionDateTime_ != null) { + size += _single_conversionDateTime_codec.CalculateSizeWithTag(ConversionDateTime); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GclidDateTimePair other) { + if (other == null) { + return; + } + if (other.gclid_ != null) { + if (gclid_ == null || other.Gclid != "") { + Gclid = other.Gclid; + } + } + if (other.conversionDateTime_ != null) { + if (conversionDateTime_ == null || other.ConversionDateTime != "") { + ConversionDateTime = other.ConversionDateTime; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_gclid_codec.Read(input); + if (gclid_ == null || value != "") { + Gclid = value; + } + break; + } + case 18: { + string value = _single_conversionDateTime_codec.Read(input); + if (conversionDateTime_ == null || value != "") { + ConversionDateTime = value; + } + break; + } + } + } + } + + } + + /// + /// Information identifying a successfully processed ConversionAdjustment. + /// + public sealed partial class ConversionAdjustmentResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionAdjustmentResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentUploadServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentResult(ConversionAdjustmentResult other) : this() { + ConversionAction = other.ConversionAction; + AdjustmentDateTime = other.AdjustmentDateTime; + adjustmentType_ = other.adjustmentType_; + switch (other.ConversionIdentifierCase) { + case ConversionIdentifierOneofCase.GclidDateTimePair: + GclidDateTimePair = other.GclidDateTimePair.Clone(); + break; + case ConversionIdentifierOneofCase.OrderId: + OrderId = other.OrderId; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAdjustmentResult Clone() { + return new ConversionAdjustmentResult(this); + } + + /// Field number for the "conversion_action" field. + public const int ConversionActionFieldNumber = 3; + private static readonly pb::FieldCodec _single_conversionAction_codec = pb::FieldCodec.ForClassWrapper(26); + private string conversionAction_; + /// + /// Resource name of the conversion action associated with this conversion + /// adjustment. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionAction { + get { return conversionAction_; } + set { + conversionAction_ = value; + } + } + + + /// Field number for the "adjustment_date_time" field. + public const int AdjustmentDateTimeFieldNumber = 4; + private static readonly pb::FieldCodec _single_adjustmentDateTime_codec = pb::FieldCodec.ForClassWrapper(34); + private string adjustmentDateTime_; + /// + /// The date time at which the adjustment occurred. The format is + /// "yyyy-mm-dd hh:mm:ss+|-hh:mm", e.g. "2019-01-01 12:32:45-08:00". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdjustmentDateTime { + get { return adjustmentDateTime_; } + set { + adjustmentDateTime_ = value; + } + } + + + /// Field number for the "adjustment_type" field. + public const int AdjustmentTypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Types.ConversionAdjustmentType adjustmentType_ = 0; + /// + /// The adjustment type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Types.ConversionAdjustmentType AdjustmentType { + get { return adjustmentType_; } + set { + adjustmentType_ = value; + } + } + + /// Field number for the "gclid_date_time_pair" field. + public const int GclidDateTimePairFieldNumber = 1; + /// + /// Uniquely identifies a conversion that was reported without an order ID + /// specified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair GclidDateTimePair { + get { return conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair ? (global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair) conversionIdentifier_ : null; } + set { + conversionIdentifier_ = value; + conversionIdentifierCase_ = value == null ? ConversionIdentifierOneofCase.None : ConversionIdentifierOneofCase.GclidDateTimePair; + } + } + + /// Field number for the "order_id" field. + public const int OrderIdFieldNumber = 2; + private static readonly pb::FieldCodec _oneof_orderId_codec = pb::FieldCodec.ForClassWrapper(18); + /// + /// The order ID of the conversion that was adjusted. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string OrderId { + get { return conversionIdentifierCase_ == ConversionIdentifierOneofCase.OrderId ? (string) conversionIdentifier_ : (string) null; } + set { + conversionIdentifier_ = value; + conversionIdentifierCase_ = value == null ? ConversionIdentifierOneofCase.None : ConversionIdentifierOneofCase.OrderId; + } + } + + private object conversionIdentifier_; + /// Enum of possible cases for the "conversion_identifier" oneof. + public enum ConversionIdentifierOneofCase { + None = 0, + GclidDateTimePair = 1, + OrderId = 2, + } + private ConversionIdentifierOneofCase conversionIdentifierCase_ = ConversionIdentifierOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionIdentifierOneofCase ConversionIdentifierCase { + get { return conversionIdentifierCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearConversionIdentifier() { + conversionIdentifierCase_ = ConversionIdentifierOneofCase.None; + conversionIdentifier_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionAdjustmentResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionAdjustmentResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ConversionAction != other.ConversionAction) return false; + if (AdjustmentDateTime != other.AdjustmentDateTime) return false; + if (AdjustmentType != other.AdjustmentType) return false; + if (!object.Equals(GclidDateTimePair, other.GclidDateTimePair)) return false; + if (OrderId != other.OrderId) return false; + if (ConversionIdentifierCase != other.ConversionIdentifierCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (conversionAction_ != null) hash ^= ConversionAction.GetHashCode(); + if (adjustmentDateTime_ != null) hash ^= AdjustmentDateTime.GetHashCode(); + if (AdjustmentType != 0) hash ^= AdjustmentType.GetHashCode(); + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair) hash ^= GclidDateTimePair.GetHashCode(); + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.OrderId) hash ^= OrderId.GetHashCode(); + hash ^= (int) conversionIdentifierCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair) { + output.WriteRawTag(10); + output.WriteMessage(GclidDateTimePair); + } + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.OrderId) { + _oneof_orderId_codec.WriteTagAndValue(output, (string) conversionIdentifier_); + } + if (conversionAction_ != null) { + _single_conversionAction_codec.WriteTagAndValue(output, ConversionAction); + } + if (adjustmentDateTime_ != null) { + _single_adjustmentDateTime_codec.WriteTagAndValue(output, AdjustmentDateTime); + } + if (AdjustmentType != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) AdjustmentType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (conversionAction_ != null) { + size += _single_conversionAction_codec.CalculateSizeWithTag(ConversionAction); + } + if (adjustmentDateTime_ != null) { + size += _single_adjustmentDateTime_codec.CalculateSizeWithTag(AdjustmentDateTime); + } + if (AdjustmentType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdjustmentType); + } + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(GclidDateTimePair); + } + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.OrderId) { + size += _oneof_orderId_codec.CalculateSizeWithTag(OrderId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionAdjustmentResult other) { + if (other == null) { + return; + } + if (other.conversionAction_ != null) { + if (conversionAction_ == null || other.ConversionAction != "") { + ConversionAction = other.ConversionAction; + } + } + if (other.adjustmentDateTime_ != null) { + if (adjustmentDateTime_ == null || other.AdjustmentDateTime != "") { + AdjustmentDateTime = other.AdjustmentDateTime; + } + } + if (other.AdjustmentType != 0) { + AdjustmentType = other.AdjustmentType; + } + switch (other.ConversionIdentifierCase) { + case ConversionIdentifierOneofCase.GclidDateTimePair: + if (GclidDateTimePair == null) { + GclidDateTimePair = new global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair(); + } + GclidDateTimePair.MergeFrom(other.GclidDateTimePair); + break; + case ConversionIdentifierOneofCase.OrderId: + OrderId = other.OrderId; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair subBuilder = new global::Google.Ads.GoogleAds.V3.Services.GclidDateTimePair(); + if (conversionIdentifierCase_ == ConversionIdentifierOneofCase.GclidDateTimePair) { + subBuilder.MergeFrom(GclidDateTimePair); + } + input.ReadMessage(subBuilder); + GclidDateTimePair = subBuilder; + break; + } + case 18: { + OrderId = _oneof_orderId_codec.Read(input); + break; + } + case 26: { + string value = _single_conversionAction_codec.Read(input); + if (conversionAction_ == null || value != "") { + ConversionAction = value; + } + break; + } + case 34: { + string value = _single_adjustmentDateTime_codec.Read(input); + if (adjustmentDateTime_ == null || value != "") { + AdjustmentDateTime = value; + } + break; + } + case 40: { + AdjustmentType = (global::Google.Ads.GoogleAds.V3.Enums.ConversionAdjustmentTypeEnum.Types.ConversionAdjustmentType) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionAdjustmentUploadServiceClient.cs b/src/V3/Stubs/ConversionAdjustmentUploadServiceClient.cs new file mode 100644 index 000000000..fd0387dac --- /dev/null +++ b/src/V3/Stubs/ConversionAdjustmentUploadServiceClient.cs @@ -0,0 +1,691 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class ConversionAdjustmentUploadServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static ConversionAdjustmentUploadServiceSettings GetDefault() => new ConversionAdjustmentUploadServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public ConversionAdjustmentUploadServiceSettings() { } + + private ConversionAdjustmentUploadServiceSettings(ConversionAdjustmentUploadServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + UploadConversionAdjustmentsSettings = existing.UploadConversionAdjustmentsSettings; + OnCopy(existing); + } + + partial void OnCopy(ConversionAdjustmentUploadServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// ConversionAdjustmentUploadServiceClient.UploadConversionAdjustments and ConversionAdjustmentUploadServiceClient.UploadConversionAdjustmentsAsync. + /// + /// + /// The default ConversionAdjustmentUploadServiceClient.UploadConversionAdjustments and + /// ConversionAdjustmentUploadServiceClient.UploadConversionAdjustmentsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings UploadConversionAdjustmentsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public ConversionAdjustmentUploadServiceSettings Clone() => new ConversionAdjustmentUploadServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class ConversionAdjustmentUploadServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public ConversionAdjustmentUploadServiceSettings Settings { get; set; } + + /// + public override ConversionAdjustmentUploadServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return ConversionAdjustmentUploadServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return ConversionAdjustmentUploadServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => ConversionAdjustmentUploadServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => ConversionAdjustmentUploadServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => ConversionAdjustmentUploadServiceClient.ChannelPool; + } + + /// + /// ConversionAdjustmentUploadService client wrapper, for convenient use. + /// + public abstract partial class ConversionAdjustmentUploadServiceClient + { + /// + /// The default endpoint for the ConversionAdjustmentUploadService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default ConversionAdjustmentUploadService scopes. + /// + /// + /// The default ConversionAdjustmentUploadService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ConversionAdjustmentUploadServiceClient client = await ConversionAdjustmentUploadServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ConversionAdjustmentUploadServiceClient.DefaultEndpoint.Host, ConversionAdjustmentUploadServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ConversionAdjustmentUploadServiceClient client = ConversionAdjustmentUploadServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, ConversionAdjustmentUploadServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ConversionAdjustmentUploadServiceClient client = ConversionAdjustmentUploadServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ConversionAdjustmentUploadServiceClient.DefaultEndpoint.Host, ConversionAdjustmentUploadServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ConversionAdjustmentUploadServiceClient client = ConversionAdjustmentUploadServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static ConversionAdjustmentUploadServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, ConversionAdjustmentUploadServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ConversionAdjustmentUploadServiceClient Create(grpccore::Channel channel, ConversionAdjustmentUploadServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ConversionAdjustmentUploadServiceClient Create(grpccore::CallInvoker callInvoker, ConversionAdjustmentUploadServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + ConversionAdjustmentUploadService.ConversionAdjustmentUploadServiceClient grpcClient = new ConversionAdjustmentUploadService.ConversionAdjustmentUploadServiceClient(callInvoker); + return new ConversionAdjustmentUploadServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC ConversionAdjustmentUploadService client. + /// + public virtual ConversionAdjustmentUploadService.ConversionAdjustmentUploadServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Processes the given conversion adjustments. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversion adjustments that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried out + /// in one transaction if and only if they are all valid. This should always be + /// set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadConversionAdjustmentsAsync( + string customerId, + scg::IEnumerable conversionAdjustments, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => UploadConversionAdjustmentsAsync( + new UploadConversionAdjustmentsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + ConversionAdjustments = { gax::GaxPreconditions.CheckNotNull(conversionAdjustments, nameof(conversionAdjustments)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Processes the given conversion adjustments. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversion adjustments that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried out + /// in one transaction if and only if they are all valid. This should always be + /// set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadConversionAdjustmentsAsync( + string customerId, + scg::IEnumerable conversionAdjustments, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => UploadConversionAdjustmentsAsync( + customerId, + conversionAdjustments, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given conversion adjustments. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversion adjustments that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried out + /// in one transaction if and only if they are all valid. This should always be + /// set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadConversionAdjustmentsResponse UploadConversionAdjustments( + string customerId, + scg::IEnumerable conversionAdjustments, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => UploadConversionAdjustments( + new UploadConversionAdjustmentsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + ConversionAdjustments = { gax::GaxPreconditions.CheckNotNull(conversionAdjustments, nameof(conversionAdjustments)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Processes the given conversion adjustments. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversion adjustments that are being uploaded. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadConversionAdjustmentsAsync( + string customerId, + scg::IEnumerable conversionAdjustments, + gaxgrpc::CallSettings callSettings = null) => UploadConversionAdjustmentsAsync( + new UploadConversionAdjustmentsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + ConversionAdjustments = { gax::GaxPreconditions.CheckNotNull(conversionAdjustments, nameof(conversionAdjustments)) }, + }, + callSettings); + + /// + /// Processes the given conversion adjustments. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversion adjustments that are being uploaded. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadConversionAdjustmentsAsync( + string customerId, + scg::IEnumerable conversionAdjustments, + st::CancellationToken cancellationToken) => UploadConversionAdjustmentsAsync( + customerId, + conversionAdjustments, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given conversion adjustments. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversion adjustments that are being uploaded. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadConversionAdjustmentsResponse UploadConversionAdjustments( + string customerId, + scg::IEnumerable conversionAdjustments, + gaxgrpc::CallSettings callSettings = null) => UploadConversionAdjustments( + new UploadConversionAdjustmentsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + ConversionAdjustments = { gax::GaxPreconditions.CheckNotNull(conversionAdjustments, nameof(conversionAdjustments)) }, + }, + callSettings); + + /// + /// Processes the given conversion adjustments. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadConversionAdjustmentsAsync( + UploadConversionAdjustmentsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Processes the given conversion adjustments. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadConversionAdjustmentsAsync( + UploadConversionAdjustmentsRequest request, + st::CancellationToken cancellationToken) => UploadConversionAdjustmentsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given conversion adjustments. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadConversionAdjustmentsResponse UploadConversionAdjustments( + UploadConversionAdjustmentsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// ConversionAdjustmentUploadService client wrapper implementation, for convenient use. + /// + public sealed partial class ConversionAdjustmentUploadServiceClientImpl : ConversionAdjustmentUploadServiceClient + { + private readonly gaxgrpc::ApiCall _callUploadConversionAdjustments; + + /// + /// Constructs a client wrapper for the ConversionAdjustmentUploadService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public ConversionAdjustmentUploadServiceClientImpl(ConversionAdjustmentUploadService.ConversionAdjustmentUploadServiceClient grpcClient, ConversionAdjustmentUploadServiceSettings settings) + { + GrpcClient = grpcClient; + ConversionAdjustmentUploadServiceSettings effectiveSettings = settings ?? ConversionAdjustmentUploadServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callUploadConversionAdjustments = clientHelper.BuildApiCall( + GrpcClient.UploadConversionAdjustmentsAsync, GrpcClient.UploadConversionAdjustments, effectiveSettings.UploadConversionAdjustmentsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callUploadConversionAdjustments); + Modify_UploadConversionAdjustmentsApiCall(ref _callUploadConversionAdjustments); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_UploadConversionAdjustmentsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(ConversionAdjustmentUploadService.ConversionAdjustmentUploadServiceClient grpcClient, ConversionAdjustmentUploadServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC ConversionAdjustmentUploadService client. + /// + public override ConversionAdjustmentUploadService.ConversionAdjustmentUploadServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_UploadConversionAdjustmentsRequest(ref UploadConversionAdjustmentsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Processes the given conversion adjustments. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task UploadConversionAdjustmentsAsync( + UploadConversionAdjustmentsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_UploadConversionAdjustmentsRequest(ref request, ref callSettings); + return _callUploadConversionAdjustments.Async(request, callSettings); + } + + /// + /// Processes the given conversion adjustments. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override UploadConversionAdjustmentsResponse UploadConversionAdjustments( + UploadConversionAdjustmentsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_UploadConversionAdjustmentsRequest(ref request, ref callSettings); + return _callUploadConversionAdjustments.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/ConversionAdjustmentUploadServiceGrpc.cs b/src/V3/Stubs/ConversionAdjustmentUploadServiceGrpc.cs new file mode 100644 index 000000000..24e912e97 --- /dev/null +++ b/src/V3/Stubs/ConversionAdjustmentUploadServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/conversion_adjustment_upload_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to upload conversion adjustments. + /// + public static partial class ConversionAdjustmentUploadService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.ConversionAdjustmentUploadService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_UploadConversionAdjustmentsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_UploadConversionAdjustmentsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_UploadConversionAdjustments = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "UploadConversionAdjustments", + __Marshaller_google_ads_googleads_v3_services_UploadConversionAdjustmentsRequest, + __Marshaller_google_ads_googleads_v3_services_UploadConversionAdjustmentsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionAdjustmentUploadServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of ConversionAdjustmentUploadService + public abstract partial class ConversionAdjustmentUploadServiceBase + { + /// + /// Processes the given conversion adjustments. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task UploadConversionAdjustments(global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for ConversionAdjustmentUploadService + public partial class ConversionAdjustmentUploadServiceClient : grpc::ClientBase + { + /// Creates a new client for ConversionAdjustmentUploadService + /// The channel to use to make remote calls. + public ConversionAdjustmentUploadServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for ConversionAdjustmentUploadService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public ConversionAdjustmentUploadServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected ConversionAdjustmentUploadServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected ConversionAdjustmentUploadServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Processes the given conversion adjustments. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsResponse UploadConversionAdjustments(global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return UploadConversionAdjustments(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Processes the given conversion adjustments. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsResponse UploadConversionAdjustments(global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_UploadConversionAdjustments, null, options, request); + } + /// + /// Processes the given conversion adjustments. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall UploadConversionAdjustmentsAsync(global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return UploadConversionAdjustmentsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Processes the given conversion adjustments. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall UploadConversionAdjustmentsAsync(global::Google.Ads.GoogleAds.V3.Services.UploadConversionAdjustmentsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_UploadConversionAdjustments, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override ConversionAdjustmentUploadServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new ConversionAdjustmentUploadServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(ConversionAdjustmentUploadServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_UploadConversionAdjustments, serviceImpl.UploadConversionAdjustments).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, ConversionAdjustmentUploadServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_UploadConversionAdjustments, serviceImpl.UploadConversionAdjustments); + } + + } +} +#endregion diff --git a/src/V3/Stubs/ConversionAttributionEventType.cs b/src/V3/Stubs/ConversionAttributionEventType.cs new file mode 100644 index 000000000..75e687e34 --- /dev/null +++ b/src/V3/Stubs/ConversionAttributionEventType.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/conversion_attribution_event_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/conversion_attribution_event_type.proto + public static partial class ConversionAttributionEventTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/conversion_attribution_event_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionAttributionEventTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb252ZXJzaW9uX2F0", + "dHJpYnV0aW9uX2V2ZW50X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIoUB", + "CiJDb252ZXJzaW9uQXR0cmlidXRpb25FdmVudFR5cGVFbnVtIl8KHkNvbnZl", + "cnNpb25BdHRyaWJ1dGlvbkV2ZW50VHlwZRIPCgtVTlNQRUNJRklFRBAAEgsK", + "B1VOS05PV04QARIOCgpJTVBSRVNTSU9OEAISDwoLSU5URVJBQ1RJT04QA0L4", + "AQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQiNDb252ZXJz", + "aW9uQXR0cmlidXRpb25FdmVudFR5cGVQcm90b1ABWkJnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVt", + "c8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionAttributionEventTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.ConversionAttributionEventTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionAttributionEventTypeEnum.Types.ConversionAttributionEventType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum indicating the event type the conversion is attributed to. + /// + public sealed partial class ConversionAttributionEventTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionAttributionEventTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ConversionAttributionEventTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAttributionEventTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAttributionEventTypeEnum(ConversionAttributionEventTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionAttributionEventTypeEnum Clone() { + return new ConversionAttributionEventTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionAttributionEventTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionAttributionEventTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionAttributionEventTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionAttributionEventTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The event type of conversions that are attributed to. + /// + public enum ConversionAttributionEventType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The conversion is attributed to an impression. + /// + [pbr::OriginalName("IMPRESSION")] Impression = 2, + /// + /// The conversion is attributed to an interaction. + /// + [pbr::OriginalName("INTERACTION")] Interaction = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionLagBucket.cs b/src/V3/Stubs/ConversionLagBucket.cs new file mode 100644 index 000000000..96f806bd1 --- /dev/null +++ b/src/V3/Stubs/ConversionLagBucket.cs @@ -0,0 +1,281 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/conversion_lag_bucket.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/conversion_lag_bucket.proto + public static partial class ConversionLagBucketReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/conversion_lag_bucket.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionLagBucketReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb252ZXJzaW9uX2xh", + "Z19idWNrZXQucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIrsEChdDb252ZXJzaW9u", + "TGFnQnVja2V0RW51bSKfBAoTQ29udmVyc2lvbkxhZ0J1Y2tldBIPCgtVTlNQ", + "RUNJRklFRBAAEgsKB1VOS05PV04QARIVChFMRVNTX1RIQU5fT05FX0RBWRAC", + "EhMKD09ORV9UT19UV09fREFZUxADEhUKEVRXT19UT19USFJFRV9EQVlTEAQS", + "FgoSVEhSRUVfVE9fRk9VUl9EQVlTEAUSFQoRRk9VUl9UT19GSVZFX0RBWVMQ", + "BhIUChBGSVZFX1RPX1NJWF9EQVlTEAcSFQoRU0lYX1RPX1NFVkVOX0RBWVMQ", + "CBIXChNTRVZFTl9UT19FSUdIVF9EQVlTEAkSFgoSRUlHSFRfVE9fTklORV9E", + "QVlTEAoSFAoQTklORV9UT19URU5fREFZUxALEhYKElRFTl9UT19FTEVWRU5f", + "REFZUxAMEhkKFUVMRVZFTl9UT19UV0VMVkVfREFZUxANEhsKF1RXRUxWRV9U", + "T19USElSVEVFTl9EQVlTEA4SHQoZVEhJUlRFRU5fVE9fRk9VUlRFRU5fREFZ", + "UxAPEh8KG0ZPVVJURUVOX1RPX1RXRU5UWV9PTkVfREFZUxAQEh0KGVRXRU5U", + "WV9PTkVfVE9fVEhJUlRZX0RBWVMQERIdChlUSElSVFlfVE9fRk9SVFlfRklW", + "RV9EQVlTEBISHAoYRk9SVFlfRklWRV9UT19TSVhUWV9EQVlTEBMSGAoUU0lY", + "VFlfVE9fTklORVRZX0RBWVMQFELtAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zQhhDb252ZXJzaW9uTGFnQnVja2V0UHJvdG9QAVpCZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVB", + "ZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oC", + "IUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionLagBucketEnum), global::Google.Ads.GoogleAds.V3.Enums.ConversionLagBucketEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionLagBucketEnum.Types.ConversionLagBucket) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum representing the number of days between impression and + /// conversion. + /// + public sealed partial class ConversionLagBucketEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionLagBucketEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ConversionLagBucketReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionLagBucketEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionLagBucketEnum(ConversionLagBucketEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionLagBucketEnum Clone() { + return new ConversionLagBucketEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionLagBucketEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionLagBucketEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionLagBucketEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionLagBucketEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum representing the number of days between impression and conversion. + /// + public enum ConversionLagBucket { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Conversion lag bucket from 0 to 1 day. 0 day is included, 1 day is not. + /// + [pbr::OriginalName("LESS_THAN_ONE_DAY")] LessThanOneDay = 2, + /// + /// Conversion lag bucket from 1 to 2 days. 1 day is included, 2 days is not. + /// + [pbr::OriginalName("ONE_TO_TWO_DAYS")] OneToTwoDays = 3, + /// + /// Conversion lag bucket from 2 to 3 days. 2 days is included, + /// 3 days is not. + /// + [pbr::OriginalName("TWO_TO_THREE_DAYS")] TwoToThreeDays = 4, + /// + /// Conversion lag bucket from 3 to 4 days. 3 days is included, + /// 4 days is not. + /// + [pbr::OriginalName("THREE_TO_FOUR_DAYS")] ThreeToFourDays = 5, + /// + /// Conversion lag bucket from 4 to 5 days. 4 days is included, + /// 5 days is not. + /// + [pbr::OriginalName("FOUR_TO_FIVE_DAYS")] FourToFiveDays = 6, + /// + /// Conversion lag bucket from 5 to 6 days. 5 days is included, + /// 6 days is not. + /// + [pbr::OriginalName("FIVE_TO_SIX_DAYS")] FiveToSixDays = 7, + /// + /// Conversion lag bucket from 6 to 7 days. 6 days is included, + /// 7 days is not. + /// + [pbr::OriginalName("SIX_TO_SEVEN_DAYS")] SixToSevenDays = 8, + /// + /// Conversion lag bucket from 7 to 8 days. 7 days is included, + /// 8 days is not. + /// + [pbr::OriginalName("SEVEN_TO_EIGHT_DAYS")] SevenToEightDays = 9, + /// + /// Conversion lag bucket from 8 to 9 days. 8 days is included, + /// 9 days is not. + /// + [pbr::OriginalName("EIGHT_TO_NINE_DAYS")] EightToNineDays = 10, + /// + /// Conversion lag bucket from 9 to 10 days. 9 days is included, + /// 10 days is not. + /// + [pbr::OriginalName("NINE_TO_TEN_DAYS")] NineToTenDays = 11, + /// + /// Conversion lag bucket from 10 to 11 days. 10 days is included, + /// 11 days is not. + /// + [pbr::OriginalName("TEN_TO_ELEVEN_DAYS")] TenToElevenDays = 12, + /// + /// Conversion lag bucket from 11 to 12 days. 11 days is included, + /// 12 days is not. + /// + [pbr::OriginalName("ELEVEN_TO_TWELVE_DAYS")] ElevenToTwelveDays = 13, + /// + /// Conversion lag bucket from 12 to 13 days. 12 days is included, + /// 13 days is not. + /// + [pbr::OriginalName("TWELVE_TO_THIRTEEN_DAYS")] TwelveToThirteenDays = 14, + /// + /// Conversion lag bucket from 13 to 14 days. 13 days is included, + /// 14 days is not. + /// + [pbr::OriginalName("THIRTEEN_TO_FOURTEEN_DAYS")] ThirteenToFourteenDays = 15, + /// + /// Conversion lag bucket from 14 to 21 days. 14 days is included, + /// 21 days is not. + /// + [pbr::OriginalName("FOURTEEN_TO_TWENTY_ONE_DAYS")] FourteenToTwentyOneDays = 16, + /// + /// Conversion lag bucket from 21 to 30 days. 21 days is included, + /// 30 days is not. + /// + [pbr::OriginalName("TWENTY_ONE_TO_THIRTY_DAYS")] TwentyOneToThirtyDays = 17, + /// + /// Conversion lag bucket from 30 to 45 days. 30 days is included, + /// 45 days is not. + /// + [pbr::OriginalName("THIRTY_TO_FORTY_FIVE_DAYS")] ThirtyToFortyFiveDays = 18, + /// + /// Conversion lag bucket from 45 to 60 days. 45 days is included, + /// 60 days is not. + /// + [pbr::OriginalName("FORTY_FIVE_TO_SIXTY_DAYS")] FortyFiveToSixtyDays = 19, + /// + /// Conversion lag bucket from 60 to 90 days. 60 days is included, + /// 90 days is not. + /// + [pbr::OriginalName("SIXTY_TO_NINETY_DAYS")] SixtyToNinetyDays = 20, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionOrAdjustmentLagBucket.cs b/src/V3/Stubs/ConversionOrAdjustmentLagBucket.cs new file mode 100644 index 000000000..277698f36 --- /dev/null +++ b/src/V3/Stubs/ConversionOrAdjustmentLagBucket.cs @@ -0,0 +1,416 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/conversion_or_adjustment_lag_bucket.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/conversion_or_adjustment_lag_bucket.proto + public static partial class ConversionOrAdjustmentLagBucketReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/conversion_or_adjustment_lag_bucket.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionOrAdjustmentLagBucketReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jb252ZXJzaW9uX29y", + "X2FkanVzdG1lbnRfbGFnX2J1Y2tldC5wcm90bxIdZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i", + "ywwKI0NvbnZlcnNpb25PckFkanVzdG1lbnRMYWdCdWNrZXRFbnVtIqMMCh9D", + "b252ZXJzaW9uT3JBZGp1c3RtZW50TGFnQnVja2V0Eg8KC1VOU1BFQ0lGSUVE", + "EAASCwoHVU5LTk9XThABEiAKHENPTlZFUlNJT05fTEVTU19USEFOX09ORV9E", + "QVkQAhIeChpDT05WRVJTSU9OX09ORV9UT19UV09fREFZUxADEiAKHENPTlZF", + "UlNJT05fVFdPX1RPX1RIUkVFX0RBWVMQBBIhCh1DT05WRVJTSU9OX1RIUkVF", + "X1RPX0ZPVVJfREFZUxAFEiAKHENPTlZFUlNJT05fRk9VUl9UT19GSVZFX0RB", + "WVMQBhIfChtDT05WRVJTSU9OX0ZJVkVfVE9fU0lYX0RBWVMQBxIgChxDT05W", + "RVJTSU9OX1NJWF9UT19TRVZFTl9EQVlTEAgSIgoeQ09OVkVSU0lPTl9TRVZF", + "Tl9UT19FSUdIVF9EQVlTEAkSIQodQ09OVkVSU0lPTl9FSUdIVF9UT19OSU5F", + "X0RBWVMQChIfChtDT05WRVJTSU9OX05JTkVfVE9fVEVOX0RBWVMQCxIhCh1D", + "T05WRVJTSU9OX1RFTl9UT19FTEVWRU5fREFZUxAMEiQKIENPTlZFUlNJT05f", + "RUxFVkVOX1RPX1RXRUxWRV9EQVlTEA0SJgoiQ09OVkVSU0lPTl9UV0VMVkVf", + "VE9fVEhJUlRFRU5fREFZUxAOEigKJENPTlZFUlNJT05fVEhJUlRFRU5fVE9f", + "Rk9VUlRFRU5fREFZUxAPEioKJkNPTlZFUlNJT05fRk9VUlRFRU5fVE9fVFdF", + "TlRZX09ORV9EQVlTEBASKAokQ09OVkVSU0lPTl9UV0VOVFlfT05FX1RPX1RI", + "SVJUWV9EQVlTEBESKAokQ09OVkVSU0lPTl9USElSVFlfVE9fRk9SVFlfRklW", + "RV9EQVlTEBISJwojQ09OVkVSU0lPTl9GT1JUWV9GSVZFX1RPX1NJWFRZX0RB", + "WVMQExIjCh9DT05WRVJTSU9OX1NJWFRZX1RPX05JTkVUWV9EQVlTEBQSIAoc", + "QURKVVNUTUVOVF9MRVNTX1RIQU5fT05FX0RBWRAVEh4KGkFESlVTVE1FTlRf", + "T05FX1RPX1RXT19EQVlTEBYSIAocQURKVVNUTUVOVF9UV09fVE9fVEhSRUVf", + "REFZUxAXEiEKHUFESlVTVE1FTlRfVEhSRUVfVE9fRk9VUl9EQVlTEBgSIAoc", + "QURKVVNUTUVOVF9GT1VSX1RPX0ZJVkVfREFZUxAZEh8KG0FESlVTVE1FTlRf", + "RklWRV9UT19TSVhfREFZUxAaEiAKHEFESlVTVE1FTlRfU0lYX1RPX1NFVkVO", + "X0RBWVMQGxIiCh5BREpVU1RNRU5UX1NFVkVOX1RPX0VJR0hUX0RBWVMQHBIh", + "Ch1BREpVU1RNRU5UX0VJR0hUX1RPX05JTkVfREFZUxAdEh8KG0FESlVTVE1F", + "TlRfTklORV9UT19URU5fREFZUxAeEiEKHUFESlVTVE1FTlRfVEVOX1RPX0VM", + "RVZFTl9EQVlTEB8SJAogQURKVVNUTUVOVF9FTEVWRU5fVE9fVFdFTFZFX0RB", + "WVMQIBImCiJBREpVU1RNRU5UX1RXRUxWRV9UT19USElSVEVFTl9EQVlTECES", + "KAokQURKVVNUTUVOVF9USElSVEVFTl9UT19GT1VSVEVFTl9EQVlTECISKgom", + "QURKVVNUTUVOVF9GT1VSVEVFTl9UT19UV0VOVFlfT05FX0RBWVMQIxIoCiRB", + "REpVU1RNRU5UX1RXRU5UWV9PTkVfVE9fVEhJUlRZX0RBWVMQJBIoCiRBREpV", + "U1RNRU5UX1RISVJUWV9UT19GT1JUWV9GSVZFX0RBWVMQJRInCiNBREpVU1RN", + "RU5UX0ZPUlRZX0ZJVkVfVE9fU0lYVFlfREFZUxAmEiMKH0FESlVTVE1FTlRf", + "U0lYVFlfVE9fTklORVRZX0RBWVMQJxI4CjRBREpVU1RNRU5UX05JTkVUWV9U", + "T19PTkVfSFVORFJFRF9BTkRfRk9SVFlfRklWRV9EQVlTECgSFgoSQ09OVkVS", + "U0lPTl9VTktOT1dOECkSFgoSQURKVVNUTUVOVF9VTktOT1dOECpC+QEKIWNv", + "bS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IkQ29udmVyc2lvbk9y", + "QWRqdXN0bWVudExhZ0J1Y2tldFByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztl", + "bnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygId", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionOrAdjustmentLagBucketEnum), global::Google.Ads.GoogleAds.V3.Enums.ConversionOrAdjustmentLagBucketEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ConversionOrAdjustmentLagBucketEnum.Types.ConversionOrAdjustmentLagBucket) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum representing the number of days between the impression and + /// the conversion or between the impression and adjustments to the conversion. + /// + public sealed partial class ConversionOrAdjustmentLagBucketEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionOrAdjustmentLagBucketEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ConversionOrAdjustmentLagBucketReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionOrAdjustmentLagBucketEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionOrAdjustmentLagBucketEnum(ConversionOrAdjustmentLagBucketEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionOrAdjustmentLagBucketEnum Clone() { + return new ConversionOrAdjustmentLagBucketEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionOrAdjustmentLagBucketEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionOrAdjustmentLagBucketEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionOrAdjustmentLagBucketEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionOrAdjustmentLagBucketEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum representing the number of days between the impression and the + /// conversion or between the impression and adjustments to the conversion. + /// + public enum ConversionOrAdjustmentLagBucket { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Conversion lag bucket from 0 to 1 day. 0 day is included, 1 day is not. + /// + [pbr::OriginalName("CONVERSION_LESS_THAN_ONE_DAY")] ConversionLessThanOneDay = 2, + /// + /// Conversion lag bucket from 1 to 2 days. 1 day is included, 2 days is not. + /// + [pbr::OriginalName("CONVERSION_ONE_TO_TWO_DAYS")] ConversionOneToTwoDays = 3, + /// + /// Conversion lag bucket from 2 to 3 days. 2 days is included, + /// 3 days is not. + /// + [pbr::OriginalName("CONVERSION_TWO_TO_THREE_DAYS")] ConversionTwoToThreeDays = 4, + /// + /// Conversion lag bucket from 3 to 4 days. 3 days is included, + /// 4 days is not. + /// + [pbr::OriginalName("CONVERSION_THREE_TO_FOUR_DAYS")] ConversionThreeToFourDays = 5, + /// + /// Conversion lag bucket from 4 to 5 days. 4 days is included, + /// 5 days is not. + /// + [pbr::OriginalName("CONVERSION_FOUR_TO_FIVE_DAYS")] ConversionFourToFiveDays = 6, + /// + /// Conversion lag bucket from 5 to 6 days. 5 days is included, + /// 6 days is not. + /// + [pbr::OriginalName("CONVERSION_FIVE_TO_SIX_DAYS")] ConversionFiveToSixDays = 7, + /// + /// Conversion lag bucket from 6 to 7 days. 6 days is included, + /// 7 days is not. + /// + [pbr::OriginalName("CONVERSION_SIX_TO_SEVEN_DAYS")] ConversionSixToSevenDays = 8, + /// + /// Conversion lag bucket from 7 to 8 days. 7 days is included, + /// 8 days is not. + /// + [pbr::OriginalName("CONVERSION_SEVEN_TO_EIGHT_DAYS")] ConversionSevenToEightDays = 9, + /// + /// Conversion lag bucket from 8 to 9 days. 8 days is included, + /// 9 days is not. + /// + [pbr::OriginalName("CONVERSION_EIGHT_TO_NINE_DAYS")] ConversionEightToNineDays = 10, + /// + /// Conversion lag bucket from 9 to 10 days. 9 days is included, + /// 10 days is not. + /// + [pbr::OriginalName("CONVERSION_NINE_TO_TEN_DAYS")] ConversionNineToTenDays = 11, + /// + /// Conversion lag bucket from 10 to 11 days. 10 days is included, + /// 11 days is not. + /// + [pbr::OriginalName("CONVERSION_TEN_TO_ELEVEN_DAYS")] ConversionTenToElevenDays = 12, + /// + /// Conversion lag bucket from 11 to 12 days. 11 days is included, + /// 12 days is not. + /// + [pbr::OriginalName("CONVERSION_ELEVEN_TO_TWELVE_DAYS")] ConversionElevenToTwelveDays = 13, + /// + /// Conversion lag bucket from 12 to 13 days. 12 days is included, + /// 13 days is not. + /// + [pbr::OriginalName("CONVERSION_TWELVE_TO_THIRTEEN_DAYS")] ConversionTwelveToThirteenDays = 14, + /// + /// Conversion lag bucket from 13 to 14 days. 13 days is included, + /// 14 days is not. + /// + [pbr::OriginalName("CONVERSION_THIRTEEN_TO_FOURTEEN_DAYS")] ConversionThirteenToFourteenDays = 15, + /// + /// Conversion lag bucket from 14 to 21 days. 14 days is included, + /// 21 days is not. + /// + [pbr::OriginalName("CONVERSION_FOURTEEN_TO_TWENTY_ONE_DAYS")] ConversionFourteenToTwentyOneDays = 16, + /// + /// Conversion lag bucket from 21 to 30 days. 21 days is included, + /// 30 days is not. + /// + [pbr::OriginalName("CONVERSION_TWENTY_ONE_TO_THIRTY_DAYS")] ConversionTwentyOneToThirtyDays = 17, + /// + /// Conversion lag bucket from 30 to 45 days. 30 days is included, + /// 45 days is not. + /// + [pbr::OriginalName("CONVERSION_THIRTY_TO_FORTY_FIVE_DAYS")] ConversionThirtyToFortyFiveDays = 18, + /// + /// Conversion lag bucket from 45 to 60 days. 45 days is included, + /// 60 days is not. + /// + [pbr::OriginalName("CONVERSION_FORTY_FIVE_TO_SIXTY_DAYS")] ConversionFortyFiveToSixtyDays = 19, + /// + /// Conversion lag bucket from 60 to 90 days. 60 days is included, + /// 90 days is not. + /// + [pbr::OriginalName("CONVERSION_SIXTY_TO_NINETY_DAYS")] ConversionSixtyToNinetyDays = 20, + /// + /// Conversion adjustment lag bucket from 0 to 1 day. 0 day is included, + /// 1 day is not. + /// + [pbr::OriginalName("ADJUSTMENT_LESS_THAN_ONE_DAY")] AdjustmentLessThanOneDay = 21, + /// + /// Conversion adjustment lag bucket from 1 to 2 days. 1 day is included, + /// 2 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_ONE_TO_TWO_DAYS")] AdjustmentOneToTwoDays = 22, + /// + /// Conversion adjustment lag bucket from 2 to 3 days. 2 days is included, + /// 3 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_TWO_TO_THREE_DAYS")] AdjustmentTwoToThreeDays = 23, + /// + /// Conversion adjustment lag bucket from 3 to 4 days. 3 days is included, + /// 4 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_THREE_TO_FOUR_DAYS")] AdjustmentThreeToFourDays = 24, + /// + /// Conversion adjustment lag bucket from 4 to 5 days. 4 days is included, + /// 5 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_FOUR_TO_FIVE_DAYS")] AdjustmentFourToFiveDays = 25, + /// + /// Conversion adjustment lag bucket from 5 to 6 days. 5 days is included, + /// 6 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_FIVE_TO_SIX_DAYS")] AdjustmentFiveToSixDays = 26, + /// + /// Conversion adjustment lag bucket from 6 to 7 days. 6 days is included, + /// 7 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_SIX_TO_SEVEN_DAYS")] AdjustmentSixToSevenDays = 27, + /// + /// Conversion adjustment lag bucket from 7 to 8 days. 7 days is included, + /// 8 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_SEVEN_TO_EIGHT_DAYS")] AdjustmentSevenToEightDays = 28, + /// + /// Conversion adjustment lag bucket from 8 to 9 days. 8 days is included, + /// 9 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_EIGHT_TO_NINE_DAYS")] AdjustmentEightToNineDays = 29, + /// + /// Conversion adjustment lag bucket from 9 to 10 days. 9 days is included, + /// 10 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_NINE_TO_TEN_DAYS")] AdjustmentNineToTenDays = 30, + /// + /// Conversion adjustment lag bucket from 10 to 11 days. 10 days is included, + /// 11 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_TEN_TO_ELEVEN_DAYS")] AdjustmentTenToElevenDays = 31, + /// + /// Conversion adjustment lag bucket from 11 to 12 days. 11 days is included, + /// 12 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_ELEVEN_TO_TWELVE_DAYS")] AdjustmentElevenToTwelveDays = 32, + /// + /// Conversion adjustment lag bucket from 12 to 13 days. 12 days is included, + /// 13 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_TWELVE_TO_THIRTEEN_DAYS")] AdjustmentTwelveToThirteenDays = 33, + /// + /// Conversion adjustment lag bucket from 13 to 14 days. 13 days is included, + /// 14 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_THIRTEEN_TO_FOURTEEN_DAYS")] AdjustmentThirteenToFourteenDays = 34, + /// + /// Conversion adjustment lag bucket from 14 to 21 days. 14 days is included, + /// 21 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_FOURTEEN_TO_TWENTY_ONE_DAYS")] AdjustmentFourteenToTwentyOneDays = 35, + /// + /// Conversion adjustment lag bucket from 21 to 30 days. 21 days is included, + /// 30 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_TWENTY_ONE_TO_THIRTY_DAYS")] AdjustmentTwentyOneToThirtyDays = 36, + /// + /// Conversion adjustment lag bucket from 30 to 45 days. 30 days is included, + /// 45 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_THIRTY_TO_FORTY_FIVE_DAYS")] AdjustmentThirtyToFortyFiveDays = 37, + /// + /// Conversion adjustment lag bucket from 45 to 60 days. 45 days is included, + /// 60 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_FORTY_FIVE_TO_SIXTY_DAYS")] AdjustmentFortyFiveToSixtyDays = 38, + /// + /// Conversion adjustment lag bucket from 60 to 90 days. 60 days is included, + /// 90 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_SIXTY_TO_NINETY_DAYS")] AdjustmentSixtyToNinetyDays = 39, + /// + /// Conversion adjustment lag bucket from 90 to 145 days. 90 days is + /// included, 145 days is not. + /// + [pbr::OriginalName("ADJUSTMENT_NINETY_TO_ONE_HUNDRED_AND_FORTY_FIVE_DAYS")] AdjustmentNinetyToOneHundredAndFortyFiveDays = 40, + /// + /// Conversion lag bucket UNKNOWN. This is for dates before conversion lag + /// bucket was available in Google Ads. + /// + [pbr::OriginalName("CONVERSION_UNKNOWN")] ConversionUnknown = 41, + /// + /// Conversion adjustment lag bucket UNKNOWN. This is for dates before + /// conversion adjustment lag bucket was available in Google Ads. + /// + [pbr::OriginalName("ADJUSTMENT_UNKNOWN")] AdjustmentUnknown = 42, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionUploadError.cs b/src/V3/Stubs/ConversionUploadError.cs new file mode 100644 index 000000000..44b9279c4 --- /dev/null +++ b/src/V3/Stubs/ConversionUploadError.cs @@ -0,0 +1,301 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/conversion_upload_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/conversion_upload_error.proto + public static partial class ConversionUploadErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/conversion_upload_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionUploadErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY29udmVyc2lvbl91", + "cGxvYWRfZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLUBgoZQ29udmVy", + "c2lvblVwbG9hZEVycm9yRW51bSK2BgoVQ29udmVyc2lvblVwbG9hZEVycm9y", + "Eg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEiMKH1RPT19NQU5ZX0NP", + "TlZFUlNJT05TX0lOX1JFUVVFU1QQAhIVChFVTlBBUlNFQUJMRV9HQ0xJRBAD", + "Eh0KGUNPTlZFUlNJT05fUFJFQ0VERVNfR0NMSUQQBBIRCg1FWFBJUkVEX0dD", + "TElEEAUSFAoQVE9PX1JFQ0VOVF9HQ0xJRBAGEhMKD0dDTElEX05PVF9GT1VO", + "RBAHEhkKFVVOQVVUSE9SSVpFRF9DVVNUT01FUhAIEh0KGUlOVkFMSURfQ09O", + "VkVSU0lPTl9BQ1RJT04QCRIgChxUT09fUkVDRU5UX0NPTlZFUlNJT05fQUNU", + "SU9OEAoSNgoyQ09OVkVSU0lPTl9UUkFDS0lOR19OT1RfRU5BQkxFRF9BVF9J", + "TVBSRVNTSU9OX1RJTUUQCxJRCk1FWFRFUk5BTF9BVFRSSUJVVElPTl9EQVRB", + "X1NFVF9GT1JfTk9OX0VYVEVSTkFMTFlfQVRUUklCVVRFRF9DT05WRVJTSU9O", + "X0FDVElPThAMElEKTUVYVEVSTkFMX0FUVFJJQlVUSU9OX0RBVEFfTk9UX1NF", + "VF9GT1JfRVhURVJOQUxMWV9BVFRSSUJVVEVEX0NPTlZFUlNJT05fQUNUSU9O", + "EA0SRgpCT1JERVJfSURfTk9UX1BFUk1JVFRFRF9GT1JfRVhURVJOQUxMWV9B", + "VFRSSUJVVEVEX0NPTlZFUlNJT05fQUNUSU9OEA4SGwoXT1JERVJfSURfQUxS", + "RUFEWV9JTl9VU0UQDxIWChJEVVBMSUNBVEVfT1JERVJfSUQQEBITCg9UT09f", + "UkVDRU5UX0NBTEwQERIQCgxFWFBJUkVEX0NBTEwQEhISCg5DQUxMX05PVF9G", + "T1VORBATEhwKGENPTlZFUlNJT05fUFJFQ0VERVNfQ0FMTBAUEjAKLENPTlZF", + "UlNJT05fVFJBQ0tJTkdfTk9UX0VOQUJMRURfQVRfQ0FMTF9USU1FEBUSJAog", + "VU5QQVJTRUFCTEVfQ0FMTEVSU19QSE9ORV9OVU1CRVIQFkL1AQoiY29tLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IaQ29udmVyc2lvblVwbG9h", + "ZEVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGq", + "Ah5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRz", + "XEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ConversionUploadErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.ConversionUploadErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.ConversionUploadErrorEnum.Types.ConversionUploadError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible conversion upload errors. + /// + public sealed partial class ConversionUploadErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionUploadErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ConversionUploadErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionUploadErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionUploadErrorEnum(ConversionUploadErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionUploadErrorEnum Clone() { + return new ConversionUploadErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionUploadErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionUploadErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionUploadErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ConversionUploadErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible conversion upload errors. + /// + public enum ConversionUploadError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The request contained more than 2000 conversions. + /// + [pbr::OriginalName("TOO_MANY_CONVERSIONS_IN_REQUEST")] TooManyConversionsInRequest = 2, + /// + /// The specified gclid could not be decoded. + /// + [pbr::OriginalName("UNPARSEABLE_GCLID")] UnparseableGclid = 3, + /// + /// The specified conversion_date_time is before the event time + /// associated with the given gclid. + /// + [pbr::OriginalName("CONVERSION_PRECEDES_GCLID")] ConversionPrecedesGclid = 4, + /// + /// The click associated with the given gclid is either too old to be + /// imported or occurred outside of the click through lookback window for the + /// specified conversion action. + /// + [pbr::OriginalName("EXPIRED_GCLID")] ExpiredGclid = 5, + /// + /// The click associated with the given gclid occurred too recently. Please + /// try uploading again after 6 hours have passed since the click occurred. + /// + [pbr::OriginalName("TOO_RECENT_GCLID")] TooRecentGclid = 6, + /// + /// The click associated with the given gclid could not be found in the + /// system. This can happen if Google Click IDs are collected for non Google + /// Ads clicks. + /// + [pbr::OriginalName("GCLID_NOT_FOUND")] GclidNotFound = 7, + /// + /// The click associated with the given gclid is owned by a customer + /// account that the uploading customer does not manage. + /// + [pbr::OriginalName("UNAUTHORIZED_CUSTOMER")] UnauthorizedCustomer = 8, + /// + /// No upload eligible conversion action that matches the provided + /// information can be found for the customer. + /// + [pbr::OriginalName("INVALID_CONVERSION_ACTION")] InvalidConversionAction = 9, + /// + /// The specified conversion action was created too recently. + /// Please try the upload again after 4-6 hours have passed since the + /// conversion action was created. + /// + [pbr::OriginalName("TOO_RECENT_CONVERSION_ACTION")] TooRecentConversionAction = 10, + /// + /// The click associated with the given gclid does not contain conversion + /// tracking information. + /// + [pbr::OriginalName("CONVERSION_TRACKING_NOT_ENABLED_AT_IMPRESSION_TIME")] ConversionTrackingNotEnabledAtImpressionTime = 11, + /// + /// The specified conversion action does not use an external attribution + /// model, but external_attribution_data was set. + /// + [pbr::OriginalName("EXTERNAL_ATTRIBUTION_DATA_SET_FOR_NON_EXTERNALLY_ATTRIBUTED_CONVERSION_ACTION")] ExternalAttributionDataSetForNonExternallyAttributedConversionAction = 12, + /// + /// The specified conversion action uses an external attribution model, but + /// external_attribution_data or one of its contained fields was not set. + /// Both external_attribution_credit and external_attribution_model must be + /// set for externally attributed conversion actions. + /// + [pbr::OriginalName("EXTERNAL_ATTRIBUTION_DATA_NOT_SET_FOR_EXTERNALLY_ATTRIBUTED_CONVERSION_ACTION")] ExternalAttributionDataNotSetForExternallyAttributedConversionAction = 13, + /// + /// Order IDs are not supported for conversion actions which use an external + /// attribution model. + /// + [pbr::OriginalName("ORDER_ID_NOT_PERMITTED_FOR_EXTERNALLY_ATTRIBUTED_CONVERSION_ACTION")] OrderIdNotPermittedForExternallyAttributedConversionAction = 14, + /// + /// A conversion with the same order id and conversion action combination + /// already exists in our system. + /// + [pbr::OriginalName("ORDER_ID_ALREADY_IN_USE")] OrderIdAlreadyInUse = 15, + /// + /// The request contained two or more conversions with the same order id and + /// conversion action combination. + /// + [pbr::OriginalName("DUPLICATE_ORDER_ID")] DuplicateOrderId = 16, + /// + /// The call occurred too recently. Please try uploading again after 6 hours + /// have passed since the call occurred. + /// + [pbr::OriginalName("TOO_RECENT_CALL")] TooRecentCall = 17, + /// + /// The click that initiated the call is too old for this conversion to be + /// imported. + /// + [pbr::OriginalName("EXPIRED_CALL")] ExpiredCall = 18, + /// + /// The call or the click leading to the call was not found. + /// + [pbr::OriginalName("CALL_NOT_FOUND")] CallNotFound = 19, + /// + /// The specified conversion_date_time is before the call_start_date_time. + /// + [pbr::OriginalName("CONVERSION_PRECEDES_CALL")] ConversionPrecedesCall = 20, + /// + /// The click associated with the call does not contain conversion tracking + /// information. + /// + [pbr::OriginalName("CONVERSION_TRACKING_NOT_ENABLED_AT_CALL_TIME")] ConversionTrackingNotEnabledAtCallTime = 21, + /// + /// The caller’s phone number cannot be parsed. It should be formatted either + /// as E.164 "+16502531234", International "+64 3-331 6005" or US national + /// number "6502531234". + /// + [pbr::OriginalName("UNPARSEABLE_CALLERS_PHONE_NUMBER")] UnparseableCallersPhoneNumber = 22, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionUploadService.cs b/src/V3/Stubs/ConversionUploadService.cs new file mode 100644 index 000000000..f2962e46e --- /dev/null +++ b/src/V3/Stubs/ConversionUploadService.cs @@ -0,0 +1,2260 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/conversion_upload_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/conversion_upload_service.proto + public static partial class ConversionUploadServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/conversion_upload_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ConversionUploadServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jb252ZXJzaW9u", + "X3VwbG9hZF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90bxoXZ29v", + "Z2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZp", + "b3IucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxoXZ29v", + "Z2xlL3JwYy9zdGF0dXMucHJvdG8itgEKHVVwbG9hZENsaWNrQ29udmVyc2lv", + "bnNSZXF1ZXN0EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPgQQISSwoLY29udmVy", + "c2lvbnMYAiADKAsyMS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5DbGlja0NvbnZlcnNpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyAB", + "KAgSFQoNdmFsaWRhdGVfb25seRgEIAEoCCKdAQoeVXBsb2FkQ2xpY2tDb252", + "ZXJzaW9uc1Jlc3BvbnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJvchgBIAEo", + "CzISLmdvb2dsZS5ycGMuU3RhdHVzEkgKB3Jlc3VsdHMYAiADKAsyNy5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5DbGlja0NvbnZlcnNpb25S", + "ZXN1bHQitAEKHFVwbG9hZENhbGxDb252ZXJzaW9uc1JlcXVlc3QSGAoLY3Vz", + "dG9tZXJfaWQYASABKAlCA+BBAhJKCgtjb252ZXJzaW9ucxgCIAMoCzIwLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkNhbGxDb252ZXJzaW9u", + "QgPgQQISFwoPcGFydGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlkYXRlX29u", + "bHkYBCABKAgimwEKHVVwbG9hZENhbGxDb252ZXJzaW9uc1Jlc3BvbnNlEjEK", + "FXBhcnRpYWxfZmFpbHVyZV9lcnJvchgBIAEoCzISLmdvb2dsZS5ycGMuU3Rh", + "dHVzEkcKB3Jlc3VsdHMYAiADKAsyNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5DYWxsQ29udmVyc2lvblJlc3VsdCKuAwoPQ2xpY2tDb252", + "ZXJzaW9uEisKBWdjbGlkGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlEjcKEWNvbnZlcnNpb25fYWN0aW9uGAIgASgLMhwuZ29vZ2xlLnBy", + "b3RvYnVmLlN0cmluZ1ZhbHVlEjoKFGNvbnZlcnNpb25fZGF0ZV90aW1lGAMg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjYKEGNvbnZlcnNp", + "b25fdmFsdWUYBCABKAsyHC5nb29nbGUucHJvdG9idWYuRG91YmxlVmFsdWUS", + "MwoNY3VycmVuY3lfY29kZRgFIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZRIuCghvcmRlcl9pZBgGIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZRJcChlleHRlcm5hbF9hdHRyaWJ1dGlvbl9kYXRhGAcgASgL", + "MjkuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuRXh0ZXJuYWxB", + "dHRyaWJ1dGlvbkRhdGEi3wIKDkNhbGxDb252ZXJzaW9uEi8KCWNhbGxlcl9p", + "ZBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI6ChRjYWxs", + "X3N0YXJ0X2RhdGVfdGltZRgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZRI3ChFjb252ZXJzaW9uX2FjdGlvbhgDIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZRI6ChRjb252ZXJzaW9uX2RhdGVfdGltZRgE", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI2ChBjb252ZXJz", + "aW9uX3ZhbHVlGAUgASgLMhwuZ29vZ2xlLnByb3RvYnVmLkRvdWJsZVZhbHVl", + "EjMKDWN1cnJlbmN5X2NvZGUYBiABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWUingEKF0V4dGVybmFsQXR0cmlidXRpb25EYXRhEkEKG2V4dGVy", + "bmFsX2F0dHJpYnV0aW9uX2NyZWRpdBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5Eb3VibGVWYWx1ZRJAChpleHRlcm5hbF9hdHRyaWJ1dGlvbl9tb2RlbBgC", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSK5AQoVQ2xpY2tD", + "b252ZXJzaW9uUmVzdWx0EisKBWdjbGlkGAEgASgLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlEjcKEWNvbnZlcnNpb25fYWN0aW9uGAIgASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjoKFGNvbnZlcnNpb25fZGF0", + "ZV90aW1lGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlIvgB", + "ChRDYWxsQ29udmVyc2lvblJlc3VsdBIvCgljYWxsZXJfaWQYASABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSOgoUY2FsbF9zdGFydF9kYXRl", + "X3RpbWUYAiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSNwoR", + "Y29udmVyc2lvbl9hY3Rpb24YAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWUSOgoUY29udmVyc2lvbl9kYXRlX3RpbWUYBCABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWUypAQKF0NvbnZlcnNpb25VcGxvYWRT", + "ZXJ2aWNlEvYBChZVcGxvYWRDbGlja0NvbnZlcnNpb25zEj8uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuVXBsb2FkQ2xpY2tDb252ZXJzaW9u", + "c1JlcXVlc3QaQC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5V", + "cGxvYWRDbGlja0NvbnZlcnNpb25zUmVzcG9uc2UiWYLT5JMCOSI0L3YzL2N1", + "c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn06dXBsb2FkQ2xpY2tDb252ZXJzaW9u", + "czoBKtpBF2N1c3RvbWVyX2lkLGNvbnZlcnNpb25zEvIBChVVcGxvYWRDYWxs", + "Q29udmVyc2lvbnMSPi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5VcGxvYWRDYWxsQ29udmVyc2lvbnNSZXF1ZXN0Gj8uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuVXBsb2FkQ2FsbENvbnZlcnNpb25zUmVz", + "cG9uc2UiWILT5JMCOCIzL3YzL2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn06", + "dXBsb2FkQ2FsbENvbnZlcnNpb25zOgEq2kEXY3VzdG9tZXJfaWQsY29udmVy", + "c2lvbnMaG8pBGGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbUKDAgokY29tLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzQhxDb252ZXJzaW9uVXBs", + "b2FkU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3Rv", + "L2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNl", + "c6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIg", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFk", + "czo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsRequest), global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsRequest.Parser, new[]{ "CustomerId", "Conversions", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsResponse), global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsRequest), global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsRequest.Parser, new[]{ "CustomerId", "Conversions", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsResponse), global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ClickConversion), global::Google.Ads.GoogleAds.V3.Services.ClickConversion.Parser, new[]{ "Gclid", "ConversionAction", "ConversionDateTime", "ConversionValue", "CurrencyCode", "OrderId", "ExternalAttributionData" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CallConversion), global::Google.Ads.GoogleAds.V3.Services.CallConversion.Parser, new[]{ "CallerId", "CallStartDateTime", "ConversionAction", "ConversionDateTime", "ConversionValue", "CurrencyCode" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ExternalAttributionData), global::Google.Ads.GoogleAds.V3.Services.ExternalAttributionData.Parser, new[]{ "ExternalAttributionCredit", "ExternalAttributionModel" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ClickConversionResult), global::Google.Ads.GoogleAds.V3.Services.ClickConversionResult.Parser, new[]{ "Gclid", "ConversionAction", "ConversionDateTime" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CallConversionResult), global::Google.Ads.GoogleAds.V3.Services.CallConversionResult.Parser, new[]{ "CallerId", "CallStartDateTime", "ConversionAction", "ConversionDateTime" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [ConversionUploadService.UploadClickConversions][google.ads.googleads.v3.services.ConversionUploadService.UploadClickConversions]. + /// + public sealed partial class UploadClickConversionsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UploadClickConversionsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadClickConversionsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadClickConversionsRequest(UploadClickConversionsRequest other) : this() { + customerId_ = other.customerId_; + conversions_ = other.conversions_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadClickConversionsRequest Clone() { + return new UploadClickConversionsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer performing the upload. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "conversions" field. + public const int ConversionsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_conversions_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.ClickConversion.Parser); + private readonly pbc::RepeatedField conversions_ = new pbc::RepeatedField(); + /// + /// Required. The conversions that are being uploaded. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Conversions { + get { return conversions_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// This should always be set to true. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UploadClickConversionsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UploadClickConversionsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!conversions_.Equals(other.conversions_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= conversions_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + conversions_.WriteTo(output, _repeated_conversions_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += conversions_.CalculateSize(_repeated_conversions_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UploadClickConversionsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + conversions_.Add(other.conversions_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + conversions_.AddEntriesFrom(input, _repeated_conversions_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// Response message for [ConversionUploadService.UploadClickConversions][google.ads.googleads.v3.services.ConversionUploadService.UploadClickConversions]. + /// + public sealed partial class UploadClickConversionsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UploadClickConversionsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadClickConversionsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadClickConversionsResponse(UploadClickConversionsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadClickConversionsResponse Clone() { + return new UploadClickConversionsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 1; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to conversion failures in the partial failure mode. + /// Returned when all errors occur inside the conversions. If any errors occur + /// outside the conversions (e.g. auth errors), we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.ClickConversionResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// Returned for successfully processed conversions. Proto will be empty for + /// rows that received an error. Results are not returned when validate_only is + /// true. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UploadClickConversionsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UploadClickConversionsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (partialFailureError_ != null) { + output.WriteRawTag(10); + output.WriteMessage(PartialFailureError); + } + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UploadClickConversionsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// Request message for [ConversionUploadService.UploadCallConversions][google.ads.googleads.v3.services.ConversionUploadService.UploadCallConversions]. + /// + public sealed partial class UploadCallConversionsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UploadCallConversionsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadCallConversionsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadCallConversionsRequest(UploadCallConversionsRequest other) : this() { + customerId_ = other.customerId_; + conversions_ = other.conversions_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadCallConversionsRequest Clone() { + return new UploadCallConversionsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer performing the upload. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "conversions" field. + public const int ConversionsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_conversions_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CallConversion.Parser); + private readonly pbc::RepeatedField conversions_ = new pbc::RepeatedField(); + /// + /// Required. The conversions that are being uploaded. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Conversions { + get { return conversions_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// This should always be set to true. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UploadCallConversionsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UploadCallConversionsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!conversions_.Equals(other.conversions_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= conversions_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + conversions_.WriteTo(output, _repeated_conversions_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += conversions_.CalculateSize(_repeated_conversions_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UploadCallConversionsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + conversions_.Add(other.conversions_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + conversions_.AddEntriesFrom(input, _repeated_conversions_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// Response message for [ConversionUploadService.UploadCallConversions][google.ads.googleads.v3.services.ConversionUploadService.UploadCallConversions]. + /// + public sealed partial class UploadCallConversionsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UploadCallConversionsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadCallConversionsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadCallConversionsResponse(UploadCallConversionsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UploadCallConversionsResponse Clone() { + return new UploadCallConversionsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 1; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to conversion failures in the partial failure mode. + /// Returned when all errors occur inside the conversions. If any errors occur + /// outside the conversions (e.g. auth errors), we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CallConversionResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// Returned for successfully processed conversions. Proto will be empty for + /// rows that received an error. Results are not returned when validate_only is + /// true. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UploadCallConversionsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UploadCallConversionsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (partialFailureError_ != null) { + output.WriteRawTag(10); + output.WriteMessage(PartialFailureError); + } + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UploadCallConversionsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// A click conversion. + /// + public sealed partial class ClickConversion : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ClickConversion()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickConversion() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickConversion(ClickConversion other) : this() { + Gclid = other.Gclid; + ConversionAction = other.ConversionAction; + ConversionDateTime = other.ConversionDateTime; + ConversionValue = other.ConversionValue; + CurrencyCode = other.CurrencyCode; + OrderId = other.OrderId; + externalAttributionData_ = other.externalAttributionData_ != null ? other.externalAttributionData_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickConversion Clone() { + return new ClickConversion(this); + } + + /// Field number for the "gclid" field. + public const int GclidFieldNumber = 1; + private static readonly pb::FieldCodec _single_gclid_codec = pb::FieldCodec.ForClassWrapper(10); + private string gclid_; + /// + /// The Google click ID (gclid) associated with this conversion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Gclid { + get { return gclid_; } + set { + gclid_ = value; + } + } + + + /// Field number for the "conversion_action" field. + public const int ConversionActionFieldNumber = 2; + private static readonly pb::FieldCodec _single_conversionAction_codec = pb::FieldCodec.ForClassWrapper(18); + private string conversionAction_; + /// + /// Resource name of the conversion action associated with this conversion. + /// Note: Although this resource name consists of a customer id and a + /// conversion action id, validation will ignore the customer id and use the + /// conversion action id as the sole identifier of the conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionAction { + get { return conversionAction_; } + set { + conversionAction_ = value; + } + } + + + /// Field number for the "conversion_date_time" field. + public const int ConversionDateTimeFieldNumber = 3; + private static readonly pb::FieldCodec _single_conversionDateTime_codec = pb::FieldCodec.ForClassWrapper(26); + private string conversionDateTime_; + /// + /// The date time at which the conversion occurred. Must be after + /// the click time. The timezone must be specified. The format is + /// "yyyy-mm-dd hh:mm:ss+|-hh:mm", e.g. “2019-01-01 12:32:45-08:00”. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionDateTime { + get { return conversionDateTime_; } + set { + conversionDateTime_ = value; + } + } + + + /// Field number for the "conversion_value" field. + public const int ConversionValueFieldNumber = 4; + private static readonly pb::FieldCodec _single_conversionValue_codec = pb::FieldCodec.ForStructWrapper(34); + private double? conversionValue_; + /// + /// The value of the conversion for the advertiser. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? ConversionValue { + get { return conversionValue_; } + set { + conversionValue_ = value; + } + } + + + /// Field number for the "currency_code" field. + public const int CurrencyCodeFieldNumber = 5; + private static readonly pb::FieldCodec _single_currencyCode_codec = pb::FieldCodec.ForClassWrapper(42); + private string currencyCode_; + /// + /// Currency associated with the conversion value. This is the ISO 4217 + /// 3-character currency code. For example: USD, EUR. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CurrencyCode { + get { return currencyCode_; } + set { + currencyCode_ = value; + } + } + + + /// Field number for the "order_id" field. + public const int OrderIdFieldNumber = 6; + private static readonly pb::FieldCodec _single_orderId_codec = pb::FieldCodec.ForClassWrapper(50); + private string orderId_; + /// + /// The order ID associated with the conversion. An order id can only be used + /// for one conversion per conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string OrderId { + get { return orderId_; } + set { + orderId_ = value; + } + } + + + /// Field number for the "external_attribution_data" field. + public const int ExternalAttributionDataFieldNumber = 7; + private global::Google.Ads.GoogleAds.V3.Services.ExternalAttributionData externalAttributionData_; + /// + /// Additional data about externally attributed conversions. This field + /// is required for conversions with an externally attributed conversion + /// action, but should not be set otherwise. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.ExternalAttributionData ExternalAttributionData { + get { return externalAttributionData_; } + set { + externalAttributionData_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ClickConversion); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ClickConversion other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Gclid != other.Gclid) return false; + if (ConversionAction != other.ConversionAction) return false; + if (ConversionDateTime != other.ConversionDateTime) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(ConversionValue, other.ConversionValue)) return false; + if (CurrencyCode != other.CurrencyCode) return false; + if (OrderId != other.OrderId) return false; + if (!object.Equals(ExternalAttributionData, other.ExternalAttributionData)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (gclid_ != null) hash ^= Gclid.GetHashCode(); + if (conversionAction_ != null) hash ^= ConversionAction.GetHashCode(); + if (conversionDateTime_ != null) hash ^= ConversionDateTime.GetHashCode(); + if (conversionValue_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(ConversionValue); + if (currencyCode_ != null) hash ^= CurrencyCode.GetHashCode(); + if (orderId_ != null) hash ^= OrderId.GetHashCode(); + if (externalAttributionData_ != null) hash ^= ExternalAttributionData.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (gclid_ != null) { + _single_gclid_codec.WriteTagAndValue(output, Gclid); + } + if (conversionAction_ != null) { + _single_conversionAction_codec.WriteTagAndValue(output, ConversionAction); + } + if (conversionDateTime_ != null) { + _single_conversionDateTime_codec.WriteTagAndValue(output, ConversionDateTime); + } + if (conversionValue_ != null) { + _single_conversionValue_codec.WriteTagAndValue(output, ConversionValue); + } + if (currencyCode_ != null) { + _single_currencyCode_codec.WriteTagAndValue(output, CurrencyCode); + } + if (orderId_ != null) { + _single_orderId_codec.WriteTagAndValue(output, OrderId); + } + if (externalAttributionData_ != null) { + output.WriteRawTag(58); + output.WriteMessage(ExternalAttributionData); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (gclid_ != null) { + size += _single_gclid_codec.CalculateSizeWithTag(Gclid); + } + if (conversionAction_ != null) { + size += _single_conversionAction_codec.CalculateSizeWithTag(ConversionAction); + } + if (conversionDateTime_ != null) { + size += _single_conversionDateTime_codec.CalculateSizeWithTag(ConversionDateTime); + } + if (conversionValue_ != null) { + size += _single_conversionValue_codec.CalculateSizeWithTag(ConversionValue); + } + if (currencyCode_ != null) { + size += _single_currencyCode_codec.CalculateSizeWithTag(CurrencyCode); + } + if (orderId_ != null) { + size += _single_orderId_codec.CalculateSizeWithTag(OrderId); + } + if (externalAttributionData_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ExternalAttributionData); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ClickConversion other) { + if (other == null) { + return; + } + if (other.gclid_ != null) { + if (gclid_ == null || other.Gclid != "") { + Gclid = other.Gclid; + } + } + if (other.conversionAction_ != null) { + if (conversionAction_ == null || other.ConversionAction != "") { + ConversionAction = other.ConversionAction; + } + } + if (other.conversionDateTime_ != null) { + if (conversionDateTime_ == null || other.ConversionDateTime != "") { + ConversionDateTime = other.ConversionDateTime; + } + } + if (other.conversionValue_ != null) { + if (conversionValue_ == null || other.ConversionValue != 0D) { + ConversionValue = other.ConversionValue; + } + } + if (other.currencyCode_ != null) { + if (currencyCode_ == null || other.CurrencyCode != "") { + CurrencyCode = other.CurrencyCode; + } + } + if (other.orderId_ != null) { + if (orderId_ == null || other.OrderId != "") { + OrderId = other.OrderId; + } + } + if (other.externalAttributionData_ != null) { + if (externalAttributionData_ == null) { + ExternalAttributionData = new global::Google.Ads.GoogleAds.V3.Services.ExternalAttributionData(); + } + ExternalAttributionData.MergeFrom(other.ExternalAttributionData); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_gclid_codec.Read(input); + if (gclid_ == null || value != "") { + Gclid = value; + } + break; + } + case 18: { + string value = _single_conversionAction_codec.Read(input); + if (conversionAction_ == null || value != "") { + ConversionAction = value; + } + break; + } + case 26: { + string value = _single_conversionDateTime_codec.Read(input); + if (conversionDateTime_ == null || value != "") { + ConversionDateTime = value; + } + break; + } + case 34: { + double? value = _single_conversionValue_codec.Read(input); + if (conversionValue_ == null || value != 0D) { + ConversionValue = value; + } + break; + } + case 42: { + string value = _single_currencyCode_codec.Read(input); + if (currencyCode_ == null || value != "") { + CurrencyCode = value; + } + break; + } + case 50: { + string value = _single_orderId_codec.Read(input); + if (orderId_ == null || value != "") { + OrderId = value; + } + break; + } + case 58: { + if (externalAttributionData_ == null) { + ExternalAttributionData = new global::Google.Ads.GoogleAds.V3.Services.ExternalAttributionData(); + } + input.ReadMessage(ExternalAttributionData); + break; + } + } + } + } + + } + + /// + /// A call conversion. + /// + public sealed partial class CallConversion : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CallConversion()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversion() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversion(CallConversion other) : this() { + CallerId = other.CallerId; + CallStartDateTime = other.CallStartDateTime; + ConversionAction = other.ConversionAction; + ConversionDateTime = other.ConversionDateTime; + ConversionValue = other.ConversionValue; + CurrencyCode = other.CurrencyCode; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversion Clone() { + return new CallConversion(this); + } + + /// Field number for the "caller_id" field. + public const int CallerIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_callerId_codec = pb::FieldCodec.ForClassWrapper(10); + private string callerId_; + /// + /// The caller id from which this call was placed. Caller id is expected to be + /// in E.164 format with preceding '+' sign. e.g. "+16502531234". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CallerId { + get { return callerId_; } + set { + callerId_ = value; + } + } + + + /// Field number for the "call_start_date_time" field. + public const int CallStartDateTimeFieldNumber = 2; + private static readonly pb::FieldCodec _single_callStartDateTime_codec = pb::FieldCodec.ForClassWrapper(18); + private string callStartDateTime_; + /// + /// The date time at which the call occurred. The timezone must be specified. + /// The format is "yyyy-mm-dd hh:mm:ss+|-hh:mm", + /// e.g. "2019-01-01 12:32:45-08:00". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CallStartDateTime { + get { return callStartDateTime_; } + set { + callStartDateTime_ = value; + } + } + + + /// Field number for the "conversion_action" field. + public const int ConversionActionFieldNumber = 3; + private static readonly pb::FieldCodec _single_conversionAction_codec = pb::FieldCodec.ForClassWrapper(26); + private string conversionAction_; + /// + /// Resource name of the conversion action associated with this conversion. + /// Note: Although this resource name consists of a customer id and a + /// conversion action id, validation will ignore the customer id and use the + /// conversion action id as the sole identifier of the conversion action. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionAction { + get { return conversionAction_; } + set { + conversionAction_ = value; + } + } + + + /// Field number for the "conversion_date_time" field. + public const int ConversionDateTimeFieldNumber = 4; + private static readonly pb::FieldCodec _single_conversionDateTime_codec = pb::FieldCodec.ForClassWrapper(34); + private string conversionDateTime_; + /// + /// The date time at which the conversion occurred. Must be after the call + /// time. The timezone must be specified. The format is + /// "yyyy-mm-dd hh:mm:ss+|-hh:mm", e.g. "2019-01-01 12:32:45-08:00". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionDateTime { + get { return conversionDateTime_; } + set { + conversionDateTime_ = value; + } + } + + + /// Field number for the "conversion_value" field. + public const int ConversionValueFieldNumber = 5; + private static readonly pb::FieldCodec _single_conversionValue_codec = pb::FieldCodec.ForStructWrapper(42); + private double? conversionValue_; + /// + /// The value of the conversion for the advertiser. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? ConversionValue { + get { return conversionValue_; } + set { + conversionValue_ = value; + } + } + + + /// Field number for the "currency_code" field. + public const int CurrencyCodeFieldNumber = 6; + private static readonly pb::FieldCodec _single_currencyCode_codec = pb::FieldCodec.ForClassWrapper(50); + private string currencyCode_; + /// + /// Currency associated with the conversion value. This is the ISO 4217 + /// 3-character currency code. For example: USD, EUR. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CurrencyCode { + get { return currencyCode_; } + set { + currencyCode_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CallConversion); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CallConversion other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CallerId != other.CallerId) return false; + if (CallStartDateTime != other.CallStartDateTime) return false; + if (ConversionAction != other.ConversionAction) return false; + if (ConversionDateTime != other.ConversionDateTime) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(ConversionValue, other.ConversionValue)) return false; + if (CurrencyCode != other.CurrencyCode) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (callerId_ != null) hash ^= CallerId.GetHashCode(); + if (callStartDateTime_ != null) hash ^= CallStartDateTime.GetHashCode(); + if (conversionAction_ != null) hash ^= ConversionAction.GetHashCode(); + if (conversionDateTime_ != null) hash ^= ConversionDateTime.GetHashCode(); + if (conversionValue_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(ConversionValue); + if (currencyCode_ != null) hash ^= CurrencyCode.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (callerId_ != null) { + _single_callerId_codec.WriteTagAndValue(output, CallerId); + } + if (callStartDateTime_ != null) { + _single_callStartDateTime_codec.WriteTagAndValue(output, CallStartDateTime); + } + if (conversionAction_ != null) { + _single_conversionAction_codec.WriteTagAndValue(output, ConversionAction); + } + if (conversionDateTime_ != null) { + _single_conversionDateTime_codec.WriteTagAndValue(output, ConversionDateTime); + } + if (conversionValue_ != null) { + _single_conversionValue_codec.WriteTagAndValue(output, ConversionValue); + } + if (currencyCode_ != null) { + _single_currencyCode_codec.WriteTagAndValue(output, CurrencyCode); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (callerId_ != null) { + size += _single_callerId_codec.CalculateSizeWithTag(CallerId); + } + if (callStartDateTime_ != null) { + size += _single_callStartDateTime_codec.CalculateSizeWithTag(CallStartDateTime); + } + if (conversionAction_ != null) { + size += _single_conversionAction_codec.CalculateSizeWithTag(ConversionAction); + } + if (conversionDateTime_ != null) { + size += _single_conversionDateTime_codec.CalculateSizeWithTag(ConversionDateTime); + } + if (conversionValue_ != null) { + size += _single_conversionValue_codec.CalculateSizeWithTag(ConversionValue); + } + if (currencyCode_ != null) { + size += _single_currencyCode_codec.CalculateSizeWithTag(CurrencyCode); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CallConversion other) { + if (other == null) { + return; + } + if (other.callerId_ != null) { + if (callerId_ == null || other.CallerId != "") { + CallerId = other.CallerId; + } + } + if (other.callStartDateTime_ != null) { + if (callStartDateTime_ == null || other.CallStartDateTime != "") { + CallStartDateTime = other.CallStartDateTime; + } + } + if (other.conversionAction_ != null) { + if (conversionAction_ == null || other.ConversionAction != "") { + ConversionAction = other.ConversionAction; + } + } + if (other.conversionDateTime_ != null) { + if (conversionDateTime_ == null || other.ConversionDateTime != "") { + ConversionDateTime = other.ConversionDateTime; + } + } + if (other.conversionValue_ != null) { + if (conversionValue_ == null || other.ConversionValue != 0D) { + ConversionValue = other.ConversionValue; + } + } + if (other.currencyCode_ != null) { + if (currencyCode_ == null || other.CurrencyCode != "") { + CurrencyCode = other.CurrencyCode; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_callerId_codec.Read(input); + if (callerId_ == null || value != "") { + CallerId = value; + } + break; + } + case 18: { + string value = _single_callStartDateTime_codec.Read(input); + if (callStartDateTime_ == null || value != "") { + CallStartDateTime = value; + } + break; + } + case 26: { + string value = _single_conversionAction_codec.Read(input); + if (conversionAction_ == null || value != "") { + ConversionAction = value; + } + break; + } + case 34: { + string value = _single_conversionDateTime_codec.Read(input); + if (conversionDateTime_ == null || value != "") { + ConversionDateTime = value; + } + break; + } + case 42: { + double? value = _single_conversionValue_codec.Read(input); + if (conversionValue_ == null || value != 0D) { + ConversionValue = value; + } + break; + } + case 50: { + string value = _single_currencyCode_codec.Read(input); + if (currencyCode_ == null || value != "") { + CurrencyCode = value; + } + break; + } + } + } + } + + } + + /// + /// Contains additional information about externally attributed conversions. + /// + public sealed partial class ExternalAttributionData : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExternalAttributionData()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExternalAttributionData() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExternalAttributionData(ExternalAttributionData other) : this() { + ExternalAttributionCredit = other.ExternalAttributionCredit; + ExternalAttributionModel = other.ExternalAttributionModel; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExternalAttributionData Clone() { + return new ExternalAttributionData(this); + } + + /// Field number for the "external_attribution_credit" field. + public const int ExternalAttributionCreditFieldNumber = 1; + private static readonly pb::FieldCodec _single_externalAttributionCredit_codec = pb::FieldCodec.ForStructWrapper(10); + private double? externalAttributionCredit_; + /// + /// Represents the fraction of the conversion that is attributed to the + /// Google Ads click. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? ExternalAttributionCredit { + get { return externalAttributionCredit_; } + set { + externalAttributionCredit_ = value; + } + } + + + /// Field number for the "external_attribution_model" field. + public const int ExternalAttributionModelFieldNumber = 2; + private static readonly pb::FieldCodec _single_externalAttributionModel_codec = pb::FieldCodec.ForClassWrapper(18); + private string externalAttributionModel_; + /// + /// Specifies the attribution model name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ExternalAttributionModel { + get { return externalAttributionModel_; } + set { + externalAttributionModel_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExternalAttributionData); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExternalAttributionData other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(ExternalAttributionCredit, other.ExternalAttributionCredit)) return false; + if (ExternalAttributionModel != other.ExternalAttributionModel) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (externalAttributionCredit_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(ExternalAttributionCredit); + if (externalAttributionModel_ != null) hash ^= ExternalAttributionModel.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (externalAttributionCredit_ != null) { + _single_externalAttributionCredit_codec.WriteTagAndValue(output, ExternalAttributionCredit); + } + if (externalAttributionModel_ != null) { + _single_externalAttributionModel_codec.WriteTagAndValue(output, ExternalAttributionModel); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (externalAttributionCredit_ != null) { + size += _single_externalAttributionCredit_codec.CalculateSizeWithTag(ExternalAttributionCredit); + } + if (externalAttributionModel_ != null) { + size += _single_externalAttributionModel_codec.CalculateSizeWithTag(ExternalAttributionModel); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExternalAttributionData other) { + if (other == null) { + return; + } + if (other.externalAttributionCredit_ != null) { + if (externalAttributionCredit_ == null || other.ExternalAttributionCredit != 0D) { + ExternalAttributionCredit = other.ExternalAttributionCredit; + } + } + if (other.externalAttributionModel_ != null) { + if (externalAttributionModel_ == null || other.ExternalAttributionModel != "") { + ExternalAttributionModel = other.ExternalAttributionModel; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + double? value = _single_externalAttributionCredit_codec.Read(input); + if (externalAttributionCredit_ == null || value != 0D) { + ExternalAttributionCredit = value; + } + break; + } + case 18: { + string value = _single_externalAttributionModel_codec.Read(input); + if (externalAttributionModel_ == null || value != "") { + ExternalAttributionModel = value; + } + break; + } + } + } + } + + } + + /// + /// Identifying information for a successfully processed ClickConversion. + /// + public sealed partial class ClickConversionResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ClickConversionResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickConversionResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickConversionResult(ClickConversionResult other) : this() { + Gclid = other.Gclid; + ConversionAction = other.ConversionAction; + ConversionDateTime = other.ConversionDateTime; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ClickConversionResult Clone() { + return new ClickConversionResult(this); + } + + /// Field number for the "gclid" field. + public const int GclidFieldNumber = 1; + private static readonly pb::FieldCodec _single_gclid_codec = pb::FieldCodec.ForClassWrapper(10); + private string gclid_; + /// + /// The Google Click ID (gclid) associated with this conversion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Gclid { + get { return gclid_; } + set { + gclid_ = value; + } + } + + + /// Field number for the "conversion_action" field. + public const int ConversionActionFieldNumber = 2; + private static readonly pb::FieldCodec _single_conversionAction_codec = pb::FieldCodec.ForClassWrapper(18); + private string conversionAction_; + /// + /// Resource name of the conversion action associated with this conversion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionAction { + get { return conversionAction_; } + set { + conversionAction_ = value; + } + } + + + /// Field number for the "conversion_date_time" field. + public const int ConversionDateTimeFieldNumber = 3; + private static readonly pb::FieldCodec _single_conversionDateTime_codec = pb::FieldCodec.ForClassWrapper(26); + private string conversionDateTime_; + /// + /// The date time at which the conversion occurred. The format is + /// "yyyy-mm-dd hh:mm:ss+|-hh:mm", e.g. “2019-01-01 12:32:45-08:00”. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionDateTime { + get { return conversionDateTime_; } + set { + conversionDateTime_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ClickConversionResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ClickConversionResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Gclid != other.Gclid) return false; + if (ConversionAction != other.ConversionAction) return false; + if (ConversionDateTime != other.ConversionDateTime) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (gclid_ != null) hash ^= Gclid.GetHashCode(); + if (conversionAction_ != null) hash ^= ConversionAction.GetHashCode(); + if (conversionDateTime_ != null) hash ^= ConversionDateTime.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (gclid_ != null) { + _single_gclid_codec.WriteTagAndValue(output, Gclid); + } + if (conversionAction_ != null) { + _single_conversionAction_codec.WriteTagAndValue(output, ConversionAction); + } + if (conversionDateTime_ != null) { + _single_conversionDateTime_codec.WriteTagAndValue(output, ConversionDateTime); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (gclid_ != null) { + size += _single_gclid_codec.CalculateSizeWithTag(Gclid); + } + if (conversionAction_ != null) { + size += _single_conversionAction_codec.CalculateSizeWithTag(ConversionAction); + } + if (conversionDateTime_ != null) { + size += _single_conversionDateTime_codec.CalculateSizeWithTag(ConversionDateTime); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ClickConversionResult other) { + if (other == null) { + return; + } + if (other.gclid_ != null) { + if (gclid_ == null || other.Gclid != "") { + Gclid = other.Gclid; + } + } + if (other.conversionAction_ != null) { + if (conversionAction_ == null || other.ConversionAction != "") { + ConversionAction = other.ConversionAction; + } + } + if (other.conversionDateTime_ != null) { + if (conversionDateTime_ == null || other.ConversionDateTime != "") { + ConversionDateTime = other.ConversionDateTime; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_gclid_codec.Read(input); + if (gclid_ == null || value != "") { + Gclid = value; + } + break; + } + case 18: { + string value = _single_conversionAction_codec.Read(input); + if (conversionAction_ == null || value != "") { + ConversionAction = value; + } + break; + } + case 26: { + string value = _single_conversionDateTime_codec.Read(input); + if (conversionDateTime_ == null || value != "") { + ConversionDateTime = value; + } + break; + } + } + } + } + + } + + /// + /// Identifying information for a successfully processed CallConversionUpload. + /// + public sealed partial class CallConversionResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CallConversionResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversionResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversionResult(CallConversionResult other) : this() { + CallerId = other.CallerId; + CallStartDateTime = other.CallStartDateTime; + ConversionAction = other.ConversionAction; + ConversionDateTime = other.ConversionDateTime; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallConversionResult Clone() { + return new CallConversionResult(this); + } + + /// Field number for the "caller_id" field. + public const int CallerIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_callerId_codec = pb::FieldCodec.ForClassWrapper(10); + private string callerId_; + /// + /// The caller id from which this call was placed. Caller id is expected to be + /// in E.164 format with preceding '+' sign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CallerId { + get { return callerId_; } + set { + callerId_ = value; + } + } + + + /// Field number for the "call_start_date_time" field. + public const int CallStartDateTimeFieldNumber = 2; + private static readonly pb::FieldCodec _single_callStartDateTime_codec = pb::FieldCodec.ForClassWrapper(18); + private string callStartDateTime_; + /// + /// The date time at which the call occurred. The format is + /// "yyyy-mm-dd hh:mm:ss+|-hh:mm", e.g. "2019-01-01 12:32:45-08:00". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CallStartDateTime { + get { return callStartDateTime_; } + set { + callStartDateTime_ = value; + } + } + + + /// Field number for the "conversion_action" field. + public const int ConversionActionFieldNumber = 3; + private static readonly pb::FieldCodec _single_conversionAction_codec = pb::FieldCodec.ForClassWrapper(26); + private string conversionAction_; + /// + /// Resource name of the conversion action associated with this conversion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionAction { + get { return conversionAction_; } + set { + conversionAction_ = value; + } + } + + + /// Field number for the "conversion_date_time" field. + public const int ConversionDateTimeFieldNumber = 4; + private static readonly pb::FieldCodec _single_conversionDateTime_codec = pb::FieldCodec.ForClassWrapper(34); + private string conversionDateTime_; + /// + /// The date time at which the conversion occurred. The format is + /// "yyyy-mm-dd hh:mm:ss+|-hh:mm", e.g. "2019-01-01 12:32:45-08:00". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ConversionDateTime { + get { return conversionDateTime_; } + set { + conversionDateTime_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CallConversionResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CallConversionResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CallerId != other.CallerId) return false; + if (CallStartDateTime != other.CallStartDateTime) return false; + if (ConversionAction != other.ConversionAction) return false; + if (ConversionDateTime != other.ConversionDateTime) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (callerId_ != null) hash ^= CallerId.GetHashCode(); + if (callStartDateTime_ != null) hash ^= CallStartDateTime.GetHashCode(); + if (conversionAction_ != null) hash ^= ConversionAction.GetHashCode(); + if (conversionDateTime_ != null) hash ^= ConversionDateTime.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (callerId_ != null) { + _single_callerId_codec.WriteTagAndValue(output, CallerId); + } + if (callStartDateTime_ != null) { + _single_callStartDateTime_codec.WriteTagAndValue(output, CallStartDateTime); + } + if (conversionAction_ != null) { + _single_conversionAction_codec.WriteTagAndValue(output, ConversionAction); + } + if (conversionDateTime_ != null) { + _single_conversionDateTime_codec.WriteTagAndValue(output, ConversionDateTime); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (callerId_ != null) { + size += _single_callerId_codec.CalculateSizeWithTag(CallerId); + } + if (callStartDateTime_ != null) { + size += _single_callStartDateTime_codec.CalculateSizeWithTag(CallStartDateTime); + } + if (conversionAction_ != null) { + size += _single_conversionAction_codec.CalculateSizeWithTag(ConversionAction); + } + if (conversionDateTime_ != null) { + size += _single_conversionDateTime_codec.CalculateSizeWithTag(ConversionDateTime); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CallConversionResult other) { + if (other == null) { + return; + } + if (other.callerId_ != null) { + if (callerId_ == null || other.CallerId != "") { + CallerId = other.CallerId; + } + } + if (other.callStartDateTime_ != null) { + if (callStartDateTime_ == null || other.CallStartDateTime != "") { + CallStartDateTime = other.CallStartDateTime; + } + } + if (other.conversionAction_ != null) { + if (conversionAction_ == null || other.ConversionAction != "") { + ConversionAction = other.ConversionAction; + } + } + if (other.conversionDateTime_ != null) { + if (conversionDateTime_ == null || other.ConversionDateTime != "") { + ConversionDateTime = other.ConversionDateTime; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_callerId_codec.Read(input); + if (callerId_ == null || value != "") { + CallerId = value; + } + break; + } + case 18: { + string value = _single_callStartDateTime_codec.Read(input); + if (callStartDateTime_ == null || value != "") { + CallStartDateTime = value; + } + break; + } + case 26: { + string value = _single_conversionAction_codec.Read(input); + if (conversionAction_ == null || value != "") { + ConversionAction = value; + } + break; + } + case 34: { + string value = _single_conversionDateTime_codec.Read(input); + if (conversionDateTime_ == null || value != "") { + ConversionDateTime = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ConversionUploadServiceClient.cs b/src/V3/Stubs/ConversionUploadServiceClient.cs new file mode 100644 index 000000000..7212166f4 --- /dev/null +++ b/src/V3/Stubs/ConversionUploadServiceClient.cs @@ -0,0 +1,1017 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class ConversionUploadServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static ConversionUploadServiceSettings GetDefault() => new ConversionUploadServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public ConversionUploadServiceSettings() { } + + private ConversionUploadServiceSettings(ConversionUploadServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + UploadClickConversionsSettings = existing.UploadClickConversionsSettings; + UploadCallConversionsSettings = existing.UploadCallConversionsSettings; + OnCopy(existing); + } + + partial void OnCopy(ConversionUploadServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// ConversionUploadServiceClient.UploadClickConversions and ConversionUploadServiceClient.UploadClickConversionsAsync. + /// + /// + /// The default ConversionUploadServiceClient.UploadClickConversions and + /// ConversionUploadServiceClient.UploadClickConversionsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings UploadClickConversionsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// ConversionUploadServiceClient.UploadCallConversions and ConversionUploadServiceClient.UploadCallConversionsAsync. + /// + /// + /// The default ConversionUploadServiceClient.UploadCallConversions and + /// ConversionUploadServiceClient.UploadCallConversionsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings UploadCallConversionsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public ConversionUploadServiceSettings Clone() => new ConversionUploadServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class ConversionUploadServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public ConversionUploadServiceSettings Settings { get; set; } + + /// + public override ConversionUploadServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return ConversionUploadServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return ConversionUploadServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => ConversionUploadServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => ConversionUploadServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => ConversionUploadServiceClient.ChannelPool; + } + + /// + /// ConversionUploadService client wrapper, for convenient use. + /// + public abstract partial class ConversionUploadServiceClient + { + /// + /// The default endpoint for the ConversionUploadService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default ConversionUploadService scopes. + /// + /// + /// The default ConversionUploadService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ConversionUploadServiceClient client = await ConversionUploadServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ConversionUploadServiceClient.DefaultEndpoint.Host, ConversionUploadServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ConversionUploadServiceClient client = ConversionUploadServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, ConversionUploadServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ConversionUploadServiceClient client = ConversionUploadServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ConversionUploadServiceClient.DefaultEndpoint.Host, ConversionUploadServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ConversionUploadServiceClient client = ConversionUploadServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static ConversionUploadServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, ConversionUploadServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ConversionUploadServiceClient Create(grpccore::Channel channel, ConversionUploadServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ConversionUploadServiceClient Create(grpccore::CallInvoker callInvoker, ConversionUploadServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + ConversionUploadService.ConversionUploadServiceClient grpcClient = new ConversionUploadService.ConversionUploadServiceClient(callInvoker); + return new ConversionUploadServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC ConversionUploadService client. + /// + public virtual ConversionUploadService.ConversionUploadServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Processes the given click conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// This should always be set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadClickConversionsAsync( + string customerId, + scg::IEnumerable conversions, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => UploadClickConversionsAsync( + new UploadClickConversionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Conversions = { gax::GaxPreconditions.CheckNotNull(conversions, nameof(conversions)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Processes the given click conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// This should always be set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadClickConversionsAsync( + string customerId, + scg::IEnumerable conversions, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => UploadClickConversionsAsync( + customerId, + conversions, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given click conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// This should always be set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadClickConversionsResponse UploadClickConversions( + string customerId, + scg::IEnumerable conversions, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => UploadClickConversions( + new UploadClickConversionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Conversions = { gax::GaxPreconditions.CheckNotNull(conversions, nameof(conversions)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Processes the given click conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadClickConversionsAsync( + string customerId, + scg::IEnumerable conversions, + gaxgrpc::CallSettings callSettings = null) => UploadClickConversionsAsync( + new UploadClickConversionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Conversions = { gax::GaxPreconditions.CheckNotNull(conversions, nameof(conversions)) }, + }, + callSettings); + + /// + /// Processes the given click conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadClickConversionsAsync( + string customerId, + scg::IEnumerable conversions, + st::CancellationToken cancellationToken) => UploadClickConversionsAsync( + customerId, + conversions, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given click conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadClickConversionsResponse UploadClickConversions( + string customerId, + scg::IEnumerable conversions, + gaxgrpc::CallSettings callSettings = null) => UploadClickConversions( + new UploadClickConversionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Conversions = { gax::GaxPreconditions.CheckNotNull(conversions, nameof(conversions)) }, + }, + callSettings); + + /// + /// Processes the given click conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadClickConversionsAsync( + UploadClickConversionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Processes the given click conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadClickConversionsAsync( + UploadClickConversionsRequest request, + st::CancellationToken cancellationToken) => UploadClickConversionsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given click conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadClickConversionsResponse UploadClickConversions( + UploadClickConversionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Processes the given call conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// This should always be set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadCallConversionsAsync( + string customerId, + scg::IEnumerable conversions, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => UploadCallConversionsAsync( + new UploadCallConversionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Conversions = { gax::GaxPreconditions.CheckNotNull(conversions, nameof(conversions)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Processes the given call conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// This should always be set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadCallConversionsAsync( + string customerId, + scg::IEnumerable conversions, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => UploadCallConversionsAsync( + customerId, + conversions, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given call conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// This should always be set to true. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadCallConversionsResponse UploadCallConversions( + string customerId, + scg::IEnumerable conversions, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => UploadCallConversions( + new UploadCallConversionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Conversions = { gax::GaxPreconditions.CheckNotNull(conversions, nameof(conversions)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Processes the given call conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadCallConversionsAsync( + string customerId, + scg::IEnumerable conversions, + gaxgrpc::CallSettings callSettings = null) => UploadCallConversionsAsync( + new UploadCallConversionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Conversions = { gax::GaxPreconditions.CheckNotNull(conversions, nameof(conversions)) }, + }, + callSettings); + + /// + /// Processes the given call conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadCallConversionsAsync( + string customerId, + scg::IEnumerable conversions, + st::CancellationToken cancellationToken) => UploadCallConversionsAsync( + customerId, + conversions, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given call conversions. + /// + /// + /// Required. The ID of the customer performing the upload. + /// + /// + /// Required. The conversions that are being uploaded. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadCallConversionsResponse UploadCallConversions( + string customerId, + scg::IEnumerable conversions, + gaxgrpc::CallSettings callSettings = null) => UploadCallConversions( + new UploadCallConversionsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Conversions = { gax::GaxPreconditions.CheckNotNull(conversions, nameof(conversions)) }, + }, + callSettings); + + /// + /// Processes the given call conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadCallConversionsAsync( + UploadCallConversionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Processes the given call conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task UploadCallConversionsAsync( + UploadCallConversionsRequest request, + st::CancellationToken cancellationToken) => UploadCallConversionsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Processes the given call conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual UploadCallConversionsResponse UploadCallConversions( + UploadCallConversionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// ConversionUploadService client wrapper implementation, for convenient use. + /// + public sealed partial class ConversionUploadServiceClientImpl : ConversionUploadServiceClient + { + private readonly gaxgrpc::ApiCall _callUploadClickConversions; + private readonly gaxgrpc::ApiCall _callUploadCallConversions; + + /// + /// Constructs a client wrapper for the ConversionUploadService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public ConversionUploadServiceClientImpl(ConversionUploadService.ConversionUploadServiceClient grpcClient, ConversionUploadServiceSettings settings) + { + GrpcClient = grpcClient; + ConversionUploadServiceSettings effectiveSettings = settings ?? ConversionUploadServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callUploadClickConversions = clientHelper.BuildApiCall( + GrpcClient.UploadClickConversionsAsync, GrpcClient.UploadClickConversions, effectiveSettings.UploadClickConversionsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callUploadCallConversions = clientHelper.BuildApiCall( + GrpcClient.UploadCallConversionsAsync, GrpcClient.UploadCallConversions, effectiveSettings.UploadCallConversionsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callUploadClickConversions); + Modify_UploadClickConversionsApiCall(ref _callUploadClickConversions); + Modify_ApiCall(ref _callUploadCallConversions); + Modify_UploadCallConversionsApiCall(ref _callUploadCallConversions); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_UploadClickConversionsApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_UploadCallConversionsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(ConversionUploadService.ConversionUploadServiceClient grpcClient, ConversionUploadServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC ConversionUploadService client. + /// + public override ConversionUploadService.ConversionUploadServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_UploadClickConversionsRequest(ref UploadClickConversionsRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_UploadCallConversionsRequest(ref UploadCallConversionsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Processes the given click conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task UploadClickConversionsAsync( + UploadClickConversionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_UploadClickConversionsRequest(ref request, ref callSettings); + return _callUploadClickConversions.Async(request, callSettings); + } + + /// + /// Processes the given click conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override UploadClickConversionsResponse UploadClickConversions( + UploadClickConversionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_UploadClickConversionsRequest(ref request, ref callSettings); + return _callUploadClickConversions.Sync(request, callSettings); + } + + /// + /// Processes the given call conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task UploadCallConversionsAsync( + UploadCallConversionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_UploadCallConversionsRequest(ref request, ref callSettings); + return _callUploadCallConversions.Async(request, callSettings); + } + + /// + /// Processes the given call conversions. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override UploadCallConversionsResponse UploadCallConversions( + UploadCallConversionsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_UploadCallConversionsRequest(ref request, ref callSettings); + return _callUploadCallConversions.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/ConversionUploadServiceGrpc.cs b/src/V3/Stubs/ConversionUploadServiceGrpc.cs new file mode 100644 index 000000000..8d79bebc2 --- /dev/null +++ b/src/V3/Stubs/ConversionUploadServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/conversion_upload_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to upload conversions. + /// + public static partial class ConversionUploadService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.ConversionUploadService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_UploadClickConversionsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_UploadClickConversionsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_UploadCallConversionsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_UploadCallConversionsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_UploadClickConversions = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "UploadClickConversions", + __Marshaller_google_ads_googleads_v3_services_UploadClickConversionsRequest, + __Marshaller_google_ads_googleads_v3_services_UploadClickConversionsResponse); + + static readonly grpc::Method __Method_UploadCallConversions = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "UploadCallConversions", + __Marshaller_google_ads_googleads_v3_services_UploadCallConversionsRequest, + __Marshaller_google_ads_googleads_v3_services_UploadCallConversionsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.ConversionUploadServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of ConversionUploadService + public abstract partial class ConversionUploadServiceBase + { + /// + /// Processes the given click conversions. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task UploadClickConversions(global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Processes the given call conversions. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task UploadCallConversions(global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for ConversionUploadService + public partial class ConversionUploadServiceClient : grpc::ClientBase + { + /// Creates a new client for ConversionUploadService + /// The channel to use to make remote calls. + public ConversionUploadServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for ConversionUploadService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public ConversionUploadServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected ConversionUploadServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected ConversionUploadServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Processes the given click conversions. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsResponse UploadClickConversions(global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return UploadClickConversions(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Processes the given click conversions. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsResponse UploadClickConversions(global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_UploadClickConversions, null, options, request); + } + /// + /// Processes the given click conversions. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall UploadClickConversionsAsync(global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return UploadClickConversionsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Processes the given click conversions. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall UploadClickConversionsAsync(global::Google.Ads.GoogleAds.V3.Services.UploadClickConversionsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_UploadClickConversions, null, options, request); + } + /// + /// Processes the given call conversions. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsResponse UploadCallConversions(global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return UploadCallConversions(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Processes the given call conversions. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsResponse UploadCallConversions(global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_UploadCallConversions, null, options, request); + } + /// + /// Processes the given call conversions. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall UploadCallConversionsAsync(global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return UploadCallConversionsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Processes the given call conversions. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall UploadCallConversionsAsync(global::Google.Ads.GoogleAds.V3.Services.UploadCallConversionsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_UploadCallConversions, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override ConversionUploadServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new ConversionUploadServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(ConversionUploadServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_UploadClickConversions, serviceImpl.UploadClickConversions) + .AddMethod(__Method_UploadCallConversions, serviceImpl.UploadCallConversions).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, ConversionUploadServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_UploadClickConversions, serviceImpl.UploadClickConversions); + serviceBinder.AddMethod(__Method_UploadCallConversions, serviceImpl.UploadCallConversions); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CountryCodeError.cs b/src/V3/Stubs/CountryCodeError.cs new file mode 100644 index 000000000..fe4e48eb7 --- /dev/null +++ b/src/V3/Stubs/CountryCodeError.cs @@ -0,0 +1,181 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/country_code_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/country_code_error.proto + public static partial class CountryCodeErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/country_code_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CountryCodeErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY291bnRyeV9jb2Rl", + "X2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMa", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iYgoUQ291bnRyeUNvZGVF", + "cnJvckVudW0iSgoQQ291bnRyeUNvZGVFcnJvchIPCgtVTlNQRUNJRklFRBAA", + "EgsKB1VOS05PV04QARIYChRJTlZBTElEX0NPVU5UUllfQ09ERRACQvABCiJj", + "b20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQhVDb3VudHJ5Q29k", + "ZUVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGq", + "Ah5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRz", + "XEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CountryCodeErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CountryCodeErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CountryCodeErrorEnum.Types.CountryCodeError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing country code errors. + /// + public sealed partial class CountryCodeErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CountryCodeErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CountryCodeErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CountryCodeErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CountryCodeErrorEnum(CountryCodeErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CountryCodeErrorEnum Clone() { + return new CountryCodeErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CountryCodeErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CountryCodeErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CountryCodeErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CountryCodeErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing country code errors. + /// + public enum CountryCodeError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The country code is invalid. + /// + [pbr::OriginalName("INVALID_COUNTRY_CODE")] InvalidCountryCode = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Criteria.cs b/src/V3/Stubs/Criteria.cs new file mode 100644 index 000000000..4222ce26d --- /dev/null +++ b/src/V3/Stubs/Criteria.cs @@ -0,0 +1,9472 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/criteria.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/criteria.proto + public static partial class CriteriaReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/criteria.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CriteriaReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vY3JpdGVyaWEucHJv", + "dG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbhoyZ29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZW51bXMvYWdlX3JhbmdlX3R5cGUucHJvdG8aOmdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2FwcF9wYXltZW50X21vZGVs", + "X3R5cGUucHJvdG8aNmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2Nv", + "bnRlbnRfbGFiZWxfdHlwZS5wcm90bxovZ29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZW51bXMvZGF5X29mX3dlZWsucHJvdG8aKmdvb2dsZS9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zL2RldmljZS5wcm90bxovZ29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvZW51bXMvZ2VuZGVyX3R5cGUucHJvdG8aPWdvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL2VudW1zL2hvdGVsX2RhdGVfc2VsZWN0aW9uX3R5cGUucHJv", + "dG8aNWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2luY29tZV9yYW5n", + "ZV90eXBlLnByb3RvGjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9p", + "bnRlcmFjdGlvbl90eXBlLnByb3RvGjZnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9rZXl3b3JkX21hdGNoX3R5cGUucHJvdG8aNmdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2VudW1zL2xpc3RpbmdfZ3JvdXBfdHlwZS5wcm90bxo/", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvbG9jYXRpb25fZ3JvdXBf", + "cmFkaXVzX3VuaXRzLnByb3RvGjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9l", + "bnVtcy9taW51dGVfb2ZfaG91ci5wcm90bxo4Z29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvZW51bXMvcGFyZW50YWxfc3RhdHVzX3R5cGUucHJvdG8aOmdvb2ds", + "ZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3ByZWZlcnJlZF9jb250ZW50X3R5", + "cGUucHJvdG8aQmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3Byb2R1", + "Y3RfYmlkZGluZ19jYXRlZ29yeV9sZXZlbC5wcm90bxozZ29vZ2xlL2Fkcy9n", + "b29nbGVhZHMvdjMvZW51bXMvcHJvZHVjdF9jaGFubmVsLnByb3RvGj9nb29n", + "bGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9wcm9kdWN0X2NoYW5uZWxfZXhj", + "bHVzaXZpdHkucHJvdG8aNWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1z", + "L3Byb2R1Y3RfY29uZGl0aW9uLnByb3RvGkJnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9lbnVtcy9wcm9kdWN0X2N1c3RvbV9hdHRyaWJ1dGVfaW5kZXgucHJv", + "dG8aNmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3Byb2R1Y3RfdHlw", + "ZV9sZXZlbC5wcm90bxo6Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMv", + "cHJveGltaXR5X3JhZGl1c191bml0cy5wcm90bxo9Z29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvZW51bXMvd2VicGFnZV9jb25kaXRpb25fb3BlcmFuZC5wcm90", + "bxo+Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvd2VicGFnZV9jb25k", + "aXRpb25fb3BlcmF0b3IucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVy", + "cy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKTAQoLS2V5", + "d29yZEluZm8SKgoEdGV4dBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZRJYCgptYXRjaF90eXBlGAIgASgOMkQuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXMuS2V5d29yZE1hdGNoVHlwZUVudW0uS2V5d29yZE1h", + "dGNoVHlwZSI6Cg1QbGFjZW1lbnRJbmZvEikKA3VybBgBIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSJbChVNb2JpbGVBcHBDYXRlZ29yeUlu", + "Zm8SQgocbW9iaWxlX2FwcF9jYXRlZ29yeV9jb25zdGFudBgBIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSJxChVNb2JpbGVBcHBsaWNhdGlv", + "bkluZm8SLAoGYXBwX2lkGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlEioKBG5hbWUYAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5n", + "VmFsdWUiSQoMTG9jYXRpb25JbmZvEjkKE2dlb190YXJnZXRfY29uc3RhbnQY", + "ASABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUiTAoKRGV2aWNl", + "SW5mbxI+CgR0eXBlGAEgASgOMjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuRGV2aWNlRW51bS5EZXZpY2UicgoUUHJlZmVycmVkQ29udGVudElu", + "Zm8SWgoEdHlwZRgCIAEoDjJMLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zLlByZWZlcnJlZENvbnRlbnRUeXBlRW51bS5QcmVmZXJyZWRDb250ZW50", + "VHlwZSLxAQoQTGlzdGluZ0dyb3VwSW5mbxJSCgR0eXBlGAEgASgOMkQuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuTGlzdGluZ0dyb3VwVHlwZUVu", + "dW0uTGlzdGluZ0dyb3VwVHlwZRJICgpjYXNlX3ZhbHVlGAIgASgLMjQuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkxpc3RpbmdEaW1lbnNpb25J", + "bmZvEj8KGXBhcmVudF9hZF9ncm91cF9jcml0ZXJpb24YAyABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWUiXAoQTGlzdGluZ1Njb3BlSW5mbxJI", + "CgpkaW1lbnNpb25zGAIgAygLMjQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "Y29tbW9uLkxpc3RpbmdEaW1lbnNpb25JbmZvIpsJChRMaXN0aW5nRGltZW5z", + "aW9uSW5mbxI/Cghob3RlbF9pZBgCIAEoCzIrLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmNvbW1vbi5Ib3RlbElkSW5mb0gAEkUKC2hvdGVsX2NsYXNzGAMg", + "ASgLMi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkhvdGVsQ2xh", + "c3NJbmZvSAASVgoUaG90ZWxfY291bnRyeV9yZWdpb24YBCABKAsyNi5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uSG90ZWxDb3VudHJ5UmVnaW9u", + "SW5mb0gAEkUKC2hvdGVsX3N0YXRlGAUgASgLMi4uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLkhvdGVsU3RhdGVJbmZvSAASQwoKaG90ZWxfY2l0", + "eRgGIAEoCzItLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Ib3Rl", + "bENpdHlJbmZvSAASXgoYcHJvZHVjdF9iaWRkaW5nX2NhdGVnb3J5GA0gASgL", + "MjouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLlByb2R1Y3RCaWRk", + "aW5nQ2F0ZWdvcnlJbmZvSAASSQoNcHJvZHVjdF9icmFuZBgPIAEoCzIwLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Qcm9kdWN0QnJhbmRJbmZv", + "SAASTQoPcHJvZHVjdF9jaGFubmVsGAggASgLMjIuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLlByb2R1Y3RDaGFubmVsSW5mb0gAEmQKG3Byb2R1", + "Y3RfY2hhbm5lbF9leGNsdXNpdml0eRgJIAEoCzI9Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmNvbW1vbi5Qcm9kdWN0Q2hhbm5lbEV4Y2x1c2l2aXR5SW5m", + "b0gAElEKEXByb2R1Y3RfY29uZGl0aW9uGAogASgLMjQuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuY29tbW9uLlByb2R1Y3RDb25kaXRpb25JbmZvSAASXgoY", + "cHJvZHVjdF9jdXN0b21fYXR0cmlidXRlGBAgASgLMjouZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuY29tbW9uLlByb2R1Y3RDdXN0b21BdHRyaWJ1dGVJbmZv", + "SAASTAoPcHJvZHVjdF9pdGVtX2lkGAsgASgLMjEuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLlByb2R1Y3RJdGVtSWRJbmZvSAASRwoMcHJvZHVj", + "dF90eXBlGAwgASgLMi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9u", + "LlByb2R1Y3RUeXBlSW5mb0gAEmAKGXVua25vd25fbGlzdGluZ19kaW1lbnNp", + "b24YDiABKAsyOy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uVW5r", + "bm93bkxpc3RpbmdEaW1lbnNpb25JbmZvSABCCwoJZGltZW5zaW9uIjoKC0hv", + "dGVsSWRJbmZvEisKBXZhbHVlGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlIjwKDkhvdGVsQ2xhc3NJbmZvEioKBXZhbHVlGAEgASgLMhsu", + "Z29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUiWAoWSG90ZWxDb3VudHJ5UmVn", + "aW9uSW5mbxI+Chhjb3VudHJ5X3JlZ2lvbl9jcml0ZXJpb24YASABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUiRwoOSG90ZWxTdGF0ZUluZm8S", + "NQoPc3RhdGVfY3JpdGVyaW9uGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlIkUKDUhvdGVsQ2l0eUluZm8SNAoOY2l0eV9jcml0ZXJpb24Y", + "ASABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUi5AEKGlByb2R1", + "Y3RCaWRkaW5nQ2F0ZWdvcnlJbmZvEicKAmlkGAEgASgLMhsuZ29vZ2xlLnBy", + "b3RvYnVmLkludDY0VmFsdWUSMgoMY291bnRyeV9jb2RlGAIgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEmkKBWxldmVsGAMgASgOMlouZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuUHJvZHVjdEJpZGRpbmdDYXRl", + "Z29yeUxldmVsRW51bS5Qcm9kdWN0QmlkZGluZ0NhdGVnb3J5TGV2ZWwiPwoQ", + "UHJvZHVjdEJyYW5kSW5mbxIrCgV2YWx1ZRgBIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZSJnChJQcm9kdWN0Q2hhbm5lbEluZm8SUQoHY2hh", + "bm5lbBgBIAEoDjJALmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLlBy", + "b2R1Y3RDaGFubmVsRW51bS5Qcm9kdWN0Q2hhbm5lbCKUAQodUHJvZHVjdENo", + "YW5uZWxFeGNsdXNpdml0eUluZm8ScwoTY2hhbm5lbF9leGNsdXNpdml0eRgB", + "IAEoDjJWLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLlByb2R1Y3RD", + "aGFubmVsRXhjbHVzaXZpdHlFbnVtLlByb2R1Y3RDaGFubmVsRXhjbHVzaXZp", + "dHkibwoUUHJvZHVjdENvbmRpdGlvbkluZm8SVwoJY29uZGl0aW9uGAEgASgO", + "MkQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuUHJvZHVjdENvbmRp", + "dGlvbkVudW0uUHJvZHVjdENvbmRpdGlvbiK0AQoaUHJvZHVjdEN1c3RvbUF0", + "dHJpYnV0ZUluZm8SKwoFdmFsdWUYASABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWUSaQoFaW5kZXgYAiABKA4yWi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lbnVtcy5Qcm9kdWN0Q3VzdG9tQXR0cmlidXRlSW5kZXhFbnVt", + "LlByb2R1Y3RDdXN0b21BdHRyaWJ1dGVJbmRleCJAChFQcm9kdWN0SXRlbUlk", + "SW5mbxIrCgV2YWx1ZRgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZSKTAQoPUHJvZHVjdFR5cGVJbmZvEisKBXZhbHVlGAEgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlElMKBWxldmVsGAIgASgOMkQuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuUHJvZHVjdFR5cGVMZXZlbEVu", + "dW0uUHJvZHVjdFR5cGVMZXZlbCIdChtVbmtub3duTGlzdGluZ0RpbWVuc2lv", + "bkluZm8ifAoaSG90ZWxEYXRlU2VsZWN0aW9uVHlwZUluZm8SXgoEdHlwZRgB", + "IAEoDjJQLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkhvdGVsRGF0", + "ZVNlbGVjdGlvblR5cGVFbnVtLkhvdGVsRGF0ZVNlbGVjdGlvblR5cGUifQod", + "SG90ZWxBZHZhbmNlQm9va2luZ1dpbmRvd0luZm8SLQoIbWluX2RheXMYASAB", + "KAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZRItCghtYXhfZGF5cxgC", + "IAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlInkKFUhvdGVsTGVu", + "Z3RoT2ZTdGF5SW5mbxIvCgptaW5fbmlnaHRzGAEgASgLMhsuZ29vZ2xlLnBy", + "b3RvYnVmLkludDY0VmFsdWUSLwoKbWF4X25pZ2h0cxgCIAEoCzIbLmdvb2ds", + "ZS5wcm90b2J1Zi5JbnQ2NFZhbHVlImIKE0hvdGVsQ2hlY2tJbkRheUluZm8S", + "SwoLZGF5X29mX3dlZWsYASABKA4yNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtcy5EYXlPZldlZWtFbnVtLkRheU9mV2VlayJnChNJbnRlcmFjdGlv", + "blR5cGVJbmZvElAKBHR5cGUYASABKA4yQi5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtcy5JbnRlcmFjdGlvblR5cGVFbnVtLkludGVyYWN0aW9uVHlw", + "ZSLjAgoOQWRTY2hlZHVsZUluZm8SUgoMc3RhcnRfbWludXRlGAEgASgOMjwu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuTWludXRlT2ZIb3VyRW51", + "bS5NaW51dGVPZkhvdXISUAoKZW5kX21pbnV0ZRgCIAEoDjI8Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVudW1zLk1pbnV0ZU9mSG91ckVudW0uTWludXRl", + "T2ZIb3VyEi8KCnN0YXJ0X2hvdXIYAyABKAsyGy5nb29nbGUucHJvdG9idWYu", + "SW50MzJWYWx1ZRItCghlbmRfaG91chgEIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQzMlZhbHVlEksKC2RheV9vZl93ZWVrGAUgASgOMjYuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMuRGF5T2ZXZWVrRW51bS5EYXlPZldlZWsi", + "WgoMQWdlUmFuZ2VJbmZvEkoKBHR5cGUYASABKA4yPC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtcy5BZ2VSYW5nZVR5cGVFbnVtLkFnZVJhbmdlVHlw", + "ZSJUCgpHZW5kZXJJbmZvEkYKBHR5cGUYASABKA4yOC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtcy5HZW5kZXJUeXBlRW51bS5HZW5kZXJUeXBlImMK", + "D0luY29tZVJhbmdlSW5mbxJQCgR0eXBlGAEgASgOMkIuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuZW51bXMuSW5jb21lUmFuZ2VUeXBlRW51bS5JbmNvbWVS", + "YW5nZVR5cGUibAoSUGFyZW50YWxTdGF0dXNJbmZvElYKBHR5cGUYASABKA4y", + "SC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5QYXJlbnRhbFN0YXR1", + "c1R5cGVFbnVtLlBhcmVudGFsU3RhdHVzVHlwZSJCChBZb3VUdWJlVmlkZW9J", + "bmZvEi4KCHZpZGVvX2lkGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlIkYKEllvdVR1YmVDaGFubmVsSW5mbxIwCgpjaGFubmVsX2lkGAEg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlIj8KDFVzZXJMaXN0", + "SW5mbxIvCgl1c2VyX2xpc3QYASABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWUioAIKDVByb3hpbWl0eUluZm8SPwoJZ2VvX3BvaW50GAEgASgL", + "MiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkdlb1BvaW50SW5m", + "bxIsCgZyYWRpdXMYAiABKAsyHC5nb29nbGUucHJvdG9idWYuRG91YmxlVmFs", + "dWUSYgoMcmFkaXVzX3VuaXRzGAMgASgOMkwuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZW51bXMuUHJveGltaXR5UmFkaXVzVW5pdHNFbnVtLlByb3hpbWl0", + "eVJhZGl1c1VuaXRzEjwKB2FkZHJlc3MYBCABKAsyKy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5jb21tb24uQWRkcmVzc0luZm8ijwEKDEdlb1BvaW50SW5m", + "bxI/Chpsb25naXR1ZGVfaW5fbWljcm9fZGVncmVlcxgBIAEoCzIbLmdvb2ds", + "ZS5wcm90b2J1Zi5JbnQzMlZhbHVlEj4KGWxhdGl0dWRlX2luX21pY3JvX2Rl", + "Z3JlZXMYAiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50MzJWYWx1ZSL8AgoL", + "QWRkcmVzc0luZm8SMQoLcG9zdGFsX2NvZGUYASABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWUSMwoNcHJvdmluY2VfY29kZRgCIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIyCgxjb3VudHJ5X2NvZGUYAyAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMwoNcHJvdmluY2Vf", + "bmFtZRgEIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI0Cg5z", + "dHJlZXRfYWRkcmVzcxgFIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZRI1Cg9zdHJlZXRfYWRkcmVzczIYBiABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWUSLwoJY2l0eV9uYW1lGAcgASgLMhwuZ29vZ2xlLnBy", + "b3RvYnVmLlN0cmluZ1ZhbHVlIm0KCVRvcGljSW5mbxI0Cg50b3BpY19jb25z", + "dGFudBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIqCgRw", + "YXRoGAIgAygLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlIkcKDExh", + "bmd1YWdlSW5mbxI3ChFsYW5ndWFnZV9jb25zdGFudBgBIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSI/CgtJcEJsb2NrSW5mbxIwCgppcF9h", + "ZGRyZXNzGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlImYK", + "EENvbnRlbnRMYWJlbEluZm8SUgoEdHlwZRgBIAEoDjJELmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zLkNvbnRlbnRMYWJlbFR5cGVFbnVtLkNvbnRl", + "bnRMYWJlbFR5cGUiRQoLQ2FycmllckluZm8SNgoQY2Fycmllcl9jb25zdGFu", + "dBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSJQChBVc2Vy", + "SW50ZXJlc3RJbmZvEjwKFnVzZXJfaW50ZXJlc3RfY2F0ZWdvcnkYASABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUijQEKC1dlYnBhZ2VJbmZv", + "EjQKDmNyaXRlcmlvbl9uYW1lGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlEkgKCmNvbmRpdGlvbnMYAiADKAsyNC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5jb21tb24uV2VicGFnZUNvbmRpdGlvbkluZm8ikwIKFFdl", + "YnBhZ2VDb25kaXRpb25JbmZvEmMKB29wZXJhbmQYASABKA4yUi5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtcy5XZWJwYWdlQ29uZGl0aW9uT3BlcmFu", + "ZEVudW0uV2VicGFnZUNvbmRpdGlvbk9wZXJhbmQSZgoIb3BlcmF0b3IYAiAB", + "KA4yVC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5XZWJwYWdlQ29u", + "ZGl0aW9uT3BlcmF0b3JFbnVtLldlYnBhZ2VDb25kaXRpb25PcGVyYXRvchIu", + "Cghhcmd1bWVudBgDIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZSJlChpPcGVyYXRpbmdTeXN0ZW1WZXJzaW9uSW5mbxJHCiFvcGVyYXRpbmdf", + "c3lzdGVtX3ZlcnNpb25fY29uc3RhbnQYASABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWUibwoTQXBwUGF5bWVudE1vZGVsSW5mbxJYCgR0eXBl", + "GAEgASgOMkouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQXBwUGF5", + "bWVudE1vZGVsVHlwZUVudW0uQXBwUGF5bWVudE1vZGVsVHlwZSJQChBNb2Jp", + "bGVEZXZpY2VJbmZvEjwKFm1vYmlsZV9kZXZpY2VfY29uc3RhbnQYASABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUiSwoSQ3VzdG9tQWZmaW5p", + "dHlJbmZvEjUKD2N1c3RvbV9hZmZpbml0eRgBIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZSJHChBDdXN0b21JbnRlbnRJbmZvEjMKDWN1c3Rv", + "bV9pbnRlbnQYASABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUi", + "lAIKEUxvY2F0aW9uR3JvdXBJbmZvEioKBGZlZWQYASABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWUSOgoUZ2VvX3RhcmdldF9jb25zdGFudHMY", + "AiADKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSKwoGcmFkaXVz", + "GAMgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUSagoMcmFkaXVz", + "X3VuaXRzGAQgASgOMlQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMu", + "TG9jYXRpb25Hcm91cFJhZGl1c1VuaXRzRW51bS5Mb2NhdGlvbkdyb3VwUmFk", + "aXVzVW5pdHNC6AEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21t", + "b25CDUNyaXRlcmlhUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbjtjb21tb26i", + "AgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5Db21tb27KAh5Hb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xDb21tb27qAiJHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6Q29tbW9uYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AppPaymentModelTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.DeviceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.GenderTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.HotelDateSelectionTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.IncomeRangeTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.InteractionTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ListingGroupTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.LocationGroupRadiusUnitsReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.MinuteOfHourReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ParentalStatusTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PreferredContentTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ProductBiddingCategoryLevelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ProductChannelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ProductChannelExclusivityReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ProductConditionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ProductCustomAttributeIndexReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ProductTypeLevelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ProximityRadiusUnitsReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperandReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperatorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.KeywordInfo), global::Google.Ads.GoogleAds.V3.Common.KeywordInfo.Parser, new[]{ "Text", "MatchType" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.PlacementInfo), global::Google.Ads.GoogleAds.V3.Common.PlacementInfo.Parser, new[]{ "Url" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo), global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo.Parser, new[]{ "MobileAppCategoryConstant" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo), global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo.Parser, new[]{ "AppId", "Name" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.LocationInfo), global::Google.Ads.GoogleAds.V3.Common.LocationInfo.Parser, new[]{ "GeoTargetConstant" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.DeviceInfo), global::Google.Ads.GoogleAds.V3.Common.DeviceInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.PreferredContentInfo), global::Google.Ads.GoogleAds.V3.Common.PreferredContentInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ListingGroupInfo), global::Google.Ads.GoogleAds.V3.Common.ListingGroupInfo.Parser, new[]{ "Type", "CaseValue", "ParentAdGroupCriterion" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ListingScopeInfo), global::Google.Ads.GoogleAds.V3.Common.ListingScopeInfo.Parser, new[]{ "Dimensions" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ListingDimensionInfo), global::Google.Ads.GoogleAds.V3.Common.ListingDimensionInfo.Parser, new[]{ "HotelId", "HotelClass", "HotelCountryRegion", "HotelState", "HotelCity", "ProductBiddingCategory", "ProductBrand", "ProductChannel", "ProductChannelExclusivity", "ProductCondition", "ProductCustomAttribute", "ProductItemId", "ProductType", "UnknownListingDimension" }, new[]{ "Dimension" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelIdInfo), global::Google.Ads.GoogleAds.V3.Common.HotelIdInfo.Parser, new[]{ "Value" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelClassInfo), global::Google.Ads.GoogleAds.V3.Common.HotelClassInfo.Parser, new[]{ "Value" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelCountryRegionInfo), global::Google.Ads.GoogleAds.V3.Common.HotelCountryRegionInfo.Parser, new[]{ "CountryRegionCriterion" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelStateInfo), global::Google.Ads.GoogleAds.V3.Common.HotelStateInfo.Parser, new[]{ "StateCriterion" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelCityInfo), global::Google.Ads.GoogleAds.V3.Common.HotelCityInfo.Parser, new[]{ "CityCriterion" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductBiddingCategoryInfo), global::Google.Ads.GoogleAds.V3.Common.ProductBiddingCategoryInfo.Parser, new[]{ "Id", "CountryCode", "Level" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductBrandInfo), global::Google.Ads.GoogleAds.V3.Common.ProductBrandInfo.Parser, new[]{ "Value" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductChannelInfo), global::Google.Ads.GoogleAds.V3.Common.ProductChannelInfo.Parser, new[]{ "Channel" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductChannelExclusivityInfo), global::Google.Ads.GoogleAds.V3.Common.ProductChannelExclusivityInfo.Parser, new[]{ "ChannelExclusivity" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductConditionInfo), global::Google.Ads.GoogleAds.V3.Common.ProductConditionInfo.Parser, new[]{ "Condition" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductCustomAttributeInfo), global::Google.Ads.GoogleAds.V3.Common.ProductCustomAttributeInfo.Parser, new[]{ "Value", "Index" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductItemIdInfo), global::Google.Ads.GoogleAds.V3.Common.ProductItemIdInfo.Parser, new[]{ "Value" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProductTypeInfo), global::Google.Ads.GoogleAds.V3.Common.ProductTypeInfo.Parser, new[]{ "Value", "Level" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.UnknownListingDimensionInfo), global::Google.Ads.GoogleAds.V3.Common.UnknownListingDimensionInfo.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelDateSelectionTypeInfo), global::Google.Ads.GoogleAds.V3.Common.HotelDateSelectionTypeInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelAdvanceBookingWindowInfo), global::Google.Ads.GoogleAds.V3.Common.HotelAdvanceBookingWindowInfo.Parser, new[]{ "MinDays", "MaxDays" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelLengthOfStayInfo), global::Google.Ads.GoogleAds.V3.Common.HotelLengthOfStayInfo.Parser, new[]{ "MinNights", "MaxNights" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelCheckInDayInfo), global::Google.Ads.GoogleAds.V3.Common.HotelCheckInDayInfo.Parser, new[]{ "DayOfWeek" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.InteractionTypeInfo), global::Google.Ads.GoogleAds.V3.Common.InteractionTypeInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo), global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo.Parser, new[]{ "StartMinute", "EndMinute", "StartHour", "EndHour", "DayOfWeek" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo), global::Google.Ads.GoogleAds.V3.Common.AgeRangeInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.GenderInfo), global::Google.Ads.GoogleAds.V3.Common.GenderInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo), global::Google.Ads.GoogleAds.V3.Common.IncomeRangeInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo), global::Google.Ads.GoogleAds.V3.Common.ParentalStatusInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo), global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo.Parser, new[]{ "VideoId" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo), global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo.Parser, new[]{ "ChannelId" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.UserListInfo), global::Google.Ads.GoogleAds.V3.Common.UserListInfo.Parser, new[]{ "UserList" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ProximityInfo), global::Google.Ads.GoogleAds.V3.Common.ProximityInfo.Parser, new[]{ "GeoPoint", "Radius", "RadiusUnits", "Address" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.GeoPointInfo), global::Google.Ads.GoogleAds.V3.Common.GeoPointInfo.Parser, new[]{ "LongitudeInMicroDegrees", "LatitudeInMicroDegrees" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AddressInfo), global::Google.Ads.GoogleAds.V3.Common.AddressInfo.Parser, new[]{ "PostalCode", "ProvinceCode", "CountryCode", "ProvinceName", "StreetAddress", "StreetAddress2", "CityName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TopicInfo), global::Google.Ads.GoogleAds.V3.Common.TopicInfo.Parser, new[]{ "TopicConstant", "Path" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.LanguageInfo), global::Google.Ads.GoogleAds.V3.Common.LanguageInfo.Parser, new[]{ "LanguageConstant" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.IpBlockInfo), global::Google.Ads.GoogleAds.V3.Common.IpBlockInfo.Parser, new[]{ "IpAddress" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo), global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CarrierInfo), global::Google.Ads.GoogleAds.V3.Common.CarrierInfo.Parser, new[]{ "CarrierConstant" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo), global::Google.Ads.GoogleAds.V3.Common.UserInterestInfo.Parser, new[]{ "UserInterestCategory" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.WebpageInfo), global::Google.Ads.GoogleAds.V3.Common.WebpageInfo.Parser, new[]{ "CriterionName", "Conditions" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.WebpageConditionInfo), global::Google.Ads.GoogleAds.V3.Common.WebpageConditionInfo.Parser, new[]{ "Operand", "Operator", "Argument" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.OperatingSystemVersionInfo), global::Google.Ads.GoogleAds.V3.Common.OperatingSystemVersionInfo.Parser, new[]{ "OperatingSystemVersionConstant" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AppPaymentModelInfo), global::Google.Ads.GoogleAds.V3.Common.AppPaymentModelInfo.Parser, new[]{ "Type" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.MobileDeviceInfo), global::Google.Ads.GoogleAds.V3.Common.MobileDeviceInfo.Parser, new[]{ "MobileDeviceConstant" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo), global::Google.Ads.GoogleAds.V3.Common.CustomAffinityInfo.Parser, new[]{ "CustomAffinity" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CustomIntentInfo), global::Google.Ads.GoogleAds.V3.Common.CustomIntentInfo.Parser, new[]{ "CustomIntent" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.LocationGroupInfo), global::Google.Ads.GoogleAds.V3.Common.LocationGroupInfo.Parser, new[]{ "Feed", "GeoTargetConstants", "Radius", "RadiusUnits" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A keyword criterion. + /// + public sealed partial class KeywordInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordInfo(KeywordInfo other) : this() { + Text = other.Text; + matchType_ = other.matchType_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordInfo Clone() { + return new KeywordInfo(this); + } + + /// Field number for the "text" field. + public const int TextFieldNumber = 1; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(10); + private string text_; + /// + /// The text of the keyword (at most 80 characters and 10 words). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + /// Field number for the "match_type" field. + public const int MatchTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType matchType_ = 0; + /// + /// The match type of the keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType MatchType { + get { return matchType_; } + set { + matchType_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Text != other.Text) return false; + if (MatchType != other.MatchType) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (text_ != null) hash ^= Text.GetHashCode(); + if (MatchType != 0) hash ^= MatchType.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (MatchType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) MatchType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (MatchType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MatchType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordInfo other) { + if (other == null) { + return; + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + if (other.MatchType != 0) { + MatchType = other.MatchType; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + case 16: { + MatchType = (global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A placement criterion. This can be used to modify bids for sites when + /// targeting the content network. + /// + public sealed partial class PlacementInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PlacementInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PlacementInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PlacementInfo(PlacementInfo other) : this() { + Url = other.Url; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PlacementInfo Clone() { + return new PlacementInfo(this); + } + + /// Field number for the "url" field. + public const int UrlFieldNumber = 1; + private static readonly pb::FieldCodec _single_url_codec = pb::FieldCodec.ForClassWrapper(10); + private string url_; + /// + /// URL of the placement. + /// + /// For example, "http://www.domain.com". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Url { + get { return url_; } + set { + url_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PlacementInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PlacementInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Url != other.Url) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (url_ != null) hash ^= Url.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (url_ != null) { + _single_url_codec.WriteTagAndValue(output, Url); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (url_ != null) { + size += _single_url_codec.CalculateSizeWithTag(Url); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PlacementInfo other) { + if (other == null) { + return; + } + if (other.url_ != null) { + if (url_ == null || other.Url != "") { + Url = other.Url; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_url_codec.Read(input); + if (url_ == null || value != "") { + Url = value; + } + break; + } + } + } + } + + } + + /// + /// A mobile app category criterion. + /// + public sealed partial class MobileAppCategoryInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MobileAppCategoryInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileAppCategoryInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileAppCategoryInfo(MobileAppCategoryInfo other) : this() { + MobileAppCategoryConstant = other.MobileAppCategoryConstant; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileAppCategoryInfo Clone() { + return new MobileAppCategoryInfo(this); + } + + /// Field number for the "mobile_app_category_constant" field. + public const int MobileAppCategoryConstantFieldNumber = 1; + private static readonly pb::FieldCodec _single_mobileAppCategoryConstant_codec = pb::FieldCodec.ForClassWrapper(10); + private string mobileAppCategoryConstant_; + /// + /// The mobile app category constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MobileAppCategoryConstant { + get { return mobileAppCategoryConstant_; } + set { + mobileAppCategoryConstant_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MobileAppCategoryInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MobileAppCategoryInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (MobileAppCategoryConstant != other.MobileAppCategoryConstant) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (mobileAppCategoryConstant_ != null) hash ^= MobileAppCategoryConstant.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (mobileAppCategoryConstant_ != null) { + _single_mobileAppCategoryConstant_codec.WriteTagAndValue(output, MobileAppCategoryConstant); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (mobileAppCategoryConstant_ != null) { + size += _single_mobileAppCategoryConstant_codec.CalculateSizeWithTag(MobileAppCategoryConstant); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MobileAppCategoryInfo other) { + if (other == null) { + return; + } + if (other.mobileAppCategoryConstant_ != null) { + if (mobileAppCategoryConstant_ == null || other.MobileAppCategoryConstant != "") { + MobileAppCategoryConstant = other.MobileAppCategoryConstant; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_mobileAppCategoryConstant_codec.Read(input); + if (mobileAppCategoryConstant_ == null || value != "") { + MobileAppCategoryConstant = value; + } + break; + } + } + } + } + + } + + /// + /// A mobile application criterion. + /// + public sealed partial class MobileApplicationInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MobileApplicationInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileApplicationInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileApplicationInfo(MobileApplicationInfo other) : this() { + AppId = other.AppId; + Name = other.Name; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileApplicationInfo Clone() { + return new MobileApplicationInfo(this); + } + + /// Field number for the "app_id" field. + public const int AppIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_appId_codec = pb::FieldCodec.ForClassWrapper(18); + private string appId_; + /// + /// A string that uniquely identifies a mobile application to Google Ads API. + /// The format of this string is "{platform}-{platform_native_id}", where + /// platform is "1" for iOS apps and "2" for Android apps, and where + /// platform_native_id is the mobile application identifier native to the + /// corresponding platform. + /// For iOS, this native identifier is the 9 digit string that appears at the + /// end of an App Store URL (e.g., "476943146" for "Flood-It! 2" whose App + /// Store link is "http://itunes.apple.com/us/app/flood-it!-2/id476943146"). + /// For Android, this native identifier is the application's package name + /// (e.g., "com.labpixies.colordrips" for "Color Drips" given Google Play link + /// "https://play.google.com/store/apps/details?id=com.labpixies.colordrips"). + /// A well formed app id for Google Ads API would thus be "1-476943146" for iOS + /// and "2-com.labpixies.colordrips" for Android. + /// This field is required and must be set in CREATE operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AppId { + get { return appId_; } + set { + appId_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 3; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(26); + private string name_; + /// + /// Name of this mobile application. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MobileApplicationInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MobileApplicationInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (AppId != other.AppId) return false; + if (Name != other.Name) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (appId_ != null) hash ^= AppId.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (appId_ != null) { + _single_appId_codec.WriteTagAndValue(output, AppId); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (appId_ != null) { + size += _single_appId_codec.CalculateSizeWithTag(AppId); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MobileApplicationInfo other) { + if (other == null) { + return; + } + if (other.appId_ != null) { + if (appId_ == null || other.AppId != "") { + AppId = other.AppId; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + string value = _single_appId_codec.Read(input); + if (appId_ == null || value != "") { + AppId = value; + } + break; + } + case 26: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + } + } + } + + } + + /// + /// A location criterion. + /// + public sealed partial class LocationInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new LocationInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationInfo(LocationInfo other) : this() { + GeoTargetConstant = other.GeoTargetConstant; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationInfo Clone() { + return new LocationInfo(this); + } + + /// Field number for the "geo_target_constant" field. + public const int GeoTargetConstantFieldNumber = 1; + private static readonly pb::FieldCodec _single_geoTargetConstant_codec = pb::FieldCodec.ForClassWrapper(10); + private string geoTargetConstant_; + /// + /// The geo target constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string GeoTargetConstant { + get { return geoTargetConstant_; } + set { + geoTargetConstant_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as LocationInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(LocationInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (GeoTargetConstant != other.GeoTargetConstant) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (geoTargetConstant_ != null) hash ^= GeoTargetConstant.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (geoTargetConstant_ != null) { + _single_geoTargetConstant_codec.WriteTagAndValue(output, GeoTargetConstant); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (geoTargetConstant_ != null) { + size += _single_geoTargetConstant_codec.CalculateSizeWithTag(GeoTargetConstant); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(LocationInfo other) { + if (other == null) { + return; + } + if (other.geoTargetConstant_ != null) { + if (geoTargetConstant_ == null || other.GeoTargetConstant != "") { + GeoTargetConstant = other.GeoTargetConstant; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_geoTargetConstant_codec.Read(input); + if (geoTargetConstant_ == null || value != "") { + GeoTargetConstant = value; + } + break; + } + } + } + } + + } + + /// + /// A device criterion. + /// + public sealed partial class DeviceInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DeviceInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DeviceInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DeviceInfo(DeviceInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DeviceInfo Clone() { + return new DeviceInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types.Device type_ = 0; + /// + /// Type of the device. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types.Device Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DeviceInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DeviceInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DeviceInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types.Device) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A preferred content criterion. + /// + public sealed partial class PreferredContentInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PreferredContentInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PreferredContentInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PreferredContentInfo(PreferredContentInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PreferredContentInfo Clone() { + return new PreferredContentInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.PreferredContentTypeEnum.Types.PreferredContentType type_ = 0; + /// + /// Type of the preferred content. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PreferredContentTypeEnum.Types.PreferredContentType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PreferredContentInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PreferredContentInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PreferredContentInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 16: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.PreferredContentTypeEnum.Types.PreferredContentType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A listing group criterion. + /// + public sealed partial class ListingGroupInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListingGroupInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingGroupInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingGroupInfo(ListingGroupInfo other) : this() { + type_ = other.type_; + caseValue_ = other.caseValue_ != null ? other.caseValue_.Clone() : null; + ParentAdGroupCriterion = other.ParentAdGroupCriterion; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingGroupInfo Clone() { + return new ListingGroupInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.ListingGroupTypeEnum.Types.ListingGroupType type_ = 0; + /// + /// Type of the listing group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ListingGroupTypeEnum.Types.ListingGroupType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "case_value" field. + public const int CaseValueFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Common.ListingDimensionInfo caseValue_; + /// + /// Dimension value with which this listing group is refining its parent. + /// Undefined for the root group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ListingDimensionInfo CaseValue { + get { return caseValue_; } + set { + caseValue_ = value; + } + } + + /// Field number for the "parent_ad_group_criterion" field. + public const int ParentAdGroupCriterionFieldNumber = 3; + private static readonly pb::FieldCodec _single_parentAdGroupCriterion_codec = pb::FieldCodec.ForClassWrapper(26); + private string parentAdGroupCriterion_; + /// + /// Resource name of ad group criterion which is the parent listing group + /// subdivision. Null for the root group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ParentAdGroupCriterion { + get { return parentAdGroupCriterion_; } + set { + parentAdGroupCriterion_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListingGroupInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListingGroupInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + if (!object.Equals(CaseValue, other.CaseValue)) return false; + if (ParentAdGroupCriterion != other.ParentAdGroupCriterion) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (caseValue_ != null) hash ^= CaseValue.GetHashCode(); + if (parentAdGroupCriterion_ != null) hash ^= ParentAdGroupCriterion.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (caseValue_ != null) { + output.WriteRawTag(18); + output.WriteMessage(CaseValue); + } + if (parentAdGroupCriterion_ != null) { + _single_parentAdGroupCriterion_codec.WriteTagAndValue(output, ParentAdGroupCriterion); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (caseValue_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CaseValue); + } + if (parentAdGroupCriterion_ != null) { + size += _single_parentAdGroupCriterion_codec.CalculateSizeWithTag(ParentAdGroupCriterion); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListingGroupInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.caseValue_ != null) { + if (caseValue_ == null) { + CaseValue = new global::Google.Ads.GoogleAds.V3.Common.ListingDimensionInfo(); + } + CaseValue.MergeFrom(other.CaseValue); + } + if (other.parentAdGroupCriterion_ != null) { + if (parentAdGroupCriterion_ == null || other.ParentAdGroupCriterion != "") { + ParentAdGroupCriterion = other.ParentAdGroupCriterion; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.ListingGroupTypeEnum.Types.ListingGroupType) input.ReadEnum(); + break; + } + case 18: { + if (caseValue_ == null) { + CaseValue = new global::Google.Ads.GoogleAds.V3.Common.ListingDimensionInfo(); + } + input.ReadMessage(CaseValue); + break; + } + case 26: { + string value = _single_parentAdGroupCriterion_codec.Read(input); + if (parentAdGroupCriterion_ == null || value != "") { + ParentAdGroupCriterion = value; + } + break; + } + } + } + } + + } + + /// + /// A listing scope criterion. + /// + public sealed partial class ListingScopeInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListingScopeInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingScopeInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingScopeInfo(ListingScopeInfo other) : this() { + dimensions_ = other.dimensions_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingScopeInfo Clone() { + return new ListingScopeInfo(this); + } + + /// Field number for the "dimensions" field. + public const int DimensionsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_dimensions_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Common.ListingDimensionInfo.Parser); + private readonly pbc::RepeatedField dimensions_ = new pbc::RepeatedField(); + /// + /// Scope of the campaign criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Dimensions { + get { return dimensions_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListingScopeInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListingScopeInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!dimensions_.Equals(other.dimensions_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= dimensions_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + dimensions_.WriteTo(output, _repeated_dimensions_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += dimensions_.CalculateSize(_repeated_dimensions_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListingScopeInfo other) { + if (other == null) { + return; + } + dimensions_.Add(other.dimensions_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + dimensions_.AddEntriesFrom(input, _repeated_dimensions_codec); + break; + } + } + } + } + + } + + /// + /// Listing dimensions for listing group criterion. + /// + public sealed partial class ListingDimensionInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListingDimensionInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[9]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingDimensionInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingDimensionInfo(ListingDimensionInfo other) : this() { + switch (other.DimensionCase) { + case DimensionOneofCase.HotelId: + HotelId = other.HotelId.Clone(); + break; + case DimensionOneofCase.HotelClass: + HotelClass = other.HotelClass.Clone(); + break; + case DimensionOneofCase.HotelCountryRegion: + HotelCountryRegion = other.HotelCountryRegion.Clone(); + break; + case DimensionOneofCase.HotelState: + HotelState = other.HotelState.Clone(); + break; + case DimensionOneofCase.HotelCity: + HotelCity = other.HotelCity.Clone(); + break; + case DimensionOneofCase.ProductBiddingCategory: + ProductBiddingCategory = other.ProductBiddingCategory.Clone(); + break; + case DimensionOneofCase.ProductBrand: + ProductBrand = other.ProductBrand.Clone(); + break; + case DimensionOneofCase.ProductChannel: + ProductChannel = other.ProductChannel.Clone(); + break; + case DimensionOneofCase.ProductChannelExclusivity: + ProductChannelExclusivity = other.ProductChannelExclusivity.Clone(); + break; + case DimensionOneofCase.ProductCondition: + ProductCondition = other.ProductCondition.Clone(); + break; + case DimensionOneofCase.ProductCustomAttribute: + ProductCustomAttribute = other.ProductCustomAttribute.Clone(); + break; + case DimensionOneofCase.ProductItemId: + ProductItemId = other.ProductItemId.Clone(); + break; + case DimensionOneofCase.ProductType: + ProductType = other.ProductType.Clone(); + break; + case DimensionOneofCase.UnknownListingDimension: + UnknownListingDimension = other.UnknownListingDimension.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListingDimensionInfo Clone() { + return new ListingDimensionInfo(this); + } + + /// Field number for the "hotel_id" field. + public const int HotelIdFieldNumber = 2; + /// + /// Advertiser-specific hotel ID. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelIdInfo HotelId { + get { return dimensionCase_ == DimensionOneofCase.HotelId ? (global::Google.Ads.GoogleAds.V3.Common.HotelIdInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.HotelId; + } + } + + /// Field number for the "hotel_class" field. + public const int HotelClassFieldNumber = 3; + /// + /// Class of the hotel as a number of stars 1 to 5. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelClassInfo HotelClass { + get { return dimensionCase_ == DimensionOneofCase.HotelClass ? (global::Google.Ads.GoogleAds.V3.Common.HotelClassInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.HotelClass; + } + } + + /// Field number for the "hotel_country_region" field. + public const int HotelCountryRegionFieldNumber = 4; + /// + /// Country or Region the hotel is located in. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelCountryRegionInfo HotelCountryRegion { + get { return dimensionCase_ == DimensionOneofCase.HotelCountryRegion ? (global::Google.Ads.GoogleAds.V3.Common.HotelCountryRegionInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.HotelCountryRegion; + } + } + + /// Field number for the "hotel_state" field. + public const int HotelStateFieldNumber = 5; + /// + /// State the hotel is located in. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelStateInfo HotelState { + get { return dimensionCase_ == DimensionOneofCase.HotelState ? (global::Google.Ads.GoogleAds.V3.Common.HotelStateInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.HotelState; + } + } + + /// Field number for the "hotel_city" field. + public const int HotelCityFieldNumber = 6; + /// + /// City the hotel is located in. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelCityInfo HotelCity { + get { return dimensionCase_ == DimensionOneofCase.HotelCity ? (global::Google.Ads.GoogleAds.V3.Common.HotelCityInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.HotelCity; + } + } + + /// Field number for the "product_bidding_category" field. + public const int ProductBiddingCategoryFieldNumber = 13; + /// + /// Bidding category of a product offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProductBiddingCategoryInfo ProductBiddingCategory { + get { return dimensionCase_ == DimensionOneofCase.ProductBiddingCategory ? (global::Google.Ads.GoogleAds.V3.Common.ProductBiddingCategoryInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.ProductBiddingCategory; + } + } + + /// Field number for the "product_brand" field. + public const int ProductBrandFieldNumber = 15; + /// + /// Brand of a product offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProductBrandInfo ProductBrand { + get { return dimensionCase_ == DimensionOneofCase.ProductBrand ? (global::Google.Ads.GoogleAds.V3.Common.ProductBrandInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.ProductBrand; + } + } + + /// Field number for the "product_channel" field. + public const int ProductChannelFieldNumber = 8; + /// + /// Locality of a product offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProductChannelInfo ProductChannel { + get { return dimensionCase_ == DimensionOneofCase.ProductChannel ? (global::Google.Ads.GoogleAds.V3.Common.ProductChannelInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.ProductChannel; + } + } + + /// Field number for the "product_channel_exclusivity" field. + public const int ProductChannelExclusivityFieldNumber = 9; + /// + /// Availability of a product offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProductChannelExclusivityInfo ProductChannelExclusivity { + get { return dimensionCase_ == DimensionOneofCase.ProductChannelExclusivity ? (global::Google.Ads.GoogleAds.V3.Common.ProductChannelExclusivityInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.ProductChannelExclusivity; + } + } + + /// Field number for the "product_condition" field. + public const int ProductConditionFieldNumber = 10; + /// + /// Condition of a product offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProductConditionInfo ProductCondition { + get { return dimensionCase_ == DimensionOneofCase.ProductCondition ? (global::Google.Ads.GoogleAds.V3.Common.ProductConditionInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.ProductCondition; + } + } + + /// Field number for the "product_custom_attribute" field. + public const int ProductCustomAttributeFieldNumber = 16; + /// + /// Custom attribute of a product offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProductCustomAttributeInfo ProductCustomAttribute { + get { return dimensionCase_ == DimensionOneofCase.ProductCustomAttribute ? (global::Google.Ads.GoogleAds.V3.Common.ProductCustomAttributeInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.ProductCustomAttribute; + } + } + + /// Field number for the "product_item_id" field. + public const int ProductItemIdFieldNumber = 11; + /// + /// Item id of a product offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProductItemIdInfo ProductItemId { + get { return dimensionCase_ == DimensionOneofCase.ProductItemId ? (global::Google.Ads.GoogleAds.V3.Common.ProductItemIdInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.ProductItemId; + } + } + + /// Field number for the "product_type" field. + public const int ProductTypeFieldNumber = 12; + /// + /// Type of a product offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ProductTypeInfo ProductType { + get { return dimensionCase_ == DimensionOneofCase.ProductType ? (global::Google.Ads.GoogleAds.V3.Common.ProductTypeInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.ProductType; + } + } + + /// Field number for the "unknown_listing_dimension" field. + public const int UnknownListingDimensionFieldNumber = 14; + /// + /// Unknown dimension. Set when no other listing dimension is set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.UnknownListingDimensionInfo UnknownListingDimension { + get { return dimensionCase_ == DimensionOneofCase.UnknownListingDimension ? (global::Google.Ads.GoogleAds.V3.Common.UnknownListingDimensionInfo) dimension_ : null; } + set { + dimension_ = value; + dimensionCase_ = value == null ? DimensionOneofCase.None : DimensionOneofCase.UnknownListingDimension; + } + } + + private object dimension_; + /// Enum of possible cases for the "dimension" oneof. + public enum DimensionOneofCase { + None = 0, + HotelId = 2, + HotelClass = 3, + HotelCountryRegion = 4, + HotelState = 5, + HotelCity = 6, + ProductBiddingCategory = 13, + ProductBrand = 15, + ProductChannel = 8, + ProductChannelExclusivity = 9, + ProductCondition = 10, + ProductCustomAttribute = 16, + ProductItemId = 11, + ProductType = 12, + UnknownListingDimension = 14, + } + private DimensionOneofCase dimensionCase_ = DimensionOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DimensionOneofCase DimensionCase { + get { return dimensionCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearDimension() { + dimensionCase_ = DimensionOneofCase.None; + dimension_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListingDimensionInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListingDimensionInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(HotelId, other.HotelId)) return false; + if (!object.Equals(HotelClass, other.HotelClass)) return false; + if (!object.Equals(HotelCountryRegion, other.HotelCountryRegion)) return false; + if (!object.Equals(HotelState, other.HotelState)) return false; + if (!object.Equals(HotelCity, other.HotelCity)) return false; + if (!object.Equals(ProductBiddingCategory, other.ProductBiddingCategory)) return false; + if (!object.Equals(ProductBrand, other.ProductBrand)) return false; + if (!object.Equals(ProductChannel, other.ProductChannel)) return false; + if (!object.Equals(ProductChannelExclusivity, other.ProductChannelExclusivity)) return false; + if (!object.Equals(ProductCondition, other.ProductCondition)) return false; + if (!object.Equals(ProductCustomAttribute, other.ProductCustomAttribute)) return false; + if (!object.Equals(ProductItemId, other.ProductItemId)) return false; + if (!object.Equals(ProductType, other.ProductType)) return false; + if (!object.Equals(UnknownListingDimension, other.UnknownListingDimension)) return false; + if (DimensionCase != other.DimensionCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (dimensionCase_ == DimensionOneofCase.HotelId) hash ^= HotelId.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.HotelClass) hash ^= HotelClass.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.HotelCountryRegion) hash ^= HotelCountryRegion.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.HotelState) hash ^= HotelState.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.HotelCity) hash ^= HotelCity.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.ProductBiddingCategory) hash ^= ProductBiddingCategory.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.ProductBrand) hash ^= ProductBrand.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.ProductChannel) hash ^= ProductChannel.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.ProductChannelExclusivity) hash ^= ProductChannelExclusivity.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.ProductCondition) hash ^= ProductCondition.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.ProductCustomAttribute) hash ^= ProductCustomAttribute.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.ProductItemId) hash ^= ProductItemId.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.ProductType) hash ^= ProductType.GetHashCode(); + if (dimensionCase_ == DimensionOneofCase.UnknownListingDimension) hash ^= UnknownListingDimension.GetHashCode(); + hash ^= (int) dimensionCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (dimensionCase_ == DimensionOneofCase.HotelId) { + output.WriteRawTag(18); + output.WriteMessage(HotelId); + } + if (dimensionCase_ == DimensionOneofCase.HotelClass) { + output.WriteRawTag(26); + output.WriteMessage(HotelClass); + } + if (dimensionCase_ == DimensionOneofCase.HotelCountryRegion) { + output.WriteRawTag(34); + output.WriteMessage(HotelCountryRegion); + } + if (dimensionCase_ == DimensionOneofCase.HotelState) { + output.WriteRawTag(42); + output.WriteMessage(HotelState); + } + if (dimensionCase_ == DimensionOneofCase.HotelCity) { + output.WriteRawTag(50); + output.WriteMessage(HotelCity); + } + if (dimensionCase_ == DimensionOneofCase.ProductChannel) { + output.WriteRawTag(66); + output.WriteMessage(ProductChannel); + } + if (dimensionCase_ == DimensionOneofCase.ProductChannelExclusivity) { + output.WriteRawTag(74); + output.WriteMessage(ProductChannelExclusivity); + } + if (dimensionCase_ == DimensionOneofCase.ProductCondition) { + output.WriteRawTag(82); + output.WriteMessage(ProductCondition); + } + if (dimensionCase_ == DimensionOneofCase.ProductItemId) { + output.WriteRawTag(90); + output.WriteMessage(ProductItemId); + } + if (dimensionCase_ == DimensionOneofCase.ProductType) { + output.WriteRawTag(98); + output.WriteMessage(ProductType); + } + if (dimensionCase_ == DimensionOneofCase.ProductBiddingCategory) { + output.WriteRawTag(106); + output.WriteMessage(ProductBiddingCategory); + } + if (dimensionCase_ == DimensionOneofCase.UnknownListingDimension) { + output.WriteRawTag(114); + output.WriteMessage(UnknownListingDimension); + } + if (dimensionCase_ == DimensionOneofCase.ProductBrand) { + output.WriteRawTag(122); + output.WriteMessage(ProductBrand); + } + if (dimensionCase_ == DimensionOneofCase.ProductCustomAttribute) { + output.WriteRawTag(130, 1); + output.WriteMessage(ProductCustomAttribute); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (dimensionCase_ == DimensionOneofCase.HotelId) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelId); + } + if (dimensionCase_ == DimensionOneofCase.HotelClass) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelClass); + } + if (dimensionCase_ == DimensionOneofCase.HotelCountryRegion) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelCountryRegion); + } + if (dimensionCase_ == DimensionOneofCase.HotelState) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelState); + } + if (dimensionCase_ == DimensionOneofCase.HotelCity) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(HotelCity); + } + if (dimensionCase_ == DimensionOneofCase.ProductBiddingCategory) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ProductBiddingCategory); + } + if (dimensionCase_ == DimensionOneofCase.ProductBrand) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ProductBrand); + } + if (dimensionCase_ == DimensionOneofCase.ProductChannel) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ProductChannel); + } + if (dimensionCase_ == DimensionOneofCase.ProductChannelExclusivity) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ProductChannelExclusivity); + } + if (dimensionCase_ == DimensionOneofCase.ProductCondition) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ProductCondition); + } + if (dimensionCase_ == DimensionOneofCase.ProductCustomAttribute) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ProductCustomAttribute); + } + if (dimensionCase_ == DimensionOneofCase.ProductItemId) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ProductItemId); + } + if (dimensionCase_ == DimensionOneofCase.ProductType) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ProductType); + } + if (dimensionCase_ == DimensionOneofCase.UnknownListingDimension) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UnknownListingDimension); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListingDimensionInfo other) { + if (other == null) { + return; + } + switch (other.DimensionCase) { + case DimensionOneofCase.HotelId: + if (HotelId == null) { + HotelId = new global::Google.Ads.GoogleAds.V3.Common.HotelIdInfo(); + } + HotelId.MergeFrom(other.HotelId); + break; + case DimensionOneofCase.HotelClass: + if (HotelClass == null) { + HotelClass = new global::Google.Ads.GoogleAds.V3.Common.HotelClassInfo(); + } + HotelClass.MergeFrom(other.HotelClass); + break; + case DimensionOneofCase.HotelCountryRegion: + if (HotelCountryRegion == null) { + HotelCountryRegion = new global::Google.Ads.GoogleAds.V3.Common.HotelCountryRegionInfo(); + } + HotelCountryRegion.MergeFrom(other.HotelCountryRegion); + break; + case DimensionOneofCase.HotelState: + if (HotelState == null) { + HotelState = new global::Google.Ads.GoogleAds.V3.Common.HotelStateInfo(); + } + HotelState.MergeFrom(other.HotelState); + break; + case DimensionOneofCase.HotelCity: + if (HotelCity == null) { + HotelCity = new global::Google.Ads.GoogleAds.V3.Common.HotelCityInfo(); + } + HotelCity.MergeFrom(other.HotelCity); + break; + case DimensionOneofCase.ProductBiddingCategory: + if (ProductBiddingCategory == null) { + ProductBiddingCategory = new global::Google.Ads.GoogleAds.V3.Common.ProductBiddingCategoryInfo(); + } + ProductBiddingCategory.MergeFrom(other.ProductBiddingCategory); + break; + case DimensionOneofCase.ProductBrand: + if (ProductBrand == null) { + ProductBrand = new global::Google.Ads.GoogleAds.V3.Common.ProductBrandInfo(); + } + ProductBrand.MergeFrom(other.ProductBrand); + break; + case DimensionOneofCase.ProductChannel: + if (ProductChannel == null) { + ProductChannel = new global::Google.Ads.GoogleAds.V3.Common.ProductChannelInfo(); + } + ProductChannel.MergeFrom(other.ProductChannel); + break; + case DimensionOneofCase.ProductChannelExclusivity: + if (ProductChannelExclusivity == null) { + ProductChannelExclusivity = new global::Google.Ads.GoogleAds.V3.Common.ProductChannelExclusivityInfo(); + } + ProductChannelExclusivity.MergeFrom(other.ProductChannelExclusivity); + break; + case DimensionOneofCase.ProductCondition: + if (ProductCondition == null) { + ProductCondition = new global::Google.Ads.GoogleAds.V3.Common.ProductConditionInfo(); + } + ProductCondition.MergeFrom(other.ProductCondition); + break; + case DimensionOneofCase.ProductCustomAttribute: + if (ProductCustomAttribute == null) { + ProductCustomAttribute = new global::Google.Ads.GoogleAds.V3.Common.ProductCustomAttributeInfo(); + } + ProductCustomAttribute.MergeFrom(other.ProductCustomAttribute); + break; + case DimensionOneofCase.ProductItemId: + if (ProductItemId == null) { + ProductItemId = new global::Google.Ads.GoogleAds.V3.Common.ProductItemIdInfo(); + } + ProductItemId.MergeFrom(other.ProductItemId); + break; + case DimensionOneofCase.ProductType: + if (ProductType == null) { + ProductType = new global::Google.Ads.GoogleAds.V3.Common.ProductTypeInfo(); + } + ProductType.MergeFrom(other.ProductType); + break; + case DimensionOneofCase.UnknownListingDimension: + if (UnknownListingDimension == null) { + UnknownListingDimension = new global::Google.Ads.GoogleAds.V3.Common.UnknownListingDimensionInfo(); + } + UnknownListingDimension.MergeFrom(other.UnknownListingDimension); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + global::Google.Ads.GoogleAds.V3.Common.HotelIdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelIdInfo(); + if (dimensionCase_ == DimensionOneofCase.HotelId) { + subBuilder.MergeFrom(HotelId); + } + input.ReadMessage(subBuilder); + HotelId = subBuilder; + break; + } + case 26: { + global::Google.Ads.GoogleAds.V3.Common.HotelClassInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelClassInfo(); + if (dimensionCase_ == DimensionOneofCase.HotelClass) { + subBuilder.MergeFrom(HotelClass); + } + input.ReadMessage(subBuilder); + HotelClass = subBuilder; + break; + } + case 34: { + global::Google.Ads.GoogleAds.V3.Common.HotelCountryRegionInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelCountryRegionInfo(); + if (dimensionCase_ == DimensionOneofCase.HotelCountryRegion) { + subBuilder.MergeFrom(HotelCountryRegion); + } + input.ReadMessage(subBuilder); + HotelCountryRegion = subBuilder; + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Common.HotelStateInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelStateInfo(); + if (dimensionCase_ == DimensionOneofCase.HotelState) { + subBuilder.MergeFrom(HotelState); + } + input.ReadMessage(subBuilder); + HotelState = subBuilder; + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Common.HotelCityInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelCityInfo(); + if (dimensionCase_ == DimensionOneofCase.HotelCity) { + subBuilder.MergeFrom(HotelCity); + } + input.ReadMessage(subBuilder); + HotelCity = subBuilder; + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.ProductChannelInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProductChannelInfo(); + if (dimensionCase_ == DimensionOneofCase.ProductChannel) { + subBuilder.MergeFrom(ProductChannel); + } + input.ReadMessage(subBuilder); + ProductChannel = subBuilder; + break; + } + case 74: { + global::Google.Ads.GoogleAds.V3.Common.ProductChannelExclusivityInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProductChannelExclusivityInfo(); + if (dimensionCase_ == DimensionOneofCase.ProductChannelExclusivity) { + subBuilder.MergeFrom(ProductChannelExclusivity); + } + input.ReadMessage(subBuilder); + ProductChannelExclusivity = subBuilder; + break; + } + case 82: { + global::Google.Ads.GoogleAds.V3.Common.ProductConditionInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProductConditionInfo(); + if (dimensionCase_ == DimensionOneofCase.ProductCondition) { + subBuilder.MergeFrom(ProductCondition); + } + input.ReadMessage(subBuilder); + ProductCondition = subBuilder; + break; + } + case 90: { + global::Google.Ads.GoogleAds.V3.Common.ProductItemIdInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProductItemIdInfo(); + if (dimensionCase_ == DimensionOneofCase.ProductItemId) { + subBuilder.MergeFrom(ProductItemId); + } + input.ReadMessage(subBuilder); + ProductItemId = subBuilder; + break; + } + case 98: { + global::Google.Ads.GoogleAds.V3.Common.ProductTypeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProductTypeInfo(); + if (dimensionCase_ == DimensionOneofCase.ProductType) { + subBuilder.MergeFrom(ProductType); + } + input.ReadMessage(subBuilder); + ProductType = subBuilder; + break; + } + case 106: { + global::Google.Ads.GoogleAds.V3.Common.ProductBiddingCategoryInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProductBiddingCategoryInfo(); + if (dimensionCase_ == DimensionOneofCase.ProductBiddingCategory) { + subBuilder.MergeFrom(ProductBiddingCategory); + } + input.ReadMessage(subBuilder); + ProductBiddingCategory = subBuilder; + break; + } + case 114: { + global::Google.Ads.GoogleAds.V3.Common.UnknownListingDimensionInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.UnknownListingDimensionInfo(); + if (dimensionCase_ == DimensionOneofCase.UnknownListingDimension) { + subBuilder.MergeFrom(UnknownListingDimension); + } + input.ReadMessage(subBuilder); + UnknownListingDimension = subBuilder; + break; + } + case 122: { + global::Google.Ads.GoogleAds.V3.Common.ProductBrandInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProductBrandInfo(); + if (dimensionCase_ == DimensionOneofCase.ProductBrand) { + subBuilder.MergeFrom(ProductBrand); + } + input.ReadMessage(subBuilder); + ProductBrand = subBuilder; + break; + } + case 130: { + global::Google.Ads.GoogleAds.V3.Common.ProductCustomAttributeInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ProductCustomAttributeInfo(); + if (dimensionCase_ == DimensionOneofCase.ProductCustomAttribute) { + subBuilder.MergeFrom(ProductCustomAttribute); + } + input.ReadMessage(subBuilder); + ProductCustomAttribute = subBuilder; + break; + } + } + } + } + + } + + /// + /// Advertiser-specific hotel ID. + /// + public sealed partial class HotelIdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelIdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[10]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelIdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelIdInfo(HotelIdInfo other) : this() { + Value = other.Value; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelIdInfo Clone() { + return new HotelIdInfo(this); + } + + /// Field number for the "value" field. + public const int ValueFieldNumber = 1; + private static readonly pb::FieldCodec _single_value_codec = pb::FieldCodec.ForClassWrapper(10); + private string value_; + /// + /// String value of the hotel ID. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Value { + get { return value_; } + set { + value_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelIdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelIdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Value != other.Value) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (value_ != null) hash ^= Value.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (value_ != null) { + _single_value_codec.WriteTagAndValue(output, Value); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (value_ != null) { + size += _single_value_codec.CalculateSizeWithTag(Value); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelIdInfo other) { + if (other == null) { + return; + } + if (other.value_ != null) { + if (value_ == null || other.Value != "") { + Value = other.Value; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_value_codec.Read(input); + if (value_ == null || value != "") { + Value = value; + } + break; + } + } + } + } + + } + + /// + /// Class of the hotel as a number of stars 1 to 5. + /// + public sealed partial class HotelClassInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelClassInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[11]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelClassInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelClassInfo(HotelClassInfo other) : this() { + Value = other.Value; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelClassInfo Clone() { + return new HotelClassInfo(this); + } + + /// Field number for the "value" field. + public const int ValueFieldNumber = 1; + private static readonly pb::FieldCodec _single_value_codec = pb::FieldCodec.ForStructWrapper(10); + private long? value_; + /// + /// Long value of the hotel class. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Value { + get { return value_; } + set { + value_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelClassInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelClassInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Value != other.Value) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (value_ != null) hash ^= Value.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (value_ != null) { + _single_value_codec.WriteTagAndValue(output, Value); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (value_ != null) { + size += _single_value_codec.CalculateSizeWithTag(Value); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelClassInfo other) { + if (other == null) { + return; + } + if (other.value_ != null) { + if (value_ == null || other.Value != 0L) { + Value = other.Value; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_value_codec.Read(input); + if (value_ == null || value != 0L) { + Value = value; + } + break; + } + } + } + } + + } + + /// + /// Country or Region the hotel is located in. + /// + public sealed partial class HotelCountryRegionInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelCountryRegionInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[12]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCountryRegionInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCountryRegionInfo(HotelCountryRegionInfo other) : this() { + CountryRegionCriterion = other.CountryRegionCriterion; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCountryRegionInfo Clone() { + return new HotelCountryRegionInfo(this); + } + + /// Field number for the "country_region_criterion" field. + public const int CountryRegionCriterionFieldNumber = 1; + private static readonly pb::FieldCodec _single_countryRegionCriterion_codec = pb::FieldCodec.ForClassWrapper(10); + private string countryRegionCriterion_; + /// + /// The Geo Target Constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryRegionCriterion { + get { return countryRegionCriterion_; } + set { + countryRegionCriterion_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelCountryRegionInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelCountryRegionInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CountryRegionCriterion != other.CountryRegionCriterion) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (countryRegionCriterion_ != null) hash ^= CountryRegionCriterion.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (countryRegionCriterion_ != null) { + _single_countryRegionCriterion_codec.WriteTagAndValue(output, CountryRegionCriterion); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (countryRegionCriterion_ != null) { + size += _single_countryRegionCriterion_codec.CalculateSizeWithTag(CountryRegionCriterion); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelCountryRegionInfo other) { + if (other == null) { + return; + } + if (other.countryRegionCriterion_ != null) { + if (countryRegionCriterion_ == null || other.CountryRegionCriterion != "") { + CountryRegionCriterion = other.CountryRegionCriterion; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_countryRegionCriterion_codec.Read(input); + if (countryRegionCriterion_ == null || value != "") { + CountryRegionCriterion = value; + } + break; + } + } + } + } + + } + + /// + /// State the hotel is located in. + /// + public sealed partial class HotelStateInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelStateInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[13]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelStateInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelStateInfo(HotelStateInfo other) : this() { + StateCriterion = other.StateCriterion; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelStateInfo Clone() { + return new HotelStateInfo(this); + } + + /// Field number for the "state_criterion" field. + public const int StateCriterionFieldNumber = 1; + private static readonly pb::FieldCodec _single_stateCriterion_codec = pb::FieldCodec.ForClassWrapper(10); + private string stateCriterion_; + /// + /// The Geo Target Constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StateCriterion { + get { return stateCriterion_; } + set { + stateCriterion_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelStateInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelStateInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (StateCriterion != other.StateCriterion) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (stateCriterion_ != null) hash ^= StateCriterion.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (stateCriterion_ != null) { + _single_stateCriterion_codec.WriteTagAndValue(output, StateCriterion); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (stateCriterion_ != null) { + size += _single_stateCriterion_codec.CalculateSizeWithTag(StateCriterion); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelStateInfo other) { + if (other == null) { + return; + } + if (other.stateCriterion_ != null) { + if (stateCriterion_ == null || other.StateCriterion != "") { + StateCriterion = other.StateCriterion; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_stateCriterion_codec.Read(input); + if (stateCriterion_ == null || value != "") { + StateCriterion = value; + } + break; + } + } + } + } + + } + + /// + /// City the hotel is located in. + /// + public sealed partial class HotelCityInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelCityInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[14]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCityInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCityInfo(HotelCityInfo other) : this() { + CityCriterion = other.CityCriterion; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCityInfo Clone() { + return new HotelCityInfo(this); + } + + /// Field number for the "city_criterion" field. + public const int CityCriterionFieldNumber = 1; + private static readonly pb::FieldCodec _single_cityCriterion_codec = pb::FieldCodec.ForClassWrapper(10); + private string cityCriterion_; + /// + /// The Geo Target Constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CityCriterion { + get { return cityCriterion_; } + set { + cityCriterion_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelCityInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelCityInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CityCriterion != other.CityCriterion) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (cityCriterion_ != null) hash ^= CityCriterion.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (cityCriterion_ != null) { + _single_cityCriterion_codec.WriteTagAndValue(output, CityCriterion); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (cityCriterion_ != null) { + size += _single_cityCriterion_codec.CalculateSizeWithTag(CityCriterion); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelCityInfo other) { + if (other == null) { + return; + } + if (other.cityCriterion_ != null) { + if (cityCriterion_ == null || other.CityCriterion != "") { + CityCriterion = other.CityCriterion; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_cityCriterion_codec.Read(input); + if (cityCriterion_ == null || value != "") { + CityCriterion = value; + } + break; + } + } + } + } + + } + + /// + /// Bidding category of a product offer. + /// + public sealed partial class ProductBiddingCategoryInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductBiddingCategoryInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[15]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductBiddingCategoryInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductBiddingCategoryInfo(ProductBiddingCategoryInfo other) : this() { + Id = other.Id; + CountryCode = other.CountryCode; + level_ = other.level_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductBiddingCategoryInfo Clone() { + return new ProductBiddingCategoryInfo(this); + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 1; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(10); + private long? id_; + /// + /// ID of the product bidding category. + /// + /// This ID is equivalent to the google_product_category ID as described in + /// this article: https://support.google.com/merchants/answer/6324436 + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string countryCode_; + /// + /// Two-letter upper-case country code of the product bidding category. It must + /// match the campaign.shopping_setting.sales_country field. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "level" field. + public const int LevelFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.ProductBiddingCategoryLevelEnum.Types.ProductBiddingCategoryLevel level_ = 0; + /// + /// Level of the product bidding category. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ProductBiddingCategoryLevelEnum.Types.ProductBiddingCategoryLevel Level { + get { return level_; } + set { + level_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductBiddingCategoryInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductBiddingCategoryInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Id != other.Id) return false; + if (CountryCode != other.CountryCode) return false; + if (Level != other.Level) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (id_ != null) hash ^= Id.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (Level != 0) hash ^= Level.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (Level != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Level); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (Level != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Level); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductBiddingCategoryInfo other) { + if (other == null) { + return; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.Level != 0) { + Level = other.Level; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 18: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 24: { + Level = (global::Google.Ads.GoogleAds.V3.Enums.ProductBiddingCategoryLevelEnum.Types.ProductBiddingCategoryLevel) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Brand of the product. + /// + public sealed partial class ProductBrandInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductBrandInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[16]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductBrandInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductBrandInfo(ProductBrandInfo other) : this() { + Value = other.Value; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductBrandInfo Clone() { + return new ProductBrandInfo(this); + } + + /// Field number for the "value" field. + public const int ValueFieldNumber = 1; + private static readonly pb::FieldCodec _single_value_codec = pb::FieldCodec.ForClassWrapper(10); + private string value_; + /// + /// String value of the product brand. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Value { + get { return value_; } + set { + value_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductBrandInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductBrandInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Value != other.Value) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (value_ != null) hash ^= Value.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (value_ != null) { + _single_value_codec.WriteTagAndValue(output, Value); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (value_ != null) { + size += _single_value_codec.CalculateSizeWithTag(Value); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductBrandInfo other) { + if (other == null) { + return; + } + if (other.value_ != null) { + if (value_ == null || other.Value != "") { + Value = other.Value; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_value_codec.Read(input); + if (value_ == null || value != "") { + Value = value; + } + break; + } + } + } + } + + } + + /// + /// Locality of a product offer. + /// + public sealed partial class ProductChannelInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductChannelInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[17]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductChannelInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductChannelInfo(ProductChannelInfo other) : this() { + channel_ = other.channel_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductChannelInfo Clone() { + return new ProductChannelInfo(this); + } + + /// Field number for the "channel" field. + public const int ChannelFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.ProductChannelEnum.Types.ProductChannel channel_ = 0; + /// + /// Value of the locality. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ProductChannelEnum.Types.ProductChannel Channel { + get { return channel_; } + set { + channel_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductChannelInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductChannelInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Channel != other.Channel) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Channel != 0) hash ^= Channel.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Channel != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Channel); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Channel != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Channel); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductChannelInfo other) { + if (other == null) { + return; + } + if (other.Channel != 0) { + Channel = other.Channel; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Channel = (global::Google.Ads.GoogleAds.V3.Enums.ProductChannelEnum.Types.ProductChannel) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Availability of a product offer. + /// + public sealed partial class ProductChannelExclusivityInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductChannelExclusivityInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[18]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductChannelExclusivityInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductChannelExclusivityInfo(ProductChannelExclusivityInfo other) : this() { + channelExclusivity_ = other.channelExclusivity_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductChannelExclusivityInfo Clone() { + return new ProductChannelExclusivityInfo(this); + } + + /// Field number for the "channel_exclusivity" field. + public const int ChannelExclusivityFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.ProductChannelExclusivityEnum.Types.ProductChannelExclusivity channelExclusivity_ = 0; + /// + /// Value of the availability. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ProductChannelExclusivityEnum.Types.ProductChannelExclusivity ChannelExclusivity { + get { return channelExclusivity_; } + set { + channelExclusivity_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductChannelExclusivityInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductChannelExclusivityInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ChannelExclusivity != other.ChannelExclusivity) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ChannelExclusivity != 0) hash ^= ChannelExclusivity.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ChannelExclusivity != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) ChannelExclusivity); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ChannelExclusivity != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ChannelExclusivity); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductChannelExclusivityInfo other) { + if (other == null) { + return; + } + if (other.ChannelExclusivity != 0) { + ChannelExclusivity = other.ChannelExclusivity; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + ChannelExclusivity = (global::Google.Ads.GoogleAds.V3.Enums.ProductChannelExclusivityEnum.Types.ProductChannelExclusivity) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Condition of a product offer. + /// + public sealed partial class ProductConditionInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductConditionInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[19]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductConditionInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductConditionInfo(ProductConditionInfo other) : this() { + condition_ = other.condition_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductConditionInfo Clone() { + return new ProductConditionInfo(this); + } + + /// Field number for the "condition" field. + public const int ConditionFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.ProductConditionEnum.Types.ProductCondition condition_ = 0; + /// + /// Value of the condition. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ProductConditionEnum.Types.ProductCondition Condition { + get { return condition_; } + set { + condition_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductConditionInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductConditionInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Condition != other.Condition) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Condition != 0) hash ^= Condition.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Condition != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Condition); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Condition != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Condition); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductConditionInfo other) { + if (other == null) { + return; + } + if (other.Condition != 0) { + Condition = other.Condition; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Condition = (global::Google.Ads.GoogleAds.V3.Enums.ProductConditionEnum.Types.ProductCondition) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Custom attribute of a product offer. + /// + public sealed partial class ProductCustomAttributeInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductCustomAttributeInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[20]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductCustomAttributeInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductCustomAttributeInfo(ProductCustomAttributeInfo other) : this() { + Value = other.Value; + index_ = other.index_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductCustomAttributeInfo Clone() { + return new ProductCustomAttributeInfo(this); + } + + /// Field number for the "value" field. + public const int ValueFieldNumber = 1; + private static readonly pb::FieldCodec _single_value_codec = pb::FieldCodec.ForClassWrapper(10); + private string value_; + /// + /// String value of the product custom attribute. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Value { + get { return value_; } + set { + value_ = value; + } + } + + + /// Field number for the "index" field. + public const int IndexFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.ProductCustomAttributeIndexEnum.Types.ProductCustomAttributeIndex index_ = 0; + /// + /// Indicates the index of the custom attribute. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ProductCustomAttributeIndexEnum.Types.ProductCustomAttributeIndex Index { + get { return index_; } + set { + index_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductCustomAttributeInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductCustomAttributeInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Value != other.Value) return false; + if (Index != other.Index) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (value_ != null) hash ^= Value.GetHashCode(); + if (Index != 0) hash ^= Index.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (value_ != null) { + _single_value_codec.WriteTagAndValue(output, Value); + } + if (Index != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) Index); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (value_ != null) { + size += _single_value_codec.CalculateSizeWithTag(Value); + } + if (Index != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Index); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductCustomAttributeInfo other) { + if (other == null) { + return; + } + if (other.value_ != null) { + if (value_ == null || other.Value != "") { + Value = other.Value; + } + } + if (other.Index != 0) { + Index = other.Index; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_value_codec.Read(input); + if (value_ == null || value != "") { + Value = value; + } + break; + } + case 16: { + Index = (global::Google.Ads.GoogleAds.V3.Enums.ProductCustomAttributeIndexEnum.Types.ProductCustomAttributeIndex) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Item id of a product offer. + /// + public sealed partial class ProductItemIdInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductItemIdInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[21]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductItemIdInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductItemIdInfo(ProductItemIdInfo other) : this() { + Value = other.Value; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductItemIdInfo Clone() { + return new ProductItemIdInfo(this); + } + + /// Field number for the "value" field. + public const int ValueFieldNumber = 1; + private static readonly pb::FieldCodec _single_value_codec = pb::FieldCodec.ForClassWrapper(10); + private string value_; + /// + /// Value of the id. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Value { + get { return value_; } + set { + value_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductItemIdInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductItemIdInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Value != other.Value) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (value_ != null) hash ^= Value.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (value_ != null) { + _single_value_codec.WriteTagAndValue(output, Value); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (value_ != null) { + size += _single_value_codec.CalculateSizeWithTag(Value); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductItemIdInfo other) { + if (other == null) { + return; + } + if (other.value_ != null) { + if (value_ == null || other.Value != "") { + Value = other.Value; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_value_codec.Read(input); + if (value_ == null || value != "") { + Value = value; + } + break; + } + } + } + } + + } + + /// + /// Type of a product offer. + /// + public sealed partial class ProductTypeInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProductTypeInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[22]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductTypeInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductTypeInfo(ProductTypeInfo other) : this() { + Value = other.Value; + level_ = other.level_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProductTypeInfo Clone() { + return new ProductTypeInfo(this); + } + + /// Field number for the "value" field. + public const int ValueFieldNumber = 1; + private static readonly pb::FieldCodec _single_value_codec = pb::FieldCodec.ForClassWrapper(10); + private string value_; + /// + /// Value of the type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Value { + get { return value_; } + set { + value_ = value; + } + } + + + /// Field number for the "level" field. + public const int LevelFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.ProductTypeLevelEnum.Types.ProductTypeLevel level_ = 0; + /// + /// Level of the type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ProductTypeLevelEnum.Types.ProductTypeLevel Level { + get { return level_; } + set { + level_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProductTypeInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProductTypeInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Value != other.Value) return false; + if (Level != other.Level) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (value_ != null) hash ^= Value.GetHashCode(); + if (Level != 0) hash ^= Level.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (value_ != null) { + _single_value_codec.WriteTagAndValue(output, Value); + } + if (Level != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) Level); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (value_ != null) { + size += _single_value_codec.CalculateSizeWithTag(Value); + } + if (Level != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Level); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProductTypeInfo other) { + if (other == null) { + return; + } + if (other.value_ != null) { + if (value_ == null || other.Value != "") { + Value = other.Value; + } + } + if (other.Level != 0) { + Level = other.Level; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_value_codec.Read(input); + if (value_ == null || value != "") { + Value = value; + } + break; + } + case 16: { + Level = (global::Google.Ads.GoogleAds.V3.Enums.ProductTypeLevelEnum.Types.ProductTypeLevel) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Unknown listing dimension. + /// + public sealed partial class UnknownListingDimensionInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UnknownListingDimensionInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[23]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UnknownListingDimensionInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UnknownListingDimensionInfo(UnknownListingDimensionInfo other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UnknownListingDimensionInfo Clone() { + return new UnknownListingDimensionInfo(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UnknownListingDimensionInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UnknownListingDimensionInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UnknownListingDimensionInfo other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// Criterion for hotel date selection (default dates vs. user selected). + /// + public sealed partial class HotelDateSelectionTypeInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelDateSelectionTypeInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[24]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelDateSelectionTypeInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelDateSelectionTypeInfo(HotelDateSelectionTypeInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelDateSelectionTypeInfo Clone() { + return new HotelDateSelectionTypeInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.HotelDateSelectionTypeEnum.Types.HotelDateSelectionType type_ = 0; + /// + /// Type of the hotel date selection + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.HotelDateSelectionTypeEnum.Types.HotelDateSelectionType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelDateSelectionTypeInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelDateSelectionTypeInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelDateSelectionTypeInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.HotelDateSelectionTypeEnum.Types.HotelDateSelectionType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Criterion for number of days prior to the stay the booking is being made. + /// + public sealed partial class HotelAdvanceBookingWindowInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelAdvanceBookingWindowInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[25]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelAdvanceBookingWindowInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelAdvanceBookingWindowInfo(HotelAdvanceBookingWindowInfo other) : this() { + MinDays = other.MinDays; + MaxDays = other.MaxDays; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelAdvanceBookingWindowInfo Clone() { + return new HotelAdvanceBookingWindowInfo(this); + } + + /// Field number for the "min_days" field. + public const int MinDaysFieldNumber = 1; + private static readonly pb::FieldCodec _single_minDays_codec = pb::FieldCodec.ForStructWrapper(10); + private long? minDays_; + /// + /// Low end of the number of days prior to the stay. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? MinDays { + get { return minDays_; } + set { + minDays_ = value; + } + } + + + /// Field number for the "max_days" field. + public const int MaxDaysFieldNumber = 2; + private static readonly pb::FieldCodec _single_maxDays_codec = pb::FieldCodec.ForStructWrapper(18); + private long? maxDays_; + /// + /// High end of the number of days prior to the stay. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? MaxDays { + get { return maxDays_; } + set { + maxDays_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelAdvanceBookingWindowInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelAdvanceBookingWindowInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (MinDays != other.MinDays) return false; + if (MaxDays != other.MaxDays) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (minDays_ != null) hash ^= MinDays.GetHashCode(); + if (maxDays_ != null) hash ^= MaxDays.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (minDays_ != null) { + _single_minDays_codec.WriteTagAndValue(output, MinDays); + } + if (maxDays_ != null) { + _single_maxDays_codec.WriteTagAndValue(output, MaxDays); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (minDays_ != null) { + size += _single_minDays_codec.CalculateSizeWithTag(MinDays); + } + if (maxDays_ != null) { + size += _single_maxDays_codec.CalculateSizeWithTag(MaxDays); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelAdvanceBookingWindowInfo other) { + if (other == null) { + return; + } + if (other.minDays_ != null) { + if (minDays_ == null || other.MinDays != 0L) { + MinDays = other.MinDays; + } + } + if (other.maxDays_ != null) { + if (maxDays_ == null || other.MaxDays != 0L) { + MaxDays = other.MaxDays; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_minDays_codec.Read(input); + if (minDays_ == null || value != 0L) { + MinDays = value; + } + break; + } + case 18: { + long? value = _single_maxDays_codec.Read(input); + if (maxDays_ == null || value != 0L) { + MaxDays = value; + } + break; + } + } + } + } + + } + + /// + /// Criterion for length of hotel stay in nights. + /// + public sealed partial class HotelLengthOfStayInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelLengthOfStayInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[26]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelLengthOfStayInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelLengthOfStayInfo(HotelLengthOfStayInfo other) : this() { + MinNights = other.MinNights; + MaxNights = other.MaxNights; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelLengthOfStayInfo Clone() { + return new HotelLengthOfStayInfo(this); + } + + /// Field number for the "min_nights" field. + public const int MinNightsFieldNumber = 1; + private static readonly pb::FieldCodec _single_minNights_codec = pb::FieldCodec.ForStructWrapper(10); + private long? minNights_; + /// + /// Low end of the number of nights in the stay. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? MinNights { + get { return minNights_; } + set { + minNights_ = value; + } + } + + + /// Field number for the "max_nights" field. + public const int MaxNightsFieldNumber = 2; + private static readonly pb::FieldCodec _single_maxNights_codec = pb::FieldCodec.ForStructWrapper(18); + private long? maxNights_; + /// + /// High end of the number of nights in the stay. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? MaxNights { + get { return maxNights_; } + set { + maxNights_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelLengthOfStayInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelLengthOfStayInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (MinNights != other.MinNights) return false; + if (MaxNights != other.MaxNights) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (minNights_ != null) hash ^= MinNights.GetHashCode(); + if (maxNights_ != null) hash ^= MaxNights.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (minNights_ != null) { + _single_minNights_codec.WriteTagAndValue(output, MinNights); + } + if (maxNights_ != null) { + _single_maxNights_codec.WriteTagAndValue(output, MaxNights); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (minNights_ != null) { + size += _single_minNights_codec.CalculateSizeWithTag(MinNights); + } + if (maxNights_ != null) { + size += _single_maxNights_codec.CalculateSizeWithTag(MaxNights); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelLengthOfStayInfo other) { + if (other == null) { + return; + } + if (other.minNights_ != null) { + if (minNights_ == null || other.MinNights != 0L) { + MinNights = other.MinNights; + } + } + if (other.maxNights_ != null) { + if (maxNights_ == null || other.MaxNights != 0L) { + MaxNights = other.MaxNights; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_minNights_codec.Read(input); + if (minNights_ == null || value != 0L) { + MinNights = value; + } + break; + } + case 18: { + long? value = _single_maxNights_codec.Read(input); + if (maxNights_ == null || value != 0L) { + MaxNights = value; + } + break; + } + } + } + } + + } + + /// + /// Criterion for day of the week the booking is for. + /// + public sealed partial class HotelCheckInDayInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelCheckInDayInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[27]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCheckInDayInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCheckInDayInfo(HotelCheckInDayInfo other) : this() { + dayOfWeek_ = other.dayOfWeek_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCheckInDayInfo Clone() { + return new HotelCheckInDayInfo(this); + } + + /// Field number for the "day_of_week" field. + public const int DayOfWeekFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Types.DayOfWeek dayOfWeek_ = 0; + /// + /// The day of the week. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Types.DayOfWeek DayOfWeek { + get { return dayOfWeek_; } + set { + dayOfWeek_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelCheckInDayInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelCheckInDayInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (DayOfWeek != other.DayOfWeek) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (DayOfWeek != 0) hash ^= DayOfWeek.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (DayOfWeek != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) DayOfWeek); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (DayOfWeek != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DayOfWeek); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelCheckInDayInfo other) { + if (other == null) { + return; + } + if (other.DayOfWeek != 0) { + DayOfWeek = other.DayOfWeek; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + DayOfWeek = (global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Types.DayOfWeek) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Criterion for Interaction Type. + /// + public sealed partial class InteractionTypeInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new InteractionTypeInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[28]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionTypeInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionTypeInfo(InteractionTypeInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionTypeInfo Clone() { + return new InteractionTypeInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.InteractionTypeEnum.Types.InteractionType type_ = 0; + /// + /// The interaction type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.InteractionTypeEnum.Types.InteractionType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as InteractionTypeInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(InteractionTypeInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(InteractionTypeInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.InteractionTypeEnum.Types.InteractionType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Represents an AdSchedule criterion. + /// + /// AdSchedule is specified as the day of the week and a time interval + /// within which ads will be shown. + /// + /// No more than six AdSchedules can be added for the same day. + /// + public sealed partial class AdScheduleInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AdScheduleInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[29]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdScheduleInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdScheduleInfo(AdScheduleInfo other) : this() { + startMinute_ = other.startMinute_; + endMinute_ = other.endMinute_; + StartHour = other.StartHour; + EndHour = other.EndHour; + dayOfWeek_ = other.dayOfWeek_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AdScheduleInfo Clone() { + return new AdScheduleInfo(this); + } + + /// Field number for the "start_minute" field. + public const int StartMinuteFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.MinuteOfHourEnum.Types.MinuteOfHour startMinute_ = 0; + /// + /// Minutes after the start hour at which this schedule starts. + /// + /// This field is required for CREATE operations and is prohibited on UPDATE + /// operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.MinuteOfHourEnum.Types.MinuteOfHour StartMinute { + get { return startMinute_; } + set { + startMinute_ = value; + } + } + + /// Field number for the "end_minute" field. + public const int EndMinuteFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.MinuteOfHourEnum.Types.MinuteOfHour endMinute_ = 0; + /// + /// Minutes after the end hour at which this schedule ends. The schedule is + /// exclusive of the end minute. + /// + /// This field is required for CREATE operations and is prohibited on UPDATE + /// operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.MinuteOfHourEnum.Types.MinuteOfHour EndMinute { + get { return endMinute_; } + set { + endMinute_ = value; + } + } + + /// Field number for the "start_hour" field. + public const int StartHourFieldNumber = 3; + private static readonly pb::FieldCodec _single_startHour_codec = pb::FieldCodec.ForStructWrapper(26); + private int? startHour_; + /// + /// Starting hour in 24 hour time. + /// This field must be between 0 and 23, inclusive. + /// + /// This field is required for CREATE operations and is prohibited on UPDATE + /// operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int? StartHour { + get { return startHour_; } + set { + startHour_ = value; + } + } + + + /// Field number for the "end_hour" field. + public const int EndHourFieldNumber = 4; + private static readonly pb::FieldCodec _single_endHour_codec = pb::FieldCodec.ForStructWrapper(34); + private int? endHour_; + /// + /// Ending hour in 24 hour time; 24 signifies end of the day. + /// This field must be between 0 and 24, inclusive. + /// + /// This field is required for CREATE operations and is prohibited on UPDATE + /// operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int? EndHour { + get { return endHour_; } + set { + endHour_ = value; + } + } + + + /// Field number for the "day_of_week" field. + public const int DayOfWeekFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Types.DayOfWeek dayOfWeek_ = 0; + /// + /// Day of the week the schedule applies to. + /// + /// This field is required for CREATE operations and is prohibited on UPDATE + /// operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Types.DayOfWeek DayOfWeek { + get { return dayOfWeek_; } + set { + dayOfWeek_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AdScheduleInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AdScheduleInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (StartMinute != other.StartMinute) return false; + if (EndMinute != other.EndMinute) return false; + if (StartHour != other.StartHour) return false; + if (EndHour != other.EndHour) return false; + if (DayOfWeek != other.DayOfWeek) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (StartMinute != 0) hash ^= StartMinute.GetHashCode(); + if (EndMinute != 0) hash ^= EndMinute.GetHashCode(); + if (startHour_ != null) hash ^= StartHour.GetHashCode(); + if (endHour_ != null) hash ^= EndHour.GetHashCode(); + if (DayOfWeek != 0) hash ^= DayOfWeek.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (StartMinute != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) StartMinute); + } + if (EndMinute != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) EndMinute); + } + if (startHour_ != null) { + _single_startHour_codec.WriteTagAndValue(output, StartHour); + } + if (endHour_ != null) { + _single_endHour_codec.WriteTagAndValue(output, EndHour); + } + if (DayOfWeek != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) DayOfWeek); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (StartMinute != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) StartMinute); + } + if (EndMinute != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) EndMinute); + } + if (startHour_ != null) { + size += _single_startHour_codec.CalculateSizeWithTag(StartHour); + } + if (endHour_ != null) { + size += _single_endHour_codec.CalculateSizeWithTag(EndHour); + } + if (DayOfWeek != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DayOfWeek); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AdScheduleInfo other) { + if (other == null) { + return; + } + if (other.StartMinute != 0) { + StartMinute = other.StartMinute; + } + if (other.EndMinute != 0) { + EndMinute = other.EndMinute; + } + if (other.startHour_ != null) { + if (startHour_ == null || other.StartHour != 0) { + StartHour = other.StartHour; + } + } + if (other.endHour_ != null) { + if (endHour_ == null || other.EndHour != 0) { + EndHour = other.EndHour; + } + } + if (other.DayOfWeek != 0) { + DayOfWeek = other.DayOfWeek; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + StartMinute = (global::Google.Ads.GoogleAds.V3.Enums.MinuteOfHourEnum.Types.MinuteOfHour) input.ReadEnum(); + break; + } + case 16: { + EndMinute = (global::Google.Ads.GoogleAds.V3.Enums.MinuteOfHourEnum.Types.MinuteOfHour) input.ReadEnum(); + break; + } + case 26: { + int? value = _single_startHour_codec.Read(input); + if (startHour_ == null || value != 0) { + StartHour = value; + } + break; + } + case 34: { + int? value = _single_endHour_codec.Read(input); + if (endHour_ == null || value != 0) { + EndHour = value; + } + break; + } + case 40: { + DayOfWeek = (global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Types.DayOfWeek) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// An age range criterion. + /// + public sealed partial class AgeRangeInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AgeRangeInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[30]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeInfo(AgeRangeInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AgeRangeInfo Clone() { + return new AgeRangeInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeEnum.Types.AgeRangeType type_ = 0; + /// + /// Type of the age range. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeEnum.Types.AgeRangeType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AgeRangeInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AgeRangeInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AgeRangeInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.AgeRangeTypeEnum.Types.AgeRangeType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A gender criterion. + /// + public sealed partial class GenderInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenderInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[31]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderInfo(GenderInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderInfo Clone() { + return new GenderInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.GenderTypeEnum.Types.GenderType type_ = 0; + /// + /// Type of the gender. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.GenderTypeEnum.Types.GenderType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenderInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenderInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenderInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.GenderTypeEnum.Types.GenderType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// An income range criterion. + /// + public sealed partial class IncomeRangeInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new IncomeRangeInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[32]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IncomeRangeInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IncomeRangeInfo(IncomeRangeInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IncomeRangeInfo Clone() { + return new IncomeRangeInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.IncomeRangeTypeEnum.Types.IncomeRangeType type_ = 0; + /// + /// Type of the income range. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.IncomeRangeTypeEnum.Types.IncomeRangeType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as IncomeRangeInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(IncomeRangeInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(IncomeRangeInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.IncomeRangeTypeEnum.Types.IncomeRangeType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A parental status criterion. + /// + public sealed partial class ParentalStatusInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ParentalStatusInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[33]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ParentalStatusInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ParentalStatusInfo(ParentalStatusInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ParentalStatusInfo Clone() { + return new ParentalStatusInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.ParentalStatusTypeEnum.Types.ParentalStatusType type_ = 0; + /// + /// Type of the parental status. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ParentalStatusTypeEnum.Types.ParentalStatusType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ParentalStatusInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ParentalStatusInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ParentalStatusInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.ParentalStatusTypeEnum.Types.ParentalStatusType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A YouTube Video criterion. + /// + public sealed partial class YouTubeVideoInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new YouTubeVideoInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[34]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YouTubeVideoInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YouTubeVideoInfo(YouTubeVideoInfo other) : this() { + VideoId = other.VideoId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YouTubeVideoInfo Clone() { + return new YouTubeVideoInfo(this); + } + + /// Field number for the "video_id" field. + public const int VideoIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_videoId_codec = pb::FieldCodec.ForClassWrapper(10); + private string videoId_; + /// + /// YouTube video id as it appears on the YouTube watch page. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string VideoId { + get { return videoId_; } + set { + videoId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as YouTubeVideoInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(YouTubeVideoInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (VideoId != other.VideoId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (videoId_ != null) hash ^= VideoId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (videoId_ != null) { + _single_videoId_codec.WriteTagAndValue(output, VideoId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (videoId_ != null) { + size += _single_videoId_codec.CalculateSizeWithTag(VideoId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(YouTubeVideoInfo other) { + if (other == null) { + return; + } + if (other.videoId_ != null) { + if (videoId_ == null || other.VideoId != "") { + VideoId = other.VideoId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_videoId_codec.Read(input); + if (videoId_ == null || value != "") { + VideoId = value; + } + break; + } + } + } + } + + } + + /// + /// A YouTube Channel criterion. + /// + public sealed partial class YouTubeChannelInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new YouTubeChannelInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[35]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YouTubeChannelInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YouTubeChannelInfo(YouTubeChannelInfo other) : this() { + ChannelId = other.ChannelId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public YouTubeChannelInfo Clone() { + return new YouTubeChannelInfo(this); + } + + /// Field number for the "channel_id" field. + public const int ChannelIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_channelId_codec = pb::FieldCodec.ForClassWrapper(10); + private string channelId_; + /// + /// The YouTube uploader channel id or the channel code of a YouTube channel. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ChannelId { + get { return channelId_; } + set { + channelId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as YouTubeChannelInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(YouTubeChannelInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ChannelId != other.ChannelId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (channelId_ != null) hash ^= ChannelId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (channelId_ != null) { + _single_channelId_codec.WriteTagAndValue(output, ChannelId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (channelId_ != null) { + size += _single_channelId_codec.CalculateSizeWithTag(ChannelId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(YouTubeChannelInfo other) { + if (other == null) { + return; + } + if (other.channelId_ != null) { + if (channelId_ == null || other.ChannelId != "") { + ChannelId = other.ChannelId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_channelId_codec.Read(input); + if (channelId_ == null || value != "") { + ChannelId = value; + } + break; + } + } + } + } + + } + + /// + /// A User List criterion. Represents a user list that is defined by the + /// advertiser to be targeted. + /// + public sealed partial class UserListInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UserListInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[36]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UserListInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UserListInfo(UserListInfo other) : this() { + UserList = other.UserList; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UserListInfo Clone() { + return new UserListInfo(this); + } + + /// Field number for the "user_list" field. + public const int UserListFieldNumber = 1; + private static readonly pb::FieldCodec _single_userList_codec = pb::FieldCodec.ForClassWrapper(10); + private string userList_; + /// + /// The User List resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string UserList { + get { return userList_; } + set { + userList_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UserListInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UserListInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (UserList != other.UserList) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (userList_ != null) hash ^= UserList.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (userList_ != null) { + _single_userList_codec.WriteTagAndValue(output, UserList); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (userList_ != null) { + size += _single_userList_codec.CalculateSizeWithTag(UserList); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UserListInfo other) { + if (other == null) { + return; + } + if (other.userList_ != null) { + if (userList_ == null || other.UserList != "") { + UserList = other.UserList; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_userList_codec.Read(input); + if (userList_ == null || value != "") { + UserList = value; + } + break; + } + } + } + } + + } + + /// + /// A Proximity criterion. The geo point and radius determine what geographical + /// area is included. The address is a description of the geo point that does + /// not affect ad serving. + /// + /// There are two ways to create a proximity. First, by setting an address + /// and radius. The geo point will be automatically computed. Second, by + /// setting a geo point and radius. The address is an optional label that won't + /// be validated. + /// + public sealed partial class ProximityInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ProximityInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[37]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProximityInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProximityInfo(ProximityInfo other) : this() { + geoPoint_ = other.geoPoint_ != null ? other.geoPoint_.Clone() : null; + Radius = other.Radius; + radiusUnits_ = other.radiusUnits_; + address_ = other.address_ != null ? other.address_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ProximityInfo Clone() { + return new ProximityInfo(this); + } + + /// Field number for the "geo_point" field. + public const int GeoPointFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Common.GeoPointInfo geoPoint_; + /// + /// Latitude and longitude. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.GeoPointInfo GeoPoint { + get { return geoPoint_; } + set { + geoPoint_ = value; + } + } + + /// Field number for the "radius" field. + public const int RadiusFieldNumber = 2; + private static readonly pb::FieldCodec _single_radius_codec = pb::FieldCodec.ForStructWrapper(18); + private double? radius_; + /// + /// The radius of the proximity. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? Radius { + get { return radius_; } + set { + radius_ = value; + } + } + + + /// Field number for the "radius_units" field. + public const int RadiusUnitsFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.ProximityRadiusUnitsEnum.Types.ProximityRadiusUnits radiusUnits_ = 0; + /// + /// The unit of measurement of the radius. Default is KILOMETERS. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ProximityRadiusUnitsEnum.Types.ProximityRadiusUnits RadiusUnits { + get { return radiusUnits_; } + set { + radiusUnits_ = value; + } + } + + /// Field number for the "address" field. + public const int AddressFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Common.AddressInfo address_; + /// + /// Full address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AddressInfo Address { + get { return address_; } + set { + address_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ProximityInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ProximityInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(GeoPoint, other.GeoPoint)) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(Radius, other.Radius)) return false; + if (RadiusUnits != other.RadiusUnits) return false; + if (!object.Equals(Address, other.Address)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (geoPoint_ != null) hash ^= GeoPoint.GetHashCode(); + if (radius_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(Radius); + if (RadiusUnits != 0) hash ^= RadiusUnits.GetHashCode(); + if (address_ != null) hash ^= Address.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (geoPoint_ != null) { + output.WriteRawTag(10); + output.WriteMessage(GeoPoint); + } + if (radius_ != null) { + _single_radius_codec.WriteTagAndValue(output, Radius); + } + if (RadiusUnits != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) RadiusUnits); + } + if (address_ != null) { + output.WriteRawTag(34); + output.WriteMessage(Address); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (geoPoint_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(GeoPoint); + } + if (radius_ != null) { + size += _single_radius_codec.CalculateSizeWithTag(Radius); + } + if (RadiusUnits != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) RadiusUnits); + } + if (address_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Address); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ProximityInfo other) { + if (other == null) { + return; + } + if (other.geoPoint_ != null) { + if (geoPoint_ == null) { + GeoPoint = new global::Google.Ads.GoogleAds.V3.Common.GeoPointInfo(); + } + GeoPoint.MergeFrom(other.GeoPoint); + } + if (other.radius_ != null) { + if (radius_ == null || other.Radius != 0D) { + Radius = other.Radius; + } + } + if (other.RadiusUnits != 0) { + RadiusUnits = other.RadiusUnits; + } + if (other.address_ != null) { + if (address_ == null) { + Address = new global::Google.Ads.GoogleAds.V3.Common.AddressInfo(); + } + Address.MergeFrom(other.Address); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (geoPoint_ == null) { + GeoPoint = new global::Google.Ads.GoogleAds.V3.Common.GeoPointInfo(); + } + input.ReadMessage(GeoPoint); + break; + } + case 18: { + double? value = _single_radius_codec.Read(input); + if (radius_ == null || value != 0D) { + Radius = value; + } + break; + } + case 24: { + RadiusUnits = (global::Google.Ads.GoogleAds.V3.Enums.ProximityRadiusUnitsEnum.Types.ProximityRadiusUnits) input.ReadEnum(); + break; + } + case 34: { + if (address_ == null) { + Address = new global::Google.Ads.GoogleAds.V3.Common.AddressInfo(); + } + input.ReadMessage(Address); + break; + } + } + } + } + + } + + /// + /// Geo point for proximity criterion. + /// + public sealed partial class GeoPointInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoPointInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[38]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoPointInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoPointInfo(GeoPointInfo other) : this() { + LongitudeInMicroDegrees = other.LongitudeInMicroDegrees; + LatitudeInMicroDegrees = other.LatitudeInMicroDegrees; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoPointInfo Clone() { + return new GeoPointInfo(this); + } + + /// Field number for the "longitude_in_micro_degrees" field. + public const int LongitudeInMicroDegreesFieldNumber = 1; + private static readonly pb::FieldCodec _single_longitudeInMicroDegrees_codec = pb::FieldCodec.ForStructWrapper(10); + private int? longitudeInMicroDegrees_; + /// + /// Micro degrees for the longitude. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int? LongitudeInMicroDegrees { + get { return longitudeInMicroDegrees_; } + set { + longitudeInMicroDegrees_ = value; + } + } + + + /// Field number for the "latitude_in_micro_degrees" field. + public const int LatitudeInMicroDegreesFieldNumber = 2; + private static readonly pb::FieldCodec _single_latitudeInMicroDegrees_codec = pb::FieldCodec.ForStructWrapper(18); + private int? latitudeInMicroDegrees_; + /// + /// Micro degrees for the latitude. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int? LatitudeInMicroDegrees { + get { return latitudeInMicroDegrees_; } + set { + latitudeInMicroDegrees_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoPointInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoPointInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (LongitudeInMicroDegrees != other.LongitudeInMicroDegrees) return false; + if (LatitudeInMicroDegrees != other.LatitudeInMicroDegrees) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (longitudeInMicroDegrees_ != null) hash ^= LongitudeInMicroDegrees.GetHashCode(); + if (latitudeInMicroDegrees_ != null) hash ^= LatitudeInMicroDegrees.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (longitudeInMicroDegrees_ != null) { + _single_longitudeInMicroDegrees_codec.WriteTagAndValue(output, LongitudeInMicroDegrees); + } + if (latitudeInMicroDegrees_ != null) { + _single_latitudeInMicroDegrees_codec.WriteTagAndValue(output, LatitudeInMicroDegrees); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (longitudeInMicroDegrees_ != null) { + size += _single_longitudeInMicroDegrees_codec.CalculateSizeWithTag(LongitudeInMicroDegrees); + } + if (latitudeInMicroDegrees_ != null) { + size += _single_latitudeInMicroDegrees_codec.CalculateSizeWithTag(LatitudeInMicroDegrees); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoPointInfo other) { + if (other == null) { + return; + } + if (other.longitudeInMicroDegrees_ != null) { + if (longitudeInMicroDegrees_ == null || other.LongitudeInMicroDegrees != 0) { + LongitudeInMicroDegrees = other.LongitudeInMicroDegrees; + } + } + if (other.latitudeInMicroDegrees_ != null) { + if (latitudeInMicroDegrees_ == null || other.LatitudeInMicroDegrees != 0) { + LatitudeInMicroDegrees = other.LatitudeInMicroDegrees; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + int? value = _single_longitudeInMicroDegrees_codec.Read(input); + if (longitudeInMicroDegrees_ == null || value != 0) { + LongitudeInMicroDegrees = value; + } + break; + } + case 18: { + int? value = _single_latitudeInMicroDegrees_codec.Read(input); + if (latitudeInMicroDegrees_ == null || value != 0) { + LatitudeInMicroDegrees = value; + } + break; + } + } + } + } + + } + + /// + /// Address for proximity criterion. + /// + public sealed partial class AddressInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AddressInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[39]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AddressInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AddressInfo(AddressInfo other) : this() { + PostalCode = other.PostalCode; + ProvinceCode = other.ProvinceCode; + CountryCode = other.CountryCode; + ProvinceName = other.ProvinceName; + StreetAddress = other.StreetAddress; + StreetAddress2 = other.StreetAddress2; + CityName = other.CityName; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AddressInfo Clone() { + return new AddressInfo(this); + } + + /// Field number for the "postal_code" field. + public const int PostalCodeFieldNumber = 1; + private static readonly pb::FieldCodec _single_postalCode_codec = pb::FieldCodec.ForClassWrapper(10); + private string postalCode_; + /// + /// Postal code. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PostalCode { + get { return postalCode_; } + set { + postalCode_ = value; + } + } + + + /// Field number for the "province_code" field. + public const int ProvinceCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_provinceCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string provinceCode_; + /// + /// Province or state code. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProvinceCode { + get { return provinceCode_; } + set { + provinceCode_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 3; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(26); + private string countryCode_; + /// + /// Country code. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "province_name" field. + public const int ProvinceNameFieldNumber = 4; + private static readonly pb::FieldCodec _single_provinceName_codec = pb::FieldCodec.ForClassWrapper(34); + private string provinceName_; + /// + /// Province or state name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ProvinceName { + get { return provinceName_; } + set { + provinceName_ = value; + } + } + + + /// Field number for the "street_address" field. + public const int StreetAddressFieldNumber = 5; + private static readonly pb::FieldCodec _single_streetAddress_codec = pb::FieldCodec.ForClassWrapper(42); + private string streetAddress_; + /// + /// Street address line 1. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StreetAddress { + get { return streetAddress_; } + set { + streetAddress_ = value; + } + } + + + /// Field number for the "street_address2" field. + public const int StreetAddress2FieldNumber = 6; + private static readonly pb::FieldCodec _single_streetAddress2_codec = pb::FieldCodec.ForClassWrapper(50); + private string streetAddress2_; + /// + /// Street address line 2. This field is write-only. It is only used for + /// calculating the longitude and latitude of an address when geo_point is + /// empty. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StreetAddress2 { + get { return streetAddress2_; } + set { + streetAddress2_ = value; + } + } + + + /// Field number for the "city_name" field. + public const int CityNameFieldNumber = 7; + private static readonly pb::FieldCodec _single_cityName_codec = pb::FieldCodec.ForClassWrapper(58); + private string cityName_; + /// + /// Name of the city. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CityName { + get { return cityName_; } + set { + cityName_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AddressInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AddressInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (PostalCode != other.PostalCode) return false; + if (ProvinceCode != other.ProvinceCode) return false; + if (CountryCode != other.CountryCode) return false; + if (ProvinceName != other.ProvinceName) return false; + if (StreetAddress != other.StreetAddress) return false; + if (StreetAddress2 != other.StreetAddress2) return false; + if (CityName != other.CityName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (postalCode_ != null) hash ^= PostalCode.GetHashCode(); + if (provinceCode_ != null) hash ^= ProvinceCode.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (provinceName_ != null) hash ^= ProvinceName.GetHashCode(); + if (streetAddress_ != null) hash ^= StreetAddress.GetHashCode(); + if (streetAddress2_ != null) hash ^= StreetAddress2.GetHashCode(); + if (cityName_ != null) hash ^= CityName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (postalCode_ != null) { + _single_postalCode_codec.WriteTagAndValue(output, PostalCode); + } + if (provinceCode_ != null) { + _single_provinceCode_codec.WriteTagAndValue(output, ProvinceCode); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (provinceName_ != null) { + _single_provinceName_codec.WriteTagAndValue(output, ProvinceName); + } + if (streetAddress_ != null) { + _single_streetAddress_codec.WriteTagAndValue(output, StreetAddress); + } + if (streetAddress2_ != null) { + _single_streetAddress2_codec.WriteTagAndValue(output, StreetAddress2); + } + if (cityName_ != null) { + _single_cityName_codec.WriteTagAndValue(output, CityName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (postalCode_ != null) { + size += _single_postalCode_codec.CalculateSizeWithTag(PostalCode); + } + if (provinceCode_ != null) { + size += _single_provinceCode_codec.CalculateSizeWithTag(ProvinceCode); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (provinceName_ != null) { + size += _single_provinceName_codec.CalculateSizeWithTag(ProvinceName); + } + if (streetAddress_ != null) { + size += _single_streetAddress_codec.CalculateSizeWithTag(StreetAddress); + } + if (streetAddress2_ != null) { + size += _single_streetAddress2_codec.CalculateSizeWithTag(StreetAddress2); + } + if (cityName_ != null) { + size += _single_cityName_codec.CalculateSizeWithTag(CityName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AddressInfo other) { + if (other == null) { + return; + } + if (other.postalCode_ != null) { + if (postalCode_ == null || other.PostalCode != "") { + PostalCode = other.PostalCode; + } + } + if (other.provinceCode_ != null) { + if (provinceCode_ == null || other.ProvinceCode != "") { + ProvinceCode = other.ProvinceCode; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.provinceName_ != null) { + if (provinceName_ == null || other.ProvinceName != "") { + ProvinceName = other.ProvinceName; + } + } + if (other.streetAddress_ != null) { + if (streetAddress_ == null || other.StreetAddress != "") { + StreetAddress = other.StreetAddress; + } + } + if (other.streetAddress2_ != null) { + if (streetAddress2_ == null || other.StreetAddress2 != "") { + StreetAddress2 = other.StreetAddress2; + } + } + if (other.cityName_ != null) { + if (cityName_ == null || other.CityName != "") { + CityName = other.CityName; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_postalCode_codec.Read(input); + if (postalCode_ == null || value != "") { + PostalCode = value; + } + break; + } + case 18: { + string value = _single_provinceCode_codec.Read(input); + if (provinceCode_ == null || value != "") { + ProvinceCode = value; + } + break; + } + case 26: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 34: { + string value = _single_provinceName_codec.Read(input); + if (provinceName_ == null || value != "") { + ProvinceName = value; + } + break; + } + case 42: { + string value = _single_streetAddress_codec.Read(input); + if (streetAddress_ == null || value != "") { + StreetAddress = value; + } + break; + } + case 50: { + string value = _single_streetAddress2_codec.Read(input); + if (streetAddress2_ == null || value != "") { + StreetAddress2 = value; + } + break; + } + case 58: { + string value = _single_cityName_codec.Read(input); + if (cityName_ == null || value != "") { + CityName = value; + } + break; + } + } + } + } + + } + + /// + /// A topic criterion. Use topics to target or exclude placements in the + /// Google Display Network based on the category into which the placement falls + /// (for example, "Pets & Animals/Pets/Dogs"). + /// + public sealed partial class TopicInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TopicInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[40]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TopicInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TopicInfo(TopicInfo other) : this() { + TopicConstant = other.TopicConstant; + path_ = other.path_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TopicInfo Clone() { + return new TopicInfo(this); + } + + /// Field number for the "topic_constant" field. + public const int TopicConstantFieldNumber = 1; + private static readonly pb::FieldCodec _single_topicConstant_codec = pb::FieldCodec.ForClassWrapper(10); + private string topicConstant_; + /// + /// The Topic Constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TopicConstant { + get { return topicConstant_; } + set { + topicConstant_ = value; + } + } + + + /// Field number for the "path" field. + public const int PathFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_path_codec + = pb::FieldCodec.ForClassWrapper(18); + private readonly pbc::RepeatedField path_ = new pbc::RepeatedField(); + /// + /// The category to target or exclude. Each subsequent element in the array + /// describes a more specific sub-category. For example, + /// "Pets & Animals", "Pets", "Dogs" represents the "Pets & Animals/Pets/Dogs" + /// category. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Path { + get { return path_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TopicInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TopicInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (TopicConstant != other.TopicConstant) return false; + if(!path_.Equals(other.path_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (topicConstant_ != null) hash ^= TopicConstant.GetHashCode(); + hash ^= path_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (topicConstant_ != null) { + _single_topicConstant_codec.WriteTagAndValue(output, TopicConstant); + } + path_.WriteTo(output, _repeated_path_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (topicConstant_ != null) { + size += _single_topicConstant_codec.CalculateSizeWithTag(TopicConstant); + } + size += path_.CalculateSize(_repeated_path_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TopicInfo other) { + if (other == null) { + return; + } + if (other.topicConstant_ != null) { + if (topicConstant_ == null || other.TopicConstant != "") { + TopicConstant = other.TopicConstant; + } + } + path_.Add(other.path_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_topicConstant_codec.Read(input); + if (topicConstant_ == null || value != "") { + TopicConstant = value; + } + break; + } + case 18: { + path_.AddEntriesFrom(input, _repeated_path_codec); + break; + } + } + } + } + + } + + /// + /// A language criterion. + /// + public sealed partial class LanguageInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new LanguageInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[41]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LanguageInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LanguageInfo(LanguageInfo other) : this() { + LanguageConstant = other.LanguageConstant; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LanguageInfo Clone() { + return new LanguageInfo(this); + } + + /// Field number for the "language_constant" field. + public const int LanguageConstantFieldNumber = 1; + private static readonly pb::FieldCodec _single_languageConstant_codec = pb::FieldCodec.ForClassWrapper(10); + private string languageConstant_; + /// + /// The language constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LanguageConstant { + get { return languageConstant_; } + set { + languageConstant_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as LanguageInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(LanguageInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (LanguageConstant != other.LanguageConstant) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (languageConstant_ != null) hash ^= LanguageConstant.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (languageConstant_ != null) { + _single_languageConstant_codec.WriteTagAndValue(output, LanguageConstant); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (languageConstant_ != null) { + size += _single_languageConstant_codec.CalculateSizeWithTag(LanguageConstant); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(LanguageInfo other) { + if (other == null) { + return; + } + if (other.languageConstant_ != null) { + if (languageConstant_ == null || other.LanguageConstant != "") { + LanguageConstant = other.LanguageConstant; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_languageConstant_codec.Read(input); + if (languageConstant_ == null || value != "") { + LanguageConstant = value; + } + break; + } + } + } + } + + } + + /// + /// An IpBlock criterion used for IP exclusions. We allow: + /// - IPv4 and IPv6 addresses + /// - individual addresses (192.168.0.1) + /// - masks for individual addresses (192.168.0.1/32) + /// - masks for Class C networks (192.168.0.1/24) + /// + public sealed partial class IpBlockInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new IpBlockInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[42]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IpBlockInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IpBlockInfo(IpBlockInfo other) : this() { + IpAddress = other.IpAddress; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IpBlockInfo Clone() { + return new IpBlockInfo(this); + } + + /// Field number for the "ip_address" field. + public const int IpAddressFieldNumber = 1; + private static readonly pb::FieldCodec _single_ipAddress_codec = pb::FieldCodec.ForClassWrapper(10); + private string ipAddress_; + /// + /// The IP address of this IP block. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string IpAddress { + get { return ipAddress_; } + set { + ipAddress_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as IpBlockInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(IpBlockInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (IpAddress != other.IpAddress) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ipAddress_ != null) hash ^= IpAddress.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ipAddress_ != null) { + _single_ipAddress_codec.WriteTagAndValue(output, IpAddress); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ipAddress_ != null) { + size += _single_ipAddress_codec.CalculateSizeWithTag(IpAddress); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(IpBlockInfo other) { + if (other == null) { + return; + } + if (other.ipAddress_ != null) { + if (ipAddress_ == null || other.IpAddress != "") { + IpAddress = other.IpAddress; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_ipAddress_codec.Read(input); + if (ipAddress_ == null || value != "") { + IpAddress = value; + } + break; + } + } + } + } + + } + + /// + /// Content Label for category exclusion. + /// + public sealed partial class ContentLabelInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ContentLabelInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[43]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContentLabelInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContentLabelInfo(ContentLabelInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ContentLabelInfo Clone() { + return new ContentLabelInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeEnum.Types.ContentLabelType type_ = 0; + /// + /// Content label type, required for CREATE operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeEnum.Types.ContentLabelType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ContentLabelInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ContentLabelInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ContentLabelInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.ContentLabelTypeEnum.Types.ContentLabelType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Represents a Carrier Criterion. + /// + public sealed partial class CarrierInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CarrierInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[44]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CarrierInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CarrierInfo(CarrierInfo other) : this() { + CarrierConstant = other.CarrierConstant; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CarrierInfo Clone() { + return new CarrierInfo(this); + } + + /// Field number for the "carrier_constant" field. + public const int CarrierConstantFieldNumber = 1; + private static readonly pb::FieldCodec _single_carrierConstant_codec = pb::FieldCodec.ForClassWrapper(10); + private string carrierConstant_; + /// + /// The Carrier constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CarrierConstant { + get { return carrierConstant_; } + set { + carrierConstant_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CarrierInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CarrierInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CarrierConstant != other.CarrierConstant) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (carrierConstant_ != null) hash ^= CarrierConstant.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (carrierConstant_ != null) { + _single_carrierConstant_codec.WriteTagAndValue(output, CarrierConstant); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (carrierConstant_ != null) { + size += _single_carrierConstant_codec.CalculateSizeWithTag(CarrierConstant); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CarrierInfo other) { + if (other == null) { + return; + } + if (other.carrierConstant_ != null) { + if (carrierConstant_ == null || other.CarrierConstant != "") { + CarrierConstant = other.CarrierConstant; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_carrierConstant_codec.Read(input); + if (carrierConstant_ == null || value != "") { + CarrierConstant = value; + } + break; + } + } + } + } + + } + + /// + /// Represents a particular interest-based topic to be targeted. + /// + public sealed partial class UserInterestInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UserInterestInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[45]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UserInterestInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UserInterestInfo(UserInterestInfo other) : this() { + UserInterestCategory = other.UserInterestCategory; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UserInterestInfo Clone() { + return new UserInterestInfo(this); + } + + /// Field number for the "user_interest_category" field. + public const int UserInterestCategoryFieldNumber = 1; + private static readonly pb::FieldCodec _single_userInterestCategory_codec = pb::FieldCodec.ForClassWrapper(10); + private string userInterestCategory_; + /// + /// The UserInterest resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string UserInterestCategory { + get { return userInterestCategory_; } + set { + userInterestCategory_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UserInterestInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UserInterestInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (UserInterestCategory != other.UserInterestCategory) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (userInterestCategory_ != null) hash ^= UserInterestCategory.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (userInterestCategory_ != null) { + _single_userInterestCategory_codec.WriteTagAndValue(output, UserInterestCategory); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (userInterestCategory_ != null) { + size += _single_userInterestCategory_codec.CalculateSizeWithTag(UserInterestCategory); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UserInterestInfo other) { + if (other == null) { + return; + } + if (other.userInterestCategory_ != null) { + if (userInterestCategory_ == null || other.UserInterestCategory != "") { + UserInterestCategory = other.UserInterestCategory; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_userInterestCategory_codec.Read(input); + if (userInterestCategory_ == null || value != "") { + UserInterestCategory = value; + } + break; + } + } + } + } + + } + + /// + /// Represents a criterion for targeting webpages of an advertiser's website. + /// + public sealed partial class WebpageInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new WebpageInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[46]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public WebpageInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public WebpageInfo(WebpageInfo other) : this() { + CriterionName = other.CriterionName; + conditions_ = other.conditions_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public WebpageInfo Clone() { + return new WebpageInfo(this); + } + + /// Field number for the "criterion_name" field. + public const int CriterionNameFieldNumber = 1; + private static readonly pb::FieldCodec _single_criterionName_codec = pb::FieldCodec.ForClassWrapper(10); + private string criterionName_; + /// + /// The name of the criterion that is defined by this parameter. The name value + /// will be used for identifying, sorting and filtering criteria with this type + /// of parameters. + /// + /// This field is required for CREATE operations and is prohibited on UPDATE + /// operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CriterionName { + get { return criterionName_; } + set { + criterionName_ = value; + } + } + + + /// Field number for the "conditions" field. + public const int ConditionsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_conditions_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Common.WebpageConditionInfo.Parser); + private readonly pbc::RepeatedField conditions_ = new pbc::RepeatedField(); + /// + /// Conditions, or logical expressions, for webpage targeting. The list of + /// webpage targeting conditions are and-ed together when evaluated + /// for targeting. + /// + /// This field is required for CREATE operations and is prohibited on UPDATE + /// operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Conditions { + get { return conditions_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as WebpageInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(WebpageInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CriterionName != other.CriterionName) return false; + if(!conditions_.Equals(other.conditions_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (criterionName_ != null) hash ^= CriterionName.GetHashCode(); + hash ^= conditions_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (criterionName_ != null) { + _single_criterionName_codec.WriteTagAndValue(output, CriterionName); + } + conditions_.WriteTo(output, _repeated_conditions_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (criterionName_ != null) { + size += _single_criterionName_codec.CalculateSizeWithTag(CriterionName); + } + size += conditions_.CalculateSize(_repeated_conditions_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(WebpageInfo other) { + if (other == null) { + return; + } + if (other.criterionName_ != null) { + if (criterionName_ == null || other.CriterionName != "") { + CriterionName = other.CriterionName; + } + } + conditions_.Add(other.conditions_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_criterionName_codec.Read(input); + if (criterionName_ == null || value != "") { + CriterionName = value; + } + break; + } + case 18: { + conditions_.AddEntriesFrom(input, _repeated_conditions_codec); + break; + } + } + } + } + + } + + /// + /// Logical expression for targeting webpages of an advertiser's website. + /// + public sealed partial class WebpageConditionInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new WebpageConditionInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[47]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public WebpageConditionInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public WebpageConditionInfo(WebpageConditionInfo other) : this() { + operand_ = other.operand_; + operator_ = other.operator_; + Argument = other.Argument; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public WebpageConditionInfo Clone() { + return new WebpageConditionInfo(this); + } + + /// Field number for the "operand" field. + public const int OperandFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperandEnum.Types.WebpageConditionOperand operand_ = 0; + /// + /// Operand of webpage targeting condition. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperandEnum.Types.WebpageConditionOperand Operand { + get { return operand_; } + set { + operand_ = value; + } + } + + /// Field number for the "operator" field. + public const int OperatorFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperatorEnum.Types.WebpageConditionOperator operator_ = 0; + /// + /// Operator of webpage targeting condition. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperatorEnum.Types.WebpageConditionOperator Operator { + get { return operator_; } + set { + operator_ = value; + } + } + + /// Field number for the "argument" field. + public const int ArgumentFieldNumber = 3; + private static readonly pb::FieldCodec _single_argument_codec = pb::FieldCodec.ForClassWrapper(26); + private string argument_; + /// + /// Argument of webpage targeting condition. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Argument { + get { return argument_; } + set { + argument_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as WebpageConditionInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(WebpageConditionInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Operand != other.Operand) return false; + if (Operator != other.Operator) return false; + if (Argument != other.Argument) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Operand != 0) hash ^= Operand.GetHashCode(); + if (Operator != 0) hash ^= Operator.GetHashCode(); + if (argument_ != null) hash ^= Argument.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Operand != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Operand); + } + if (Operator != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) Operator); + } + if (argument_ != null) { + _single_argument_codec.WriteTagAndValue(output, Argument); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Operand != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Operand); + } + if (Operator != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Operator); + } + if (argument_ != null) { + size += _single_argument_codec.CalculateSizeWithTag(Argument); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(WebpageConditionInfo other) { + if (other == null) { + return; + } + if (other.Operand != 0) { + Operand = other.Operand; + } + if (other.Operator != 0) { + Operator = other.Operator; + } + if (other.argument_ != null) { + if (argument_ == null || other.Argument != "") { + Argument = other.Argument; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Operand = (global::Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperandEnum.Types.WebpageConditionOperand) input.ReadEnum(); + break; + } + case 16: { + Operator = (global::Google.Ads.GoogleAds.V3.Enums.WebpageConditionOperatorEnum.Types.WebpageConditionOperator) input.ReadEnum(); + break; + } + case 26: { + string value = _single_argument_codec.Read(input); + if (argument_ == null || value != "") { + Argument = value; + } + break; + } + } + } + } + + } + + /// + /// Represents an operating system version to be targeted. + /// + public sealed partial class OperatingSystemVersionInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new OperatingSystemVersionInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[48]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperatingSystemVersionInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperatingSystemVersionInfo(OperatingSystemVersionInfo other) : this() { + OperatingSystemVersionConstant = other.OperatingSystemVersionConstant; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperatingSystemVersionInfo Clone() { + return new OperatingSystemVersionInfo(this); + } + + /// Field number for the "operating_system_version_constant" field. + public const int OperatingSystemVersionConstantFieldNumber = 1; + private static readonly pb::FieldCodec _single_operatingSystemVersionConstant_codec = pb::FieldCodec.ForClassWrapper(10); + private string operatingSystemVersionConstant_; + /// + /// The operating system version constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string OperatingSystemVersionConstant { + get { return operatingSystemVersionConstant_; } + set { + operatingSystemVersionConstant_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as OperatingSystemVersionInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(OperatingSystemVersionInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (OperatingSystemVersionConstant != other.OperatingSystemVersionConstant) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operatingSystemVersionConstant_ != null) hash ^= OperatingSystemVersionConstant.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operatingSystemVersionConstant_ != null) { + _single_operatingSystemVersionConstant_codec.WriteTagAndValue(output, OperatingSystemVersionConstant); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operatingSystemVersionConstant_ != null) { + size += _single_operatingSystemVersionConstant_codec.CalculateSizeWithTag(OperatingSystemVersionConstant); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(OperatingSystemVersionInfo other) { + if (other == null) { + return; + } + if (other.operatingSystemVersionConstant_ != null) { + if (operatingSystemVersionConstant_ == null || other.OperatingSystemVersionConstant != "") { + OperatingSystemVersionConstant = other.OperatingSystemVersionConstant; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_operatingSystemVersionConstant_codec.Read(input); + if (operatingSystemVersionConstant_ == null || value != "") { + OperatingSystemVersionConstant = value; + } + break; + } + } + } + } + + } + + /// + /// An app payment model criterion. + /// + public sealed partial class AppPaymentModelInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppPaymentModelInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[49]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPaymentModelInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPaymentModelInfo(AppPaymentModelInfo other) : this() { + type_ = other.type_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppPaymentModelInfo Clone() { + return new AppPaymentModelInfo(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.AppPaymentModelTypeEnum.Types.AppPaymentModelType type_ = 0; + /// + /// Type of the app payment model. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AppPaymentModelTypeEnum.Types.AppPaymentModelType Type { + get { return type_; } + set { + type_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppPaymentModelInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppPaymentModelInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppPaymentModelInfo other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.AppPaymentModelTypeEnum.Types.AppPaymentModelType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A mobile device criterion. + /// + public sealed partial class MobileDeviceInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MobileDeviceInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[50]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileDeviceInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileDeviceInfo(MobileDeviceInfo other) : this() { + MobileDeviceConstant = other.MobileDeviceConstant; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MobileDeviceInfo Clone() { + return new MobileDeviceInfo(this); + } + + /// Field number for the "mobile_device_constant" field. + public const int MobileDeviceConstantFieldNumber = 1; + private static readonly pb::FieldCodec _single_mobileDeviceConstant_codec = pb::FieldCodec.ForClassWrapper(10); + private string mobileDeviceConstant_; + /// + /// The mobile device constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string MobileDeviceConstant { + get { return mobileDeviceConstant_; } + set { + mobileDeviceConstant_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MobileDeviceInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MobileDeviceInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (MobileDeviceConstant != other.MobileDeviceConstant) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (mobileDeviceConstant_ != null) hash ^= MobileDeviceConstant.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (mobileDeviceConstant_ != null) { + _single_mobileDeviceConstant_codec.WriteTagAndValue(output, MobileDeviceConstant); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (mobileDeviceConstant_ != null) { + size += _single_mobileDeviceConstant_codec.CalculateSizeWithTag(MobileDeviceConstant); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MobileDeviceInfo other) { + if (other == null) { + return; + } + if (other.mobileDeviceConstant_ != null) { + if (mobileDeviceConstant_ == null || other.MobileDeviceConstant != "") { + MobileDeviceConstant = other.MobileDeviceConstant; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_mobileDeviceConstant_codec.Read(input); + if (mobileDeviceConstant_ == null || value != "") { + MobileDeviceConstant = value; + } + break; + } + } + } + } + + } + + /// + /// A custom affinity criterion. + /// A criterion of this type is only targetable. + /// + public sealed partial class CustomAffinityInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomAffinityInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[51]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomAffinityInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomAffinityInfo(CustomAffinityInfo other) : this() { + CustomAffinity = other.CustomAffinity; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomAffinityInfo Clone() { + return new CustomAffinityInfo(this); + } + + /// Field number for the "custom_affinity" field. + public const int CustomAffinityFieldNumber = 1; + private static readonly pb::FieldCodec _single_customAffinity_codec = pb::FieldCodec.ForClassWrapper(10); + private string customAffinity_; + /// + /// The CustomInterest resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomAffinity { + get { return customAffinity_; } + set { + customAffinity_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomAffinityInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomAffinityInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomAffinity != other.CustomAffinity) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (customAffinity_ != null) hash ^= CustomAffinity.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (customAffinity_ != null) { + _single_customAffinity_codec.WriteTagAndValue(output, CustomAffinity); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (customAffinity_ != null) { + size += _single_customAffinity_codec.CalculateSizeWithTag(CustomAffinity); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomAffinityInfo other) { + if (other == null) { + return; + } + if (other.customAffinity_ != null) { + if (customAffinity_ == null || other.CustomAffinity != "") { + CustomAffinity = other.CustomAffinity; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_customAffinity_codec.Read(input); + if (customAffinity_ == null || value != "") { + CustomAffinity = value; + } + break; + } + } + } + } + + } + + /// + /// A custom intent criterion. + /// A criterion of this type is only targetable. + /// + public sealed partial class CustomIntentInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomIntentInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[52]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomIntentInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomIntentInfo(CustomIntentInfo other) : this() { + CustomIntent = other.CustomIntent; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomIntentInfo Clone() { + return new CustomIntentInfo(this); + } + + /// Field number for the "custom_intent" field. + public const int CustomIntentFieldNumber = 1; + private static readonly pb::FieldCodec _single_customIntent_codec = pb::FieldCodec.ForClassWrapper(10); + private string customIntent_; + /// + /// The CustomInterest resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomIntent { + get { return customIntent_; } + set { + customIntent_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomIntentInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomIntentInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomIntent != other.CustomIntent) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (customIntent_ != null) hash ^= CustomIntent.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (customIntent_ != null) { + _single_customIntent_codec.WriteTagAndValue(output, CustomIntent); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (customIntent_ != null) { + size += _single_customIntent_codec.CalculateSizeWithTag(CustomIntent); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomIntentInfo other) { + if (other == null) { + return; + } + if (other.customIntent_ != null) { + if (customIntent_ == null || other.CustomIntent != "") { + CustomIntent = other.CustomIntent; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_customIntent_codec.Read(input); + if (customIntent_ == null || value != "") { + CustomIntent = value; + } + break; + } + } + } + } + + } + + /// + /// A radius around a list of locations specified via a feed. + /// + public sealed partial class LocationGroupInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new LocationGroupInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor.MessageTypes[53]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationGroupInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationGroupInfo(LocationGroupInfo other) : this() { + Feed = other.Feed; + geoTargetConstants_ = other.geoTargetConstants_.Clone(); + Radius = other.Radius; + radiusUnits_ = other.radiusUnits_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationGroupInfo Clone() { + return new LocationGroupInfo(this); + } + + /// Field number for the "feed" field. + public const int FeedFieldNumber = 1; + private static readonly pb::FieldCodec _single_feed_codec = pb::FieldCodec.ForClassWrapper(10); + private string feed_; + /// + /// Feed specifying locations for targeting. + /// This is required and must be set in CREATE operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Feed { + get { return feed_; } + set { + feed_ = value; + } + } + + + /// Field number for the "geo_target_constants" field. + public const int GeoTargetConstantsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_geoTargetConstants_codec + = pb::FieldCodec.ForClassWrapper(18); + private readonly pbc::RepeatedField geoTargetConstants_ = new pbc::RepeatedField(); + /// + /// Geo target constant(s) restricting the scope of the geographic area within + /// the feed. Currently only one geo target constant is allowed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField GeoTargetConstants { + get { return geoTargetConstants_; } + } + + /// Field number for the "radius" field. + public const int RadiusFieldNumber = 3; + private static readonly pb::FieldCodec _single_radius_codec = pb::FieldCodec.ForStructWrapper(26); + private long? radius_; + /// + /// Distance in units specifying the radius around targeted locations. + /// This is required and must be set in CREATE operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Radius { + get { return radius_; } + set { + radius_ = value; + } + } + + + /// Field number for the "radius_units" field. + public const int RadiusUnitsFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.LocationGroupRadiusUnitsEnum.Types.LocationGroupRadiusUnits radiusUnits_ = 0; + /// + /// Unit of the radius, miles and meters supported currently. + /// This is required and must be set in CREATE operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.LocationGroupRadiusUnitsEnum.Types.LocationGroupRadiusUnits RadiusUnits { + get { return radiusUnits_; } + set { + radiusUnits_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as LocationGroupInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(LocationGroupInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Feed != other.Feed) return false; + if(!geoTargetConstants_.Equals(other.geoTargetConstants_)) return false; + if (Radius != other.Radius) return false; + if (RadiusUnits != other.RadiusUnits) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (feed_ != null) hash ^= Feed.GetHashCode(); + hash ^= geoTargetConstants_.GetHashCode(); + if (radius_ != null) hash ^= Radius.GetHashCode(); + if (RadiusUnits != 0) hash ^= RadiusUnits.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (feed_ != null) { + _single_feed_codec.WriteTagAndValue(output, Feed); + } + geoTargetConstants_.WriteTo(output, _repeated_geoTargetConstants_codec); + if (radius_ != null) { + _single_radius_codec.WriteTagAndValue(output, Radius); + } + if (RadiusUnits != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) RadiusUnits); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (feed_ != null) { + size += _single_feed_codec.CalculateSizeWithTag(Feed); + } + size += geoTargetConstants_.CalculateSize(_repeated_geoTargetConstants_codec); + if (radius_ != null) { + size += _single_radius_codec.CalculateSizeWithTag(Radius); + } + if (RadiusUnits != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) RadiusUnits); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(LocationGroupInfo other) { + if (other == null) { + return; + } + if (other.feed_ != null) { + if (feed_ == null || other.Feed != "") { + Feed = other.Feed; + } + } + geoTargetConstants_.Add(other.geoTargetConstants_); + if (other.radius_ != null) { + if (radius_ == null || other.Radius != 0L) { + Radius = other.Radius; + } + } + if (other.RadiusUnits != 0) { + RadiusUnits = other.RadiusUnits; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_feed_codec.Read(input); + if (feed_ == null || value != "") { + Feed = value; + } + break; + } + case 18: { + geoTargetConstants_.AddEntriesFrom(input, _repeated_geoTargetConstants_codec); + break; + } + case 26: { + long? value = _single_radius_codec.Read(input); + if (radius_ == null || value != 0L) { + Radius = value; + } + break; + } + case 32: { + RadiusUnits = (global::Google.Ads.GoogleAds.V3.Enums.LocationGroupRadiusUnitsEnum.Types.LocationGroupRadiusUnits) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CriterionCategoryAvailability.cs b/src/V3/Stubs/CriterionCategoryAvailability.cs new file mode 100644 index 000000000..d45ffa591 --- /dev/null +++ b/src/V3/Stubs/CriterionCategoryAvailability.cs @@ -0,0 +1,694 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/criterion_category_availability.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/criterion_category_availability.proto + public static partial class CriterionCategoryAvailabilityReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/criterion_category_availability.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CriterionCategoryAvailabilityReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vY3JpdGVyaW9uX2Nh", + "dGVnb3J5X2F2YWlsYWJpbGl0eS5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuY29tbW9uGkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9h", + "ZHZlcnRpc2luZ19jaGFubmVsX3N1Yl90eXBlLnByb3RvGjxnb29nbGUvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcy9hZHZlcnRpc2luZ19jaGFubmVsX3R5cGUu", + "cHJvdG8aUGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2NyaXRlcmlv", + "bl9jYXRlZ29yeV9jaGFubmVsX2F2YWlsYWJpbGl0eV9tb2RlLnByb3RvGk9n", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jcml0ZXJpb25fY2F0ZWdv", + "cnlfbG9jYWxlX2F2YWlsYWJpbGl0eV9tb2RlLnByb3RvGh5nb29nbGUvcHJv", + "dG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMu", + "cHJvdG8iywEKHUNyaXRlcmlvbkNhdGVnb3J5QXZhaWxhYmlsaXR5ElUKB2No", + "YW5uZWwYASABKAsyRC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24u", + "Q3JpdGVyaW9uQ2F0ZWdvcnlDaGFubmVsQXZhaWxhYmlsaXR5ElMKBmxvY2Fs", + "ZRgCIAMoCzJDLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Dcml0", + "ZXJpb25DYXRlZ29yeUxvY2FsZUF2YWlsYWJpbGl0eSLwAwokQ3JpdGVyaW9u", + "Q2F0ZWdvcnlDaGFubmVsQXZhaWxhYmlsaXR5Eo8BChFhdmFpbGFiaWxpdHlf", + "bW9kZRgBIAEoDjJ0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkNy", + "aXRlcmlvbkNhdGVnb3J5Q2hhbm5lbEF2YWlsYWJpbGl0eU1vZGVFbnVtLkNy", + "aXRlcmlvbkNhdGVnb3J5Q2hhbm5lbEF2YWlsYWJpbGl0eU1vZGUScgoYYWR2", + "ZXJ0aXNpbmdfY2hhbm5lbF90eXBlGAIgASgOMlAuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXMuQWR2ZXJ0aXNpbmdDaGFubmVsVHlwZUVudW0uQWR2", + "ZXJ0aXNpbmdDaGFubmVsVHlwZRJ8ChxhZHZlcnRpc2luZ19jaGFubmVsX3N1", + "Yl90eXBlGAMgAygOMlYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMu", + "QWR2ZXJ0aXNpbmdDaGFubmVsU3ViVHlwZUVudW0uQWR2ZXJ0aXNpbmdDaGFu", + "bmVsU3ViVHlwZRJECiBpbmNsdWRlX2RlZmF1bHRfY2hhbm5lbF9zdWJfdHlw", + "ZRgEIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29sVmFsdWUingIKI0NyaXRl", + "cmlvbkNhdGVnb3J5TG9jYWxlQXZhaWxhYmlsaXR5Eo0BChFhdmFpbGFiaWxp", + "dHlfbW9kZRgBIAEoDjJyLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "LkNyaXRlcmlvbkNhdGVnb3J5TG9jYWxlQXZhaWxhYmlsaXR5TW9kZUVudW0u", + "Q3JpdGVyaW9uQ2F0ZWdvcnlMb2NhbGVBdmFpbGFiaWxpdHlNb2RlEjIKDGNv", + "dW50cnlfY29kZRgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZRIzCg1sYW5ndWFnZV9jb2RlGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlQv0BCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29t", + "bW9uQiJDcml0ZXJpb25DYXRlZ29yeUF2YWlsYWJpbGl0eVByb3RvUAFaRGdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9jb21tb247Y29tbW9uogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29n", + "bGVBZHMuVjMuQ29tbW9uygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcQ29t", + "bW9u6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkNvbW1vbmIGcHJv", + "dG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryChannelAvailabilityModeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryLocaleAvailabilityModeReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryAvailability), global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryAvailability.Parser, new[]{ "Channel", "Locale" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryChannelAvailability), global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryChannelAvailability.Parser, new[]{ "AvailabilityMode", "AdvertisingChannelType", "AdvertisingChannelSubType", "IncludeDefaultChannelSubType" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryLocaleAvailability), global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryLocaleAvailability.Parser, new[]{ "AvailabilityMode", "CountryCode", "LanguageCode" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Information of category availability, per advertising channel. + /// + public sealed partial class CriterionCategoryAvailability : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CriterionCategoryAvailability()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryAvailabilityReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryAvailability() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryAvailability(CriterionCategoryAvailability other) : this() { + channel_ = other.channel_ != null ? other.channel_.Clone() : null; + locale_ = other.locale_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryAvailability Clone() { + return new CriterionCategoryAvailability(this); + } + + /// Field number for the "channel" field. + public const int ChannelFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryChannelAvailability channel_; + /// + /// Channel types and subtypes that are available to the category. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryChannelAvailability Channel { + get { return channel_; } + set { + channel_ = value; + } + } + + /// Field number for the "locale" field. + public const int LocaleFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_locale_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryLocaleAvailability.Parser); + private readonly pbc::RepeatedField locale_ = new pbc::RepeatedField(); + /// + /// Locales that are available to the category for the channel. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Locale { + get { return locale_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CriterionCategoryAvailability); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CriterionCategoryAvailability other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Channel, other.Channel)) return false; + if(!locale_.Equals(other.locale_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (channel_ != null) hash ^= Channel.GetHashCode(); + hash ^= locale_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (channel_ != null) { + output.WriteRawTag(10); + output.WriteMessage(Channel); + } + locale_.WriteTo(output, _repeated_locale_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (channel_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Channel); + } + size += locale_.CalculateSize(_repeated_locale_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CriterionCategoryAvailability other) { + if (other == null) { + return; + } + if (other.channel_ != null) { + if (channel_ == null) { + Channel = new global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryChannelAvailability(); + } + Channel.MergeFrom(other.Channel); + } + locale_.Add(other.locale_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (channel_ == null) { + Channel = new global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryChannelAvailability(); + } + input.ReadMessage(Channel); + break; + } + case 18: { + locale_.AddEntriesFrom(input, _repeated_locale_codec); + break; + } + } + } + } + + } + + /// + /// Information of advertising channel type and subtypes a category is available + /// in. + /// + public sealed partial class CriterionCategoryChannelAvailability : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CriterionCategoryChannelAvailability()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryAvailabilityReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryChannelAvailability() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryChannelAvailability(CriterionCategoryChannelAvailability other) : this() { + availabilityMode_ = other.availabilityMode_; + advertisingChannelType_ = other.advertisingChannelType_; + advertisingChannelSubType_ = other.advertisingChannelSubType_.Clone(); + IncludeDefaultChannelSubType = other.IncludeDefaultChannelSubType; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryChannelAvailability Clone() { + return new CriterionCategoryChannelAvailability(this); + } + + /// Field number for the "availability_mode" field. + public const int AvailabilityModeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryChannelAvailabilityModeEnum.Types.CriterionCategoryChannelAvailabilityMode availabilityMode_ = 0; + /// + /// Format of the channel availability. Can be ALL_CHANNELS (the rest of the + /// fields will not be set), CHANNEL_TYPE (only advertising_channel_type type + /// will be set, the category is available to all sub types under it) or + /// CHANNEL_TYPE_AND_SUBTYPES (advertising_channel_type, + /// advertising_channel_sub_type, and include_default_channel_sub_type will all + /// be set). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryChannelAvailabilityModeEnum.Types.CriterionCategoryChannelAvailabilityMode AvailabilityMode { + get { return availabilityMode_; } + set { + availabilityMode_ = value; + } + } + + /// Field number for the "advertising_channel_type" field. + public const int AdvertisingChannelTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType advertisingChannelType_ = 0; + /// + /// Channel type the category is available to. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType AdvertisingChannelType { + get { return advertisingChannelType_; } + set { + advertisingChannelType_ = value; + } + } + + /// Field number for the "advertising_channel_sub_type" field. + public const int AdvertisingChannelSubTypeFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_advertisingChannelSubType_codec + = pb::FieldCodec.ForEnum(26, x => (int) x, x => (global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelSubTypeEnum.Types.AdvertisingChannelSubType) x); + private readonly pbc::RepeatedField advertisingChannelSubType_ = new pbc::RepeatedField(); + /// + /// Channel subtypes under the channel type the category is available to. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField AdvertisingChannelSubType { + get { return advertisingChannelSubType_; } + } + + /// Field number for the "include_default_channel_sub_type" field. + public const int IncludeDefaultChannelSubTypeFieldNumber = 4; + private static readonly pb::FieldCodec _single_includeDefaultChannelSubType_codec = pb::FieldCodec.ForStructWrapper(34); + private bool? includeDefaultChannelSubType_; + /// + /// Whether default channel sub type is included. For example, + /// advertising_channel_type being DISPLAY and include_default_channel_sub_type + /// being false means that the default display campaign where channel sub type + /// is not set is not included in this availability configuration. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? IncludeDefaultChannelSubType { + get { return includeDefaultChannelSubType_; } + set { + includeDefaultChannelSubType_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CriterionCategoryChannelAvailability); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CriterionCategoryChannelAvailability other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (AvailabilityMode != other.AvailabilityMode) return false; + if (AdvertisingChannelType != other.AdvertisingChannelType) return false; + if(!advertisingChannelSubType_.Equals(other.advertisingChannelSubType_)) return false; + if (IncludeDefaultChannelSubType != other.IncludeDefaultChannelSubType) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (AvailabilityMode != 0) hash ^= AvailabilityMode.GetHashCode(); + if (AdvertisingChannelType != 0) hash ^= AdvertisingChannelType.GetHashCode(); + hash ^= advertisingChannelSubType_.GetHashCode(); + if (includeDefaultChannelSubType_ != null) hash ^= IncludeDefaultChannelSubType.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (AvailabilityMode != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) AvailabilityMode); + } + if (AdvertisingChannelType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) AdvertisingChannelType); + } + advertisingChannelSubType_.WriteTo(output, _repeated_advertisingChannelSubType_codec); + if (includeDefaultChannelSubType_ != null) { + _single_includeDefaultChannelSubType_codec.WriteTagAndValue(output, IncludeDefaultChannelSubType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (AvailabilityMode != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AvailabilityMode); + } + if (AdvertisingChannelType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdvertisingChannelType); + } + size += advertisingChannelSubType_.CalculateSize(_repeated_advertisingChannelSubType_codec); + if (includeDefaultChannelSubType_ != null) { + size += _single_includeDefaultChannelSubType_codec.CalculateSizeWithTag(IncludeDefaultChannelSubType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CriterionCategoryChannelAvailability other) { + if (other == null) { + return; + } + if (other.AvailabilityMode != 0) { + AvailabilityMode = other.AvailabilityMode; + } + if (other.AdvertisingChannelType != 0) { + AdvertisingChannelType = other.AdvertisingChannelType; + } + advertisingChannelSubType_.Add(other.advertisingChannelSubType_); + if (other.includeDefaultChannelSubType_ != null) { + if (includeDefaultChannelSubType_ == null || other.IncludeDefaultChannelSubType != false) { + IncludeDefaultChannelSubType = other.IncludeDefaultChannelSubType; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + AvailabilityMode = (global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryChannelAvailabilityModeEnum.Types.CriterionCategoryChannelAvailabilityMode) input.ReadEnum(); + break; + } + case 16: { + AdvertisingChannelType = (global::Google.Ads.GoogleAds.V3.Enums.AdvertisingChannelTypeEnum.Types.AdvertisingChannelType) input.ReadEnum(); + break; + } + case 26: + case 24: { + advertisingChannelSubType_.AddEntriesFrom(input, _repeated_advertisingChannelSubType_codec); + break; + } + case 34: { + bool? value = _single_includeDefaultChannelSubType_codec.Read(input); + if (includeDefaultChannelSubType_ == null || value != false) { + IncludeDefaultChannelSubType = value; + } + break; + } + } + } + } + + } + + /// + /// Information about which locales a category is available in. + /// + public sealed partial class CriterionCategoryLocaleAvailability : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CriterionCategoryLocaleAvailability()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CriterionCategoryAvailabilityReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryLocaleAvailability() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryLocaleAvailability(CriterionCategoryLocaleAvailability other) : this() { + availabilityMode_ = other.availabilityMode_; + CountryCode = other.CountryCode; + LanguageCode = other.LanguageCode; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryLocaleAvailability Clone() { + return new CriterionCategoryLocaleAvailability(this); + } + + /// Field number for the "availability_mode" field. + public const int AvailabilityModeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryLocaleAvailabilityModeEnum.Types.CriterionCategoryLocaleAvailabilityMode availabilityMode_ = 0; + /// + /// Format of the locale availability. Can be LAUNCHED_TO_ALL (both country and + /// language will be empty), COUNTRY (only country will be set), LANGUAGE (only + /// language wil be set), COUNTRY_AND_LANGUAGE (both country and language will + /// be set). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryLocaleAvailabilityModeEnum.Types.CriterionCategoryLocaleAvailabilityMode AvailabilityMode { + get { return availabilityMode_; } + set { + availabilityMode_ = value; + } + } + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string countryCode_; + /// + /// Code of the country. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "language_code" field. + public const int LanguageCodeFieldNumber = 3; + private static readonly pb::FieldCodec _single_languageCode_codec = pb::FieldCodec.ForClassWrapper(26); + private string languageCode_; + /// + /// Code of the language. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LanguageCode { + get { return languageCode_; } + set { + languageCode_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CriterionCategoryLocaleAvailability); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CriterionCategoryLocaleAvailability other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (AvailabilityMode != other.AvailabilityMode) return false; + if (CountryCode != other.CountryCode) return false; + if (LanguageCode != other.LanguageCode) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (AvailabilityMode != 0) hash ^= AvailabilityMode.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (languageCode_ != null) hash ^= LanguageCode.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (AvailabilityMode != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) AvailabilityMode); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (languageCode_ != null) { + _single_languageCode_codec.WriteTagAndValue(output, LanguageCode); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (AvailabilityMode != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AvailabilityMode); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (languageCode_ != null) { + size += _single_languageCode_codec.CalculateSizeWithTag(LanguageCode); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CriterionCategoryLocaleAvailability other) { + if (other == null) { + return; + } + if (other.AvailabilityMode != 0) { + AvailabilityMode = other.AvailabilityMode; + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.languageCode_ != null) { + if (languageCode_ == null || other.LanguageCode != "") { + LanguageCode = other.LanguageCode; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + AvailabilityMode = (global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryLocaleAvailabilityModeEnum.Types.CriterionCategoryLocaleAvailabilityMode) input.ReadEnum(); + break; + } + case 18: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 26: { + string value = _single_languageCode_codec.Read(input); + if (languageCode_ == null || value != "") { + LanguageCode = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CriterionCategoryChannelAvailabilityMode.cs b/src/V3/Stubs/CriterionCategoryChannelAvailabilityMode.cs new file mode 100644 index 000000000..efb6ca45f --- /dev/null +++ b/src/V3/Stubs/CriterionCategoryChannelAvailabilityMode.cs @@ -0,0 +1,197 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/criterion_category_channel_availability_mode.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/criterion_category_channel_availability_mode.proto + public static partial class CriterionCategoryChannelAvailabilityModeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/criterion_category_channel_availability_mode.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CriterionCategoryChannelAvailabilityModeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "ClBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jcml0ZXJpb25fY2F0", + "ZWdvcnlfY2hhbm5lbF9hdmFpbGFiaWxpdHlfbW9kZS5wcm90bxIdZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlv", + "bnMucHJvdG8i1AEKLENyaXRlcmlvbkNhdGVnb3J5Q2hhbm5lbEF2YWlsYWJp", + "bGl0eU1vZGVFbnVtIqMBCihDcml0ZXJpb25DYXRlZ29yeUNoYW5uZWxBdmFp", + "bGFiaWxpdHlNb2RlEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhAK", + "DEFMTF9DSEFOTkVMUxACEiEKHUNIQU5ORUxfVFlQRV9BTkRfQUxMX1NVQlRZ", + "UEVTEAMSJAogQ0hBTk5FTF9UWVBFX0FORF9TVUJTRVRfU1VCVFlQRVMQBEKC", + "AgohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQi1Dcml0ZXJp", + "b25DYXRlZ29yeUNoYW5uZWxBdmFpbGFiaWxpdHlNb2RlUHJvdG9QAVpCZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVB", + "ZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oC", + "IUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryChannelAvailabilityModeEnum), global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryChannelAvailabilityModeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryChannelAvailabilityModeEnum.Types.CriterionCategoryChannelAvailabilityMode) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Describes channel availability mode for a criterion availability - whether + /// the availability is meant to include all advertising channels, or a + /// particular channel with all its channel subtypes, or a channel with a certain + /// subset of channel subtypes. + /// + public sealed partial class CriterionCategoryChannelAvailabilityModeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CriterionCategoryChannelAvailabilityModeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryChannelAvailabilityModeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryChannelAvailabilityModeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryChannelAvailabilityModeEnum(CriterionCategoryChannelAvailabilityModeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryChannelAvailabilityModeEnum Clone() { + return new CriterionCategoryChannelAvailabilityModeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CriterionCategoryChannelAvailabilityModeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CriterionCategoryChannelAvailabilityModeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CriterionCategoryChannelAvailabilityModeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CriterionCategoryChannelAvailabilityModeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum containing the possible CriterionCategoryChannelAvailabilityMode. + /// + public enum CriterionCategoryChannelAvailabilityMode { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The category is available to campaigns of all channel types and subtypes. + /// + [pbr::OriginalName("ALL_CHANNELS")] AllChannels = 2, + /// + /// The category is available to campaigns of a specific channel type, + /// including all subtypes under it. + /// + [pbr::OriginalName("CHANNEL_TYPE_AND_ALL_SUBTYPES")] ChannelTypeAndAllSubtypes = 3, + /// + /// The category is available to campaigns of a specific channel type and + /// subtype(s). + /// + [pbr::OriginalName("CHANNEL_TYPE_AND_SUBSET_SUBTYPES")] ChannelTypeAndSubsetSubtypes = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CriterionCategoryLocaleAvailabilityMode.cs b/src/V3/Stubs/CriterionCategoryLocaleAvailabilityMode.cs new file mode 100644 index 000000000..7e468be49 --- /dev/null +++ b/src/V3/Stubs/CriterionCategoryLocaleAvailabilityMode.cs @@ -0,0 +1,202 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/criterion_category_locale_availability_mode.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/criterion_category_locale_availability_mode.proto + public static partial class CriterionCategoryLocaleAvailabilityModeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/criterion_category_locale_availability_mode.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CriterionCategoryLocaleAvailabilityModeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ck9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jcml0ZXJpb25fY2F0", + "ZWdvcnlfbG9jYWxlX2F2YWlsYWJpbGl0eV9tb2RlLnByb3RvEh1nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90byLhAQorQ3JpdGVyaW9uQ2F0ZWdvcnlMb2NhbGVBdmFpbGFiaWxp", + "dHlNb2RlRW51bSKxAQonQ3JpdGVyaW9uQ2F0ZWdvcnlMb2NhbGVBdmFpbGFi", + "aWxpdHlNb2RlEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEg8KC0FM", + "TF9MT0NBTEVTEAISHQoZQ09VTlRSWV9BTkRfQUxMX0xBTkdVQUdFUxADEh4K", + "GkxBTkdVQUdFX0FORF9BTExfQ09VTlRSSUVTEAQSGAoUQ09VTlRSWV9BTkRf", + "TEFOR1VBR0UQBUKBAgohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zQixDcml0ZXJpb25DYXRlZ29yeUxvY2FsZUF2YWlsYWJpbGl0eU1vZGVQ", + "cm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlz", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRz", + "XFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1z", + "YgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryLocaleAvailabilityModeEnum), global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryLocaleAvailabilityModeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryLocaleAvailabilityModeEnum.Types.CriterionCategoryLocaleAvailabilityMode) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Describes locale availability mode for a criterion availability - whether + /// it's available globally, or a particular country with all languages, or a + /// particular language with all countries, or a country-language pair. + /// + public sealed partial class CriterionCategoryLocaleAvailabilityModeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CriterionCategoryLocaleAvailabilityModeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CriterionCategoryLocaleAvailabilityModeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryLocaleAvailabilityModeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryLocaleAvailabilityModeEnum(CriterionCategoryLocaleAvailabilityModeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionCategoryLocaleAvailabilityModeEnum Clone() { + return new CriterionCategoryLocaleAvailabilityModeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CriterionCategoryLocaleAvailabilityModeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CriterionCategoryLocaleAvailabilityModeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CriterionCategoryLocaleAvailabilityModeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CriterionCategoryLocaleAvailabilityModeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum containing the possible CriterionCategoryLocaleAvailabilityMode. + /// + public enum CriterionCategoryLocaleAvailabilityMode { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The category is available to campaigns of all locales. + /// + [pbr::OriginalName("ALL_LOCALES")] AllLocales = 2, + /// + /// The category is available to campaigns within a list of countries, + /// regardless of language. + /// + [pbr::OriginalName("COUNTRY_AND_ALL_LANGUAGES")] CountryAndAllLanguages = 3, + /// + /// The category is available to campaigns within a list of languages, + /// regardless of country. + /// + [pbr::OriginalName("LANGUAGE_AND_ALL_COUNTRIES")] LanguageAndAllCountries = 4, + /// + /// The category is available to campaigns within a list of country, language + /// pairs. + /// + [pbr::OriginalName("COUNTRY_AND_LANGUAGE")] CountryAndLanguage = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CriterionError.cs b/src/V3/Stubs/CriterionError.cs new file mode 100644 index 000000000..e9db40015 --- /dev/null +++ b/src/V3/Stubs/CriterionError.cs @@ -0,0 +1,685 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/criterion_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/criterion_error.proto + public static partial class CriterionErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/criterion_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CriterionErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY3JpdGVyaW9uX2Vy", + "cm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMaHGdv", + "b2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i4R0KEkNyaXRlcmlvbkVycm9y", + "RW51bSLKHQoOQ3JpdGVyaW9uRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdV", + "TktOT1dOEAESGgoWQ09OQ1JFVEVfVFlQRV9SRVFVSVJFRBACEh0KGUlOVkFM", + "SURfRVhDTFVERURfQ0FURUdPUlkQAxIYChRJTlZBTElEX0tFWVdPUkRfVEVY", + "VBAEEhkKFUtFWVdPUkRfVEVYVF9UT09fTE9ORxAFEh4KGktFWVdPUkRfSEFT", + "X1RPT19NQU5ZX1dPUkRTEAYSHQoZS0VZV09SRF9IQVNfSU5WQUxJRF9DSEFS", + "UxAHEhkKFUlOVkFMSURfUExBQ0VNRU5UX1VSTBAIEhUKEUlOVkFMSURfVVNF", + "Ul9MSVNUEAkSGQoVSU5WQUxJRF9VU0VSX0lOVEVSRVNUEAoSJAogSU5WQUxJ", + "RF9GT1JNQVRfRk9SX1BMQUNFTUVOVF9VUkwQCxIdChlQTEFDRU1FTlRfVVJM", + "X0lTX1RPT19MT05HEAwSIgoeUExBQ0VNRU5UX1VSTF9IQVNfSUxMRUdBTF9D", + "SEFSEA0SLAooUExBQ0VNRU5UX1VSTF9IQVNfTVVMVElQTEVfU0lURVNfSU5f", + "TElORRAOEjkKNVBMQUNFTUVOVF9JU19OT1RfQVZBSUxBQkxFX0ZPUl9UQVJH", + "RVRJTkdfT1JfRVhDTFVTSU9OEA8SFgoSSU5WQUxJRF9UT1BJQ19QQVRIEBAS", + "HgoaSU5WQUxJRF9ZT1VUVUJFX0NIQU5ORUxfSUQQERIcChhJTlZBTElEX1lP", + "VVRVQkVfVklERU9fSUQQEhInCiNZT1VUVUJFX1ZFUlRJQ0FMX0NIQU5ORUxf", + "REVQUkVDQVRFRBATEioKJllPVVRVQkVfREVNT0dSQVBISUNfQ0hBTk5FTF9E", + "RVBSRUNBVEVEEBQSGwoXWU9VVFVCRV9VUkxfVU5TVVBQT1JURUQQFRIgChxD", + "QU5OT1RfRVhDTFVERV9DUklURVJJQV9UWVBFEBYSHAoYQ0FOTk9UX0FERF9D", + "UklURVJJQV9UWVBFEBcSGgoWSU5WQUxJRF9QUk9EVUNUX0ZJTFRFUhAYEhsK", + "F1BST0RVQ1RfRklMVEVSX1RPT19MT05HEBkSJAogQ0FOTk9UX0VYQ0xVREVf", + "U0lNSUxBUl9VU0VSX0xJU1QQGhIfChtDQU5OT1RfQUREX0NMT1NFRF9VU0VS", + "X0xJU1QQGxI6CjZDQU5OT1RfQUREX0RJU1BMQVlfT05MWV9MSVNUU19UT19T", + "RUFSQ0hfT05MWV9DQU1QQUlHTlMQHBI1CjFDQU5OT1RfQUREX0RJU1BMQVlf", + "T05MWV9MSVNUU19UT19TRUFSQ0hfQ0FNUEFJR05TEB0SNwozQ0FOTk9UX0FE", + "RF9ESVNQTEFZX09OTFlfTElTVFNfVE9fU0hPUFBJTkdfQ0FNUEFJR05TEB4S", + "MQotQ0FOTk9UX0FERF9VU0VSX0lOVEVSRVNUU19UT19TRUFSQ0hfQ0FNUEFJ", + "R05TEB8SOQo1Q0FOTk9UX1NFVF9CSURTX09OX0NSSVRFUklPTl9UWVBFX0lO", + "X1NFQVJDSF9DQU1QQUlHTlMQIBI3CjNDQU5OT1RfQUREX1VSTFNfVE9fQ1JJ", + "VEVSSU9OX1RZUEVfRk9SX0NBTVBBSUdOX1RZUEUQIRIbChdJTlZBTElEX0NV", + "U1RPTV9BRkZJTklUWRBgEhkKFUlOVkFMSURfQ1VTVE9NX0lOVEVOVBBhEhYK", + "EklOVkFMSURfSVBfQUREUkVTUxAiEhUKEUlOVkFMSURfSVBfRk9STUFUECMS", + "FgoSSU5WQUxJRF9NT0JJTEVfQVBQECQSHwobSU5WQUxJRF9NT0JJTEVfQVBQ", + "X0NBVEVHT1JZECUSGAoUSU5WQUxJRF9DUklURVJJT05fSUQQJhIbChdDQU5O", + "T1RfVEFSR0VUX0NSSVRFUklPThAnEiQKIENBTk5PVF9UQVJHRVRfT0JTT0xF", + "VEVfQ1JJVEVSSU9OECgSIgoeQ1JJVEVSSU9OX0lEX0FORF9UWVBFX01JU01B", + "VENIECkSHAoYSU5WQUxJRF9QUk9YSU1JVFlfUkFESVVTECoSIgoeSU5WQUxJ", + "RF9QUk9YSU1JVFlfUkFESVVTX1VOSVRTECsSIAocSU5WQUxJRF9TVFJFRVRB", + "RERSRVNTX0xFTkdUSBAsEhsKF0lOVkFMSURfQ0lUWU5BTUVfTEVOR1RIEC0S", + "HQoZSU5WQUxJRF9SRUdJT05DT0RFX0xFTkdUSBAuEh0KGUlOVkFMSURfUkVH", + "SU9OTkFNRV9MRU5HVEgQLxIdChlJTlZBTElEX1BPU1RBTENPREVfTEVOR1RI", + "EDASGAoUSU5WQUxJRF9DT1VOVFJZX0NPREUQMRIUChBJTlZBTElEX0xBVElU", + "VURFEDISFQoRSU5WQUxJRF9MT05HSVRVREUQMxI2CjJQUk9YSU1JVFlfR0VP", + "UE9JTlRfQU5EX0FERFJFU1NfQk9USF9DQU5OT1RfQkVfTlVMTBA0Eh0KGUlO", + "VkFMSURfUFJPWElNSVRZX0FERFJFU1MQNRIcChhJTlZBTElEX1VTRVJfRE9N", + "QUlOX05BTUUQNhIgChxDUklURVJJT05fUEFSQU1FVEVSX1RPT19MT05HEDcS", + "JgoiQURfU0NIRURVTEVfVElNRV9JTlRFUlZBTFNfT1ZFUkxBUBA4EjIKLkFE", + "X1NDSEVEVUxFX0lOVEVSVkFMX0NBTk5PVF9TUEFOX01VTFRJUExFX0RBWVMQ", + "ORIlCiFBRF9TQ0hFRFVMRV9JTlZBTElEX1RJTUVfSU5URVJWQUwQOhIwCixB", + "RF9TQ0hFRFVMRV9FWENFRURFRF9JTlRFUlZBTFNfUEVSX0RBWV9MSU1JVBA7", + "Ei8KK0FEX1NDSEVEVUxFX0NSSVRFUklPTl9JRF9NSVNNQVRDSElOR19GSUVM", + "RFMQPBIkCiBDQU5OT1RfQklEX01PRElGWV9DUklURVJJT05fVFlQRRA9EjIK", + "LkNBTk5PVF9CSURfTU9ESUZZX0NSSVRFUklPTl9DQU1QQUlHTl9PUFRFRF9P", + "VVQQPhIoCiRDQU5OT1RfQklEX01PRElGWV9ORUdBVElWRV9DUklURVJJT04Q", + "PxIfChtCSURfTU9ESUZJRVJfQUxSRUFEWV9FWElTVFMQQBIXChNGRUVEX0lE", + "X05PVF9BTExPV0VEEEESKAokQUNDT1VOVF9JTkVMSUdJQkxFX0ZPUl9DUklU", + "RVJJQV9UWVBFEEISLgoqQ1JJVEVSSUFfVFlQRV9JTlZBTElEX0ZPUl9CSURE", + "SU5HX1NUUkFURUdZEEMSHAoYQ0FOTk9UX0VYQ0xVREVfQ1JJVEVSSU9OEEQS", + "GwoXQ0FOTk9UX1JFTU9WRV9DUklURVJJT04QRRIaChZQUk9EVUNUX1NDT1BF", + "X1RPT19MT05HEEYSJQohUFJPRFVDVF9TQ09QRV9UT09fTUFOWV9ESU1FTlNJ", + "T05TEEcSHgoaUFJPRFVDVF9QQVJUSVRJT05fVE9PX0xPTkcQSBIpCiVQUk9E", + "VUNUX1BBUlRJVElPTl9UT09fTUFOWV9ESU1FTlNJT05TEEkSHQoZSU5WQUxJ", + "RF9QUk9EVUNUX0RJTUVOU0lPThBKEiIKHklOVkFMSURfUFJPRFVDVF9ESU1F", + "TlNJT05fVFlQRRBLEiQKIElOVkFMSURfUFJPRFVDVF9CSURESU5HX0NBVEVH", + "T1JZEEwSHAoYTUlTU0lOR19TSE9QUElOR19TRVRUSU5HEE0SHQoZSU5WQUxJ", + "RF9NQVRDSElOR19GVU5DVElPThBOEh8KG0xPQ0FUSU9OX0ZJTFRFUl9OT1Rf", + "QUxMT1dFRBBPEiQKIElOVkFMSURfRkVFRF9GT1JfTE9DQVRJT05fRklMVEVS", + "EGISGwoXTE9DQVRJT05fRklMVEVSX0lOVkFMSUQQUBIyCi5DQU5OT1RfQVRU", + "QUNIX0NSSVRFUklBX0FUX0NBTVBBSUdOX0FORF9BREdST1VQEFESOQo1SE9U", + "RUxfTEVOR1RIX09GX1NUQVlfT1ZFUkxBUFNfV0lUSF9FWElTVElOR19DUklU", + "RVJJT04QUhJBCj1IT1RFTF9BRFZBTkNFX0JPT0tJTkdfV0lORE9XX09WRVJM", + "QVBTX1dJVEhfRVhJU1RJTkdfQ1JJVEVSSU9OEFMSLgoqRklFTERfSU5DT01Q", + "QVRJQkxFX1dJVEhfTkVHQVRJVkVfVEFSR0VUSU5HEFQSHQoZSU5WQUxJRF9X", + "RUJQQUdFX0NPTkRJVElPThBVEiEKHUlOVkFMSURfV0VCUEFHRV9DT05ESVRJ", + "T05fVVJMEFYSKQolV0VCUEFHRV9DT05ESVRJT05fVVJMX0NBTk5PVF9CRV9F", + "TVBUWRBXEi4KKldFQlBBR0VfQ09ORElUSU9OX1VSTF9VTlNVUFBPUlRFRF9Q", + "Uk9UT0NPTBBYEi4KKldFQlBBR0VfQ09ORElUSU9OX1VSTF9DQU5OT1RfQkVf", + "SVBfQUREUkVTUxBZEkUKQVdFQlBBR0VfQ09ORElUSU9OX1VSTF9ET01BSU5f", + "Tk9UX0NPTlNJU1RFTlRfV0lUSF9DQU1QQUlHTl9TRVRUSU5HEFoSMQotV0VC", + "UEFHRV9DT05ESVRJT05fVVJMX0NBTk5PVF9CRV9QVUJMSUNfU1VGRklYEFsS", + "LworV0VCUEFHRV9DT05ESVRJT05fVVJMX0lOVkFMSURfUFVCTElDX1NVRkZJ", + "WBBcEjkKNVdFQlBBR0VfQ09ORElUSU9OX1VSTF9WQUxVRV9UUkFDS19WQUxV", + "RV9OT1RfU1VQUE9SVEVEEF0SPAo4V0VCUEFHRV9DUklURVJJT05fVVJMX0VR", + "VUFMU19DQU5fSEFWRV9PTkxZX09ORV9DT05ESVRJT04QXhI3CjNXRUJQQUdF", + "X0NSSVRFUklPTl9OT1RfU1VQUE9SVEVEX09OX05PTl9EU0FfQURfR1JPVVAQ", + "XxI3CjNDQU5OT1RfVEFSR0VUX1VTRVJfTElTVF9GT1JfU01BUlRfRElTUExB", + "WV9DQU1QQUlHTlMQY0LuAQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9yc0ITQ3JpdGVyaW9uRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJy", + "b3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVy", + "cm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2ds", + "ZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CriterionErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CriterionErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CriterionErrorEnum.Types.CriterionError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible criterion errors. + /// + public sealed partial class CriterionErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CriterionErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CriterionErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionErrorEnum(CriterionErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionErrorEnum Clone() { + return new CriterionErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CriterionErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CriterionErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CriterionErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CriterionErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible criterion errors. + /// + public enum CriterionError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Concrete type of criterion is required for CREATE and UPDATE operations. + /// + [pbr::OriginalName("CONCRETE_TYPE_REQUIRED")] ConcreteTypeRequired = 2, + /// + /// The category requested for exclusion is invalid. + /// + [pbr::OriginalName("INVALID_EXCLUDED_CATEGORY")] InvalidExcludedCategory = 3, + /// + /// Invalid keyword criteria text. + /// + [pbr::OriginalName("INVALID_KEYWORD_TEXT")] InvalidKeywordText = 4, + /// + /// Keyword text should be less than 80 chars. + /// + [pbr::OriginalName("KEYWORD_TEXT_TOO_LONG")] KeywordTextTooLong = 5, + /// + /// Keyword text has too many words. + /// + [pbr::OriginalName("KEYWORD_HAS_TOO_MANY_WORDS")] KeywordHasTooManyWords = 6, + /// + /// Keyword text has invalid characters or symbols. + /// + [pbr::OriginalName("KEYWORD_HAS_INVALID_CHARS")] KeywordHasInvalidChars = 7, + /// + /// Invalid placement URL. + /// + [pbr::OriginalName("INVALID_PLACEMENT_URL")] InvalidPlacementUrl = 8, + /// + /// Invalid user list criterion. + /// + [pbr::OriginalName("INVALID_USER_LIST")] InvalidUserList = 9, + /// + /// Invalid user interest criterion. + /// + [pbr::OriginalName("INVALID_USER_INTEREST")] InvalidUserInterest = 10, + /// + /// Placement URL has wrong format. + /// + [pbr::OriginalName("INVALID_FORMAT_FOR_PLACEMENT_URL")] InvalidFormatForPlacementUrl = 11, + /// + /// Placement URL is too long. + /// + [pbr::OriginalName("PLACEMENT_URL_IS_TOO_LONG")] PlacementUrlIsTooLong = 12, + /// + /// Indicates the URL contains an illegal character. + /// + [pbr::OriginalName("PLACEMENT_URL_HAS_ILLEGAL_CHAR")] PlacementUrlHasIllegalChar = 13, + /// + /// Indicates the URL contains multiple comma separated URLs. + /// + [pbr::OriginalName("PLACEMENT_URL_HAS_MULTIPLE_SITES_IN_LINE")] PlacementUrlHasMultipleSitesInLine = 14, + /// + /// Indicates the domain is blacklisted. + /// + [pbr::OriginalName("PLACEMENT_IS_NOT_AVAILABLE_FOR_TARGETING_OR_EXCLUSION")] PlacementIsNotAvailableForTargetingOrExclusion = 15, + /// + /// Invalid topic path. + /// + [pbr::OriginalName("INVALID_TOPIC_PATH")] InvalidTopicPath = 16, + /// + /// The YouTube Channel Id is invalid. + /// + [pbr::OriginalName("INVALID_YOUTUBE_CHANNEL_ID")] InvalidYoutubeChannelId = 17, + /// + /// The YouTube Video Id is invalid. + /// + [pbr::OriginalName("INVALID_YOUTUBE_VIDEO_ID")] InvalidYoutubeVideoId = 18, + /// + /// Indicates the placement is a YouTube vertical channel, which is no longer + /// supported. + /// + [pbr::OriginalName("YOUTUBE_VERTICAL_CHANNEL_DEPRECATED")] YoutubeVerticalChannelDeprecated = 19, + /// + /// Indicates the placement is a YouTube demographic channel, which is no + /// longer supported. + /// + [pbr::OriginalName("YOUTUBE_DEMOGRAPHIC_CHANNEL_DEPRECATED")] YoutubeDemographicChannelDeprecated = 20, + /// + /// YouTube urls are not supported in Placement criterion. Use YouTubeChannel + /// and YouTubeVideo criterion instead. + /// + [pbr::OriginalName("YOUTUBE_URL_UNSUPPORTED")] YoutubeUrlUnsupported = 21, + /// + /// Criteria type can not be excluded by the customer, like AOL account type + /// cannot target site type criteria. + /// + [pbr::OriginalName("CANNOT_EXCLUDE_CRITERIA_TYPE")] CannotExcludeCriteriaType = 22, + /// + /// Criteria type can not be targeted. + /// + [pbr::OriginalName("CANNOT_ADD_CRITERIA_TYPE")] CannotAddCriteriaType = 23, + /// + /// Product filter in the product criteria has invalid characters. Operand + /// and the argument in the filter can not have "==" or "&+". + /// + [pbr::OriginalName("INVALID_PRODUCT_FILTER")] InvalidProductFilter = 24, + /// + /// Product filter in the product criteria is translated to a string as + /// operand1==argument1&+operand2==argument2, maximum allowed length for the + /// string is 255 chars. + /// + [pbr::OriginalName("PRODUCT_FILTER_TOO_LONG")] ProductFilterTooLong = 25, + /// + /// Not allowed to exclude similar user list. + /// + [pbr::OriginalName("CANNOT_EXCLUDE_SIMILAR_USER_LIST")] CannotExcludeSimilarUserList = 26, + /// + /// Not allowed to target a closed user list. + /// + [pbr::OriginalName("CANNOT_ADD_CLOSED_USER_LIST")] CannotAddClosedUserList = 27, + /// + /// Not allowed to add display only UserLists to search only campaigns. + /// + [pbr::OriginalName("CANNOT_ADD_DISPLAY_ONLY_LISTS_TO_SEARCH_ONLY_CAMPAIGNS")] CannotAddDisplayOnlyListsToSearchOnlyCampaigns = 28, + /// + /// Not allowed to add display only UserLists to search plus campaigns. + /// + [pbr::OriginalName("CANNOT_ADD_DISPLAY_ONLY_LISTS_TO_SEARCH_CAMPAIGNS")] CannotAddDisplayOnlyListsToSearchCampaigns = 29, + /// + /// Not allowed to add display only UserLists to shopping campaigns. + /// + [pbr::OriginalName("CANNOT_ADD_DISPLAY_ONLY_LISTS_TO_SHOPPING_CAMPAIGNS")] CannotAddDisplayOnlyListsToShoppingCampaigns = 30, + /// + /// Not allowed to add User interests to search only campaigns. + /// + [pbr::OriginalName("CANNOT_ADD_USER_INTERESTS_TO_SEARCH_CAMPAIGNS")] CannotAddUserInterestsToSearchCampaigns = 31, + /// + /// Not allowed to set bids for this criterion type in search campaigns + /// + [pbr::OriginalName("CANNOT_SET_BIDS_ON_CRITERION_TYPE_IN_SEARCH_CAMPAIGNS")] CannotSetBidsOnCriterionTypeInSearchCampaigns = 32, + /// + /// Final URLs, URL Templates and CustomParameters cannot be set for the + /// criterion types of Gender, AgeRange, UserList, Placement, MobileApp, and + /// MobileAppCategory in search campaigns and shopping campaigns. + /// + [pbr::OriginalName("CANNOT_ADD_URLS_TO_CRITERION_TYPE_FOR_CAMPAIGN_TYPE")] CannotAddUrlsToCriterionTypeForCampaignType = 33, + /// + /// Invalid custom affinity criterion. + /// + [pbr::OriginalName("INVALID_CUSTOM_AFFINITY")] InvalidCustomAffinity = 96, + /// + /// Invalid custom intent criterion. + /// + [pbr::OriginalName("INVALID_CUSTOM_INTENT")] InvalidCustomIntent = 97, + /// + /// IP address is not valid. + /// + [pbr::OriginalName("INVALID_IP_ADDRESS")] InvalidIpAddress = 34, + /// + /// IP format is not valid. + /// + [pbr::OriginalName("INVALID_IP_FORMAT")] InvalidIpFormat = 35, + /// + /// Mobile application is not valid. + /// + [pbr::OriginalName("INVALID_MOBILE_APP")] InvalidMobileApp = 36, + /// + /// Mobile application category is not valid. + /// + [pbr::OriginalName("INVALID_MOBILE_APP_CATEGORY")] InvalidMobileAppCategory = 37, + /// + /// The CriterionId does not exist or is of the incorrect type. + /// + [pbr::OriginalName("INVALID_CRITERION_ID")] InvalidCriterionId = 38, + /// + /// The Criterion is not allowed to be targeted. + /// + [pbr::OriginalName("CANNOT_TARGET_CRITERION")] CannotTargetCriterion = 39, + /// + /// The criterion is not allowed to be targeted as it is deprecated. + /// + [pbr::OriginalName("CANNOT_TARGET_OBSOLETE_CRITERION")] CannotTargetObsoleteCriterion = 40, + /// + /// The CriterionId is not valid for the type. + /// + [pbr::OriginalName("CRITERION_ID_AND_TYPE_MISMATCH")] CriterionIdAndTypeMismatch = 41, + /// + /// Distance for the radius for the proximity criterion is invalid. + /// + [pbr::OriginalName("INVALID_PROXIMITY_RADIUS")] InvalidProximityRadius = 42, + /// + /// Units for the distance for the radius for the proximity criterion is + /// invalid. + /// + [pbr::OriginalName("INVALID_PROXIMITY_RADIUS_UNITS")] InvalidProximityRadiusUnits = 43, + /// + /// Street address in the address is not valid. + /// + [pbr::OriginalName("INVALID_STREETADDRESS_LENGTH")] InvalidStreetaddressLength = 44, + /// + /// City name in the address is not valid. + /// + [pbr::OriginalName("INVALID_CITYNAME_LENGTH")] InvalidCitynameLength = 45, + /// + /// Region code in the address is not valid. + /// + [pbr::OriginalName("INVALID_REGIONCODE_LENGTH")] InvalidRegioncodeLength = 46, + /// + /// Region name in the address is not valid. + /// + [pbr::OriginalName("INVALID_REGIONNAME_LENGTH")] InvalidRegionnameLength = 47, + /// + /// Postal code in the address is not valid. + /// + [pbr::OriginalName("INVALID_POSTALCODE_LENGTH")] InvalidPostalcodeLength = 48, + /// + /// Country code in the address is not valid. + /// + [pbr::OriginalName("INVALID_COUNTRY_CODE")] InvalidCountryCode = 49, + /// + /// Latitude for the GeoPoint is not valid. + /// + [pbr::OriginalName("INVALID_LATITUDE")] InvalidLatitude = 50, + /// + /// Longitude for the GeoPoint is not valid. + /// + [pbr::OriginalName("INVALID_LONGITUDE")] InvalidLongitude = 51, + /// + /// The Proximity input is not valid. Both address and geoPoint cannot be + /// null. + /// + [pbr::OriginalName("PROXIMITY_GEOPOINT_AND_ADDRESS_BOTH_CANNOT_BE_NULL")] ProximityGeopointAndAddressBothCannotBeNull = 52, + /// + /// The Proximity address cannot be geocoded to a valid lat/long. + /// + [pbr::OriginalName("INVALID_PROXIMITY_ADDRESS")] InvalidProximityAddress = 53, + /// + /// User domain name is not valid. + /// + [pbr::OriginalName("INVALID_USER_DOMAIN_NAME")] InvalidUserDomainName = 54, + /// + /// Length of serialized criterion parameter exceeded size limit. + /// + [pbr::OriginalName("CRITERION_PARAMETER_TOO_LONG")] CriterionParameterTooLong = 55, + /// + /// Time interval in the AdSchedule overlaps with another AdSchedule. + /// + [pbr::OriginalName("AD_SCHEDULE_TIME_INTERVALS_OVERLAP")] AdScheduleTimeIntervalsOverlap = 56, + /// + /// AdSchedule time interval cannot span multiple days. + /// + [pbr::OriginalName("AD_SCHEDULE_INTERVAL_CANNOT_SPAN_MULTIPLE_DAYS")] AdScheduleIntervalCannotSpanMultipleDays = 57, + /// + /// AdSchedule time interval specified is invalid, endTime cannot be earlier + /// than startTime. + /// + [pbr::OriginalName("AD_SCHEDULE_INVALID_TIME_INTERVAL")] AdScheduleInvalidTimeInterval = 58, + /// + /// The number of AdSchedule entries in a day exceeds the limit. + /// + [pbr::OriginalName("AD_SCHEDULE_EXCEEDED_INTERVALS_PER_DAY_LIMIT")] AdScheduleExceededIntervalsPerDayLimit = 59, + /// + /// CriteriaId does not match the interval of the AdSchedule specified. + /// + [pbr::OriginalName("AD_SCHEDULE_CRITERION_ID_MISMATCHING_FIELDS")] AdScheduleCriterionIdMismatchingFields = 60, + /// + /// Cannot set bid modifier for this criterion type. + /// + [pbr::OriginalName("CANNOT_BID_MODIFY_CRITERION_TYPE")] CannotBidModifyCriterionType = 61, + /// + /// Cannot bid modify criterion, since it is opted out of the campaign. + /// + [pbr::OriginalName("CANNOT_BID_MODIFY_CRITERION_CAMPAIGN_OPTED_OUT")] CannotBidModifyCriterionCampaignOptedOut = 62, + /// + /// Cannot set bid modifier for a negative criterion. + /// + [pbr::OriginalName("CANNOT_BID_MODIFY_NEGATIVE_CRITERION")] CannotBidModifyNegativeCriterion = 63, + /// + /// Bid Modifier already exists. Use SET operation to update. + /// + [pbr::OriginalName("BID_MODIFIER_ALREADY_EXISTS")] BidModifierAlreadyExists = 64, + /// + /// Feed Id is not allowed in these Location Groups. + /// + [pbr::OriginalName("FEED_ID_NOT_ALLOWED")] FeedIdNotAllowed = 65, + /// + /// The account may not use the requested criteria type. For example, some + /// accounts are restricted to keywords only. + /// + [pbr::OriginalName("ACCOUNT_INELIGIBLE_FOR_CRITERIA_TYPE")] AccountIneligibleForCriteriaType = 66, + /// + /// The requested criteria type cannot be used with campaign or ad group + /// bidding strategy. + /// + [pbr::OriginalName("CRITERIA_TYPE_INVALID_FOR_BIDDING_STRATEGY")] CriteriaTypeInvalidForBiddingStrategy = 67, + /// + /// The Criterion is not allowed to be excluded. + /// + [pbr::OriginalName("CANNOT_EXCLUDE_CRITERION")] CannotExcludeCriterion = 68, + /// + /// The criterion is not allowed to be removed. For example, we cannot remove + /// any of the device criterion. + /// + [pbr::OriginalName("CANNOT_REMOVE_CRITERION")] CannotRemoveCriterion = 69, + /// + /// The combined length of product dimension values of the product scope + /// criterion is too long. + /// + [pbr::OriginalName("PRODUCT_SCOPE_TOO_LONG")] ProductScopeTooLong = 70, + /// + /// Product scope contains too many dimensions. + /// + [pbr::OriginalName("PRODUCT_SCOPE_TOO_MANY_DIMENSIONS")] ProductScopeTooManyDimensions = 71, + /// + /// The combined length of product dimension values of the product partition + /// criterion is too long. + /// + [pbr::OriginalName("PRODUCT_PARTITION_TOO_LONG")] ProductPartitionTooLong = 72, + /// + /// Product partition contains too many dimensions. + /// + [pbr::OriginalName("PRODUCT_PARTITION_TOO_MANY_DIMENSIONS")] ProductPartitionTooManyDimensions = 73, + /// + /// The product dimension is invalid (e.g. dimension contains illegal value, + /// dimension type is represented with wrong class, etc). Product dimension + /// value can not contain "==" or "&+". + /// + [pbr::OriginalName("INVALID_PRODUCT_DIMENSION")] InvalidProductDimension = 74, + /// + /// Product dimension type is either invalid for campaigns of this type or + /// cannot be used in the current context. BIDDING_CATEGORY_Lx and + /// PRODUCT_TYPE_Lx product dimensions must be used in ascending order of + /// their levels: L1, L2, L3, L4, L5... The levels must be specified + /// sequentially and start from L1. Furthermore, an "others" product + /// partition cannot be subdivided with a dimension of the same type but of a + /// higher level ("others" BIDDING_CATEGORY_L3 can be subdivided with BRAND + /// but not with BIDDING_CATEGORY_L4). + /// + [pbr::OriginalName("INVALID_PRODUCT_DIMENSION_TYPE")] InvalidProductDimensionType = 75, + /// + /// Bidding categories do not form a valid path in the Shopping bidding + /// category taxonomy. + /// + [pbr::OriginalName("INVALID_PRODUCT_BIDDING_CATEGORY")] InvalidProductBiddingCategory = 76, + /// + /// ShoppingSetting must be added to the campaign before ProductScope + /// criteria can be added. + /// + [pbr::OriginalName("MISSING_SHOPPING_SETTING")] MissingShoppingSetting = 77, + /// + /// Matching function is invalid. + /// + [pbr::OriginalName("INVALID_MATCHING_FUNCTION")] InvalidMatchingFunction = 78, + /// + /// Filter parameters not allowed for location groups targeting. + /// + [pbr::OriginalName("LOCATION_FILTER_NOT_ALLOWED")] LocationFilterNotAllowed = 79, + /// + /// Feed not found, or the feed is not an enabled location feed. + /// + [pbr::OriginalName("INVALID_FEED_FOR_LOCATION_FILTER")] InvalidFeedForLocationFilter = 98, + /// + /// Given location filter parameter is invalid for location groups targeting. + /// + [pbr::OriginalName("LOCATION_FILTER_INVALID")] LocationFilterInvalid = 80, + /// + /// Criteria type cannot be associated with a campaign and its ad group(s) + /// simultaneously. + /// + [pbr::OriginalName("CANNOT_ATTACH_CRITERIA_AT_CAMPAIGN_AND_ADGROUP")] CannotAttachCriteriaAtCampaignAndAdgroup = 81, + /// + /// Range represented by hotel length of stay's min nights and max nights + /// overlaps with an existing criterion. + /// + [pbr::OriginalName("HOTEL_LENGTH_OF_STAY_OVERLAPS_WITH_EXISTING_CRITERION")] HotelLengthOfStayOverlapsWithExistingCriterion = 82, + /// + /// Range represented by hotel advance booking window's min days and max days + /// overlaps with an existing criterion. + /// + [pbr::OriginalName("HOTEL_ADVANCE_BOOKING_WINDOW_OVERLAPS_WITH_EXISTING_CRITERION")] HotelAdvanceBookingWindowOverlapsWithExistingCriterion = 83, + /// + /// The field is not allowed to be set when the negative field is set to + /// true, e.g. we don't allow bids in negative ad group or campaign criteria. + /// + [pbr::OriginalName("FIELD_INCOMPATIBLE_WITH_NEGATIVE_TARGETING")] FieldIncompatibleWithNegativeTargeting = 84, + /// + /// The combination of operand and operator in webpage condition is invalid. + /// + [pbr::OriginalName("INVALID_WEBPAGE_CONDITION")] InvalidWebpageCondition = 85, + /// + /// The URL of webpage condition is invalid. + /// + [pbr::OriginalName("INVALID_WEBPAGE_CONDITION_URL")] InvalidWebpageConditionUrl = 86, + /// + /// The URL of webpage condition cannot be empty or contain white space. + /// + [pbr::OriginalName("WEBPAGE_CONDITION_URL_CANNOT_BE_EMPTY")] WebpageConditionUrlCannotBeEmpty = 87, + /// + /// The URL of webpage condition contains an unsupported protocol. + /// + [pbr::OriginalName("WEBPAGE_CONDITION_URL_UNSUPPORTED_PROTOCOL")] WebpageConditionUrlUnsupportedProtocol = 88, + /// + /// The URL of webpage condition cannot be an IP address. + /// + [pbr::OriginalName("WEBPAGE_CONDITION_URL_CANNOT_BE_IP_ADDRESS")] WebpageConditionUrlCannotBeIpAddress = 89, + /// + /// The domain of the URL is not consistent with the domain in campaign + /// setting. + /// + [pbr::OriginalName("WEBPAGE_CONDITION_URL_DOMAIN_NOT_CONSISTENT_WITH_CAMPAIGN_SETTING")] WebpageConditionUrlDomainNotConsistentWithCampaignSetting = 90, + /// + /// The URL of webpage condition cannot be a public suffix itself. + /// + [pbr::OriginalName("WEBPAGE_CONDITION_URL_CANNOT_BE_PUBLIC_SUFFIX")] WebpageConditionUrlCannotBePublicSuffix = 91, + /// + /// The URL of webpage condition has an invalid public suffix. + /// + [pbr::OriginalName("WEBPAGE_CONDITION_URL_INVALID_PUBLIC_SUFFIX")] WebpageConditionUrlInvalidPublicSuffix = 92, + /// + /// Value track parameter is not supported in webpage condition URL. + /// + [pbr::OriginalName("WEBPAGE_CONDITION_URL_VALUE_TRACK_VALUE_NOT_SUPPORTED")] WebpageConditionUrlValueTrackValueNotSupported = 93, + /// + /// Only one URL-EQUALS webpage condition is allowed in a webpage + /// criterion and it cannot be combined with other conditions. + /// + [pbr::OriginalName("WEBPAGE_CRITERION_URL_EQUALS_CAN_HAVE_ONLY_ONE_CONDITION")] WebpageCriterionUrlEqualsCanHaveOnlyOneCondition = 94, + /// + /// A webpage criterion cannot be added to a non-DSA ad group. + /// + [pbr::OriginalName("WEBPAGE_CRITERION_NOT_SUPPORTED_ON_NON_DSA_AD_GROUP")] WebpageCriterionNotSupportedOnNonDsaAdGroup = 95, + /// + /// Cannot add positive user list criteria in Smart Display campaigns. + /// + [pbr::OriginalName("CANNOT_TARGET_USER_LIST_FOR_SMART_DISPLAY_CAMPAIGNS")] CannotTargetUserListForSmartDisplayCampaigns = 99, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CriterionSystemServingStatus.cs b/src/V3/Stubs/CriterionSystemServingStatus.cs new file mode 100644 index 000000000..fb34904be --- /dev/null +++ b/src/V3/Stubs/CriterionSystemServingStatus.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/criterion_system_serving_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/criterion_system_serving_status.proto + public static partial class CriterionSystemServingStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/criterion_system_serving_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CriterionSystemServingStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jcml0ZXJpb25fc3lz", + "dGVtX3NlcnZpbmdfc3RhdHVzLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKBAQog", + "Q3JpdGVyaW9uU3lzdGVtU2VydmluZ1N0YXR1c0VudW0iXQocQ3JpdGVyaW9u", + "U3lzdGVtU2VydmluZ1N0YXR1cxIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05P", + "V04QARIMCghFTElHSUJMRRACEhEKDVJBUkVMWV9TRVJWRUQQA0L2AQohY29t", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQiFDcml0ZXJpb25TeXN0", + "ZW1TZXJ2aW5nU3RhdHVzUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2Vu", + "cHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1z", + "ogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29n", + "bGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CriterionSystemServingStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.CriterionSystemServingStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CriterionSystemServingStatusEnum.Types.CriterionSystemServingStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible criterion system serving statuses. + /// + public sealed partial class CriterionSystemServingStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CriterionSystemServingStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CriterionSystemServingStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionSystemServingStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionSystemServingStatusEnum(CriterionSystemServingStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionSystemServingStatusEnum Clone() { + return new CriterionSystemServingStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CriterionSystemServingStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CriterionSystemServingStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CriterionSystemServingStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CriterionSystemServingStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates criterion system serving statuses. + /// + public enum CriterionSystemServingStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Eligible. + /// + [pbr::OriginalName("ELIGIBLE")] Eligible = 2, + /// + /// Low search volume. + /// + [pbr::OriginalName("RARELY_SERVED")] RarelyServed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CriterionType.cs b/src/V3/Stubs/CriterionType.cs new file mode 100644 index 000000000..abce170f9 --- /dev/null +++ b/src/V3/Stubs/CriterionType.cs @@ -0,0 +1,308 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/criterion_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/criterion_type.proto + public static partial class CriterionTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/criterion_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CriterionTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jcml0ZXJpb25fdHlw", + "ZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2ds", + "ZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i1AQKEUNyaXRlcmlvblR5cGVFbnVt", + "Ir4ECg1Dcml0ZXJpb25UeXBlEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9X", + "ThABEgsKB0tFWVdPUkQQAhINCglQTEFDRU1FTlQQAxIXChNNT0JJTEVfQVBQ", + "X0NBVEVHT1JZEAQSFgoSTU9CSUxFX0FQUExJQ0FUSU9OEAUSCgoGREVWSUNF", + "EAYSDAoITE9DQVRJT04QBxIRCg1MSVNUSU5HX0dST1VQEAgSDwoLQURfU0NI", + "RURVTEUQCRINCglBR0VfUkFOR0UQChIKCgZHRU5ERVIQCxIQCgxJTkNPTUVf", + "UkFOR0UQDBITCg9QQVJFTlRBTF9TVEFUVVMQDRIRCg1ZT1VUVUJFX1ZJREVP", + "EA4SEwoPWU9VVFVCRV9DSEFOTkVMEA8SDQoJVVNFUl9MSVNUEBASDQoJUFJP", + "WElNSVRZEBESCQoFVE9QSUMQEhIRCg1MSVNUSU5HX1NDT1BFEBMSDAoITEFO", + "R1VBR0UQFBIMCghJUF9CTE9DSxAVEhEKDUNPTlRFTlRfTEFCRUwQFhILCgdD", + "QVJSSUVSEBcSEQoNVVNFUl9JTlRFUkVTVBAYEgsKB1dFQlBBR0UQGRIcChhP", + "UEVSQVRJTkdfU1lTVEVNX1ZFUlNJT04QGhIVChFBUFBfUEFZTUVOVF9NT0RF", + "TBAbEhEKDU1PQklMRV9ERVZJQ0UQHBITCg9DVVNUT01fQUZGSU5JVFkQHRIR", + "Cg1DVVNUT01fSU5URU5UEB4SEgoOTE9DQVRJT05fR1JPVVAQH0LnAQohY29t", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhJDcml0ZXJpb25UeXBl", + "UHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBp", + "cy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xl", + "LkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFk", + "c1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVt", + "c2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// The possible types of a criterion. + /// + public sealed partial class CriterionTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CriterionTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionTypeEnum(CriterionTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionTypeEnum Clone() { + return new CriterionTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CriterionTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CriterionTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CriterionTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CriterionTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible criterion types. + /// + public enum CriterionType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Keyword. e.g. 'mars cruise'. + /// + [pbr::OriginalName("KEYWORD")] Keyword = 2, + /// + /// Placement, aka Website. e.g. 'www.flowers4sale.com' + /// + [pbr::OriginalName("PLACEMENT")] Placement = 3, + /// + /// Mobile application categories to target. + /// + [pbr::OriginalName("MOBILE_APP_CATEGORY")] MobileAppCategory = 4, + /// + /// Mobile applications to target. + /// + [pbr::OriginalName("MOBILE_APPLICATION")] MobileApplication = 5, + /// + /// Devices to target. + /// + [pbr::OriginalName("DEVICE")] Device = 6, + /// + /// Locations to target. + /// + [pbr::OriginalName("LOCATION")] Location = 7, + /// + /// Listing groups to target. + /// + [pbr::OriginalName("LISTING_GROUP")] ListingGroup = 8, + /// + /// Ad Schedule. + /// + [pbr::OriginalName("AD_SCHEDULE")] AdSchedule = 9, + /// + /// Age range. + /// + [pbr::OriginalName("AGE_RANGE")] AgeRange = 10, + /// + /// Gender. + /// + [pbr::OriginalName("GENDER")] Gender = 11, + /// + /// Income Range. + /// + [pbr::OriginalName("INCOME_RANGE")] IncomeRange = 12, + /// + /// Parental status. + /// + [pbr::OriginalName("PARENTAL_STATUS")] ParentalStatus = 13, + /// + /// YouTube Video. + /// + [pbr::OriginalName("YOUTUBE_VIDEO")] YoutubeVideo = 14, + /// + /// YouTube Channel. + /// + [pbr::OriginalName("YOUTUBE_CHANNEL")] YoutubeChannel = 15, + /// + /// User list. + /// + [pbr::OriginalName("USER_LIST")] UserList = 16, + /// + /// Proximity. + /// + [pbr::OriginalName("PROXIMITY")] Proximity = 17, + /// + /// A topic target on the display network (e.g. "Pets & Animals"). + /// + [pbr::OriginalName("TOPIC")] Topic = 18, + /// + /// Listing scope to target. + /// + [pbr::OriginalName("LISTING_SCOPE")] ListingScope = 19, + /// + /// Language. + /// + [pbr::OriginalName("LANGUAGE")] Language = 20, + /// + /// IpBlock. + /// + [pbr::OriginalName("IP_BLOCK")] IpBlock = 21, + /// + /// Content Label for category exclusion. + /// + [pbr::OriginalName("CONTENT_LABEL")] ContentLabel = 22, + /// + /// Carrier. + /// + [pbr::OriginalName("CARRIER")] Carrier = 23, + /// + /// A category the user is interested in. + /// + [pbr::OriginalName("USER_INTEREST")] UserInterest = 24, + /// + /// Webpage criterion for dynamic search ads. + /// + [pbr::OriginalName("WEBPAGE")] Webpage = 25, + /// + /// Operating system version. + /// + [pbr::OriginalName("OPERATING_SYSTEM_VERSION")] OperatingSystemVersion = 26, + /// + /// App payment model. + /// + [pbr::OriginalName("APP_PAYMENT_MODEL")] AppPaymentModel = 27, + /// + /// Mobile device. + /// + [pbr::OriginalName("MOBILE_DEVICE")] MobileDevice = 28, + /// + /// Custom affinity. + /// + [pbr::OriginalName("CUSTOM_AFFINITY")] CustomAffinity = 29, + /// + /// Custom intent. + /// + [pbr::OriginalName("CUSTOM_INTENT")] CustomIntent = 30, + /// + /// Location group. + /// + [pbr::OriginalName("LOCATION_GROUP")] LocationGroup = 31, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CurrencyCodeError.cs b/src/V3/Stubs/CurrencyCodeError.cs new file mode 100644 index 000000000..fde99718b --- /dev/null +++ b/src/V3/Stubs/CurrencyCodeError.cs @@ -0,0 +1,181 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/currency_code_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/currency_code_error.proto + public static partial class CurrencyCodeErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/currency_code_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CurrencyCodeErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY3VycmVuY3lfY29k", + "ZV9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIlsKFUN1cnJlbmN5Q29k", + "ZUVycm9yRW51bSJCChFDdXJyZW5jeUNvZGVFcnJvchIPCgtVTlNQRUNJRklF", + "RBAAEgsKB1VOS05PV04QARIPCgtVTlNVUFBPUlRFRBACQvEBCiJjb20uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQhZDdXJyZW5jeUNvZGVFcnJv", + "clByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFw", + "aXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJyb3JzogIDR0FBqgIeR29v", + "Z2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIeR29vZ2xlXEFkc1xHb29n", + "bGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6", + "OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CurrencyCodeErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CurrencyCodeErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CurrencyCodeErrorEnum.Types.CurrencyCodeError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible currency code errors. + /// + public sealed partial class CurrencyCodeErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CurrencyCodeErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CurrencyCodeErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CurrencyCodeErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CurrencyCodeErrorEnum(CurrencyCodeErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CurrencyCodeErrorEnum Clone() { + return new CurrencyCodeErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CurrencyCodeErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CurrencyCodeErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CurrencyCodeErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CurrencyCodeErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible currency code errors. + /// + public enum CurrencyCodeError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The currency code is not supported. + /// + [pbr::OriginalName("UNSUPPORTED")] Unsupported = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CurrencyConstant.cs b/src/V3/Stubs/CurrencyConstant.cs new file mode 100644 index 000000000..a82634325 --- /dev/null +++ b/src/V3/Stubs/CurrencyConstant.cs @@ -0,0 +1,348 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/currency_constant.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/currency_constant.proto + public static partial class CurrencyConstantReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/currency_constant.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CurrencyConstantReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VycmVuY3lf", + "Y29uc3RhbnQucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291", + "cmNlcxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xl", + "L2FwaS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJz", + "LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIogDChBDdXJy", + "ZW5jeUNvbnN0YW50EkgKDXJlc291cmNlX25hbWUYASABKAlCMeBBBfpBKwop", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0N1cnJlbmN5Q29uc3RhbnQSLwoE", + "Y29kZRgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EED", + "Ei8KBG5hbWUYAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVC", + "A+BBAxIxCgZzeW1ib2wYBCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5n", + "VmFsdWVCA+BBAxI+ChRiaWxsYWJsZV91bml0X21pY3JvcxgFIAEoCzIbLmdv", + "b2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQM6VepBUgopZ29vZ2xlYWRz", + "Lmdvb2dsZWFwaXMuY29tL0N1cnJlbmN5Q29uc3RhbnQSJWN1cnJlbmN5Q29u", + "c3RhbnRzL3tjdXJyZW5jeV9jb25zdGFudH1CggIKJWNvbS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXNCFUN1cnJlbmN5Q29uc3RhbnRQcm90", + "b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNc", + "R29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVB", + "ZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant), global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant.Parser, new[]{ "ResourceName", "Code", "Name", "Symbol", "BillableUnitMicros" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A currency constant. + /// + public sealed partial class CurrencyConstant : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CurrencyConstant()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstantReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CurrencyConstant() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CurrencyConstant(CurrencyConstant other) : this() { + resourceName_ = other.resourceName_; + Code = other.Code; + Name = other.Name; + Symbol = other.Symbol; + BillableUnitMicros = other.BillableUnitMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CurrencyConstant Clone() { + return new CurrencyConstant(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the currency constant. + /// Currency constant resource names have the form: + /// + /// `currencyConstants/{currency_code}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "code" field. + public const int CodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_code_codec = pb::FieldCodec.ForClassWrapper(18); + private string code_; + /// + /// Output only. ISO 4217 three-letter currency code, e.g. "USD" + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Code { + get { return code_; } + set { + code_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 3; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(26); + private string name_; + /// + /// Output only. Full English name of the currency. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "symbol" field. + public const int SymbolFieldNumber = 4; + private static readonly pb::FieldCodec _single_symbol_codec = pb::FieldCodec.ForClassWrapper(34); + private string symbol_; + /// + /// Output only. Standard symbol for describing this currency, e.g. '$' for US Dollars. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Symbol { + get { return symbol_; } + set { + symbol_ = value; + } + } + + + /// Field number for the "billable_unit_micros" field. + public const int BillableUnitMicrosFieldNumber = 5; + private static readonly pb::FieldCodec _single_billableUnitMicros_codec = pb::FieldCodec.ForStructWrapper(42); + private long? billableUnitMicros_; + /// + /// Output only. The billable unit for this currency. Billed amounts should be multiples of + /// this value. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? BillableUnitMicros { + get { return billableUnitMicros_; } + set { + billableUnitMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CurrencyConstant); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CurrencyConstant other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Code != other.Code) return false; + if (Name != other.Name) return false; + if (Symbol != other.Symbol) return false; + if (BillableUnitMicros != other.BillableUnitMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (code_ != null) hash ^= Code.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (symbol_ != null) hash ^= Symbol.GetHashCode(); + if (billableUnitMicros_ != null) hash ^= BillableUnitMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (code_ != null) { + _single_code_codec.WriteTagAndValue(output, Code); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (symbol_ != null) { + _single_symbol_codec.WriteTagAndValue(output, Symbol); + } + if (billableUnitMicros_ != null) { + _single_billableUnitMicros_codec.WriteTagAndValue(output, BillableUnitMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (code_ != null) { + size += _single_code_codec.CalculateSizeWithTag(Code); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (symbol_ != null) { + size += _single_symbol_codec.CalculateSizeWithTag(Symbol); + } + if (billableUnitMicros_ != null) { + size += _single_billableUnitMicros_codec.CalculateSizeWithTag(BillableUnitMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CurrencyConstant other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.code_ != null) { + if (code_ == null || other.Code != "") { + Code = other.Code; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.symbol_ != null) { + if (symbol_ == null || other.Symbol != "") { + Symbol = other.Symbol; + } + } + if (other.billableUnitMicros_ != null) { + if (billableUnitMicros_ == null || other.BillableUnitMicros != 0L) { + BillableUnitMicros = other.BillableUnitMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_code_codec.Read(input); + if (code_ == null || value != "") { + Code = value; + } + break; + } + case 26: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 34: { + string value = _single_symbol_codec.Read(input); + if (symbol_ == null || value != "") { + Symbol = value; + } + break; + } + case 42: { + long? value = _single_billableUnitMicros_codec.Read(input); + if (billableUnitMicros_ == null || value != 0L) { + BillableUnitMicros = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CurrencyConstantService.cs b/src/V3/Stubs/CurrencyConstantService.cs new file mode 100644 index 000000000..308a193c8 --- /dev/null +++ b/src/V3/Stubs/CurrencyConstantService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/currency_constant_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/currency_constant_service.proto + public static partial class CurrencyConstantServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/currency_constant_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CurrencyConstantServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXJyZW5jeV9j", + "b25zdGFudF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2Vz", + "L2N1cnJlbmN5X2NvbnN0YW50LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2Fw", + "aS9maWVsZF9iZWhhdmlvci5wcm90byI4ChpHZXRDdXJyZW5jeUNvbnN0YW50", + "UmVxdWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIyggIKF0N1cnJl", + "bmN5Q29uc3RhbnRTZXJ2aWNlEskBChNHZXRDdXJyZW5jeUNvbnN0YW50Ejwu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR2V0Q3VycmVuY3lD", + "b25zdGFudFJlcXVlc3QaMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNv", + "dXJjZXMuQ3VycmVuY3lDb25zdGFudCI/gtPkkwIpEicvdjMve3Jlc291cmNl", + "X25hbWU9Y3VycmVuY3lDb25zdGFudHMvKn3aQQ1yZXNvdXJjZV9uYW1lGhvK", + "QRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21CgwIKJGNvbS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlc0IcQ3VycmVuY3lDb25zdGFudFNlcnZp", + "Y2VQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGq", + "AiBHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxB", + "ZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2ds", + "ZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstantReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCurrencyConstantRequest), global::Google.Ads.GoogleAds.V3.Services.GetCurrencyConstantRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CurrencyConstantService.GetCurrencyConstant][google.ads.googleads.v3.services.CurrencyConstantService.GetCurrencyConstant]. + /// + public sealed partial class GetCurrencyConstantRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCurrencyConstantRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CurrencyConstantServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCurrencyConstantRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCurrencyConstantRequest(GetCurrencyConstantRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCurrencyConstantRequest Clone() { + return new GetCurrencyConstantRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. Resource name of the currency constant to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCurrencyConstantRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCurrencyConstantRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCurrencyConstantRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CurrencyConstantServiceClient.cs b/src/V3/Stubs/CurrencyConstantServiceClient.cs new file mode 100644 index 000000000..821f76fb3 --- /dev/null +++ b/src/V3/Stubs/CurrencyConstantServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CurrencyConstantServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CurrencyConstantServiceSettings GetDefault() => new CurrencyConstantServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CurrencyConstantServiceSettings() { } + + private CurrencyConstantServiceSettings(CurrencyConstantServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCurrencyConstantSettings = existing.GetCurrencyConstantSettings; + OnCopy(existing); + } + + partial void OnCopy(CurrencyConstantServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CurrencyConstantServiceClient.GetCurrencyConstant and CurrencyConstantServiceClient.GetCurrencyConstantAsync. + /// + /// + /// The default CurrencyConstantServiceClient.GetCurrencyConstant and + /// CurrencyConstantServiceClient.GetCurrencyConstantAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCurrencyConstantSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CurrencyConstantServiceSettings Clone() => new CurrencyConstantServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CurrencyConstantServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CurrencyConstantServiceSettings Settings { get; set; } + + /// + public override CurrencyConstantServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CurrencyConstantServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CurrencyConstantServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CurrencyConstantServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CurrencyConstantServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CurrencyConstantServiceClient.ChannelPool; + } + + /// + /// CurrencyConstantService client wrapper, for convenient use. + /// + public abstract partial class CurrencyConstantServiceClient + { + /// + /// The default endpoint for the CurrencyConstantService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CurrencyConstantService scopes. + /// + /// + /// The default CurrencyConstantService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CurrencyConstantServiceClient client = await CurrencyConstantServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CurrencyConstantServiceClient.DefaultEndpoint.Host, CurrencyConstantServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CurrencyConstantServiceClient client = CurrencyConstantServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CurrencyConstantServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CurrencyConstantServiceClient client = CurrencyConstantServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CurrencyConstantServiceClient.DefaultEndpoint.Host, CurrencyConstantServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CurrencyConstantServiceClient client = CurrencyConstantServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CurrencyConstantServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CurrencyConstantServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CurrencyConstantServiceClient Create(grpccore::Channel channel, CurrencyConstantServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CurrencyConstantServiceClient Create(grpccore::CallInvoker callInvoker, CurrencyConstantServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CurrencyConstantService.CurrencyConstantServiceClient grpcClient = new CurrencyConstantService.CurrencyConstantServiceClient(callInvoker); + return new CurrencyConstantServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CurrencyConstantService client. + /// + public virtual CurrencyConstantService.CurrencyConstantServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested currency constant. + /// + /// + /// Required. Resource name of the currency constant to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCurrencyConstantAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCurrencyConstantAsync( + new GetCurrencyConstantRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested currency constant. + /// + /// + /// Required. Resource name of the currency constant to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCurrencyConstantAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCurrencyConstantAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested currency constant. + /// + /// + /// Required. Resource name of the currency constant to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CurrencyConstant GetCurrencyConstant( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCurrencyConstant( + new GetCurrencyConstantRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested currency constant. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCurrencyConstantAsync( + GetCurrencyConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested currency constant. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCurrencyConstantAsync( + GetCurrencyConstantRequest request, + st::CancellationToken cancellationToken) => GetCurrencyConstantAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested currency constant. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CurrencyConstant GetCurrencyConstant( + GetCurrencyConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CurrencyConstantService client wrapper implementation, for convenient use. + /// + public sealed partial class CurrencyConstantServiceClientImpl : CurrencyConstantServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCurrencyConstant; + + /// + /// Constructs a client wrapper for the CurrencyConstantService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CurrencyConstantServiceClientImpl(CurrencyConstantService.CurrencyConstantServiceClient grpcClient, CurrencyConstantServiceSettings settings) + { + GrpcClient = grpcClient; + CurrencyConstantServiceSettings effectiveSettings = settings ?? CurrencyConstantServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCurrencyConstant = clientHelper.BuildApiCall( + GrpcClient.GetCurrencyConstantAsync, GrpcClient.GetCurrencyConstant, effectiveSettings.GetCurrencyConstantSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetCurrencyConstant); + Modify_GetCurrencyConstantApiCall(ref _callGetCurrencyConstant); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCurrencyConstantApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CurrencyConstantService.CurrencyConstantServiceClient grpcClient, CurrencyConstantServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CurrencyConstantService client. + /// + public override CurrencyConstantService.CurrencyConstantServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCurrencyConstantRequest(ref GetCurrencyConstantRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested currency constant. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCurrencyConstantAsync( + GetCurrencyConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCurrencyConstantRequest(ref request, ref callSettings); + return _callGetCurrencyConstant.Async(request, callSettings); + } + + /// + /// Returns the requested currency constant. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CurrencyConstant GetCurrencyConstant( + GetCurrencyConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCurrencyConstantRequest(ref request, ref callSettings); + return _callGetCurrencyConstant.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CurrencyConstantServiceGrpc.cs b/src/V3/Stubs/CurrencyConstantServiceGrpc.cs new file mode 100644 index 000000000..54c1f460c --- /dev/null +++ b/src/V3/Stubs/CurrencyConstantServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/currency_constant_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch currency constants. + /// + public static partial class CurrencyConstantService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CurrencyConstantService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCurrencyConstantRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCurrencyConstantRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CurrencyConstant = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCurrencyConstant = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCurrencyConstant", + __Marshaller_google_ads_googleads_v3_services_GetCurrencyConstantRequest, + __Marshaller_google_ads_googleads_v3_resources_CurrencyConstant); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CurrencyConstantServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CurrencyConstantService + public abstract partial class CurrencyConstantServiceBase + { + /// + /// Returns the requested currency constant. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCurrencyConstant(global::Google.Ads.GoogleAds.V3.Services.GetCurrencyConstantRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CurrencyConstantService + public partial class CurrencyConstantServiceClient : grpc::ClientBase + { + /// Creates a new client for CurrencyConstantService + /// The channel to use to make remote calls. + public CurrencyConstantServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CurrencyConstantService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CurrencyConstantServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CurrencyConstantServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CurrencyConstantServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested currency constant. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant GetCurrencyConstant(global::Google.Ads.GoogleAds.V3.Services.GetCurrencyConstantRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCurrencyConstant(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested currency constant. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant GetCurrencyConstant(global::Google.Ads.GoogleAds.V3.Services.GetCurrencyConstantRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCurrencyConstant, null, options, request); + } + /// + /// Returns the requested currency constant. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCurrencyConstantAsync(global::Google.Ads.GoogleAds.V3.Services.GetCurrencyConstantRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCurrencyConstantAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested currency constant. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCurrencyConstantAsync(global::Google.Ads.GoogleAds.V3.Services.GetCurrencyConstantRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCurrencyConstant, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CurrencyConstantServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CurrencyConstantServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CurrencyConstantServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCurrencyConstant, serviceImpl.GetCurrencyConstant).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CurrencyConstantServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCurrencyConstant, serviceImpl.GetCurrencyConstant); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomInterest.cs b/src/V3/Stubs/CustomInterest.cs new file mode 100644 index 000000000..49a3d5528 --- /dev/null +++ b/src/V3/Stubs/CustomInterest.cs @@ -0,0 +1,588 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/custom_interest.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/custom_interest.proto + public static partial class CustomInterestReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/custom_interest.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomInterestReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tX2lu", + "dGVyZXN0LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMaP2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2N1c3RvbV9pbnRl", + "cmVzdF9tZW1iZXJfdHlwZS5wcm90bxo6Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZW51bXMvY3VzdG9tX2ludGVyZXN0X3N0YXR1cy5wcm90bxo4Z29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvY3VzdG9tX2ludGVyZXN0X3R5cGUu", + "cHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2ds", + "ZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVy", + "cy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLLBAoOQ3Vz", + "dG9tSW50ZXJlc3QSRgoNcmVzb3VyY2VfbmFtZRgBIAEoCUIv4EEF+kEpCidn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ3VzdG9tSW50ZXJlc3QSLAoCaWQY", + "AiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDElwKBnN0", + "YXR1cxgDIAEoDjJMLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkN1", + "c3RvbUludGVyZXN0U3RhdHVzRW51bS5DdXN0b21JbnRlcmVzdFN0YXR1cxIq", + "CgRuYW1lGAQgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlElYK", + "BHR5cGUYBSABKA4ySC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5D", + "dXN0b21JbnRlcmVzdFR5cGVFbnVtLkN1c3RvbUludGVyZXN0VHlwZRIxCgtk", + "ZXNjcmlwdGlvbhgGIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZRJICgdtZW1iZXJzGAcgAygLMjcuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzLkN1c3RvbUludGVyZXN0TWVtYmVyOmTqQWEKJ2dvb2dsZWFk", + "cy5nb29nbGVhcGlzLmNvbS9DdXN0b21JbnRlcmVzdBI2Y3VzdG9tZXJzL3tj", + "dXN0b21lcn0vY3VzdG9tSW50ZXJlc3RzL3tjdXN0b21faW50ZXJlc3R9IrIB", + "ChRDdXN0b21JbnRlcmVzdE1lbWJlchJpCgttZW1iZXJfdHlwZRgBIAEoDjJU", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkN1c3RvbUludGVyZXN0", + "TWVtYmVyVHlwZUVudW0uQ3VzdG9tSW50ZXJlc3RNZW1iZXJUeXBlEi8KCXBh", + "cmFtZXRlchgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUKA", + "AgolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0ITQ3Vz", + "dG9tSW50ZXJlc3RQcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90", + "by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291", + "cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNl", + "c8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2ds", + "ZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.CustomInterestMemberTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CustomInterestStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CustomInterestTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomInterest), global::Google.Ads.GoogleAds.V3.Resources.CustomInterest.Parser, new[]{ "ResourceName", "Id", "Status", "Name", "Type", "Description", "Members" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomInterestMember), global::Google.Ads.GoogleAds.V3.Resources.CustomInterestMember.Parser, new[]{ "MemberType", "Parameter" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A custom interest. This is a list of users by interest. + /// + public sealed partial class CustomInterest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomInterest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomInterestReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterest(CustomInterest other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + status_ = other.status_; + Name = other.Name; + type_ = other.type_; + Description = other.Description; + members_ = other.members_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterest Clone() { + return new CustomInterest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the custom interest. + /// Custom interest resource names have the form: + /// + /// `customers/{customer_id}/customInterests/{custom_interest_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. Id of the custom interest. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.CustomInterestStatusEnum.Types.CustomInterestStatus status_ = 0; + /// + /// Status of this custom interest. Indicates whether the custom interest is + /// enabled or removed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CustomInterestStatusEnum.Types.CustomInterestStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// Name of the custom interest. It should be unique across the same custom + /// affinity audience. + /// This field is required for create operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.CustomInterestTypeEnum.Types.CustomInterestType type_ = 0; + /// + /// Type of the custom interest, CUSTOM_AFFINITY or CUSTOM_INTENT. + /// By default the type is set to CUSTOM_AFFINITY. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CustomInterestTypeEnum.Types.CustomInterestType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 6; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(50); + private string description_; + /// + /// Description of this custom interest audience. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "members" field. + public const int MembersFieldNumber = 7; + private static readonly pb::FieldCodec _repeated_members_codec + = pb::FieldCodec.ForMessage(58, global::Google.Ads.GoogleAds.V3.Resources.CustomInterestMember.Parser); + private readonly pbc::RepeatedField members_ = new pbc::RepeatedField(); + /// + /// List of custom interest members that this custom interest is composed of. + /// Members can be added during CustomInterest creation. If members are + /// presented in UPDATE operation, existing members will be overridden. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Members { + get { return members_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomInterest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomInterest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Status != other.Status) return false; + if (Name != other.Name) return false; + if (Type != other.Type) return false; + if (Description != other.Description) return false; + if(!members_.Equals(other.members_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + hash ^= members_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (Status != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Status); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (Type != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Type); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + members_.WriteTo(output, _repeated_members_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + size += members_.CalculateSize(_repeated_members_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomInterest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + members_.Add(other.members_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 24: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.CustomInterestStatusEnum.Types.CustomInterestStatus) input.ReadEnum(); + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 40: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.CustomInterestTypeEnum.Types.CustomInterestType) input.ReadEnum(); + break; + } + case 50: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 58: { + members_.AddEntriesFrom(input, _repeated_members_codec); + break; + } + } + } + } + + } + + /// + /// A member of custom interest audience. A member can be a keyword or url. + /// It is immutable, that is, it can only be created or removed but not changed. + /// + public sealed partial class CustomInterestMember : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomInterestMember()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomInterestReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestMember() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestMember(CustomInterestMember other) : this() { + memberType_ = other.memberType_; + Parameter = other.Parameter; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestMember Clone() { + return new CustomInterestMember(this); + } + + /// Field number for the "member_type" field. + public const int MemberTypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.CustomInterestMemberTypeEnum.Types.CustomInterestMemberType memberType_ = 0; + /// + /// The type of custom interest member, KEYWORD or URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CustomInterestMemberTypeEnum.Types.CustomInterestMemberType MemberType { + get { return memberType_; } + set { + memberType_ = value; + } + } + + /// Field number for the "parameter" field. + public const int ParameterFieldNumber = 2; + private static readonly pb::FieldCodec _single_parameter_codec = pb::FieldCodec.ForClassWrapper(18); + private string parameter_; + /// + /// Keyword text when member_type is KEYWORD or URL string when + /// member_type is URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Parameter { + get { return parameter_; } + set { + parameter_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomInterestMember); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomInterestMember other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (MemberType != other.MemberType) return false; + if (Parameter != other.Parameter) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (MemberType != 0) hash ^= MemberType.GetHashCode(); + if (parameter_ != null) hash ^= Parameter.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (MemberType != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) MemberType); + } + if (parameter_ != null) { + _single_parameter_codec.WriteTagAndValue(output, Parameter); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (MemberType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MemberType); + } + if (parameter_ != null) { + size += _single_parameter_codec.CalculateSizeWithTag(Parameter); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomInterestMember other) { + if (other == null) { + return; + } + if (other.MemberType != 0) { + MemberType = other.MemberType; + } + if (other.parameter_ != null) { + if (parameter_ == null || other.Parameter != "") { + Parameter = other.Parameter; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + MemberType = (global::Google.Ads.GoogleAds.V3.Enums.CustomInterestMemberTypeEnum.Types.CustomInterestMemberType) input.ReadEnum(); + break; + } + case 18: { + string value = _single_parameter_codec.Read(input); + if (parameter_ == null || value != "") { + Parameter = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomInterestError.cs b/src/V3/Stubs/CustomInterestError.cs new file mode 100644 index 000000000..84e472f98 --- /dev/null +++ b/src/V3/Stubs/CustomInterestError.cs @@ -0,0 +1,212 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/custom_interest_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/custom_interest_error.proto + public static partial class CustomInterestErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/custom_interest_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomInterestErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY3VzdG9tX2ludGVy", + "ZXN0X2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJv", + "cnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i2QIKF0N1c3RvbUlu", + "dGVyZXN0RXJyb3JFbnVtIr0CChNDdXN0b21JbnRlcmVzdEVycm9yEg8KC1VO", + "U1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhUKEU5BTUVfQUxSRUFEWV9VU0VE", + "EAISRgpCQ1VTVE9NX0lOVEVSRVNUX01FTUJFUl9JRF9BTkRfVFlQRV9QQVJB", + "TUVURVJfTk9UX1BSRVNFTlRfSU5fUkVNT1ZFEAMSIAocVFlQRV9BTkRfUEFS", + "QU1FVEVSX05PVF9GT1VORBAEEiYKIlRZUEVfQU5EX1BBUkFNRVRFUl9BTFJF", + "QURZX0VYSVNURUQQBRInCiNJTlZBTElEX0NVU1RPTV9JTlRFUkVTVF9NRU1C", + "RVJfVFlQRRAGEh4KGkNBTk5PVF9SRU1PVkVfV0hJTEVfSU5fVVNFEAcSFgoS", + "Q0FOTk9UX0NIQU5HRV9UWVBFEAhC8wEKImNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnNCGEN1c3RvbUludGVyZXN0RXJyb3JQcm90b1ABWkRn", + "b29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29n", + "bGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVy", + "cm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomInterestErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CustomInterestErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomInterestErrorEnum.Types.CustomInterestError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible custom interest errors. + /// + public sealed partial class CustomInterestErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomInterestErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CustomInterestErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestErrorEnum(CustomInterestErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestErrorEnum Clone() { + return new CustomInterestErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomInterestErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomInterestErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomInterestErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomInterestErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible custom interest errors. + /// + public enum CustomInterestError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Duplicate custom interest name ignoring case. + /// + [pbr::OriginalName("NAME_ALREADY_USED")] NameAlreadyUsed = 2, + /// + /// In the remove custom interest member operation, both member ID and + /// pair [type, parameter] are not present. + /// + [pbr::OriginalName("CUSTOM_INTEREST_MEMBER_ID_AND_TYPE_PARAMETER_NOT_PRESENT_IN_REMOVE")] CustomInterestMemberIdAndTypeParameterNotPresentInRemove = 3, + /// + /// The pair of [type, parameter] does not exist. + /// + [pbr::OriginalName("TYPE_AND_PARAMETER_NOT_FOUND")] TypeAndParameterNotFound = 4, + /// + /// The pair of [type, parameter] already exists. + /// + [pbr::OriginalName("TYPE_AND_PARAMETER_ALREADY_EXISTED")] TypeAndParameterAlreadyExisted = 5, + /// + /// Unsupported custom interest member type. + /// + [pbr::OriginalName("INVALID_CUSTOM_INTEREST_MEMBER_TYPE")] InvalidCustomInterestMemberType = 6, + /// + /// Cannot remove a custom interest while it's still being targeted. + /// + [pbr::OriginalName("CANNOT_REMOVE_WHILE_IN_USE")] CannotRemoveWhileInUse = 7, + /// + /// Cannot mutate custom interest type. + /// + [pbr::OriginalName("CANNOT_CHANGE_TYPE")] CannotChangeType = 8, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomInterestMemberType.cs b/src/V3/Stubs/CustomInterestMemberType.cs new file mode 100644 index 000000000..9bd0f96a1 --- /dev/null +++ b/src/V3/Stubs/CustomInterestMemberType.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/custom_interest_member_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/custom_interest_member_type.proto + public static partial class CustomInterestMemberTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/custom_interest_member_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomInterestMemberTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jdXN0b21faW50ZXJl", + "c3RfbWVtYmVyX3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIm4KHEN1c3Rv", + "bUludGVyZXN0TWVtYmVyVHlwZUVudW0iTgoYQ3VzdG9tSW50ZXJlc3RNZW1i", + "ZXJUeXBlEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB0tFWVdP", + "UkQQAhIHCgNVUkwQA0LyAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zQh1DdXN0b21JbnRlcmVzdE1lbWJlclR5cGVQcm90b1ABWkJnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIh", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomInterestMemberTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.CustomInterestMemberTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomInterestMemberTypeEnum.Types.CustomInterestMemberType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// The types of custom interest member, either KEYWORD or URL. + /// + public sealed partial class CustomInterestMemberTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomInterestMemberTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CustomInterestMemberTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestMemberTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestMemberTypeEnum(CustomInterestMemberTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestMemberTypeEnum Clone() { + return new CustomInterestMemberTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomInterestMemberTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomInterestMemberTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomInterestMemberTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomInterestMemberTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum containing possible custom interest member types. + /// + public enum CustomInterestMemberType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Custom interest member type KEYWORD. + /// + [pbr::OriginalName("KEYWORD")] Keyword = 2, + /// + /// Custom interest member type URL. + /// + [pbr::OriginalName("URL")] Url = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomInterestService.cs b/src/V3/Stubs/CustomInterestService.cs new file mode 100644 index 000000000..ada08a57f --- /dev/null +++ b/src/V3/Stubs/CustomInterestService.cs @@ -0,0 +1,922 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/custom_interest_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/custom_interest_service.proto + public static partial class CustomInterestServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/custom_interest_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomInterestServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21faW50", + "ZXJlc3Rfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXMaN2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9j", + "dXN0b21faW50ZXJlc3QucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMu", + "cHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2Zp", + "ZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9idWYvZmllbGRfbWFz", + "ay5wcm90byI2ChhHZXRDdXN0b21JbnRlcmVzdFJlcXVlc3QSGgoNcmVzb3Vy", + "Y2VfbmFtZRgBIAEoCUID4EECIqMBChxNdXRhdGVDdXN0b21JbnRlcmVzdHNS", + "ZXF1ZXN0EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPgQQISUgoKb3BlcmF0aW9u", + "cxgCIAMoCzI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkN1", + "c3RvbUludGVyZXN0T3BlcmF0aW9uQgPgQQISFQoNdmFsaWRhdGVfb25seRgE", + "IAEoCCLhAQoXQ3VzdG9tSW50ZXJlc3RPcGVyYXRpb24SLwoLdXBkYXRlX21h", + "c2sYBCABKAsyGi5nb29nbGUucHJvdG9idWYuRmllbGRNYXNrEkMKBmNyZWF0", + "ZRgBIAEoCzIxLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5D", + "dXN0b21JbnRlcmVzdEgAEkMKBnVwZGF0ZRgCIAEoCzIxLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnJlc291cmNlcy5DdXN0b21JbnRlcmVzdEgAQgsKCW9w", + "ZXJhdGlvbiJuCh1NdXRhdGVDdXN0b21JbnRlcmVzdHNSZXNwb25zZRJNCgdy", + "ZXN1bHRzGAIgAygLMjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuTXV0YXRlQ3VzdG9tSW50ZXJlc3RSZXN1bHQiMwoaTXV0YXRlQ3VzdG9t", + "SW50ZXJlc3RSZXN1bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTL5AwoVQ3Vz", + "dG9tSW50ZXJlc3RTZXJ2aWNlEs0BChFHZXRDdXN0b21JbnRlcmVzdBI6Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEN1c3RvbUludGVy", + "ZXN0UmVxdWVzdBoxLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cy5DdXN0b21JbnRlcmVzdCJJgtPkkwIzEjEvdjMve3Jlc291cmNlX25hbWU9", + "Y3VzdG9tZXJzLyovY3VzdG9tSW50ZXJlc3RzLyp92kENcmVzb3VyY2VfbmFt", + "ZRLyAQoVTXV0YXRlQ3VzdG9tSW50ZXJlc3RzEj4uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ3VzdG9tSW50ZXJlc3RzUmVxdWVz", + "dBo/Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUN1", + "c3RvbUludGVyZXN0c1Jlc3BvbnNlIliC0+STAjkiNC92My9jdXN0b21lcnMv", + "e2N1c3RvbWVyX2lkPSp9L2N1c3RvbUludGVyZXN0czptdXRhdGU6ASraQRZj", + "dXN0b21lcl9pZCxvcGVyYXRpb25zGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBp", + "cy5jb21CgQIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "c0IaQ3VzdG9tSW50ZXJlc3RTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFu", + "Zy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Nl", + "cnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMu", + "VjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNl", + "c+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJv", + "dG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CustomInterestReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomInterestRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomInterestRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsRequest.Parser, new[]{ "CustomerId", "Operations", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CustomInterestOperation), global::Google.Ads.GoogleAds.V3.Services.CustomInterestOperation.Parser, new[]{ "UpdateMask", "Create", "Update" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsResponse.Parser, new[]{ "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestResult), global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CustomInterestService.GetCustomInterest][google.ads.googleads.v3.services.CustomInterestService.GetCustomInterest]. + /// + public sealed partial class GetCustomInterestRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomInterestRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomInterestServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomInterestRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomInterestRequest(GetCustomInterestRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomInterestRequest Clone() { + return new GetCustomInterestRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the custom interest to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomInterestRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomInterestRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomInterestRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomInterestService.MutateCustomInterests][google.ads.googleads.v3.services.CustomInterestService.MutateCustomInterests]. + /// + public sealed partial class MutateCustomInterestsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomInterestsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomInterestServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestsRequest(MutateCustomInterestsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestsRequest Clone() { + return new MutateCustomInterestsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose custom interests are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CustomInterestOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual custom interests. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomInterestsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomInterestsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomInterestsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update) on a custom interest. + /// + public sealed partial class CustomInterestOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomInterestOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomInterestServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestOperation(CustomInterestOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestOperation Clone() { + return new CustomInterestOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new custom + /// interest. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomInterest Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CustomInterest) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The custom interest is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomInterest Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CustomInterest) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomInterestOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomInterestOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomInterestOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CustomInterest(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CustomInterest(); + } + Update.MergeFrom(other.Update); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CustomInterest subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomInterest(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CustomInterest subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomInterest(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for custom interest mutate. + /// + public sealed partial class MutateCustomInterestsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomInterestsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomInterestServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestsResponse(MutateCustomInterestsResponse other) : this() { + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestsResponse Clone() { + return new MutateCustomInterestsResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomInterestsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomInterestsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomInterestsResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// The result for the custom interest mutate. + /// + public sealed partial class MutateCustomInterestResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomInterestResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomInterestServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestResult(MutateCustomInterestResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomInterestResult Clone() { + return new MutateCustomInterestResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomInterestResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomInterestResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomInterestResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomInterestServiceClient.cs b/src/V3/Stubs/CustomInterestServiceClient.cs new file mode 100644 index 000000000..bc81e3a4b --- /dev/null +++ b/src/V3/Stubs/CustomInterestServiceClient.cs @@ -0,0 +1,863 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomInterestServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomInterestServiceSettings GetDefault() => new CustomInterestServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomInterestServiceSettings() { } + + private CustomInterestServiceSettings(CustomInterestServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomInterestSettings = existing.GetCustomInterestSettings; + MutateCustomInterestsSettings = existing.MutateCustomInterestsSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomInterestServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomInterestServiceClient.GetCustomInterest and CustomInterestServiceClient.GetCustomInterestAsync. + /// + /// + /// The default CustomInterestServiceClient.GetCustomInterest and + /// CustomInterestServiceClient.GetCustomInterestAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomInterestSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomInterestServiceClient.MutateCustomInterests and CustomInterestServiceClient.MutateCustomInterestsAsync. + /// + /// + /// The default CustomInterestServiceClient.MutateCustomInterests and + /// CustomInterestServiceClient.MutateCustomInterestsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCustomInterestsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomInterestServiceSettings Clone() => new CustomInterestServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomInterestServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomInterestServiceSettings Settings { get; set; } + + /// + public override CustomInterestServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomInterestServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomInterestServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomInterestServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomInterestServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomInterestServiceClient.ChannelPool; + } + + /// + /// CustomInterestService client wrapper, for convenient use. + /// + public abstract partial class CustomInterestServiceClient + { + /// + /// The default endpoint for the CustomInterestService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomInterestService scopes. + /// + /// + /// The default CustomInterestService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomInterestServiceClient client = await CustomInterestServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomInterestServiceClient.DefaultEndpoint.Host, CustomInterestServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomInterestServiceClient client = CustomInterestServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomInterestServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomInterestServiceClient client = CustomInterestServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomInterestServiceClient.DefaultEndpoint.Host, CustomInterestServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomInterestServiceClient client = CustomInterestServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomInterestServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomInterestServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomInterestServiceClient Create(grpccore::Channel channel, CustomInterestServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomInterestServiceClient Create(grpccore::CallInvoker callInvoker, CustomInterestServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomInterestService.CustomInterestServiceClient grpcClient = new CustomInterestService.CustomInterestServiceClient(callInvoker); + return new CustomInterestServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomInterestService client. + /// + public virtual CustomInterestService.CustomInterestServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested custom interest in full detail. + /// + /// + /// Required. The resource name of the custom interest to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomInterestAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomInterestAsync( + new GetCustomInterestRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested custom interest in full detail. + /// + /// + /// Required. The resource name of the custom interest to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomInterestAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomInterestAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested custom interest in full detail. + /// + /// + /// Required. The resource name of the custom interest to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomInterest GetCustomInterest( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomInterest( + new GetCustomInterestRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested custom interest in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomInterestAsync( + GetCustomInterestRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested custom interest in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomInterestAsync( + GetCustomInterestRequest request, + st::CancellationToken cancellationToken) => GetCustomInterestAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested custom interest in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomInterest GetCustomInterest( + GetCustomInterestRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose custom interests are being modified. + /// + /// + /// Required. The list of operations to perform on individual custom interests. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomInterestsAsync( + string customerId, + scg::IEnumerable operations, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomInterestsAsync( + new MutateCustomInterestsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose custom interests are being modified. + /// + /// + /// Required. The list of operations to perform on individual custom interests. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomInterestsAsync( + string customerId, + scg::IEnumerable operations, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCustomInterestsAsync( + customerId, + operations, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose custom interests are being modified. + /// + /// + /// Required. The list of operations to perform on individual custom interests. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomInterestsResponse MutateCustomInterests( + string customerId, + scg::IEnumerable operations, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomInterests( + new MutateCustomInterestsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose custom interests are being modified. + /// + /// + /// Required. The list of operations to perform on individual custom interests. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomInterestsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomInterestsAsync( + new MutateCustomInterestsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose custom interests are being modified. + /// + /// + /// Required. The list of operations to perform on individual custom interests. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomInterestsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCustomInterestsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose custom interests are being modified. + /// + /// + /// Required. The list of operations to perform on individual custom interests. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomInterestsResponse MutateCustomInterests( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomInterests( + new MutateCustomInterestsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomInterestsAsync( + MutateCustomInterestsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomInterestsAsync( + MutateCustomInterestsRequest request, + st::CancellationToken cancellationToken) => MutateCustomInterestsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomInterestsResponse MutateCustomInterests( + MutateCustomInterestsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomInterestService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomInterestServiceClientImpl : CustomInterestServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomInterest; + private readonly gaxgrpc::ApiCall _callMutateCustomInterests; + + /// + /// Constructs a client wrapper for the CustomInterestService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomInterestServiceClientImpl(CustomInterestService.CustomInterestServiceClient grpcClient, CustomInterestServiceSettings settings) + { + GrpcClient = grpcClient; + CustomInterestServiceSettings effectiveSettings = settings ?? CustomInterestServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomInterest = clientHelper.BuildApiCall( + GrpcClient.GetCustomInterestAsync, GrpcClient.GetCustomInterest, effectiveSettings.GetCustomInterestSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCustomInterests = clientHelper.BuildApiCall( + GrpcClient.MutateCustomInterestsAsync, GrpcClient.MutateCustomInterests, effectiveSettings.MutateCustomInterestsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCustomInterest); + Modify_GetCustomInterestApiCall(ref _callGetCustomInterest); + Modify_ApiCall(ref _callMutateCustomInterests); + Modify_MutateCustomInterestsApiCall(ref _callMutateCustomInterests); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomInterestApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCustomInterestsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomInterestService.CustomInterestServiceClient grpcClient, CustomInterestServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomInterestService client. + /// + public override CustomInterestService.CustomInterestServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomInterestRequest(ref GetCustomInterestRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCustomInterestsRequest(ref MutateCustomInterestsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested custom interest in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomInterestAsync( + GetCustomInterestRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomInterestRequest(ref request, ref callSettings); + return _callGetCustomInterest.Async(request, callSettings); + } + + /// + /// Returns the requested custom interest in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CustomInterest GetCustomInterest( + GetCustomInterestRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomInterestRequest(ref request, ref callSettings); + return _callGetCustomInterest.Sync(request, callSettings); + } + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCustomInterestsAsync( + MutateCustomInterestsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomInterestsRequest(ref request, ref callSettings); + return _callMutateCustomInterests.Async(request, callSettings); + } + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCustomInterestsResponse MutateCustomInterests( + MutateCustomInterestsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomInterestsRequest(ref request, ref callSettings); + return _callMutateCustomInterests.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomInterestServiceGrpc.cs b/src/V3/Stubs/CustomInterestServiceGrpc.cs new file mode 100644 index 000000000..f2c242575 --- /dev/null +++ b/src/V3/Stubs/CustomInterestServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/custom_interest_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage custom interests. + /// + public static partial class CustomInterestService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomInterestService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomInterestRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomInterestRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CustomInterest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CustomInterest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomInterestsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomInterestsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomInterest = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomInterest", + __Marshaller_google_ads_googleads_v3_services_GetCustomInterestRequest, + __Marshaller_google_ads_googleads_v3_resources_CustomInterest); + + static readonly grpc::Method __Method_MutateCustomInterests = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCustomInterests", + __Marshaller_google_ads_googleads_v3_services_MutateCustomInterestsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCustomInterestsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomInterestServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomInterestService + public abstract partial class CustomInterestServiceBase + { + /// + /// Returns the requested custom interest in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomInterest(global::Google.Ads.GoogleAds.V3.Services.GetCustomInterestRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCustomInterests(global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomInterestService + public partial class CustomInterestServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomInterestService + /// The channel to use to make remote calls. + public CustomInterestServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomInterestService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomInterestServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomInterestServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomInterestServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested custom interest in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomInterest GetCustomInterest(global::Google.Ads.GoogleAds.V3.Services.GetCustomInterestRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomInterest(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested custom interest in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomInterest GetCustomInterest(global::Google.Ads.GoogleAds.V3.Services.GetCustomInterestRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomInterest, null, options, request); + } + /// + /// Returns the requested custom interest in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomInterestAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomInterestRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomInterestAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested custom interest in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomInterestAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomInterestRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomInterest, null, options, request); + } + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsResponse MutateCustomInterests(global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomInterests(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsResponse MutateCustomInterests(global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCustomInterests, null, options, request); + } + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomInterestsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomInterestsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or updates custom interests. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomInterestsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomInterestsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCustomInterests, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomInterestServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomInterestServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomInterestServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomInterest, serviceImpl.GetCustomInterest) + .AddMethod(__Method_MutateCustomInterests, serviceImpl.MutateCustomInterests).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomInterestServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomInterest, serviceImpl.GetCustomInterest); + serviceBinder.AddMethod(__Method_MutateCustomInterests, serviceImpl.MutateCustomInterests); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomInterestStatus.cs b/src/V3/Stubs/CustomInterestStatus.cs new file mode 100644 index 000000000..c82d34649 --- /dev/null +++ b/src/V3/Stubs/CustomInterestStatus.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/custom_interest_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/custom_interest_status.proto + public static partial class CustomInterestStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/custom_interest_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomInterestStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jdXN0b21faW50ZXJl", + "c3Rfc3RhdHVzLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJqChhDdXN0b21JbnRl", + "cmVzdFN0YXR1c0VudW0iTgoUQ3VzdG9tSW50ZXJlc3RTdGF0dXMSDwoLVU5T", + "UEVDSUZJRUQQABILCgdVTktOT1dOEAESCwoHRU5BQkxFRBACEgsKB1JFTU9W", + "RUQQA0LuAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhlD", + "dXN0b21JbnRlcmVzdFN0YXR1c1Byb3RvUAFaQmdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztl", + "bnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygId", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomInterestStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.CustomInterestStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomInterestStatusEnum.Types.CustomInterestStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// The status of custom interest. + /// + public sealed partial class CustomInterestStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomInterestStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CustomInterestStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestStatusEnum(CustomInterestStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestStatusEnum Clone() { + return new CustomInterestStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomInterestStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomInterestStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomInterestStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomInterestStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum containing possible custom interest types. + /// + public enum CustomInterestStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Enabled status - custom interest is enabled and can be targeted to. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Removed status - custom interest is removed and cannot be used for + /// targeting. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomInterestType.cs b/src/V3/Stubs/CustomInterestType.cs new file mode 100644 index 000000000..0fa57edc7 --- /dev/null +++ b/src/V3/Stubs/CustomInterestType.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/custom_interest_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/custom_interest_type.proto + public static partial class CustomInterestTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/custom_interest_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomInterestTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jdXN0b21faW50ZXJl", + "c3RfdHlwZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMa", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8idAoWQ3VzdG9tSW50ZXJl", + "c3RUeXBlRW51bSJaChJDdXN0b21JbnRlcmVzdFR5cGUSDwoLVU5TUEVDSUZJ", + "RUQQABILCgdVTktOT1dOEAESEwoPQ1VTVE9NX0FGRklOSVRZEAISEQoNQ1VT", + "VE9NX0lOVEVOVBADQuwBCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXNCF0N1c3RvbUludGVyZXN0VHlwZVByb3RvUAFaQmdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9l", + "bnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVu", + "dW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomInterestTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.CustomInterestTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomInterestTypeEnum.Types.CustomInterestType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// The types of custom interest. + /// + public sealed partial class CustomInterestTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomInterestTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CustomInterestTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestTypeEnum(CustomInterestTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomInterestTypeEnum Clone() { + return new CustomInterestTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomInterestTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomInterestTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomInterestTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomInterestTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum containing possible custom interest types. + /// + public enum CustomInterestType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Allows brand advertisers to define custom affinity audience lists. + /// + [pbr::OriginalName("CUSTOM_AFFINITY")] CustomAffinity = 2, + /// + /// Allows advertisers to define custom intent audience lists. + /// + [pbr::OriginalName("CUSTOM_INTENT")] CustomIntent = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomParameter.cs b/src/V3/Stubs/CustomParameter.cs new file mode 100644 index 000000000..637e6390a --- /dev/null +++ b/src/V3/Stubs/CustomParameter.cs @@ -0,0 +1,232 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/custom_parameter.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/custom_parameter.proto + public static partial class CustomParameterReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/custom_parameter.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomParameterReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vY3VzdG9tX3BhcmFt", + "ZXRlci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uGh5n", + "b29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5u", + "b3RhdGlvbnMucHJvdG8iaQoPQ3VzdG9tUGFyYW1ldGVyEikKA2tleRgBIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIrCgV2YWx1ZRgCIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZULvAQoiY29tLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbkIUQ3VzdG9tUGFyYW1ldGVyUHJv", + "dG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9h", + "ZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbjtjb21tb26iAgNHQUGqAh5Hb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5Db21tb27KAh5Hb29nbGVcQWRzXEdvb2dsZUFk", + "c1xWM1xDb21tb27qAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6Q29t", + "bW9uYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CustomParameter), global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser, new[]{ "Key", "Value" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A mapping that can be used by custom parameter tags in a + /// `tracking_url_template`, `final_urls`, or `mobile_final_urls`. + /// + public sealed partial class CustomParameter : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomParameter()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.CustomParameterReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomParameter() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomParameter(CustomParameter other) : this() { + Key = other.Key; + Value = other.Value; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomParameter Clone() { + return new CustomParameter(this); + } + + /// Field number for the "key" field. + public const int KeyFieldNumber = 1; + private static readonly pb::FieldCodec _single_key_codec = pb::FieldCodec.ForClassWrapper(10); + private string key_; + /// + /// The key matching the parameter tag name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Key { + get { return key_; } + set { + key_ = value; + } + } + + + /// Field number for the "value" field. + public const int ValueFieldNumber = 2; + private static readonly pb::FieldCodec _single_value_codec = pb::FieldCodec.ForClassWrapper(18); + private string value_; + /// + /// The value to be substituted. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Value { + get { return value_; } + set { + value_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomParameter); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomParameter other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Key != other.Key) return false; + if (Value != other.Value) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (key_ != null) hash ^= Key.GetHashCode(); + if (value_ != null) hash ^= Value.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (key_ != null) { + _single_key_codec.WriteTagAndValue(output, Key); + } + if (value_ != null) { + _single_value_codec.WriteTagAndValue(output, Value); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (key_ != null) { + size += _single_key_codec.CalculateSizeWithTag(Key); + } + if (value_ != null) { + size += _single_value_codec.CalculateSizeWithTag(Value); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomParameter other) { + if (other == null) { + return; + } + if (other.key_ != null) { + if (key_ == null || other.Key != "") { + Key = other.Key; + } + } + if (other.value_ != null) { + if (value_ == null || other.Value != "") { + Value = other.Value; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_key_codec.Read(input); + if (key_ == null || value != "") { + Key = value; + } + break; + } + case 18: { + string value = _single_value_codec.Read(input); + if (value_ == null || value != "") { + Value = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomPlaceholderField.cs b/src/V3/Stubs/CustomPlaceholderField.cs new file mode 100644 index 000000000..99fc962b5 --- /dev/null +++ b/src/V3/Stubs/CustomPlaceholderField.cs @@ -0,0 +1,290 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/custom_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/custom_placeholder_field.proto + public static partial class CustomPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/custom_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jdXN0b21fcGxhY2Vo", + "b2xkZXJfZmllbGQucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIr4DChpDdXN0b21Q", + "bGFjZWhvbGRlckZpZWxkRW51bSKfAwoWQ3VzdG9tUGxhY2Vob2xkZXJGaWVs", + "ZBIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIGCgJJRBACEgcKA0lE", + "MhADEg4KCklURU1fVElUTEUQBBIRCg1JVEVNX1NVQlRJVExFEAUSFAoQSVRF", + "TV9ERVNDUklQVElPThAGEhAKDElURU1fQUREUkVTUxAHEgkKBVBSSUNFEAgS", + "EwoPRk9STUFUVEVEX1BSSUNFEAkSDgoKU0FMRV9QUklDRRAKEhgKFEZPUk1B", + "VFRFRF9TQUxFX1BSSUNFEAsSDQoJSU1BR0VfVVJMEAwSEQoNSVRFTV9DQVRF", + "R09SWRANEg4KCkZJTkFMX1VSTFMQDhIVChFGSU5BTF9NT0JJTEVfVVJMUxAP", + "EhAKDFRSQUNLSU5HX1VSTBAQEhcKE0NPTlRFWFRVQUxfS0VZV09SRFMQERIU", + "ChBBTkRST0lEX0FQUF9MSU5LEBISDwoLU0lNSUxBUl9JRFMQExIQCgxJT1Nf", + "QVBQX0xJTksQFBIUChBJT1NfQVBQX1NUT1JFX0lEEBVC8AEKIWNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IbQ3VzdG9tUGxhY2Vob2xkZXJG", + "aWVsZFByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29n", + "bGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6", + "RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.CustomPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomPlaceholderFieldEnum.Types.CustomPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Custom placeholder fields. + /// For more information about dynamic remarketing feeds, see + /// https://support.google.com/google-ads/answer/6053288. + /// + public sealed partial class CustomPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CustomPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomPlaceholderFieldEnum(CustomPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomPlaceholderFieldEnum Clone() { + return new CustomPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Custom placeholder fields. + /// + public enum CustomPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: STRING. Required. Combination ID and ID2 must be unique per + /// offer. + /// + [pbr::OriginalName("ID")] Id = 2, + /// + /// Data Type: STRING. Combination ID and ID2 must be unique per offer. + /// + [pbr::OriginalName("ID2")] Id2 = 3, + /// + /// Data Type: STRING. Required. Main headline with product name to be shown + /// in dynamic ad. + /// + [pbr::OriginalName("ITEM_TITLE")] ItemTitle = 4, + /// + /// Data Type: STRING. Optional text to be shown in the image ad. + /// + [pbr::OriginalName("ITEM_SUBTITLE")] ItemSubtitle = 5, + /// + /// Data Type: STRING. Optional description of the product to be shown in the + /// ad. + /// + [pbr::OriginalName("ITEM_DESCRIPTION")] ItemDescription = 6, + /// + /// Data Type: STRING. Full address of your offer or service, including + /// postal code. This will be used to identify the closest product to the + /// user when there are multiple offers in the feed that are relevant to the + /// user. + /// + [pbr::OriginalName("ITEM_ADDRESS")] ItemAddress = 7, + /// + /// Data Type: STRING. Price to be shown in the ad. + /// Example: "100.00 USD" + /// + [pbr::OriginalName("PRICE")] Price = 8, + /// + /// Data Type: STRING. Formatted price to be shown in the ad. + /// Example: "Starting at $100.00 USD", "$80 - $100" + /// + [pbr::OriginalName("FORMATTED_PRICE")] FormattedPrice = 9, + /// + /// Data Type: STRING. Sale price to be shown in the ad. + /// Example: "80.00 USD" + /// + [pbr::OriginalName("SALE_PRICE")] SalePrice = 10, + /// + /// Data Type: STRING. Formatted sale price to be shown in the ad. + /// Example: "On sale for $80.00", "$60 - $80" + /// + [pbr::OriginalName("FORMATTED_SALE_PRICE")] FormattedSalePrice = 11, + /// + /// Data Type: URL. Image to be displayed in the ad. Highly recommended for + /// image ads. + /// + [pbr::OriginalName("IMAGE_URL")] ImageUrl = 12, + /// + /// Data Type: STRING. Used as a recommendation engine signal to serve items + /// in the same category. + /// + [pbr::OriginalName("ITEM_CATEGORY")] ItemCategory = 13, + /// + /// Data Type: URL_LIST. Final URLs for the ad when using Upgraded + /// URLs. User will be redirected to these URLs when they click on an ad, or + /// when they click on a specific product for ads that have multiple + /// products. + /// + [pbr::OriginalName("FINAL_URLS")] FinalUrls = 14, + /// + /// Data Type: URL_LIST. Final mobile URLs for the ad when using Upgraded + /// URLs. + /// + [pbr::OriginalName("FINAL_MOBILE_URLS")] FinalMobileUrls = 15, + /// + /// Data Type: URL. Tracking template for the ad when using Upgraded URLs. + /// + [pbr::OriginalName("TRACKING_URL")] TrackingUrl = 16, + /// + /// Data Type: STRING_LIST. Keywords used for product retrieval. + /// + [pbr::OriginalName("CONTEXTUAL_KEYWORDS")] ContextualKeywords = 17, + /// + /// Data Type: STRING. Android app link. Must be formatted as: + /// android-app://{package_id}/{scheme}/{host_path}. + /// The components are defined as follows: + /// package_id: app ID as specified in Google Play. + /// scheme: the scheme to pass to the application. Can be HTTP, or a custom + /// scheme. + /// host_path: identifies the specific content within your application. + /// + [pbr::OriginalName("ANDROID_APP_LINK")] AndroidAppLink = 18, + /// + /// Data Type: STRING_LIST. List of recommended IDs to show together with + /// this item. + /// + [pbr::OriginalName("SIMILAR_IDS")] SimilarIds = 19, + /// + /// Data Type: STRING. iOS app link. + /// + [pbr::OriginalName("IOS_APP_LINK")] IosAppLink = 20, + /// + /// Data Type: INT64. iOS app store ID. + /// + [pbr::OriginalName("IOS_APP_STORE_ID")] IosAppStoreId = 21, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Customer.cs b/src/V3/Stubs/Customer.cs new file mode 100644 index 000000000..ca1f6892c --- /dev/null +++ b/src/V3/Stubs/Customer.cs @@ -0,0 +1,1286 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/customer.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/customer.proto + public static partial class CustomerReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/customer.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXIu", + "cHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcxpaZ29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvY3VzdG9tZXJfcGF5X3Blcl9j", + "b252ZXJzaW9uX2VsaWdpYmlsaXR5X2ZhaWx1cmVfcmVhc29uLnByb3RvGh9n", + "b29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29nbGUvYXBpL3Jl", + "c291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8a", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ilAkKCEN1c3RvbWVyEkAK", + "DXJlc291cmNlX25hbWUYASABKAlCKeBBBfpBIwohZ29vZ2xlYWRzLmdvb2ds", + "ZWFwaXMuY29tL0N1c3RvbWVyEiwKAmlkGAMgASgLMhsuZ29vZ2xlLnByb3Rv", + "YnVmLkludDY0VmFsdWVCA+BBAxI2ChBkZXNjcmlwdGl2ZV9uYW1lGAQgASgL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjgKDWN1cnJlbmN5X2Nv", + "ZGUYBSABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBBRI0", + "Cgl0aW1lX3pvbmUYBiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFs", + "dWVCA+BBBRI7ChV0cmFja2luZ191cmxfdGVtcGxhdGUYByABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWUSNgoQZmluYWxfdXJsX3N1ZmZpeBgL", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI4ChRhdXRvX3Rh", + "Z2dpbmdfZW5hYmxlZBgIIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29sVmFs", + "dWUSOwoSaGFzX3BhcnRuZXJzX2JhZGdlGAkgASgLMhouZ29vZ2xlLnByb3Rv", + "YnVmLkJvb2xWYWx1ZUID4EEDEjAKB21hbmFnZXIYDCABKAsyGi5nb29nbGUu", + "cHJvdG9idWYuQm9vbFZhbHVlQgPgQQMSNQoMdGVzdF9hY2NvdW50GA0gASgL", + "MhouZ29vZ2xlLnByb3RvYnVmLkJvb2xWYWx1ZUID4EEDElcKFmNhbGxfcmVw", + "b3J0aW5nX3NldHRpbmcYCiABKAsyNy5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5yZXNvdXJjZXMuQ2FsbFJlcG9ydGluZ1NldHRpbmcSZgobY29udmVyc2lv", + "bl90cmFja2luZ19zZXR0aW5nGA4gASgLMjwuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMucmVzb3VyY2VzLkNvbnZlcnNpb25UcmFja2luZ1NldHRpbmdCA+BB", + "AxJXChNyZW1hcmtldGluZ19zZXR0aW5nGA8gASgLMjUuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMucmVzb3VyY2VzLlJlbWFya2V0aW5nU2V0dGluZ0ID4EED", + "EsIBCi5wYXlfcGVyX2NvbnZlcnNpb25fZWxpZ2liaWxpdHlfZmFpbHVyZV9y", + "ZWFzb25zGBAgAygOMoQBLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "LkN1c3RvbWVyUGF5UGVyQ29udmVyc2lvbkVsaWdpYmlsaXR5RmFpbHVyZVJl", + "YXNvbkVudW0uQ3VzdG9tZXJQYXlQZXJDb252ZXJzaW9uRWxpZ2liaWxpdHlG", + "YWlsdXJlUmVhc29uQgPgQQM6POpBOQohZ29vZ2xlYWRzLmdvb2dsZWFwaXMu", + "Y29tL0N1c3RvbWVyEhRjdXN0b21lcnMve2N1c3RvbWVyfSKHAgoUQ2FsbFJl", + "cG9ydGluZ1NldHRpbmcSOgoWY2FsbF9yZXBvcnRpbmdfZW5hYmxlZBgBIAEo", + "CzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29sVmFsdWUSRQohY2FsbF9jb252ZXJz", + "aW9uX3JlcG9ydGluZ19lbmFibGVkGAIgASgLMhouZ29vZ2xlLnByb3RvYnVm", + "LkJvb2xWYWx1ZRJsChZjYWxsX2NvbnZlcnNpb25fYWN0aW9uGAkgASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQi76QSsKKWdvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbS9Db252ZXJzaW9uQWN0aW9uIq0BChlDb252ZXJzaW9u", + "VHJhY2tpbmdTZXR0aW5nEkAKFmNvbnZlcnNpb25fdHJhY2tpbmdfaWQYASAB", + "KAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEk4KJGNyb3Nz", + "X2FjY291bnRfY29udmVyc2lvbl90cmFja2luZ19pZBgCIAEoCzIbLmdvb2ds", + "ZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMiVwoSUmVtYXJrZXRpbmdTZXR0", + "aW5nEkEKFmdvb2dsZV9nbG9iYWxfc2l0ZV90YWcYASABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBA0L6AQolY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnJlc291cmNlc0INQ3VzdG9tZXJQcm90b1ABWkpnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRz", + "XFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpS", + "ZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.CustomerPayPerConversionEligibilityFailureReasonReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Customer), global::Google.Ads.GoogleAds.V3.Resources.Customer.Parser, new[]{ "ResourceName", "Id", "DescriptiveName", "CurrencyCode", "TimeZone", "TrackingUrlTemplate", "FinalUrlSuffix", "AutoTaggingEnabled", "HasPartnersBadge", "Manager", "TestAccount", "CallReportingSetting", "ConversionTrackingSetting", "RemarketingSetting", "PayPerConversionEligibilityFailureReasons" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CallReportingSetting), global::Google.Ads.GoogleAds.V3.Resources.CallReportingSetting.Parser, new[]{ "CallReportingEnabled", "CallConversionReportingEnabled", "CallConversionAction" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.ConversionTrackingSetting), global::Google.Ads.GoogleAds.V3.Resources.ConversionTrackingSetting.Parser, new[]{ "ConversionTrackingId", "CrossAccountConversionTrackingId" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.RemarketingSetting), global::Google.Ads.GoogleAds.V3.Resources.RemarketingSetting.Parser, new[]{ "GoogleGlobalSiteTag" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A customer. + /// + public sealed partial class Customer : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Customer()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Customer() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Customer(Customer other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + DescriptiveName = other.DescriptiveName; + CurrencyCode = other.CurrencyCode; + TimeZone = other.TimeZone; + TrackingUrlTemplate = other.TrackingUrlTemplate; + FinalUrlSuffix = other.FinalUrlSuffix; + AutoTaggingEnabled = other.AutoTaggingEnabled; + HasPartnersBadge = other.HasPartnersBadge; + Manager = other.Manager; + TestAccount = other.TestAccount; + callReportingSetting_ = other.callReportingSetting_ != null ? other.callReportingSetting_.Clone() : null; + conversionTrackingSetting_ = other.conversionTrackingSetting_ != null ? other.conversionTrackingSetting_.Clone() : null; + remarketingSetting_ = other.remarketingSetting_ != null ? other.remarketingSetting_.Clone() : null; + payPerConversionEligibilityFailureReasons_ = other.payPerConversionEligibilityFailureReasons_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Customer Clone() { + return new Customer(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the customer. + /// Customer resource names have the form: + /// + /// `customers/{customer_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "descriptive_name" field. + public const int DescriptiveNameFieldNumber = 4; + private static readonly pb::FieldCodec _single_descriptiveName_codec = pb::FieldCodec.ForClassWrapper(34); + private string descriptiveName_; + /// + /// Optional, non-unique descriptive name of the customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DescriptiveName { + get { return descriptiveName_; } + set { + descriptiveName_ = value; + } + } + + + /// Field number for the "currency_code" field. + public const int CurrencyCodeFieldNumber = 5; + private static readonly pb::FieldCodec _single_currencyCode_codec = pb::FieldCodec.ForClassWrapper(42); + private string currencyCode_; + /// + /// Immutable. The currency in which the account operates. + /// A subset of the currency codes from the ISO 4217 standard is + /// supported. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CurrencyCode { + get { return currencyCode_; } + set { + currencyCode_ = value; + } + } + + + /// Field number for the "time_zone" field. + public const int TimeZoneFieldNumber = 6; + private static readonly pb::FieldCodec _single_timeZone_codec = pb::FieldCodec.ForClassWrapper(50); + private string timeZone_; + /// + /// Immutable. The local timezone ID of the customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TimeZone { + get { return timeZone_; } + set { + timeZone_ = value; + } + } + + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 7; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(58); + private string trackingUrlTemplate_; + /// + /// The URL template for constructing a tracking URL out of parameters. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 11; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(90); + private string finalUrlSuffix_; + /// + /// The URL template for appending params to the final URL + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + /// Field number for the "auto_tagging_enabled" field. + public const int AutoTaggingEnabledFieldNumber = 8; + private static readonly pb::FieldCodec _single_autoTaggingEnabled_codec = pb::FieldCodec.ForStructWrapper(66); + private bool? autoTaggingEnabled_; + /// + /// Whether auto-tagging is enabled for the customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? AutoTaggingEnabled { + get { return autoTaggingEnabled_; } + set { + autoTaggingEnabled_ = value; + } + } + + + /// Field number for the "has_partners_badge" field. + public const int HasPartnersBadgeFieldNumber = 9; + private static readonly pb::FieldCodec _single_hasPartnersBadge_codec = pb::FieldCodec.ForStructWrapper(74); + private bool? hasPartnersBadge_; + /// + /// Output only. Whether the Customer has a Partners program badge. If the Customer is not + /// associated with the Partners program, this will be false. For more + /// information, see https://support.google.com/partners/answer/3125774. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? HasPartnersBadge { + get { return hasPartnersBadge_; } + set { + hasPartnersBadge_ = value; + } + } + + + /// Field number for the "manager" field. + public const int ManagerFieldNumber = 12; + private static readonly pb::FieldCodec _single_manager_codec = pb::FieldCodec.ForStructWrapper(98); + private bool? manager_; + /// + /// Output only. Whether the customer is a manager. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Manager { + get { return manager_; } + set { + manager_ = value; + } + } + + + /// Field number for the "test_account" field. + public const int TestAccountFieldNumber = 13; + private static readonly pb::FieldCodec _single_testAccount_codec = pb::FieldCodec.ForStructWrapper(106); + private bool? testAccount_; + /// + /// Output only. Whether the customer is a test account. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? TestAccount { + get { return testAccount_; } + set { + testAccount_ = value; + } + } + + + /// Field number for the "call_reporting_setting" field. + public const int CallReportingSettingFieldNumber = 10; + private global::Google.Ads.GoogleAds.V3.Resources.CallReportingSetting callReportingSetting_; + /// + /// Call reporting setting for a customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CallReportingSetting CallReportingSetting { + get { return callReportingSetting_; } + set { + callReportingSetting_ = value; + } + } + + /// Field number for the "conversion_tracking_setting" field. + public const int ConversionTrackingSettingFieldNumber = 14; + private global::Google.Ads.GoogleAds.V3.Resources.ConversionTrackingSetting conversionTrackingSetting_; + /// + /// Output only. Conversion tracking setting for a customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ConversionTrackingSetting ConversionTrackingSetting { + get { return conversionTrackingSetting_; } + set { + conversionTrackingSetting_ = value; + } + } + + /// Field number for the "remarketing_setting" field. + public const int RemarketingSettingFieldNumber = 15; + private global::Google.Ads.GoogleAds.V3.Resources.RemarketingSetting remarketingSetting_; + /// + /// Output only. Remarketing setting for a customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.RemarketingSetting RemarketingSetting { + get { return remarketingSetting_; } + set { + remarketingSetting_ = value; + } + } + + /// Field number for the "pay_per_conversion_eligibility_failure_reasons" field. + public const int PayPerConversionEligibilityFailureReasonsFieldNumber = 16; + private static readonly pb::FieldCodec _repeated_payPerConversionEligibilityFailureReasons_codec + = pb::FieldCodec.ForEnum(130, x => (int) x, x => (global::Google.Ads.GoogleAds.V3.Enums.CustomerPayPerConversionEligibilityFailureReasonEnum.Types.CustomerPayPerConversionEligibilityFailureReason) x); + private readonly pbc::RepeatedField payPerConversionEligibilityFailureReasons_ = new pbc::RepeatedField(); + /// + /// Output only. Reasons why the customer is not eligible to use PaymentMode.CONVERSIONS. If + /// the list is empty, the customer is eligible. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PayPerConversionEligibilityFailureReasons { + get { return payPerConversionEligibilityFailureReasons_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as Customer); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(Customer other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (DescriptiveName != other.DescriptiveName) return false; + if (CurrencyCode != other.CurrencyCode) return false; + if (TimeZone != other.TimeZone) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + if (AutoTaggingEnabled != other.AutoTaggingEnabled) return false; + if (HasPartnersBadge != other.HasPartnersBadge) return false; + if (Manager != other.Manager) return false; + if (TestAccount != other.TestAccount) return false; + if (!object.Equals(CallReportingSetting, other.CallReportingSetting)) return false; + if (!object.Equals(ConversionTrackingSetting, other.ConversionTrackingSetting)) return false; + if (!object.Equals(RemarketingSetting, other.RemarketingSetting)) return false; + if(!payPerConversionEligibilityFailureReasons_.Equals(other.payPerConversionEligibilityFailureReasons_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (descriptiveName_ != null) hash ^= DescriptiveName.GetHashCode(); + if (currencyCode_ != null) hash ^= CurrencyCode.GetHashCode(); + if (timeZone_ != null) hash ^= TimeZone.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + if (autoTaggingEnabled_ != null) hash ^= AutoTaggingEnabled.GetHashCode(); + if (hasPartnersBadge_ != null) hash ^= HasPartnersBadge.GetHashCode(); + if (manager_ != null) hash ^= Manager.GetHashCode(); + if (testAccount_ != null) hash ^= TestAccount.GetHashCode(); + if (callReportingSetting_ != null) hash ^= CallReportingSetting.GetHashCode(); + if (conversionTrackingSetting_ != null) hash ^= ConversionTrackingSetting.GetHashCode(); + if (remarketingSetting_ != null) hash ^= RemarketingSetting.GetHashCode(); + hash ^= payPerConversionEligibilityFailureReasons_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (descriptiveName_ != null) { + _single_descriptiveName_codec.WriteTagAndValue(output, DescriptiveName); + } + if (currencyCode_ != null) { + _single_currencyCode_codec.WriteTagAndValue(output, CurrencyCode); + } + if (timeZone_ != null) { + _single_timeZone_codec.WriteTagAndValue(output, TimeZone); + } + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + if (autoTaggingEnabled_ != null) { + _single_autoTaggingEnabled_codec.WriteTagAndValue(output, AutoTaggingEnabled); + } + if (hasPartnersBadge_ != null) { + _single_hasPartnersBadge_codec.WriteTagAndValue(output, HasPartnersBadge); + } + if (callReportingSetting_ != null) { + output.WriteRawTag(82); + output.WriteMessage(CallReportingSetting); + } + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + if (manager_ != null) { + _single_manager_codec.WriteTagAndValue(output, Manager); + } + if (testAccount_ != null) { + _single_testAccount_codec.WriteTagAndValue(output, TestAccount); + } + if (conversionTrackingSetting_ != null) { + output.WriteRawTag(114); + output.WriteMessage(ConversionTrackingSetting); + } + if (remarketingSetting_ != null) { + output.WriteRawTag(122); + output.WriteMessage(RemarketingSetting); + } + payPerConversionEligibilityFailureReasons_.WriteTo(output, _repeated_payPerConversionEligibilityFailureReasons_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (descriptiveName_ != null) { + size += _single_descriptiveName_codec.CalculateSizeWithTag(DescriptiveName); + } + if (currencyCode_ != null) { + size += _single_currencyCode_codec.CalculateSizeWithTag(CurrencyCode); + } + if (timeZone_ != null) { + size += _single_timeZone_codec.CalculateSizeWithTag(TimeZone); + } + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + if (autoTaggingEnabled_ != null) { + size += _single_autoTaggingEnabled_codec.CalculateSizeWithTag(AutoTaggingEnabled); + } + if (hasPartnersBadge_ != null) { + size += _single_hasPartnersBadge_codec.CalculateSizeWithTag(HasPartnersBadge); + } + if (manager_ != null) { + size += _single_manager_codec.CalculateSizeWithTag(Manager); + } + if (testAccount_ != null) { + size += _single_testAccount_codec.CalculateSizeWithTag(TestAccount); + } + if (callReportingSetting_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CallReportingSetting); + } + if (conversionTrackingSetting_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ConversionTrackingSetting); + } + if (remarketingSetting_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(RemarketingSetting); + } + size += payPerConversionEligibilityFailureReasons_.CalculateSize(_repeated_payPerConversionEligibilityFailureReasons_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(Customer other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.descriptiveName_ != null) { + if (descriptiveName_ == null || other.DescriptiveName != "") { + DescriptiveName = other.DescriptiveName; + } + } + if (other.currencyCode_ != null) { + if (currencyCode_ == null || other.CurrencyCode != "") { + CurrencyCode = other.CurrencyCode; + } + } + if (other.timeZone_ != null) { + if (timeZone_ == null || other.TimeZone != "") { + TimeZone = other.TimeZone; + } + } + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + if (other.autoTaggingEnabled_ != null) { + if (autoTaggingEnabled_ == null || other.AutoTaggingEnabled != false) { + AutoTaggingEnabled = other.AutoTaggingEnabled; + } + } + if (other.hasPartnersBadge_ != null) { + if (hasPartnersBadge_ == null || other.HasPartnersBadge != false) { + HasPartnersBadge = other.HasPartnersBadge; + } + } + if (other.manager_ != null) { + if (manager_ == null || other.Manager != false) { + Manager = other.Manager; + } + } + if (other.testAccount_ != null) { + if (testAccount_ == null || other.TestAccount != false) { + TestAccount = other.TestAccount; + } + } + if (other.callReportingSetting_ != null) { + if (callReportingSetting_ == null) { + CallReportingSetting = new global::Google.Ads.GoogleAds.V3.Resources.CallReportingSetting(); + } + CallReportingSetting.MergeFrom(other.CallReportingSetting); + } + if (other.conversionTrackingSetting_ != null) { + if (conversionTrackingSetting_ == null) { + ConversionTrackingSetting = new global::Google.Ads.GoogleAds.V3.Resources.ConversionTrackingSetting(); + } + ConversionTrackingSetting.MergeFrom(other.ConversionTrackingSetting); + } + if (other.remarketingSetting_ != null) { + if (remarketingSetting_ == null) { + RemarketingSetting = new global::Google.Ads.GoogleAds.V3.Resources.RemarketingSetting(); + } + RemarketingSetting.MergeFrom(other.RemarketingSetting); + } + payPerConversionEligibilityFailureReasons_.Add(other.payPerConversionEligibilityFailureReasons_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_descriptiveName_codec.Read(input); + if (descriptiveName_ == null || value != "") { + DescriptiveName = value; + } + break; + } + case 42: { + string value = _single_currencyCode_codec.Read(input); + if (currencyCode_ == null || value != "") { + CurrencyCode = value; + } + break; + } + case 50: { + string value = _single_timeZone_codec.Read(input); + if (timeZone_ == null || value != "") { + TimeZone = value; + } + break; + } + case 58: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 66: { + bool? value = _single_autoTaggingEnabled_codec.Read(input); + if (autoTaggingEnabled_ == null || value != false) { + AutoTaggingEnabled = value; + } + break; + } + case 74: { + bool? value = _single_hasPartnersBadge_codec.Read(input); + if (hasPartnersBadge_ == null || value != false) { + HasPartnersBadge = value; + } + break; + } + case 82: { + if (callReportingSetting_ == null) { + CallReportingSetting = new global::Google.Ads.GoogleAds.V3.Resources.CallReportingSetting(); + } + input.ReadMessage(CallReportingSetting); + break; + } + case 90: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + case 98: { + bool? value = _single_manager_codec.Read(input); + if (manager_ == null || value != false) { + Manager = value; + } + break; + } + case 106: { + bool? value = _single_testAccount_codec.Read(input); + if (testAccount_ == null || value != false) { + TestAccount = value; + } + break; + } + case 114: { + if (conversionTrackingSetting_ == null) { + ConversionTrackingSetting = new global::Google.Ads.GoogleAds.V3.Resources.ConversionTrackingSetting(); + } + input.ReadMessage(ConversionTrackingSetting); + break; + } + case 122: { + if (remarketingSetting_ == null) { + RemarketingSetting = new global::Google.Ads.GoogleAds.V3.Resources.RemarketingSetting(); + } + input.ReadMessage(RemarketingSetting); + break; + } + case 130: + case 128: { + payPerConversionEligibilityFailureReasons_.AddEntriesFrom(input, _repeated_payPerConversionEligibilityFailureReasons_codec); + break; + } + } + } + } + + } + + /// + /// Call reporting setting for a customer. + /// + public sealed partial class CallReportingSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CallReportingSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallReportingSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallReportingSetting(CallReportingSetting other) : this() { + CallReportingEnabled = other.CallReportingEnabled; + CallConversionReportingEnabled = other.CallConversionReportingEnabled; + CallConversionAction = other.CallConversionAction; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallReportingSetting Clone() { + return new CallReportingSetting(this); + } + + /// Field number for the "call_reporting_enabled" field. + public const int CallReportingEnabledFieldNumber = 1; + private static readonly pb::FieldCodec _single_callReportingEnabled_codec = pb::FieldCodec.ForStructWrapper(10); + private bool? callReportingEnabled_; + /// + /// Enable reporting of phone call events by redirecting them via Google + /// System. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? CallReportingEnabled { + get { return callReportingEnabled_; } + set { + callReportingEnabled_ = value; + } + } + + + /// Field number for the "call_conversion_reporting_enabled" field. + public const int CallConversionReportingEnabledFieldNumber = 2; + private static readonly pb::FieldCodec _single_callConversionReportingEnabled_codec = pb::FieldCodec.ForStructWrapper(18); + private bool? callConversionReportingEnabled_; + /// + /// Whether to enable call conversion reporting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? CallConversionReportingEnabled { + get { return callConversionReportingEnabled_; } + set { + callConversionReportingEnabled_ = value; + } + } + + + /// Field number for the "call_conversion_action" field. + public const int CallConversionActionFieldNumber = 9; + private static readonly pb::FieldCodec _single_callConversionAction_codec = pb::FieldCodec.ForClassWrapper(74); + private string callConversionAction_; + /// + /// Customer-level call conversion action to attribute a call conversion to. + /// If not set a default conversion action is used. Only in effect when + /// call_conversion_reporting_enabled is set to true. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CallConversionAction { + get { return callConversionAction_; } + set { + callConversionAction_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CallReportingSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CallReportingSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CallReportingEnabled != other.CallReportingEnabled) return false; + if (CallConversionReportingEnabled != other.CallConversionReportingEnabled) return false; + if (CallConversionAction != other.CallConversionAction) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (callReportingEnabled_ != null) hash ^= CallReportingEnabled.GetHashCode(); + if (callConversionReportingEnabled_ != null) hash ^= CallConversionReportingEnabled.GetHashCode(); + if (callConversionAction_ != null) hash ^= CallConversionAction.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (callReportingEnabled_ != null) { + _single_callReportingEnabled_codec.WriteTagAndValue(output, CallReportingEnabled); + } + if (callConversionReportingEnabled_ != null) { + _single_callConversionReportingEnabled_codec.WriteTagAndValue(output, CallConversionReportingEnabled); + } + if (callConversionAction_ != null) { + _single_callConversionAction_codec.WriteTagAndValue(output, CallConversionAction); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (callReportingEnabled_ != null) { + size += _single_callReportingEnabled_codec.CalculateSizeWithTag(CallReportingEnabled); + } + if (callConversionReportingEnabled_ != null) { + size += _single_callConversionReportingEnabled_codec.CalculateSizeWithTag(CallConversionReportingEnabled); + } + if (callConversionAction_ != null) { + size += _single_callConversionAction_codec.CalculateSizeWithTag(CallConversionAction); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CallReportingSetting other) { + if (other == null) { + return; + } + if (other.callReportingEnabled_ != null) { + if (callReportingEnabled_ == null || other.CallReportingEnabled != false) { + CallReportingEnabled = other.CallReportingEnabled; + } + } + if (other.callConversionReportingEnabled_ != null) { + if (callConversionReportingEnabled_ == null || other.CallConversionReportingEnabled != false) { + CallConversionReportingEnabled = other.CallConversionReportingEnabled; + } + } + if (other.callConversionAction_ != null) { + if (callConversionAction_ == null || other.CallConversionAction != "") { + CallConversionAction = other.CallConversionAction; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + bool? value = _single_callReportingEnabled_codec.Read(input); + if (callReportingEnabled_ == null || value != false) { + CallReportingEnabled = value; + } + break; + } + case 18: { + bool? value = _single_callConversionReportingEnabled_codec.Read(input); + if (callConversionReportingEnabled_ == null || value != false) { + CallConversionReportingEnabled = value; + } + break; + } + case 74: { + string value = _single_callConversionAction_codec.Read(input); + if (callConversionAction_ == null || value != "") { + CallConversionAction = value; + } + break; + } + } + } + } + + } + + /// + /// A collection of customer-wide settings related to Google Ads Conversion + /// Tracking. + /// + public sealed partial class ConversionTrackingSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ConversionTrackingSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionTrackingSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionTrackingSetting(ConversionTrackingSetting other) : this() { + ConversionTrackingId = other.ConversionTrackingId; + CrossAccountConversionTrackingId = other.CrossAccountConversionTrackingId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ConversionTrackingSetting Clone() { + return new ConversionTrackingSetting(this); + } + + /// Field number for the "conversion_tracking_id" field. + public const int ConversionTrackingIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_conversionTrackingId_codec = pb::FieldCodec.ForStructWrapper(10); + private long? conversionTrackingId_; + /// + /// Output only. The conversion tracking id used for this account. This id is automatically + /// assigned after any conversion tracking feature is used. If the customer + /// doesn't use conversion tracking, this is 0. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ConversionTrackingId { + get { return conversionTrackingId_; } + set { + conversionTrackingId_ = value; + } + } + + + /// Field number for the "cross_account_conversion_tracking_id" field. + public const int CrossAccountConversionTrackingIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_crossAccountConversionTrackingId_codec = pb::FieldCodec.ForStructWrapper(18); + private long? crossAccountConversionTrackingId_; + /// + /// Output only. The conversion tracking id of the customer's manager. This is set when the + /// customer is opted into cross account conversion tracking, and it overrides + /// conversion_tracking_id. This field can only be managed through the Google + /// Ads UI. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CrossAccountConversionTrackingId { + get { return crossAccountConversionTrackingId_; } + set { + crossAccountConversionTrackingId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ConversionTrackingSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ConversionTrackingSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ConversionTrackingId != other.ConversionTrackingId) return false; + if (CrossAccountConversionTrackingId != other.CrossAccountConversionTrackingId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (conversionTrackingId_ != null) hash ^= ConversionTrackingId.GetHashCode(); + if (crossAccountConversionTrackingId_ != null) hash ^= CrossAccountConversionTrackingId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (conversionTrackingId_ != null) { + _single_conversionTrackingId_codec.WriteTagAndValue(output, ConversionTrackingId); + } + if (crossAccountConversionTrackingId_ != null) { + _single_crossAccountConversionTrackingId_codec.WriteTagAndValue(output, CrossAccountConversionTrackingId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (conversionTrackingId_ != null) { + size += _single_conversionTrackingId_codec.CalculateSizeWithTag(ConversionTrackingId); + } + if (crossAccountConversionTrackingId_ != null) { + size += _single_crossAccountConversionTrackingId_codec.CalculateSizeWithTag(CrossAccountConversionTrackingId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ConversionTrackingSetting other) { + if (other == null) { + return; + } + if (other.conversionTrackingId_ != null) { + if (conversionTrackingId_ == null || other.ConversionTrackingId != 0L) { + ConversionTrackingId = other.ConversionTrackingId; + } + } + if (other.crossAccountConversionTrackingId_ != null) { + if (crossAccountConversionTrackingId_ == null || other.CrossAccountConversionTrackingId != 0L) { + CrossAccountConversionTrackingId = other.CrossAccountConversionTrackingId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_conversionTrackingId_codec.Read(input); + if (conversionTrackingId_ == null || value != 0L) { + ConversionTrackingId = value; + } + break; + } + case 18: { + long? value = _single_crossAccountConversionTrackingId_codec.Read(input); + if (crossAccountConversionTrackingId_ == null || value != 0L) { + CrossAccountConversionTrackingId = value; + } + break; + } + } + } + } + + } + + /// + /// Remarketing setting for a customer. + /// + public sealed partial class RemarketingSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new RemarketingSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public RemarketingSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public RemarketingSetting(RemarketingSetting other) : this() { + GoogleGlobalSiteTag = other.GoogleGlobalSiteTag; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public RemarketingSetting Clone() { + return new RemarketingSetting(this); + } + + /// Field number for the "google_global_site_tag" field. + public const int GoogleGlobalSiteTagFieldNumber = 1; + private static readonly pb::FieldCodec _single_googleGlobalSiteTag_codec = pb::FieldCodec.ForClassWrapper(10); + private string googleGlobalSiteTag_; + /// + /// Output only. The Google global site tag. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string GoogleGlobalSiteTag { + get { return googleGlobalSiteTag_; } + set { + googleGlobalSiteTag_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as RemarketingSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(RemarketingSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (GoogleGlobalSiteTag != other.GoogleGlobalSiteTag) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (googleGlobalSiteTag_ != null) hash ^= GoogleGlobalSiteTag.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (googleGlobalSiteTag_ != null) { + _single_googleGlobalSiteTag_codec.WriteTagAndValue(output, GoogleGlobalSiteTag); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (googleGlobalSiteTag_ != null) { + size += _single_googleGlobalSiteTag_codec.CalculateSizeWithTag(GoogleGlobalSiteTag); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(RemarketingSetting other) { + if (other == null) { + return; + } + if (other.googleGlobalSiteTag_ != null) { + if (googleGlobalSiteTag_ == null || other.GoogleGlobalSiteTag != "") { + GoogleGlobalSiteTag = other.GoogleGlobalSiteTag; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_googleGlobalSiteTag_codec.Read(input); + if (googleGlobalSiteTag_ == null || value != "") { + GoogleGlobalSiteTag = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerClient.cs b/src/V3/Stubs/CustomerClient.cs new file mode 100644 index 000000000..df61328fe --- /dev/null +++ b/src/V3/Stubs/CustomerClient.cs @@ -0,0 +1,544 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/customer_client.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/customer_client.proto + public static partial class CustomerClientReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/customer_client.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerClientReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJf", + "Y2xpZW50LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMaH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9h", + "cGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5w", + "cm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKgBQoOQ3VzdG9t", + "ZXJDbGllbnQSRgoNcmVzb3VyY2VfbmFtZRgBIAEoCUIv4EEF+kEpCidnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb20vQ3VzdG9tZXJDbGllbnQSOgoPY2xpZW50", + "X2N1c3RvbWVyGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVl", + "QgPgQQMSLwoGaGlkZGVuGAQgASgLMhouZ29vZ2xlLnByb3RvYnVmLkJvb2xW", + "YWx1ZUID4EEDEi8KBWxldmVsGAUgASgLMhsuZ29vZ2xlLnByb3RvYnVmLklu", + "dDY0VmFsdWVCA+BBAxI0Cgl0aW1lX3pvbmUYBiABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWVCA+BBAxI1Cgx0ZXN0X2FjY291bnQYByABKAsy", + "Gi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlQgPgQQMSMAoHbWFuYWdlchgI", + "IAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29sVmFsdWVCA+BBAxI7ChBkZXNj", + "cmlwdGl2ZV9uYW1lGAkgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1Zh", + "bHVlQgPgQQMSOAoNY3VycmVuY3lfY29kZRgKIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEiwKAmlkGAsgASgLMhsuZ29vZ2xlLnBy", + "b3RvYnVmLkludDY0VmFsdWVCA+BBAzpk6kFhCidnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vQ3VzdG9tZXJDbGllbnQSNmN1c3RvbWVycy97Y3VzdG9tZXJ9", + "L2N1c3RvbWVyQ2xpZW50cy97Y3VzdG9tZXJfY2xpZW50fUKAAgolY29tLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0ITQ3VzdG9tZXJDbGll", + "bnRQcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dB", + "QaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2ds", + "ZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomerClient), global::Google.Ads.GoogleAds.V3.Resources.CustomerClient.Parser, new[]{ "ResourceName", "ClientCustomer", "Hidden", "Level", "TimeZone", "TestAccount", "Manager", "DescriptiveName", "CurrencyCode", "Id" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A link between the given customer and a client customer. CustomerClients only + /// exist for manager customers. All direct and indirect client customers are + /// included, as well as the manager itself. + /// + public sealed partial class CustomerClient : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerClient()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerClientReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClient() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClient(CustomerClient other) : this() { + resourceName_ = other.resourceName_; + ClientCustomer = other.ClientCustomer; + Hidden = other.Hidden; + Level = other.Level; + TimeZone = other.TimeZone; + TestAccount = other.TestAccount; + Manager = other.Manager; + DescriptiveName = other.DescriptiveName; + CurrencyCode = other.CurrencyCode; + Id = other.Id; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClient Clone() { + return new CustomerClient(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the customer client. + /// CustomerClient resource names have the form: + /// `customers/{customer_id}/customerClients/{client_customer_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "client_customer" field. + public const int ClientCustomerFieldNumber = 3; + private static readonly pb::FieldCodec _single_clientCustomer_codec = pb::FieldCodec.ForClassWrapper(26); + private string clientCustomer_; + /// + /// Output only. The resource name of the client-customer which is linked to + /// the given customer. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ClientCustomer { + get { return clientCustomer_; } + set { + clientCustomer_ = value; + } + } + + + /// Field number for the "hidden" field. + public const int HiddenFieldNumber = 4; + private static readonly pb::FieldCodec _single_hidden_codec = pb::FieldCodec.ForStructWrapper(34); + private bool? hidden_; + /// + /// Output only. Specifies whether this is a + /// [hidden account](https://support.google.com/google-ads/answer/7519830). + /// Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Hidden { + get { return hidden_; } + set { + hidden_ = value; + } + } + + + /// Field number for the "level" field. + public const int LevelFieldNumber = 5; + private static readonly pb::FieldCodec _single_level_codec = pb::FieldCodec.ForStructWrapper(42); + private long? level_; + /// + /// Output only. Distance between given customer and client. For self link, the level value + /// will be 0. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Level { + get { return level_; } + set { + level_ = value; + } + } + + + /// Field number for the "time_zone" field. + public const int TimeZoneFieldNumber = 6; + private static readonly pb::FieldCodec _single_timeZone_codec = pb::FieldCodec.ForClassWrapper(50); + private string timeZone_; + /// + /// Output only. Common Locale Data Repository (CLDR) string representation of the + /// time zone of the client, e.g. America/Los_Angeles. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TimeZone { + get { return timeZone_; } + set { + timeZone_ = value; + } + } + + + /// Field number for the "test_account" field. + public const int TestAccountFieldNumber = 7; + private static readonly pb::FieldCodec _single_testAccount_codec = pb::FieldCodec.ForStructWrapper(58); + private bool? testAccount_; + /// + /// Output only. Identifies if the client is a test account. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? TestAccount { + get { return testAccount_; } + set { + testAccount_ = value; + } + } + + + /// Field number for the "manager" field. + public const int ManagerFieldNumber = 8; + private static readonly pb::FieldCodec _single_manager_codec = pb::FieldCodec.ForStructWrapper(66); + private bool? manager_; + /// + /// Output only. Identifies if the client is a manager. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Manager { + get { return manager_; } + set { + manager_ = value; + } + } + + + /// Field number for the "descriptive_name" field. + public const int DescriptiveNameFieldNumber = 9; + private static readonly pb::FieldCodec _single_descriptiveName_codec = pb::FieldCodec.ForClassWrapper(74); + private string descriptiveName_; + /// + /// Output only. Descriptive name for the client. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DescriptiveName { + get { return descriptiveName_; } + set { + descriptiveName_ = value; + } + } + + + /// Field number for the "currency_code" field. + public const int CurrencyCodeFieldNumber = 10; + private static readonly pb::FieldCodec _single_currencyCode_codec = pb::FieldCodec.ForClassWrapper(82); + private string currencyCode_; + /// + /// Output only. Currency code (e.g. 'USD', 'EUR') for the client. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CurrencyCode { + get { return currencyCode_; } + set { + currencyCode_ = value; + } + } + + + /// Field number for the "id" field. + public const int IdFieldNumber = 11; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(90); + private long? id_; + /// + /// Output only. The ID of the client customer. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerClient); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerClient other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (ClientCustomer != other.ClientCustomer) return false; + if (Hidden != other.Hidden) return false; + if (Level != other.Level) return false; + if (TimeZone != other.TimeZone) return false; + if (TestAccount != other.TestAccount) return false; + if (Manager != other.Manager) return false; + if (DescriptiveName != other.DescriptiveName) return false; + if (CurrencyCode != other.CurrencyCode) return false; + if (Id != other.Id) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (clientCustomer_ != null) hash ^= ClientCustomer.GetHashCode(); + if (hidden_ != null) hash ^= Hidden.GetHashCode(); + if (level_ != null) hash ^= Level.GetHashCode(); + if (timeZone_ != null) hash ^= TimeZone.GetHashCode(); + if (testAccount_ != null) hash ^= TestAccount.GetHashCode(); + if (manager_ != null) hash ^= Manager.GetHashCode(); + if (descriptiveName_ != null) hash ^= DescriptiveName.GetHashCode(); + if (currencyCode_ != null) hash ^= CurrencyCode.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (clientCustomer_ != null) { + _single_clientCustomer_codec.WriteTagAndValue(output, ClientCustomer); + } + if (hidden_ != null) { + _single_hidden_codec.WriteTagAndValue(output, Hidden); + } + if (level_ != null) { + _single_level_codec.WriteTagAndValue(output, Level); + } + if (timeZone_ != null) { + _single_timeZone_codec.WriteTagAndValue(output, TimeZone); + } + if (testAccount_ != null) { + _single_testAccount_codec.WriteTagAndValue(output, TestAccount); + } + if (manager_ != null) { + _single_manager_codec.WriteTagAndValue(output, Manager); + } + if (descriptiveName_ != null) { + _single_descriptiveName_codec.WriteTagAndValue(output, DescriptiveName); + } + if (currencyCode_ != null) { + _single_currencyCode_codec.WriteTagAndValue(output, CurrencyCode); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (clientCustomer_ != null) { + size += _single_clientCustomer_codec.CalculateSizeWithTag(ClientCustomer); + } + if (hidden_ != null) { + size += _single_hidden_codec.CalculateSizeWithTag(Hidden); + } + if (level_ != null) { + size += _single_level_codec.CalculateSizeWithTag(Level); + } + if (timeZone_ != null) { + size += _single_timeZone_codec.CalculateSizeWithTag(TimeZone); + } + if (testAccount_ != null) { + size += _single_testAccount_codec.CalculateSizeWithTag(TestAccount); + } + if (manager_ != null) { + size += _single_manager_codec.CalculateSizeWithTag(Manager); + } + if (descriptiveName_ != null) { + size += _single_descriptiveName_codec.CalculateSizeWithTag(DescriptiveName); + } + if (currencyCode_ != null) { + size += _single_currencyCode_codec.CalculateSizeWithTag(CurrencyCode); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerClient other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.clientCustomer_ != null) { + if (clientCustomer_ == null || other.ClientCustomer != "") { + ClientCustomer = other.ClientCustomer; + } + } + if (other.hidden_ != null) { + if (hidden_ == null || other.Hidden != false) { + Hidden = other.Hidden; + } + } + if (other.level_ != null) { + if (level_ == null || other.Level != 0L) { + Level = other.Level; + } + } + if (other.timeZone_ != null) { + if (timeZone_ == null || other.TimeZone != "") { + TimeZone = other.TimeZone; + } + } + if (other.testAccount_ != null) { + if (testAccount_ == null || other.TestAccount != false) { + TestAccount = other.TestAccount; + } + } + if (other.manager_ != null) { + if (manager_ == null || other.Manager != false) { + Manager = other.Manager; + } + } + if (other.descriptiveName_ != null) { + if (descriptiveName_ == null || other.DescriptiveName != "") { + DescriptiveName = other.DescriptiveName; + } + } + if (other.currencyCode_ != null) { + if (currencyCode_ == null || other.CurrencyCode != "") { + CurrencyCode = other.CurrencyCode; + } + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + string value = _single_clientCustomer_codec.Read(input); + if (clientCustomer_ == null || value != "") { + ClientCustomer = value; + } + break; + } + case 34: { + bool? value = _single_hidden_codec.Read(input); + if (hidden_ == null || value != false) { + Hidden = value; + } + break; + } + case 42: { + long? value = _single_level_codec.Read(input); + if (level_ == null || value != 0L) { + Level = value; + } + break; + } + case 50: { + string value = _single_timeZone_codec.Read(input); + if (timeZone_ == null || value != "") { + TimeZone = value; + } + break; + } + case 58: { + bool? value = _single_testAccount_codec.Read(input); + if (testAccount_ == null || value != false) { + TestAccount = value; + } + break; + } + case 66: { + bool? value = _single_manager_codec.Read(input); + if (manager_ == null || value != false) { + Manager = value; + } + break; + } + case 74: { + string value = _single_descriptiveName_codec.Read(input); + if (descriptiveName_ == null || value != "") { + DescriptiveName = value; + } + break; + } + case 82: { + string value = _single_currencyCode_codec.Read(input); + if (currencyCode_ == null || value != "") { + CurrencyCode = value; + } + break; + } + case 90: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerClientLink.cs b/src/V3/Stubs/CustomerClientLink.cs new file mode 100644 index 000000000..d4369b0cc --- /dev/null +++ b/src/V3/Stubs/CustomerClientLink.cs @@ -0,0 +1,345 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/customer_client_link.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/customer_client_link.proto + public static partial class CustomerClientLinkReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/customer_client_link.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerClientLinkReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJf", + "Y2xpZW50X2xpbmsucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlcxo3Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvbWFuYWdl", + "cl9saW5rX3N0YXR1cy5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlv", + "ci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3By", + "b3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25z", + "LnByb3RvIs4DChJDdXN0b21lckNsaWVudExpbmsSSgoNcmVzb3VyY2VfbmFt", + "ZRgBIAEoCUIz4EEF+kEtCitnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ3Vz", + "dG9tZXJDbGllbnRMaW5rEjoKD2NsaWVudF9jdXN0b21lchgDIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEFEjkKD21hbmFnZXJfbGlu", + "a19pZBgEIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMS", + "VgoGc3RhdHVzGAUgASgOMkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMuTWFuYWdlckxpbmtTdGF0dXNFbnVtLk1hbmFnZXJMaW5rU3RhdHVzEioK", + "BmhpZGRlbhgGIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29sVmFsdWU6cepB", + "bgorZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0N1c3RvbWVyQ2xpZW50TGlu", + "axI/Y3VzdG9tZXJzL3tjdXN0b21lcn0vY3VzdG9tZXJDbGllbnRMaW5rcy97", + "Y3VzdG9tZXJfY2xpZW50X2xpbmt9QoQCCiVjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMucmVzb3VyY2VzQhdDdXN0b21lckNsaWVudExpbmtQcm90b1AB", + "Wkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2ds", + "ZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink), global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink.Parser, new[]{ "ResourceName", "ClientCustomer", "ManagerLinkId", "Status", "Hidden" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents customer client link relationship. + /// + public sealed partial class CustomerClientLink : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerClientLink()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLinkReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLink() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLink(CustomerClientLink other) : this() { + resourceName_ = other.resourceName_; + ClientCustomer = other.ClientCustomer; + ManagerLinkId = other.ManagerLinkId; + status_ = other.status_; + Hidden = other.Hidden; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLink Clone() { + return new CustomerClientLink(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. Name of the resource. + /// CustomerClientLink resource names have the form: + /// `customers/{customer_id}/customerClientLinks/{client_customer_id}~{manager_link_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "client_customer" field. + public const int ClientCustomerFieldNumber = 3; + private static readonly pb::FieldCodec _single_clientCustomer_codec = pb::FieldCodec.ForClassWrapper(26); + private string clientCustomer_; + /// + /// Immutable. The client customer linked to this customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ClientCustomer { + get { return clientCustomer_; } + set { + clientCustomer_ = value; + } + } + + + /// Field number for the "manager_link_id" field. + public const int ManagerLinkIdFieldNumber = 4; + private static readonly pb::FieldCodec _single_managerLinkId_codec = pb::FieldCodec.ForStructWrapper(34); + private long? managerLinkId_; + /// + /// Output only. This is uniquely identifies a customer client link. Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ManagerLinkId { + get { return managerLinkId_; } + set { + managerLinkId_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusEnum.Types.ManagerLinkStatus status_ = 0; + /// + /// This is the status of the link between client and manager. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusEnum.Types.ManagerLinkStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "hidden" field. + public const int HiddenFieldNumber = 6; + private static readonly pb::FieldCodec _single_hidden_codec = pb::FieldCodec.ForStructWrapper(50); + private bool? hidden_; + /// + /// The visibility of the link. Users can choose whether or not to see hidden + /// links in the AdWords UI. + /// Default value is false + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Hidden { + get { return hidden_; } + set { + hidden_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerClientLink); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerClientLink other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (ClientCustomer != other.ClientCustomer) return false; + if (ManagerLinkId != other.ManagerLinkId) return false; + if (Status != other.Status) return false; + if (Hidden != other.Hidden) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (clientCustomer_ != null) hash ^= ClientCustomer.GetHashCode(); + if (managerLinkId_ != null) hash ^= ManagerLinkId.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (hidden_ != null) hash ^= Hidden.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (clientCustomer_ != null) { + _single_clientCustomer_codec.WriteTagAndValue(output, ClientCustomer); + } + if (managerLinkId_ != null) { + _single_managerLinkId_codec.WriteTagAndValue(output, ManagerLinkId); + } + if (Status != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Status); + } + if (hidden_ != null) { + _single_hidden_codec.WriteTagAndValue(output, Hidden); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (clientCustomer_ != null) { + size += _single_clientCustomer_codec.CalculateSizeWithTag(ClientCustomer); + } + if (managerLinkId_ != null) { + size += _single_managerLinkId_codec.CalculateSizeWithTag(ManagerLinkId); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (hidden_ != null) { + size += _single_hidden_codec.CalculateSizeWithTag(Hidden); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerClientLink other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.clientCustomer_ != null) { + if (clientCustomer_ == null || other.ClientCustomer != "") { + ClientCustomer = other.ClientCustomer; + } + } + if (other.managerLinkId_ != null) { + if (managerLinkId_ == null || other.ManagerLinkId != 0L) { + ManagerLinkId = other.ManagerLinkId; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.hidden_ != null) { + if (hidden_ == null || other.Hidden != false) { + Hidden = other.Hidden; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + string value = _single_clientCustomer_codec.Read(input); + if (clientCustomer_ == null || value != "") { + ClientCustomer = value; + } + break; + } + case 34: { + long? value = _single_managerLinkId_codec.Read(input); + if (managerLinkId_ == null || value != 0L) { + ManagerLinkId = value; + } + break; + } + case 40: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusEnum.Types.ManagerLinkStatus) input.ReadEnum(); + break; + } + case 50: { + bool? value = _single_hidden_codec.Read(input); + if (hidden_ == null || value != false) { + Hidden = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerClientLinkError.cs b/src/V3/Stubs/CustomerClientLinkError.cs new file mode 100644 index 000000000..e95280fae --- /dev/null +++ b/src/V3/Stubs/CustomerClientLinkError.cs @@ -0,0 +1,211 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/customer_client_link_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/customer_client_link_error.proto + public static partial class CustomerClientLinkErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/customer_client_link_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerClientLinkErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY3VzdG9tZXJfY2xp", + "ZW50X2xpbmtfZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLtAgobQ3Vz", + "dG9tZXJDbGllbnRMaW5rRXJyb3JFbnVtIs0CChdDdXN0b21lckNsaWVudExp", + "bmtFcnJvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIqCiZDTElF", + "TlRfQUxSRUFEWV9JTlZJVEVEX0JZX1RISVNfTUFOQUdFUhACEicKI0NMSUVO", + "VF9BTFJFQURZX01BTkFHRURfSU5fSElFUkFSQ0hZEAMSGwoXQ1lDTElDX0xJ", + "TktfTk9UX0FMTE9XRUQQBBIiCh5DVVNUT01FUl9IQVNfVE9PX01BTllfQUND", + "T1VOVFMQBRIjCh9DTElFTlRfSEFTX1RPT19NQU5ZX0lOVklUQVRJT05TEAYS", + "KgomQ0FOTk9UX0hJREVfT1JfVU5ISURFX01BTkFHRVJfQUNDT1VOVFMQBxIt", + "CilDVVNUT01FUl9IQVNfVE9PX01BTllfQUNDT1VOVFNfQVRfTUFOQUdFUhAI", + "QvcBCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQhxDdXN0", + "b21lckNsaWVudExpbmtFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7", + "ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3Jz", + "ygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomerClientLinkErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CustomerClientLinkErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomerClientLinkErrorEnum.Types.CustomerClientLinkError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible CustomeClientLink errors. + /// + public sealed partial class CustomerClientLinkErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerClientLinkErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CustomerClientLinkErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLinkErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLinkErrorEnum(CustomerClientLinkErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLinkErrorEnum Clone() { + return new CustomerClientLinkErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerClientLinkErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerClientLinkErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerClientLinkErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomerClientLinkErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible CustomerClientLink errors. + /// + public enum CustomerClientLinkError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Trying to manage a client that already in being managed by customer. + /// + [pbr::OriginalName("CLIENT_ALREADY_INVITED_BY_THIS_MANAGER")] ClientAlreadyInvitedByThisManager = 2, + /// + /// Already managed by some other manager in the hierarchy. + /// + [pbr::OriginalName("CLIENT_ALREADY_MANAGED_IN_HIERARCHY")] ClientAlreadyManagedInHierarchy = 3, + /// + /// Attempt to create a cycle in the hierarchy. + /// + [pbr::OriginalName("CYCLIC_LINK_NOT_ALLOWED")] CyclicLinkNotAllowed = 4, + /// + /// Managed accounts has the maximum number of linked accounts. + /// + [pbr::OriginalName("CUSTOMER_HAS_TOO_MANY_ACCOUNTS")] CustomerHasTooManyAccounts = 5, + /// + /// Invitor has the maximum pending invitations. + /// + [pbr::OriginalName("CLIENT_HAS_TOO_MANY_INVITATIONS")] ClientHasTooManyInvitations = 6, + /// + /// Attempt to change hidden status of a link that is not active. + /// + [pbr::OriginalName("CANNOT_HIDE_OR_UNHIDE_MANAGER_ACCOUNTS")] CannotHideOrUnhideManagerAccounts = 7, + /// + /// Parent manager account has the maximum number of linked accounts. + /// + [pbr::OriginalName("CUSTOMER_HAS_TOO_MANY_ACCOUNTS_AT_MANAGER")] CustomerHasTooManyAccountsAtManager = 8, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerClientLinkService.cs b/src/V3/Stubs/CustomerClientLinkService.cs new file mode 100644 index 000000000..5ed49308f --- /dev/null +++ b/src/V3/Stubs/CustomerClientLinkService.cs @@ -0,0 +1,917 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_client_link_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/customer_client_link_service.proto + public static partial class CustomerClientLinkServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/customer_client_link_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerClientLinkServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9j", + "bGllbnRfbGlua19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzL2N1c3RvbWVyX2NsaWVudF9saW5rLnByb3RvGhxnb29nbGUvYXBpL2Fu", + "bm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29v", + "Z2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29vZ2xlL3Byb3RvYnVm", + "L2ZpZWxkX21hc2sucHJvdG8iOgocR2V0Q3VzdG9tZXJDbGllbnRMaW5rUmVx", + "dWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIikgEKH011dGF0ZUN1", + "c3RvbWVyQ2xpZW50TGlua1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlC", + "A+BBAhJVCglvcGVyYXRpb24YAiABKAsyPS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5DdXN0b21lckNsaWVudExpbmtPcGVyYXRpb25CA+BB", + "AiLtAQobQ3VzdG9tZXJDbGllbnRMaW5rT3BlcmF0aW9uEi8KC3VwZGF0ZV9t", + "YXNrGAQgASgLMhouZ29vZ2xlLnByb3RvYnVmLkZpZWxkTWFzaxJHCgZjcmVh", + "dGUYASABKAsyNS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMu", + "Q3VzdG9tZXJDbGllbnRMaW5rSAASRwoGdXBkYXRlGAIgASgLMjUuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkN1c3RvbWVyQ2xpZW50TGlu", + "a0gAQgsKCW9wZXJhdGlvbiJ0CiBNdXRhdGVDdXN0b21lckNsaWVudExpbmtS", + "ZXNwb25zZRJQCgZyZXN1bHQYASABKAsyQC5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5NdXRhdGVDdXN0b21lckNsaWVudExpbmtSZXN1bHQi", + "NwoeTXV0YXRlQ3VzdG9tZXJDbGllbnRMaW5rUmVzdWx0EhUKDXJlc291cmNl", + "X25hbWUYASABKAkymQQKGUN1c3RvbWVyQ2xpZW50TGlua1NlcnZpY2US3QEK", + "FUdldEN1c3RvbWVyQ2xpZW50TGluaxI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLkdldEN1c3RvbWVyQ2xpZW50TGlua1JlcXVlc3QaNS5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ3VzdG9tZXJDbGll", + "bnRMaW5rIk2C0+STAjcSNS92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMv", + "Ki9jdXN0b21lckNsaWVudExpbmtzLyp92kENcmVzb3VyY2VfbmFtZRL+AQoY", + "TXV0YXRlQ3VzdG9tZXJDbGllbnRMaW5rEkEuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuTXV0YXRlQ3VzdG9tZXJDbGllbnRMaW5rUmVxdWVz", + "dBpCLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUN1", + "c3RvbWVyQ2xpZW50TGlua1Jlc3BvbnNlIluC0+STAj0iOC92My9jdXN0b21l", + "cnMve2N1c3RvbWVyX2lkPSp9L2N1c3RvbWVyQ2xpZW50TGlua3M6bXV0YXRl", + "OgEq2kEVY3VzdG9tZXJfaWQsb3BlcmF0aW9uGhvKQRhnb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb21ChQIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlc0IeQ3VzdG9tZXJDbGllbnRMaW5rU2VydmljZVByb3RvUAFaSGdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2Vy", + "dmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLinkReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientLinkRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientLinkRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkRequest.Parser, new[]{ "CustomerId", "Operation" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkOperation), global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkOperation.Parser, new[]{ "UpdateMask", "Create", "Update" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResponse.Parser, new[]{ "Result" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResult), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CustomerClientLinkService.GetCustomerClientLink][google.ads.googleads.v3.services.CustomerClientLinkService.GetCustomerClientLink]. + /// + public sealed partial class GetCustomerClientLinkRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomerClientLinkRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerClientLinkRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerClientLinkRequest(GetCustomerClientLinkRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerClientLinkRequest Clone() { + return new GetCustomerClientLinkRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the customer client link to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomerClientLinkRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomerClientLinkRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomerClientLinkRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomerClientLinkService.MutateCustomerClientLink][google.ads.googleads.v3.services.CustomerClientLinkService.MutateCustomerClientLink]. + /// + public sealed partial class MutateCustomerClientLinkRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerClientLinkRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkRequest(MutateCustomerClientLinkRequest other) : this() { + customerId_ = other.customerId_; + operation_ = other.operation_ != null ? other.operation_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkRequest Clone() { + return new MutateCustomerClientLinkRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose customer link are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operation" field. + public const int OperationFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkOperation operation_; + /// + /// Required. The operation to perform on the individual CustomerClientLink. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkOperation Operation { + get { return operation_; } + set { + operation_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerClientLinkRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerClientLinkRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (!object.Equals(Operation, other.Operation)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (operation_ != null) hash ^= Operation.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (operation_ != null) { + output.WriteRawTag(18); + output.WriteMessage(Operation); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (operation_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Operation); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerClientLinkRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.operation_ != null) { + if (operation_ == null) { + Operation = new global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkOperation(); + } + Operation.MergeFrom(other.Operation); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + if (operation_ == null) { + Operation = new global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkOperation(); + } + input.ReadMessage(Operation); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update) on a CustomerClientLink. + /// + public sealed partial class CustomerClientLinkOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerClientLinkOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLinkOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLinkOperation(CustomerClientLinkOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerClientLinkOperation Clone() { + return new CustomerClientLinkOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new link. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The link is expected to have a valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerClientLinkOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerClientLinkOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerClientLinkOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink(); + } + Update.MergeFrom(other.Update); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a CustomerClientLink mutate. + /// + public sealed partial class MutateCustomerClientLinkResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerClientLinkResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkResponse(MutateCustomerClientLinkResponse other) : this() { + result_ = other.result_ != null ? other.result_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkResponse Clone() { + return new MutateCustomerClientLinkResponse(this); + } + + /// Field number for the "result" field. + public const int ResultFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResult result_; + /// + /// A result that identifies the resource affected by the mutate request. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResult Result { + get { return result_; } + set { + result_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerClientLinkResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerClientLinkResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Result, other.Result)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (result_ != null) hash ^= Result.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (result_ != null) { + output.WriteRawTag(10); + output.WriteMessage(Result); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (result_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Result); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerClientLinkResponse other) { + if (other == null) { + return; + } + if (other.result_ != null) { + if (result_ == null) { + Result = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResult(); + } + Result.MergeFrom(other.Result); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (result_ == null) { + Result = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResult(); + } + input.ReadMessage(Result); + break; + } + } + } + } + + } + + /// + /// The result for a single customer client link mutate. + /// + public sealed partial class MutateCustomerClientLinkResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerClientLinkResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkResult(MutateCustomerClientLinkResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerClientLinkResult Clone() { + return new MutateCustomerClientLinkResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerClientLinkResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerClientLinkResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerClientLinkResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerClientLinkServiceClient.cs b/src/V3/Stubs/CustomerClientLinkServiceClient.cs new file mode 100644 index 000000000..d7a6fe5d3 --- /dev/null +++ b/src/V3/Stubs/CustomerClientLinkServiceClient.cs @@ -0,0 +1,770 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomerClientLinkServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomerClientLinkServiceSettings GetDefault() => new CustomerClientLinkServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomerClientLinkServiceSettings() { } + + private CustomerClientLinkServiceSettings(CustomerClientLinkServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomerClientLinkSettings = existing.GetCustomerClientLinkSettings; + MutateCustomerClientLinkSettings = existing.MutateCustomerClientLinkSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomerClientLinkServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomerClientLinkServiceClient.GetCustomerClientLink and CustomerClientLinkServiceClient.GetCustomerClientLinkAsync. + /// + /// + /// The default CustomerClientLinkServiceClient.GetCustomerClientLink and + /// CustomerClientLinkServiceClient.GetCustomerClientLinkAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomerClientLinkSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerClientLinkServiceClient.MutateCustomerClientLink and CustomerClientLinkServiceClient.MutateCustomerClientLinkAsync. + /// + /// + /// The default CustomerClientLinkServiceClient.MutateCustomerClientLink and + /// CustomerClientLinkServiceClient.MutateCustomerClientLinkAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCustomerClientLinkSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomerClientLinkServiceSettings Clone() => new CustomerClientLinkServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomerClientLinkServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomerClientLinkServiceSettings Settings { get; set; } + + /// + public override CustomerClientLinkServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomerClientLinkServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomerClientLinkServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomerClientLinkServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomerClientLinkServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomerClientLinkServiceClient.ChannelPool; + } + + /// + /// CustomerClientLinkService client wrapper, for convenient use. + /// + public abstract partial class CustomerClientLinkServiceClient + { + /// + /// The default endpoint for the CustomerClientLinkService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomerClientLinkService scopes. + /// + /// + /// The default CustomerClientLinkService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerClientLinkServiceClient client = await CustomerClientLinkServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerClientLinkServiceClient.DefaultEndpoint.Host, CustomerClientLinkServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerClientLinkServiceClient client = CustomerClientLinkServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomerClientLinkServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerClientLinkServiceClient client = CustomerClientLinkServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerClientLinkServiceClient.DefaultEndpoint.Host, CustomerClientLinkServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerClientLinkServiceClient client = CustomerClientLinkServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomerClientLinkServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomerClientLinkServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerClientLinkServiceClient Create(grpccore::Channel channel, CustomerClientLinkServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerClientLinkServiceClient Create(grpccore::CallInvoker callInvoker, CustomerClientLinkServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomerClientLinkService.CustomerClientLinkServiceClient grpcClient = new CustomerClientLinkService.CustomerClientLinkServiceClient(callInvoker); + return new CustomerClientLinkServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomerClientLinkService client. + /// + public virtual CustomerClientLinkService.CustomerClientLinkServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// + /// Required. The resource name of the customer client link to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerClientLinkAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerClientLinkAsync( + new GetCustomerClientLinkRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// + /// Required. The resource name of the customer client link to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerClientLinkAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomerClientLinkAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// + /// Required. The resource name of the customer client link to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerClientLink GetCustomerClientLink( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerClientLink( + new GetCustomerClientLinkRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerClientLinkAsync( + GetCustomerClientLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerClientLinkAsync( + GetCustomerClientLinkRequest request, + st::CancellationToken cancellationToken) => GetCustomerClientLinkAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerClientLink GetCustomerClientLink( + GetCustomerClientLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer link are being modified. + /// + /// + /// Required. The operation to perform on the individual CustomerClientLink. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerClientLinkAsync( + string customerId, + CustomerClientLinkOperation operation, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerClientLinkAsync( + new MutateCustomerClientLinkRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + }, + callSettings); + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer link are being modified. + /// + /// + /// Required. The operation to perform on the individual CustomerClientLink. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerClientLinkAsync( + string customerId, + CustomerClientLinkOperation operation, + st::CancellationToken cancellationToken) => MutateCustomerClientLinkAsync( + customerId, + operation, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer link are being modified. + /// + /// + /// Required. The operation to perform on the individual CustomerClientLink. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerClientLinkResponse MutateCustomerClientLink( + string customerId, + CustomerClientLinkOperation operation, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerClientLink( + new MutateCustomerClientLinkRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + }, + callSettings); + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerClientLinkAsync( + MutateCustomerClientLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerClientLinkAsync( + MutateCustomerClientLinkRequest request, + st::CancellationToken cancellationToken) => MutateCustomerClientLinkAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerClientLinkResponse MutateCustomerClientLink( + MutateCustomerClientLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomerClientLinkService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomerClientLinkServiceClientImpl : CustomerClientLinkServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomerClientLink; + private readonly gaxgrpc::ApiCall _callMutateCustomerClientLink; + + /// + /// Constructs a client wrapper for the CustomerClientLinkService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomerClientLinkServiceClientImpl(CustomerClientLinkService.CustomerClientLinkServiceClient grpcClient, CustomerClientLinkServiceSettings settings) + { + GrpcClient = grpcClient; + CustomerClientLinkServiceSettings effectiveSettings = settings ?? CustomerClientLinkServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomerClientLink = clientHelper.BuildApiCall( + GrpcClient.GetCustomerClientLinkAsync, GrpcClient.GetCustomerClientLink, effectiveSettings.GetCustomerClientLinkSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCustomerClientLink = clientHelper.BuildApiCall( + GrpcClient.MutateCustomerClientLinkAsync, GrpcClient.MutateCustomerClientLink, effectiveSettings.MutateCustomerClientLinkSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCustomerClientLink); + Modify_GetCustomerClientLinkApiCall(ref _callGetCustomerClientLink); + Modify_ApiCall(ref _callMutateCustomerClientLink); + Modify_MutateCustomerClientLinkApiCall(ref _callMutateCustomerClientLink); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomerClientLinkApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCustomerClientLinkApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomerClientLinkService.CustomerClientLinkServiceClient grpcClient, CustomerClientLinkServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomerClientLinkService client. + /// + public override CustomerClientLinkService.CustomerClientLinkServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomerClientLinkRequest(ref GetCustomerClientLinkRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCustomerClientLinkRequest(ref MutateCustomerClientLinkRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomerClientLinkAsync( + GetCustomerClientLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerClientLinkRequest(ref request, ref callSettings); + return _callGetCustomerClientLink.Async(request, callSettings); + } + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CustomerClientLink GetCustomerClientLink( + GetCustomerClientLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerClientLinkRequest(ref request, ref callSettings); + return _callGetCustomerClientLink.Sync(request, callSettings); + } + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCustomerClientLinkAsync( + MutateCustomerClientLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerClientLinkRequest(ref request, ref callSettings); + return _callMutateCustomerClientLink.Async(request, callSettings); + } + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCustomerClientLinkResponse MutateCustomerClientLink( + MutateCustomerClientLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerClientLinkRequest(ref request, ref callSettings); + return _callMutateCustomerClientLink.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomerClientLinkServiceGrpc.cs b/src/V3/Stubs/CustomerClientLinkServiceGrpc.cs new file mode 100644 index 000000000..f9ff37086 --- /dev/null +++ b/src/V3/Stubs/CustomerClientLinkServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_client_link_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage customer client links. + /// + public static partial class CustomerClientLinkService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomerClientLinkService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomerClientLinkRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientLinkRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CustomerClientLink = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerClientLinkRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerClientLinkResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomerClientLink = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomerClientLink", + __Marshaller_google_ads_googleads_v3_services_GetCustomerClientLinkRequest, + __Marshaller_google_ads_googleads_v3_resources_CustomerClientLink); + + static readonly grpc::Method __Method_MutateCustomerClientLink = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCustomerClientLink", + __Marshaller_google_ads_googleads_v3_services_MutateCustomerClientLinkRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCustomerClientLinkResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerClientLinkServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomerClientLinkService + public abstract partial class CustomerClientLinkServiceBase + { + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomerClientLink(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientLinkRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCustomerClientLink(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomerClientLinkService + public partial class CustomerClientLinkServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomerClientLinkService + /// The channel to use to make remote calls. + public CustomerClientLinkServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomerClientLinkService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomerClientLinkServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomerClientLinkServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomerClientLinkServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink GetCustomerClientLink(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerClientLink(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink GetCustomerClientLink(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomerClientLink, null, options, request); + } + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerClientLinkAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerClientLinkAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested CustomerClientLink in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerClientLinkAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomerClientLink, null, options, request); + } + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResponse MutateCustomerClientLink(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerClientLink(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkResponse MutateCustomerClientLink(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCustomerClientLink, null, options, request); + } + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerClientLinkAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerClientLinkAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or updates a customer client link. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerClientLinkAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerClientLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCustomerClientLink, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomerClientLinkServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomerClientLinkServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomerClientLinkServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomerClientLink, serviceImpl.GetCustomerClientLink) + .AddMethod(__Method_MutateCustomerClientLink, serviceImpl.MutateCustomerClientLink).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomerClientLinkServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomerClientLink, serviceImpl.GetCustomerClientLink); + serviceBinder.AddMethod(__Method_MutateCustomerClientLink, serviceImpl.MutateCustomerClientLink); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomerClientService.cs b/src/V3/Stubs/CustomerClientService.cs new file mode 100644 index 000000000..e3f3e31d8 --- /dev/null +++ b/src/V3/Stubs/CustomerClientService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_client_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/customer_client_service.proto + public static partial class CustomerClientServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/customer_client_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerClientServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9j", + "bGllbnRfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXMaN2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9j", + "dXN0b21lcl9jbGllbnQucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMu", + "cHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2Zp", + "ZWxkX2JlaGF2aW9yLnByb3RvIjYKGEdldEN1c3RvbWVyQ2xpZW50UmVxdWVz", + "dBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIyhAIKFUN1c3RvbWVyQ2xp", + "ZW50U2VydmljZRLNAQoRR2V0Q3VzdG9tZXJDbGllbnQSOi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXRDdXN0b21lckNsaWVudFJlcXVl", + "c3QaMS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ3VzdG9t", + "ZXJDbGllbnQiSYLT5JMCMxIxL3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVy", + "cy8qL2N1c3RvbWVyQ2xpZW50cy8qfdpBDXJlc291cmNlX25hbWUaG8pBGGdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbUKBAgokY29tLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzQhpDdXN0b21lckNsaWVudFNlcnZpY2VQcm90", + "b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CustomerClientReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CustomerClientService.GetCustomerClient][google.ads.googleads.v3.services.CustomerClientService.GetCustomerClient]. + /// + public sealed partial class GetCustomerClientRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomerClientRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerClientServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerClientRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerClientRequest(GetCustomerClientRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerClientRequest Clone() { + return new GetCustomerClientRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the client to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomerClientRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomerClientRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomerClientRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerClientServiceClient.cs b/src/V3/Stubs/CustomerClientServiceClient.cs new file mode 100644 index 000000000..56c5a5fa9 --- /dev/null +++ b/src/V3/Stubs/CustomerClientServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomerClientServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomerClientServiceSettings GetDefault() => new CustomerClientServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomerClientServiceSettings() { } + + private CustomerClientServiceSettings(CustomerClientServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomerClientSettings = existing.GetCustomerClientSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomerClientServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomerClientServiceClient.GetCustomerClient and CustomerClientServiceClient.GetCustomerClientAsync. + /// + /// + /// The default CustomerClientServiceClient.GetCustomerClient and + /// CustomerClientServiceClient.GetCustomerClientAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomerClientSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomerClientServiceSettings Clone() => new CustomerClientServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomerClientServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomerClientServiceSettings Settings { get; set; } + + /// + public override CustomerClientServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomerClientServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomerClientServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomerClientServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomerClientServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomerClientServiceClient.ChannelPool; + } + + /// + /// CustomerClientService client wrapper, for convenient use. + /// + public abstract partial class CustomerClientServiceClient + { + /// + /// The default endpoint for the CustomerClientService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomerClientService scopes. + /// + /// + /// The default CustomerClientService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerClientServiceClient client = await CustomerClientServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerClientServiceClient.DefaultEndpoint.Host, CustomerClientServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerClientServiceClient client = CustomerClientServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomerClientServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerClientServiceClient client = CustomerClientServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerClientServiceClient.DefaultEndpoint.Host, CustomerClientServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerClientServiceClient client = CustomerClientServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomerClientServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomerClientServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerClientServiceClient Create(grpccore::Channel channel, CustomerClientServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerClientServiceClient Create(grpccore::CallInvoker callInvoker, CustomerClientServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomerClientService.CustomerClientServiceClient grpcClient = new CustomerClientService.CustomerClientServiceClient(callInvoker); + return new CustomerClientServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomerClientService client. + /// + public virtual CustomerClientService.CustomerClientServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested client in full detail. + /// + /// + /// Required. The resource name of the client to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerClientAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerClientAsync( + new GetCustomerClientRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested client in full detail. + /// + /// + /// Required. The resource name of the client to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerClientAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomerClientAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested client in full detail. + /// + /// + /// Required. The resource name of the client to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerClient GetCustomerClient( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerClient( + new GetCustomerClientRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested client in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerClientAsync( + GetCustomerClientRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested client in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerClientAsync( + GetCustomerClientRequest request, + st::CancellationToken cancellationToken) => GetCustomerClientAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested client in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerClient GetCustomerClient( + GetCustomerClientRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomerClientService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomerClientServiceClientImpl : CustomerClientServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomerClient; + + /// + /// Constructs a client wrapper for the CustomerClientService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomerClientServiceClientImpl(CustomerClientService.CustomerClientServiceClient grpcClient, CustomerClientServiceSettings settings) + { + GrpcClient = grpcClient; + CustomerClientServiceSettings effectiveSettings = settings ?? CustomerClientServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomerClient = clientHelper.BuildApiCall( + GrpcClient.GetCustomerClientAsync, GrpcClient.GetCustomerClient, effectiveSettings.GetCustomerClientSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetCustomerClient); + Modify_GetCustomerClientApiCall(ref _callGetCustomerClient); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomerClientApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomerClientService.CustomerClientServiceClient grpcClient, CustomerClientServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomerClientService client. + /// + public override CustomerClientService.CustomerClientServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomerClientRequest(ref GetCustomerClientRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested client in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomerClientAsync( + GetCustomerClientRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerClientRequest(ref request, ref callSettings); + return _callGetCustomerClient.Async(request, callSettings); + } + + /// + /// Returns the requested client in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CustomerClient GetCustomerClient( + GetCustomerClientRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerClientRequest(ref request, ref callSettings); + return _callGetCustomerClient.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomerClientServiceGrpc.cs b/src/V3/Stubs/CustomerClientServiceGrpc.cs new file mode 100644 index 000000000..892a11868 --- /dev/null +++ b/src/V3/Stubs/CustomerClientServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_client_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to get clients in a customer's hierarchy. + /// + public static partial class CustomerClientService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomerClientService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomerClientRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CustomerClient = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CustomerClient.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomerClient = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomerClient", + __Marshaller_google_ads_googleads_v3_services_GetCustomerClientRequest, + __Marshaller_google_ads_googleads_v3_resources_CustomerClient); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerClientServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomerClientService + public abstract partial class CustomerClientServiceBase + { + /// + /// Returns the requested client in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomerClient(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomerClientService + public partial class CustomerClientServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomerClientService + /// The channel to use to make remote calls. + public CustomerClientServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomerClientService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomerClientServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomerClientServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomerClientServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested client in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerClient GetCustomerClient(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerClient(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested client in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerClient GetCustomerClient(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomerClient, null, options, request); + } + /// + /// Returns the requested client in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerClientAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerClientAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested client in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerClientAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerClientRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomerClient, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomerClientServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomerClientServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomerClientServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomerClient, serviceImpl.GetCustomerClient).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomerClientServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomerClient, serviceImpl.GetCustomerClient); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomerError.cs b/src/V3/Stubs/CustomerError.cs new file mode 100644 index 000000000..0da08ecfb --- /dev/null +++ b/src/V3/Stubs/CustomerError.cs @@ -0,0 +1,188 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/customer_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/customer_error.proto + public static partial class CustomerErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/customer_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY3VzdG9tZXJfZXJy", + "b3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJ4ChFDdXN0b21lckVycm9yRW51", + "bSJjCg1DdXN0b21lckVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9X", + "ThABEhwKGFNUQVRVU19DSEFOR0VfRElTQUxMT1dFRBACEhYKEkFDQ09VTlRf", + "Tk9UX1NFVF9VUBADQu0BCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZXJyb3JzQhJDdXN0b21lckVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5v", + "cmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9y", + "cztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJv", + "cnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomerErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CustomerErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomerErrorEnum.Types.CustomerError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible customer errors. + /// + public sealed partial class CustomerErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CustomerErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerErrorEnum(CustomerErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerErrorEnum Clone() { + return new CustomerErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomerErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Set of errors that are related to requests dealing with Customer. + /// Next id: 26 + /// + public enum CustomerError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Customer status is not allowed to be changed from DRAFT and CLOSED. + /// Currency code and at least one of country code and time zone needs to be + /// set when status is changed to ENABLED. + /// + [pbr::OriginalName("STATUS_CHANGE_DISALLOWED")] StatusChangeDisallowed = 2, + /// + /// CustomerService cannot get a customer that has not been fully set up. + /// + [pbr::OriginalName("ACCOUNT_NOT_SET_UP")] AccountNotSetUp = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerExtensionSetting.cs b/src/V3/Stubs/CustomerExtensionSetting.cs new file mode 100644 index 000000000..b5a6e4cf6 --- /dev/null +++ b/src/V3/Stubs/CustomerExtensionSetting.cs @@ -0,0 +1,293 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/customer_extension_setting.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/customer_extension_setting.proto + public static partial class CustomerExtensionSettingReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/customer_extension_setting.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerExtensionSettingReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJf", + "ZXh0ZW5zaW9uX3NldHRpbmcucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMv", + "ZXh0ZW5zaW9uX3NldHRpbmdfZGV2aWNlLnByb3RvGjJnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcy9leHRlbnNpb25fdHlwZS5wcm90bxofZ29vZ2xl", + "L2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJj", + "ZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvIp8EChhDdXN0b21lckV4dGVuc2lv", + "blNldHRpbmcSUAoNcmVzb3VyY2VfbmFtZRgBIAEoCUI54EEF+kEzCjFnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb20vQ3VzdG9tZXJFeHRlbnNpb25TZXR0aW5n", + "ElsKDmV4dGVuc2lvbl90eXBlGAIgASgOMj4uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZW51bXMuRXh0ZW5zaW9uVHlwZUVudW0uRXh0ZW5zaW9uVHlwZUID", + "4EEFEmsKFGV4dGVuc2lvbl9mZWVkX2l0ZW1zGAMgAygLMhwuZ29vZ2xlLnBy", + "b3RvYnVmLlN0cmluZ1ZhbHVlQi/6QSwKKmdvb2dsZWFkcy5nb29nbGVhcGlz", + "LmNvbS9FeHRlbnNpb25GZWVkSXRlbRJgCgZkZXZpY2UYBCABKA4yUC5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5FeHRlbnNpb25TZXR0aW5nRGV2", + "aWNlRW51bS5FeHRlbnNpb25TZXR0aW5nRGV2aWNlOoQB6kGAAQoxZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tL0N1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZxJL", + "Y3VzdG9tZXJzL3tjdXN0b21lcn0vY3VzdG9tZXJFeHRlbnNpb25TZXR0aW5n", + "cy97Y3VzdG9tZXJfZXh0ZW5zaW9uX3NldHRpbmd9QooCCiVjb20uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzQh1DdXN0b21lckV4dGVuc2lv", + "blNldHRpbmdQcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9n", + "b29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNl", + "c6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oC", + "IUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting), global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting.Parser, new[]{ "ResourceName", "ExtensionType", "ExtensionFeedItems", "Device" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A customer extension setting. + /// + public sealed partial class CustomerExtensionSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerExtensionSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSettingReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerExtensionSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerExtensionSetting(CustomerExtensionSetting other) : this() { + resourceName_ = other.resourceName_; + extensionType_ = other.extensionType_; + extensionFeedItems_ = other.extensionFeedItems_.Clone(); + device_ = other.device_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerExtensionSetting Clone() { + return new CustomerExtensionSetting(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the customer extension setting. + /// CustomerExtensionSetting resource names have the form: + /// + /// `customers/{customer_id}/customerExtensionSettings/{extension_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "extension_type" field. + public const int ExtensionTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType extensionType_ = 0; + /// + /// Immutable. The extension type of the customer extension setting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType ExtensionType { + get { return extensionType_; } + set { + extensionType_ = value; + } + } + + /// Field number for the "extension_feed_items" field. + public const int ExtensionFeedItemsFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_extensionFeedItems_codec + = pb::FieldCodec.ForClassWrapper(26); + private readonly pbc::RepeatedField extensionFeedItems_ = new pbc::RepeatedField(); + /// + /// The resource names of the extension feed items to serve under the customer. + /// ExtensionFeedItem resource names have the form: + /// + /// `customers/{customer_id}/extensionFeedItems/{feed_item_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ExtensionFeedItems { + get { return extensionFeedItems_; } + } + + /// Field number for the "device" field. + public const int DeviceFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice device_ = 0; + /// + /// The device for which the extensions will serve. Optional. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice Device { + get { return device_; } + set { + device_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerExtensionSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerExtensionSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (ExtensionType != other.ExtensionType) return false; + if(!extensionFeedItems_.Equals(other.extensionFeedItems_)) return false; + if (Device != other.Device) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (ExtensionType != 0) hash ^= ExtensionType.GetHashCode(); + hash ^= extensionFeedItems_.GetHashCode(); + if (Device != 0) hash ^= Device.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (ExtensionType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) ExtensionType); + } + extensionFeedItems_.WriteTo(output, _repeated_extensionFeedItems_codec); + if (Device != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) Device); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (ExtensionType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ExtensionType); + } + size += extensionFeedItems_.CalculateSize(_repeated_extensionFeedItems_codec); + if (Device != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Device); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerExtensionSetting other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.ExtensionType != 0) { + ExtensionType = other.ExtensionType; + } + extensionFeedItems_.Add(other.extensionFeedItems_); + if (other.Device != 0) { + Device = other.Device; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 16: { + ExtensionType = (global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType) input.ReadEnum(); + break; + } + case 26: { + extensionFeedItems_.AddEntriesFrom(input, _repeated_extensionFeedItems_codec); + break; + } + case 32: { + Device = (global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerExtensionSettingService.cs b/src/V3/Stubs/CustomerExtensionSettingService.cs new file mode 100644 index 000000000..8ef9dc9d9 --- /dev/null +++ b/src/V3/Stubs/CustomerExtensionSettingService.cs @@ -0,0 +1,1044 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_extension_setting_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/customer_extension_setting_service.proto + public static partial class CustomerExtensionSettingServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/customer_extension_setting_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerExtensionSettingServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cklnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9l", + "eHRlbnNpb25fc2V0dGluZ19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcxpCZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "cmVzb3VyY2VzL2N1c3RvbWVyX2V4dGVuc2lvbl9zZXR0aW5nLnByb3RvGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVu", + "dC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29v", + "Z2xlL3Byb3RvYnVmL2ZpZWxkX21hc2sucHJvdG8aF2dvb2dsZS9ycGMvc3Rh", + "dHVzLnByb3RvIkAKIkdldEN1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ1JlcXVl", + "c3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEoCUID4EECItABCiZNdXRhdGVDdXN0", + "b21lckV4dGVuc2lvblNldHRpbmdzUmVxdWVzdBIYCgtjdXN0b21lcl9pZBgB", + "IAEoCUID4EECElwKCm9wZXJhdGlvbnMYAiADKAsyQy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcy5DdXN0b21lckV4dGVuc2lvblNldHRpbmdP", + "cGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUYAyABKAgSFQoNdmFs", + "aWRhdGVfb25seRgEIAEoCCKRAgohQ3VzdG9tZXJFeHRlbnNpb25TZXR0aW5n", + "T3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAQgASgLMhouZ29vZ2xlLnByb3Rv", + "YnVmLkZpZWxkTWFzaxJNCgZjcmVhdGUYASABKAsyOy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5yZXNvdXJjZXMuQ3VzdG9tZXJFeHRlbnNpb25TZXR0aW5n", + "SAASTQoGdXBkYXRlGAIgASgLMjsuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzLkN1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ0gAEhAKBnJlbW92", + "ZRgDIAEoCUgAQgsKCW9wZXJhdGlvbiK1AQonTXV0YXRlQ3VzdG9tZXJFeHRl", + "bnNpb25TZXR0aW5nc1Jlc3BvbnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJv", + "chgDIAEoCzISLmdvb2dsZS5ycGMuU3RhdHVzElcKB3Jlc3VsdHMYAiADKAsy", + "Ri5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDdXN0", + "b21lckV4dGVuc2lvblNldHRpbmdSZXN1bHQiPQokTXV0YXRlQ3VzdG9tZXJF", + "eHRlbnNpb25TZXR0aW5nUmVzdWx0EhUKDXJlc291cmNlX25hbWUYASABKAky", + "0wQKH0N1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ1NlcnZpY2US9QEKG0dldEN1", + "c3RvbWVyRXh0ZW5zaW9uU2V0dGluZxJELmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLkdldEN1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ1JlcXVl", + "c3QaOy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ3VzdG9t", + "ZXJFeHRlbnNpb25TZXR0aW5nIlOC0+STAj0SOy92My97cmVzb3VyY2VfbmFt", + "ZT1jdXN0b21lcnMvKi9jdXN0b21lckV4dGVuc2lvblNldHRpbmdzLyp92kEN", + "cmVzb3VyY2VfbmFtZRKaAgofTXV0YXRlQ3VzdG9tZXJFeHRlbnNpb25TZXR0", + "aW5ncxJILmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0", + "ZUN1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ3NSZXF1ZXN0GkkuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ3VzdG9tZXJFeHRlbnNp", + "b25TZXR0aW5nc1Jlc3BvbnNlImKC0+STAkMiPi92My9jdXN0b21lcnMve2N1", + "c3RvbWVyX2lkPSp9L2N1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ3M6bXV0YXRl", + "OgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9ucxobykEYZ29vZ2xlYWRzLmdv", + "b2dsZWFwaXMuY29tQosCCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXNCJEN1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ1NlcnZpY2VQcm90", + "b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSettingReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomerExtensionSettingRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomerExtensionSettingRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingOperation), global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingResult), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [CustomerExtensionSettingService.GetCustomerExtensionSetting][google.ads.googleads.v3.services.CustomerExtensionSettingService.GetCustomerExtensionSetting]. + /// + public sealed partial class GetCustomerExtensionSettingRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomerExtensionSettingRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerExtensionSettingRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerExtensionSettingRequest(GetCustomerExtensionSettingRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerExtensionSettingRequest Clone() { + return new GetCustomerExtensionSettingRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the customer extension setting to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomerExtensionSettingRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomerExtensionSettingRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomerExtensionSettingRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [CustomerExtensionSettingService.MutateCustomerExtensionSettings][google.ads.googleads.v3.services.CustomerExtensionSettingService.MutateCustomerExtensionSettings]. + /// + public sealed partial class MutateCustomerExtensionSettingsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerExtensionSettingsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingsRequest(MutateCustomerExtensionSettingsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingsRequest Clone() { + return new MutateCustomerExtensionSettingsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose customer extension settings are being + /// modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual customer extension + /// settings. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerExtensionSettingsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerExtensionSettingsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerExtensionSettingsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a customer extension setting. + /// + public sealed partial class CustomerExtensionSettingOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerExtensionSettingOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerExtensionSettingOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerExtensionSettingOperation(CustomerExtensionSettingOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerExtensionSettingOperation Clone() { + return new CustomerExtensionSettingOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new customer + /// extension setting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The customer extension setting is expected to have a + /// valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed customer extension + /// setting is expected, in this format: + /// + /// `customers/{customer_id}/customerExtensionSettings/{extension_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerExtensionSettingOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerExtensionSettingOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerExtensionSettingOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a customer extension setting mutate. + /// + public sealed partial class MutateCustomerExtensionSettingsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerExtensionSettingsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingsResponse(MutateCustomerExtensionSettingsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingsResponse Clone() { + return new MutateCustomerExtensionSettingsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerExtensionSettingsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerExtensionSettingsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerExtensionSettingsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the customer extension setting mutate. + /// + public sealed partial class MutateCustomerExtensionSettingResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerExtensionSettingResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingResult(MutateCustomerExtensionSettingResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerExtensionSettingResult Clone() { + return new MutateCustomerExtensionSettingResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerExtensionSettingResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerExtensionSettingResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerExtensionSettingResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerExtensionSettingServiceClient.cs b/src/V3/Stubs/CustomerExtensionSettingServiceClient.cs new file mode 100644 index 000000000..5c877335c --- /dev/null +++ b/src/V3/Stubs/CustomerExtensionSettingServiceClient.cs @@ -0,0 +1,910 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomerExtensionSettingServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomerExtensionSettingServiceSettings GetDefault() => new CustomerExtensionSettingServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomerExtensionSettingServiceSettings() { } + + private CustomerExtensionSettingServiceSettings(CustomerExtensionSettingServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomerExtensionSettingSettings = existing.GetCustomerExtensionSettingSettings; + MutateCustomerExtensionSettingsSettings = existing.MutateCustomerExtensionSettingsSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomerExtensionSettingServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomerExtensionSettingServiceClient.GetCustomerExtensionSetting and CustomerExtensionSettingServiceClient.GetCustomerExtensionSettingAsync. + /// + /// + /// The default CustomerExtensionSettingServiceClient.GetCustomerExtensionSetting and + /// CustomerExtensionSettingServiceClient.GetCustomerExtensionSettingAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomerExtensionSettingSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerExtensionSettingServiceClient.MutateCustomerExtensionSettings and CustomerExtensionSettingServiceClient.MutateCustomerExtensionSettingsAsync. + /// + /// + /// The default CustomerExtensionSettingServiceClient.MutateCustomerExtensionSettings and + /// CustomerExtensionSettingServiceClient.MutateCustomerExtensionSettingsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCustomerExtensionSettingsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomerExtensionSettingServiceSettings Clone() => new CustomerExtensionSettingServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomerExtensionSettingServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomerExtensionSettingServiceSettings Settings { get; set; } + + /// + public override CustomerExtensionSettingServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomerExtensionSettingServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomerExtensionSettingServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomerExtensionSettingServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomerExtensionSettingServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomerExtensionSettingServiceClient.ChannelPool; + } + + /// + /// CustomerExtensionSettingService client wrapper, for convenient use. + /// + public abstract partial class CustomerExtensionSettingServiceClient + { + /// + /// The default endpoint for the CustomerExtensionSettingService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomerExtensionSettingService scopes. + /// + /// + /// The default CustomerExtensionSettingService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerExtensionSettingServiceClient client = await CustomerExtensionSettingServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerExtensionSettingServiceClient.DefaultEndpoint.Host, CustomerExtensionSettingServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerExtensionSettingServiceClient client = CustomerExtensionSettingServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomerExtensionSettingServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerExtensionSettingServiceClient client = CustomerExtensionSettingServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerExtensionSettingServiceClient.DefaultEndpoint.Host, CustomerExtensionSettingServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerExtensionSettingServiceClient client = CustomerExtensionSettingServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomerExtensionSettingServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomerExtensionSettingServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerExtensionSettingServiceClient Create(grpccore::Channel channel, CustomerExtensionSettingServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerExtensionSettingServiceClient Create(grpccore::CallInvoker callInvoker, CustomerExtensionSettingServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomerExtensionSettingService.CustomerExtensionSettingServiceClient grpcClient = new CustomerExtensionSettingService.CustomerExtensionSettingServiceClient(callInvoker); + return new CustomerExtensionSettingServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomerExtensionSettingService client. + /// + public virtual CustomerExtensionSettingService.CustomerExtensionSettingServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// + /// Required. The resource name of the customer extension setting to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerExtensionSettingAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerExtensionSettingAsync( + new GetCustomerExtensionSettingRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// + /// Required. The resource name of the customer extension setting to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerExtensionSettingAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomerExtensionSettingAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// + /// Required. The resource name of the customer extension setting to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerExtensionSetting GetCustomerExtensionSetting( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerExtensionSetting( + new GetCustomerExtensionSettingRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerExtensionSettingAsync( + GetCustomerExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerExtensionSettingAsync( + GetCustomerExtensionSettingRequest request, + st::CancellationToken cancellationToken) => GetCustomerExtensionSettingAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerExtensionSetting GetCustomerExtensionSetting( + GetCustomerExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual customer extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerExtensionSettingsAsync( + new MutateCustomerExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual customer extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCustomerExtensionSettingsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual customer extension + /// settings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerExtensionSettingsResponse MutateCustomerExtensionSettings( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerExtensionSettings( + new MutateCustomerExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual customer extension + /// settings. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerExtensionSettingsAsync( + new MutateCustomerExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual customer extension + /// settings. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerExtensionSettingsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCustomerExtensionSettingsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer extension settings are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual customer extension + /// settings. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerExtensionSettingsResponse MutateCustomerExtensionSettings( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerExtensionSettings( + new MutateCustomerExtensionSettingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerExtensionSettingsAsync( + MutateCustomerExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerExtensionSettingsAsync( + MutateCustomerExtensionSettingsRequest request, + st::CancellationToken cancellationToken) => MutateCustomerExtensionSettingsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerExtensionSettingsResponse MutateCustomerExtensionSettings( + MutateCustomerExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomerExtensionSettingService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomerExtensionSettingServiceClientImpl : CustomerExtensionSettingServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomerExtensionSetting; + private readonly gaxgrpc::ApiCall _callMutateCustomerExtensionSettings; + + /// + /// Constructs a client wrapper for the CustomerExtensionSettingService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomerExtensionSettingServiceClientImpl(CustomerExtensionSettingService.CustomerExtensionSettingServiceClient grpcClient, CustomerExtensionSettingServiceSettings settings) + { + GrpcClient = grpcClient; + CustomerExtensionSettingServiceSettings effectiveSettings = settings ?? CustomerExtensionSettingServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomerExtensionSetting = clientHelper.BuildApiCall( + GrpcClient.GetCustomerExtensionSettingAsync, GrpcClient.GetCustomerExtensionSetting, effectiveSettings.GetCustomerExtensionSettingSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCustomerExtensionSettings = clientHelper.BuildApiCall( + GrpcClient.MutateCustomerExtensionSettingsAsync, GrpcClient.MutateCustomerExtensionSettings, effectiveSettings.MutateCustomerExtensionSettingsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCustomerExtensionSetting); + Modify_GetCustomerExtensionSettingApiCall(ref _callGetCustomerExtensionSetting); + Modify_ApiCall(ref _callMutateCustomerExtensionSettings); + Modify_MutateCustomerExtensionSettingsApiCall(ref _callMutateCustomerExtensionSettings); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomerExtensionSettingApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCustomerExtensionSettingsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomerExtensionSettingService.CustomerExtensionSettingServiceClient grpcClient, CustomerExtensionSettingServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomerExtensionSettingService client. + /// + public override CustomerExtensionSettingService.CustomerExtensionSettingServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomerExtensionSettingRequest(ref GetCustomerExtensionSettingRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCustomerExtensionSettingsRequest(ref MutateCustomerExtensionSettingsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomerExtensionSettingAsync( + GetCustomerExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerExtensionSettingRequest(ref request, ref callSettings); + return _callGetCustomerExtensionSetting.Async(request, callSettings); + } + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CustomerExtensionSetting GetCustomerExtensionSetting( + GetCustomerExtensionSettingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerExtensionSettingRequest(ref request, ref callSettings); + return _callGetCustomerExtensionSetting.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCustomerExtensionSettingsAsync( + MutateCustomerExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerExtensionSettingsRequest(ref request, ref callSettings); + return _callMutateCustomerExtensionSettings.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCustomerExtensionSettingsResponse MutateCustomerExtensionSettings( + MutateCustomerExtensionSettingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerExtensionSettingsRequest(ref request, ref callSettings); + return _callMutateCustomerExtensionSettings.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomerExtensionSettingServiceGrpc.cs b/src/V3/Stubs/CustomerExtensionSettingServiceGrpc.cs new file mode 100644 index 000000000..3f707472e --- /dev/null +++ b/src/V3/Stubs/CustomerExtensionSettingServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_extension_setting_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage customer extension settings. + /// + public static partial class CustomerExtensionSettingService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomerExtensionSettingService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomerExtensionSettingRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomerExtensionSettingRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CustomerExtensionSetting = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerExtensionSettingsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerExtensionSettingsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomerExtensionSetting = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomerExtensionSetting", + __Marshaller_google_ads_googleads_v3_services_GetCustomerExtensionSettingRequest, + __Marshaller_google_ads_googleads_v3_resources_CustomerExtensionSetting); + + static readonly grpc::Method __Method_MutateCustomerExtensionSettings = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCustomerExtensionSettings", + __Marshaller_google_ads_googleads_v3_services_MutateCustomerExtensionSettingsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCustomerExtensionSettingsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomerExtensionSettingService + public abstract partial class CustomerExtensionSettingServiceBase + { + /// + /// Returns the requested customer extension setting in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomerExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetCustomerExtensionSettingRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCustomerExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomerExtensionSettingService + public partial class CustomerExtensionSettingServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomerExtensionSettingService + /// The channel to use to make remote calls. + public CustomerExtensionSettingServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomerExtensionSettingService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomerExtensionSettingServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomerExtensionSettingServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomerExtensionSettingServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested customer extension setting in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting GetCustomerExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetCustomerExtensionSettingRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerExtensionSetting(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested customer extension setting in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting GetCustomerExtensionSetting(global::Google.Ads.GoogleAds.V3.Services.GetCustomerExtensionSettingRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomerExtensionSetting, null, options, request); + } + /// + /// Returns the requested customer extension setting in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerExtensionSettingAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerExtensionSettingRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerExtensionSettingAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested customer extension setting in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerExtensionSettingAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerExtensionSettingRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomerExtensionSetting, null, options, request); + } + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsResponse MutateCustomerExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerExtensionSettings(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsResponse MutateCustomerExtensionSettings(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCustomerExtensionSettings, null, options, request); + } + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerExtensionSettingsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerExtensionSettingsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes customer extension settings. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerExtensionSettingsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCustomerExtensionSettings, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomerExtensionSettingServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomerExtensionSettingServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomerExtensionSettingServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomerExtensionSetting, serviceImpl.GetCustomerExtensionSetting) + .AddMethod(__Method_MutateCustomerExtensionSettings, serviceImpl.MutateCustomerExtensionSettings).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomerExtensionSettingServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomerExtensionSetting, serviceImpl.GetCustomerExtensionSetting); + serviceBinder.AddMethod(__Method_MutateCustomerExtensionSettings, serviceImpl.MutateCustomerExtensionSettings); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomerFeed.cs b/src/V3/Stubs/CustomerFeed.cs new file mode 100644 index 000000000..318006649 --- /dev/null +++ b/src/V3/Stubs/CustomerFeed.cs @@ -0,0 +1,338 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/customer_feed.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/customer_feed.proto + public static partial class CustomerFeedReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/customer_feed.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerFeedReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJf", + "ZmVlZC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "GjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vbWF0Y2hpbmdfZnVu", + "Y3Rpb24ucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2Zl", + "ZWRfbGlua19zdGF0dXMucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL3BsYWNlaG9sZGVyX3R5cGUucHJvdG8aH2dvb2dsZS9hcGkvZmll", + "bGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8a", + "Hmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9h", + "bm5vdGF0aW9ucy5wcm90byKKBAoMQ3VzdG9tZXJGZWVkEkQKDXJlc291cmNl", + "X25hbWUYASABKAlCLeBBBfpBJwolZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29t", + "L0N1c3RvbWVyRmVlZBJRCgRmZWVkGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlQiXgQQX6QR8KHWdvb2dsZWFkcy5nb29nbGVhcGlzLmNv", + "bS9GZWVkEl0KEXBsYWNlaG9sZGVyX3R5cGVzGAMgAygOMkIuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMuUGxhY2Vob2xkZXJUeXBlRW51bS5QbGFj", + "ZWhvbGRlclR5cGUSSwoRbWF0Y2hpbmdfZnVuY3Rpb24YBCABKAsyMC5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uTWF0Y2hpbmdGdW5jdGlvbhJV", + "CgZzdGF0dXMYBSABKA4yQC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cy5GZWVkTGlua1N0YXR1c0VudW0uRmVlZExpbmtTdGF0dXNCA+BBAzpe6kFb", + "CiVnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ3VzdG9tZXJGZWVkEjJjdXN0", + "b21lcnMve2N1c3RvbWVyfS9jdXN0b21lckZlZWRzL3tjdXN0b21lcl9mZWVk", + "fUL+AQolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IR", + "Q3VzdG9tZXJGZWVkUHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNv", + "dXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJj", + "ZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.MatchingFunctionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed), global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed.Parser, new[]{ "ResourceName", "Feed", "PlaceholderTypes", "MatchingFunction", "Status" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A customer feed. + /// + public sealed partial class CustomerFeed : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerFeed()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerFeedReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeed() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeed(CustomerFeed other) : this() { + resourceName_ = other.resourceName_; + Feed = other.Feed; + placeholderTypes_ = other.placeholderTypes_.Clone(); + matchingFunction_ = other.matchingFunction_ != null ? other.matchingFunction_.Clone() : null; + status_ = other.status_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeed Clone() { + return new CustomerFeed(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the customer feed. + /// Customer feed resource names have the form: + /// + /// `customers/{customer_id}/customerFeeds/{feed_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "feed" field. + public const int FeedFieldNumber = 2; + private static readonly pb::FieldCodec _single_feed_codec = pb::FieldCodec.ForClassWrapper(18); + private string feed_; + /// + /// Immutable. The feed being linked to the customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Feed { + get { return feed_; } + set { + feed_ = value; + } + } + + + /// Field number for the "placeholder_types" field. + public const int PlaceholderTypesFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_placeholderTypes_codec + = pb::FieldCodec.ForEnum(26, x => (int) x, x => (global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType) x); + private readonly pbc::RepeatedField placeholderTypes_ = new pbc::RepeatedField(); + /// + /// Indicates which placeholder types the feed may populate under the connected + /// customer. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PlaceholderTypes { + get { return placeholderTypes_; } + } + + /// Field number for the "matching_function" field. + public const int MatchingFunctionFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Common.MatchingFunction matchingFunction_; + /// + /// Matching function associated with the CustomerFeed. + /// The matching function is used to filter the set of feed items selected. + /// Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MatchingFunction MatchingFunction { + get { return matchingFunction_; } + set { + matchingFunction_ = value; + } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus status_ = 0; + /// + /// Output only. Status of the customer feed. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerFeed); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerFeed other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Feed != other.Feed) return false; + if(!placeholderTypes_.Equals(other.placeholderTypes_)) return false; + if (!object.Equals(MatchingFunction, other.MatchingFunction)) return false; + if (Status != other.Status) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (feed_ != null) hash ^= Feed.GetHashCode(); + hash ^= placeholderTypes_.GetHashCode(); + if (matchingFunction_ != null) hash ^= MatchingFunction.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (feed_ != null) { + _single_feed_codec.WriteTagAndValue(output, Feed); + } + placeholderTypes_.WriteTo(output, _repeated_placeholderTypes_codec); + if (matchingFunction_ != null) { + output.WriteRawTag(34); + output.WriteMessage(MatchingFunction); + } + if (Status != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Status); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (feed_ != null) { + size += _single_feed_codec.CalculateSizeWithTag(Feed); + } + size += placeholderTypes_.CalculateSize(_repeated_placeholderTypes_codec); + if (matchingFunction_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MatchingFunction); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerFeed other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.feed_ != null) { + if (feed_ == null || other.Feed != "") { + Feed = other.Feed; + } + } + placeholderTypes_.Add(other.placeholderTypes_); + if (other.matchingFunction_ != null) { + if (matchingFunction_ == null) { + MatchingFunction = new global::Google.Ads.GoogleAds.V3.Common.MatchingFunction(); + } + MatchingFunction.MergeFrom(other.MatchingFunction); + } + if (other.Status != 0) { + Status = other.Status; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_feed_codec.Read(input); + if (feed_ == null || value != "") { + Feed = value; + } + break; + } + case 26: + case 24: { + placeholderTypes_.AddEntriesFrom(input, _repeated_placeholderTypes_codec); + break; + } + case 34: { + if (matchingFunction_ == null) { + MatchingFunction = new global::Google.Ads.GoogleAds.V3.Common.MatchingFunction(); + } + input.ReadMessage(MatchingFunction); + break; + } + case 40: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerFeedError.cs b/src/V3/Stubs/CustomerFeedError.cs new file mode 100644 index 000000000..d2025ac85 --- /dev/null +++ b/src/V3/Stubs/CustomerFeedError.cs @@ -0,0 +1,212 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/customer_feed_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/customer_feed_error.proto + public static partial class CustomerFeedErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/customer_feed_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerFeedErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY3VzdG9tZXJfZmVl", + "ZF9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvcCChVDdXN0b21lckZl", + "ZWRFcnJvckVudW0i3QIKEUN1c3RvbWVyRmVlZEVycm9yEg8KC1VOU1BFQ0lG", + "SUVEEAASCwoHVU5LTk9XThABEiwKKEZFRURfQUxSRUFEWV9FWElTVFNfRk9S", + "X1BMQUNFSE9MREVSX1RZUEUQAhIiCh5DQU5OT1RfQ1JFQVRFX0ZPUl9SRU1P", + "VkVEX0ZFRUQQAxIwCixDQU5OT1RfQ1JFQVRFX0FMUkVBRFlfRVhJU1RJTkdf", + "Q1VTVE9NRVJfRkVFRBAEEicKI0NBTk5PVF9NT0RJRllfUkVNT1ZFRF9DVVNU", + "T01FUl9GRUVEEAUSHAoYSU5WQUxJRF9QTEFDRUhPTERFUl9UWVBFEAYSLAoo", + "TUlTU0lOR19GRUVETUFQUElOR19GT1JfUExBQ0VIT0xERVJfVFlQRRAHEjEK", + "LVBMQUNFSE9MREVSX1RZUEVfTk9UX0FMTE9XRURfT05fQ1VTVE9NRVJfRkVF", + "RBAIQvEBCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQhZD", + "dXN0b21lckZlZWRFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJy", + "b3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIe", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomerFeedErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CustomerFeedErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomerFeedErrorEnum.Types.CustomerFeedError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible customer feed errors. + /// + public sealed partial class CustomerFeedErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerFeedErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CustomerFeedErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeedErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeedErrorEnum(CustomerFeedErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeedErrorEnum Clone() { + return new CustomerFeedErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerFeedErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerFeedErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerFeedErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomerFeedErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible customer feed errors. + /// + public enum CustomerFeedError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// An active feed already exists for this customer and place holder type. + /// + [pbr::OriginalName("FEED_ALREADY_EXISTS_FOR_PLACEHOLDER_TYPE")] FeedAlreadyExistsForPlaceholderType = 2, + /// + /// The specified feed is removed. + /// + [pbr::OriginalName("CANNOT_CREATE_FOR_REMOVED_FEED")] CannotCreateForRemovedFeed = 3, + /// + /// The CustomerFeed already exists. Update should be used to modify the + /// existing CustomerFeed. + /// + [pbr::OriginalName("CANNOT_CREATE_ALREADY_EXISTING_CUSTOMER_FEED")] CannotCreateAlreadyExistingCustomerFeed = 4, + /// + /// Cannot update removed customer feed. + /// + [pbr::OriginalName("CANNOT_MODIFY_REMOVED_CUSTOMER_FEED")] CannotModifyRemovedCustomerFeed = 5, + /// + /// Invalid placeholder type. + /// + [pbr::OriginalName("INVALID_PLACEHOLDER_TYPE")] InvalidPlaceholderType = 6, + /// + /// Feed mapping for this placeholder type does not exist. + /// + [pbr::OriginalName("MISSING_FEEDMAPPING_FOR_PLACEHOLDER_TYPE")] MissingFeedmappingForPlaceholderType = 7, + /// + /// Placeholder not allowed at the account level. + /// + [pbr::OriginalName("PLACEHOLDER_TYPE_NOT_ALLOWED_ON_CUSTOMER_FEED")] PlaceholderTypeNotAllowedOnCustomerFeed = 8, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerFeedService.cs b/src/V3/Stubs/CustomerFeedService.cs new file mode 100644 index 000000000..58f03705f --- /dev/null +++ b/src/V3/Stubs/CustomerFeedService.cs @@ -0,0 +1,1033 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_feed_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/customer_feed_service.proto + public static partial class CustomerFeedServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/customer_feed_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerFeedServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9m", + "ZWVkX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzGjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3Vz", + "dG9tZXJfZmVlZC5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRf", + "YmVoYXZpb3IucHJvdG8aIGdvb2dsZS9wcm90b2J1Zi9maWVsZF9tYXNrLnBy", + "b3RvGhdnb29nbGUvcnBjL3N0YXR1cy5wcm90byI0ChZHZXRDdXN0b21lckZl", + "ZWRSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiK4AQoaTXV0", + "YXRlQ3VzdG9tZXJGZWVkc1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlC", + "A+BBAhJQCgpvcGVyYXRpb25zGAIgAygLMjcuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuQ3VzdG9tZXJGZWVkT3BlcmF0aW9uQgPgQQISFwoP", + "cGFydGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlkYXRlX29ubHkYBCABKAgi", + "7QEKFUN1c3RvbWVyRmVlZE9wZXJhdGlvbhIvCgt1cGRhdGVfbWFzaxgEIAEo", + "CzIaLmdvb2dsZS5wcm90b2J1Zi5GaWVsZE1hc2sSQQoGY3JlYXRlGAEgASgL", + "Mi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkN1c3RvbWVy", + "RmVlZEgAEkEKBnVwZGF0ZRgCIAEoCzIvLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5DdXN0b21lckZlZWRIABIQCgZyZW1vdmUYAyABKAlI", + "AEILCglvcGVyYXRpb24inQEKG011dGF0ZUN1c3RvbWVyRmVlZHNSZXNwb25z", + "ZRIxChVwYXJ0aWFsX2ZhaWx1cmVfZXJyb3IYAyABKAsyEi5nb29nbGUucnBj", + "LlN0YXR1cxJLCgdyZXN1bHRzGAIgAygLMjouZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuTXV0YXRlQ3VzdG9tZXJGZWVkUmVzdWx0IjEKGE11", + "dGF0ZUN1c3RvbWVyRmVlZFJlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJ", + "MucDChNDdXN0b21lckZlZWRTZXJ2aWNlEsUBCg9HZXRDdXN0b21lckZlZWQS", + "OC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXRDdXN0b21l", + "ckZlZWRSZXF1ZXN0Gi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkN1c3RvbWVyRmVlZCJHgtPkkwIxEi8vdjMve3Jlc291cmNlX25hbWU9", + "Y3VzdG9tZXJzLyovY3VzdG9tZXJGZWVkcy8qfdpBDXJlc291cmNlX25hbWUS", + "6gEKE011dGF0ZUN1c3RvbWVyRmVlZHMSPC5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5NdXRhdGVDdXN0b21lckZlZWRzUmVxdWVzdBo9Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUN1c3RvbWVy", + "RmVlZHNSZXNwb25zZSJWgtPkkwI3IjIvdjMvY3VzdG9tZXJzL3tjdXN0b21l", + "cl9pZD0qfS9jdXN0b21lckZlZWRzOm11dGF0ZToBKtpBFmN1c3RvbWVyX2lk", + "LG9wZXJhdGlvbnMaG8pBGGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbUL/AQok", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzQhhDdXN0b21l", + "ckZlZWRTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZp", + "Y2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPK", + "AiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CustomerFeedReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomerFeedRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomerFeedRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CustomerFeedOperation), global::Google.Ads.GoogleAds.V3.Services.CustomerFeedOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedResult), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CustomerFeedService.GetCustomerFeed][google.ads.googleads.v3.services.CustomerFeedService.GetCustomerFeed]. + /// + public sealed partial class GetCustomerFeedRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomerFeedRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerFeedServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerFeedRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerFeedRequest(GetCustomerFeedRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerFeedRequest Clone() { + return new GetCustomerFeedRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the customer feed to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomerFeedRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomerFeedRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomerFeedRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomerFeedService.MutateCustomerFeeds][google.ads.googleads.v3.services.CustomerFeedService.MutateCustomerFeeds]. + /// + public sealed partial class MutateCustomerFeedsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerFeedsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerFeedServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedsRequest(MutateCustomerFeedsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedsRequest Clone() { + return new MutateCustomerFeedsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose customer feeds are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CustomerFeedOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual customer feeds. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerFeedsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerFeedsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerFeedsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a customer feed. + /// + public sealed partial class CustomerFeedOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerFeedOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerFeedServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeedOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeedOperation(CustomerFeedOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerFeedOperation Clone() { + return new CustomerFeedOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new customer feed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The customer feed is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed customer feed is + /// expected, in this format: + /// + /// `customers/{customer_id}/customerFeeds/{feed_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerFeedOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerFeedOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerFeedOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a customer feed mutate. + /// + public sealed partial class MutateCustomerFeedsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerFeedsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerFeedServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedsResponse(MutateCustomerFeedsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedsResponse Clone() { + return new MutateCustomerFeedsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerFeedsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerFeedsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerFeedsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the customer feed mutate. + /// + public sealed partial class MutateCustomerFeedResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerFeedResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerFeedServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedResult(MutateCustomerFeedResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerFeedResult Clone() { + return new MutateCustomerFeedResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerFeedResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerFeedResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerFeedResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerFeedServiceClient.cs b/src/V3/Stubs/CustomerFeedServiceClient.cs new file mode 100644 index 000000000..811cc525d --- /dev/null +++ b/src/V3/Stubs/CustomerFeedServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomerFeedServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomerFeedServiceSettings GetDefault() => new CustomerFeedServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomerFeedServiceSettings() { } + + private CustomerFeedServiceSettings(CustomerFeedServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomerFeedSettings = existing.GetCustomerFeedSettings; + MutateCustomerFeedsSettings = existing.MutateCustomerFeedsSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomerFeedServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomerFeedServiceClient.GetCustomerFeed and CustomerFeedServiceClient.GetCustomerFeedAsync. + /// + /// + /// The default CustomerFeedServiceClient.GetCustomerFeed and + /// CustomerFeedServiceClient.GetCustomerFeedAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomerFeedSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerFeedServiceClient.MutateCustomerFeeds and CustomerFeedServiceClient.MutateCustomerFeedsAsync. + /// + /// + /// The default CustomerFeedServiceClient.MutateCustomerFeeds and + /// CustomerFeedServiceClient.MutateCustomerFeedsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCustomerFeedsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomerFeedServiceSettings Clone() => new CustomerFeedServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomerFeedServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomerFeedServiceSettings Settings { get; set; } + + /// + public override CustomerFeedServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomerFeedServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomerFeedServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomerFeedServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomerFeedServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomerFeedServiceClient.ChannelPool; + } + + /// + /// CustomerFeedService client wrapper, for convenient use. + /// + public abstract partial class CustomerFeedServiceClient + { + /// + /// The default endpoint for the CustomerFeedService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomerFeedService scopes. + /// + /// + /// The default CustomerFeedService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerFeedServiceClient client = await CustomerFeedServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerFeedServiceClient.DefaultEndpoint.Host, CustomerFeedServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerFeedServiceClient client = CustomerFeedServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomerFeedServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerFeedServiceClient client = CustomerFeedServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerFeedServiceClient.DefaultEndpoint.Host, CustomerFeedServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerFeedServiceClient client = CustomerFeedServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomerFeedServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomerFeedServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerFeedServiceClient Create(grpccore::Channel channel, CustomerFeedServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerFeedServiceClient Create(grpccore::CallInvoker callInvoker, CustomerFeedServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomerFeedService.CustomerFeedServiceClient grpcClient = new CustomerFeedService.CustomerFeedServiceClient(callInvoker); + return new CustomerFeedServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomerFeedService client. + /// + public virtual CustomerFeedService.CustomerFeedServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested customer feed in full detail. + /// + /// + /// Required. The resource name of the customer feed to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerFeedAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerFeedAsync( + new GetCustomerFeedRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested customer feed in full detail. + /// + /// + /// Required. The resource name of the customer feed to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerFeedAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomerFeedAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested customer feed in full detail. + /// + /// + /// Required. The resource name of the customer feed to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerFeed GetCustomerFeed( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerFeed( + new GetCustomerFeedRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested customer feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerFeedAsync( + GetCustomerFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested customer feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerFeedAsync( + GetCustomerFeedRequest request, + st::CancellationToken cancellationToken) => GetCustomerFeedAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested customer feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerFeed GetCustomerFeed( + GetCustomerFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose customer feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerFeedsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerFeedsAsync( + new MutateCustomerFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose customer feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerFeedsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCustomerFeedsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose customer feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerFeedsResponse MutateCustomerFeeds( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerFeeds( + new MutateCustomerFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose customer feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer feeds. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerFeedsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerFeedsAsync( + new MutateCustomerFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose customer feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer feeds. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerFeedsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCustomerFeedsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose customer feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer feeds. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerFeedsResponse MutateCustomerFeeds( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerFeeds( + new MutateCustomerFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerFeedsAsync( + MutateCustomerFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerFeedsAsync( + MutateCustomerFeedsRequest request, + st::CancellationToken cancellationToken) => MutateCustomerFeedsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerFeedsResponse MutateCustomerFeeds( + MutateCustomerFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomerFeedService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomerFeedServiceClientImpl : CustomerFeedServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomerFeed; + private readonly gaxgrpc::ApiCall _callMutateCustomerFeeds; + + /// + /// Constructs a client wrapper for the CustomerFeedService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomerFeedServiceClientImpl(CustomerFeedService.CustomerFeedServiceClient grpcClient, CustomerFeedServiceSettings settings) + { + GrpcClient = grpcClient; + CustomerFeedServiceSettings effectiveSettings = settings ?? CustomerFeedServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomerFeed = clientHelper.BuildApiCall( + GrpcClient.GetCustomerFeedAsync, GrpcClient.GetCustomerFeed, effectiveSettings.GetCustomerFeedSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCustomerFeeds = clientHelper.BuildApiCall( + GrpcClient.MutateCustomerFeedsAsync, GrpcClient.MutateCustomerFeeds, effectiveSettings.MutateCustomerFeedsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCustomerFeed); + Modify_GetCustomerFeedApiCall(ref _callGetCustomerFeed); + Modify_ApiCall(ref _callMutateCustomerFeeds); + Modify_MutateCustomerFeedsApiCall(ref _callMutateCustomerFeeds); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomerFeedApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCustomerFeedsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomerFeedService.CustomerFeedServiceClient grpcClient, CustomerFeedServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomerFeedService client. + /// + public override CustomerFeedService.CustomerFeedServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomerFeedRequest(ref GetCustomerFeedRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCustomerFeedsRequest(ref MutateCustomerFeedsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested customer feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomerFeedAsync( + GetCustomerFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerFeedRequest(ref request, ref callSettings); + return _callGetCustomerFeed.Async(request, callSettings); + } + + /// + /// Returns the requested customer feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CustomerFeed GetCustomerFeed( + GetCustomerFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerFeedRequest(ref request, ref callSettings); + return _callGetCustomerFeed.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCustomerFeedsAsync( + MutateCustomerFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerFeedsRequest(ref request, ref callSettings); + return _callMutateCustomerFeeds.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCustomerFeedsResponse MutateCustomerFeeds( + MutateCustomerFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerFeedsRequest(ref request, ref callSettings); + return _callMutateCustomerFeeds.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomerFeedServiceGrpc.cs b/src/V3/Stubs/CustomerFeedServiceGrpc.cs new file mode 100644 index 000000000..50c04d1df --- /dev/null +++ b/src/V3/Stubs/CustomerFeedServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_feed_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage customer feeds. + /// + public static partial class CustomerFeedService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomerFeedService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomerFeedRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomerFeedRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CustomerFeed = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerFeedsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerFeedsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomerFeed = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomerFeed", + __Marshaller_google_ads_googleads_v3_services_GetCustomerFeedRequest, + __Marshaller_google_ads_googleads_v3_resources_CustomerFeed); + + static readonly grpc::Method __Method_MutateCustomerFeeds = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCustomerFeeds", + __Marshaller_google_ads_googleads_v3_services_MutateCustomerFeedsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCustomerFeedsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerFeedServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomerFeedService + public abstract partial class CustomerFeedServiceBase + { + /// + /// Returns the requested customer feed in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomerFeed(global::Google.Ads.GoogleAds.V3.Services.GetCustomerFeedRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCustomerFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomerFeedService + public partial class CustomerFeedServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomerFeedService + /// The channel to use to make remote calls. + public CustomerFeedServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomerFeedService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomerFeedServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomerFeedServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomerFeedServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested customer feed in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed GetCustomerFeed(global::Google.Ads.GoogleAds.V3.Services.GetCustomerFeedRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerFeed(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested customer feed in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed GetCustomerFeed(global::Google.Ads.GoogleAds.V3.Services.GetCustomerFeedRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomerFeed, null, options, request); + } + /// + /// Returns the requested customer feed in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerFeedAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerFeedRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerFeedAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested customer feed in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerFeedAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerFeedRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomerFeed, null, options, request); + } + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsResponse MutateCustomerFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerFeeds(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsResponse MutateCustomerFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCustomerFeeds, null, options, request); + } + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerFeedsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerFeedsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes customer feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerFeedsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCustomerFeeds, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomerFeedServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomerFeedServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomerFeedServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomerFeed, serviceImpl.GetCustomerFeed) + .AddMethod(__Method_MutateCustomerFeeds, serviceImpl.MutateCustomerFeeds).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomerFeedServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomerFeed, serviceImpl.GetCustomerFeed); + serviceBinder.AddMethod(__Method_MutateCustomerFeeds, serviceImpl.MutateCustomerFeeds); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomerLabel.cs b/src/V3/Stubs/CustomerLabel.cs new file mode 100644 index 000000000..9fcd9bd32 --- /dev/null +++ b/src/V3/Stubs/CustomerLabel.cs @@ -0,0 +1,276 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/customer_label.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/customer_label.proto + public static partial class CustomerLabelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/customer_label.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerLabelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJf", + "bGFiZWwucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2Fw", + "aS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnBy", + "b3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIqACCg1DdXN0b21l", + "ckxhYmVsEkUKDXJlc291cmNlX25hbWUYASABKAlCLuBBBfpBKAomZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tL0N1c3RvbWVyTGFiZWwSMwoIY3VzdG9tZXIY", + "AiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxIwCgVs", + "YWJlbBgDIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EED", + "OmHqQV4KJmdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9DdXN0b21lckxhYmVs", + "EjRjdXN0b21lcnMve2N1c3RvbWVyfS9jdXN0b21lckxhYmVscy97Y3VzdG9t", + "ZXJfbGFiZWx9Qv8BCiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzQhJDdXN0b21lckxhYmVsUHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5v", + "cmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5W", + "My5SZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJj", + "ZXPqAiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZw", + "cm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel), global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel.Parser, new[]{ "ResourceName", "Customer", "Label" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents a relationship between a customer and a label. This customer may + /// not have access to all the labels attached to it. Additional CustomerLabels + /// may be returned by increasing permissions with login-customer-id. + /// + public sealed partial class CustomerLabel : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerLabel()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerLabelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerLabel() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerLabel(CustomerLabel other) : this() { + resourceName_ = other.resourceName_; + Customer = other.Customer; + Label = other.Label; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerLabel Clone() { + return new CustomerLabel(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. Name of the resource. + /// Customer label resource names have the form: + /// `customers/{customer_id}/customerLabels/{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "customer" field. + public const int CustomerFieldNumber = 2; + private static readonly pb::FieldCodec _single_customer_codec = pb::FieldCodec.ForClassWrapper(18); + private string customer_; + /// + /// Output only. The resource name of the customer to which the label is attached. + /// Read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Customer { + get { return customer_; } + set { + customer_ = value; + } + } + + + /// Field number for the "label" field. + public const int LabelFieldNumber = 3; + private static readonly pb::FieldCodec _single_label_codec = pb::FieldCodec.ForClassWrapper(26); + private string label_; + /// + /// Output only. The resource name of the label assigned to the customer. + /// + /// Note: the Customer ID portion of the label resource name is not + /// validated when creating a new CustomerLabel. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Label { + get { return label_; } + set { + label_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerLabel); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerLabel other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Customer != other.Customer) return false; + if (Label != other.Label) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (customer_ != null) hash ^= Customer.GetHashCode(); + if (label_ != null) hash ^= Label.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (customer_ != null) { + _single_customer_codec.WriteTagAndValue(output, Customer); + } + if (label_ != null) { + _single_label_codec.WriteTagAndValue(output, Label); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (customer_ != null) { + size += _single_customer_codec.CalculateSizeWithTag(Customer); + } + if (label_ != null) { + size += _single_label_codec.CalculateSizeWithTag(Label); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerLabel other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.customer_ != null) { + if (customer_ == null || other.Customer != "") { + Customer = other.Customer; + } + } + if (other.label_ != null) { + if (label_ == null || other.Label != "") { + Label = other.Label; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_customer_codec.Read(input); + if (customer_ == null || value != "") { + Customer = value; + } + break; + } + case 26: { + string value = _single_label_codec.Read(input); + if (label_ == null || value != "") { + Label = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerLabelService.cs b/src/V3/Stubs/CustomerLabelService.cs new file mode 100644 index 000000000..d9dbca133 --- /dev/null +++ b/src/V3/Stubs/CustomerLabelService.cs @@ -0,0 +1,951 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_label_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/customer_label_service.proto + public static partial class CustomerLabelServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/customer_label_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerLabelServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9s", + "YWJlbF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2N1", + "c3RvbWVyX2xhYmVsLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVs", + "ZF9iZWhhdmlvci5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8iNQoX", + "R2V0Q3VzdG9tZXJMYWJlbFJlcXVlc3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEo", + "CUID4EECIroBChtNdXRhdGVDdXN0b21lckxhYmVsc1JlcXVlc3QSGAoLY3Vz", + "dG9tZXJfaWQYASABKAlCA+BBAhJRCgpvcGVyYXRpb25zGAIgAygLMjguZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ3VzdG9tZXJMYWJlbE9w", + "ZXJhdGlvbkID4EECEhcKD3BhcnRpYWxfZmFpbHVyZRgDIAEoCBIVCg12YWxp", + "ZGF0ZV9vbmx5GAQgASgIInsKFkN1c3RvbWVyTGFiZWxPcGVyYXRpb24SQgoG", + "Y3JlYXRlGAEgASgLMjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkN1c3RvbWVyTGFiZWxIABIQCgZyZW1vdmUYAiABKAlIAEILCglvcGVy", + "YXRpb24inwEKHE11dGF0ZUN1c3RvbWVyTGFiZWxzUmVzcG9uc2USMQoVcGFy", + "dGlhbF9mYWlsdXJlX2Vycm9yGAMgASgLMhIuZ29vZ2xlLnJwYy5TdGF0dXMS", + "TAoHcmVzdWx0cxgCIAMoCzI7Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzLk11dGF0ZUN1c3RvbWVyTGFiZWxSZXN1bHQiMgoZTXV0YXRlQ3Vz", + "dG9tZXJMYWJlbFJlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJMvADChRD", + "dXN0b21lckxhYmVsU2VydmljZRLJAQoQR2V0Q3VzdG9tZXJMYWJlbBI5Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEN1c3RvbWVyTGFi", + "ZWxSZXF1ZXN0GjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "LkN1c3RvbWVyTGFiZWwiSILT5JMCMhIwL3YzL3tyZXNvdXJjZV9uYW1lPWN1", + "c3RvbWVycy8qL2N1c3RvbWVyTGFiZWxzLyp92kENcmVzb3VyY2VfbmFtZRLu", + "AQoUTXV0YXRlQ3VzdG9tZXJMYWJlbHMSPS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5NdXRhdGVDdXN0b21lckxhYmVsc1JlcXVlc3QaPi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDdXN0b21l", + "ckxhYmVsc1Jlc3BvbnNlIleC0+STAjgiMy92My9jdXN0b21lcnMve2N1c3Rv", + "bWVyX2lkPSp9L2N1c3RvbWVyTGFiZWxzOm11dGF0ZToBKtpBFmN1c3RvbWVy", + "X2lkLG9wZXJhdGlvbnMaG8pBGGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbUKA", + "AgokY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzQhlDdXN0", + "b21lckxhYmVsU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztz", + "ZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZp", + "Y2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CustomerLabelReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomerLabelRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomerLabelRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CustomerLabelOperation), global::Google.Ads.GoogleAds.V3.Services.CustomerLabelOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelResult), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CustomerLabelService.GetCustomerLabel][google.ads.googleads.v3.services.CustomerLabelService.GetCustomerLabel]. + /// + public sealed partial class GetCustomerLabelRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomerLabelRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerLabelServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerLabelRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerLabelRequest(GetCustomerLabelRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerLabelRequest Clone() { + return new GetCustomerLabelRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the customer-label relationship to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomerLabelRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomerLabelRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomerLabelRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomerLabelService.MutateCustomerLabels][google.ads.googleads.v3.services.CustomerLabelService.MutateCustomerLabels]. + /// + public sealed partial class MutateCustomerLabelsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerLabelsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerLabelServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelsRequest(MutateCustomerLabelsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelsRequest Clone() { + return new MutateCustomerLabelsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. ID of the customer whose customer-label relationships are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CustomerLabelOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on customer-label relationships. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerLabelsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerLabelsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerLabelsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove) on a customer-label relationship. + /// + public sealed partial class CustomerLabelOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerLabelOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerLabelServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerLabelOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerLabelOperation(CustomerLabelOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerLabelOperation Clone() { + return new CustomerLabelOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new customer-label + /// relationship. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 2; + /// + /// Remove operation: A resource name for the customer-label relationship + /// being removed, in this format: + /// + /// `customers/{customer_id}/customerLabels/{label_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerLabelOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerLabelOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(18); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerLabelOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for a customer labels mutate. + /// + public sealed partial class MutateCustomerLabelsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerLabelsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerLabelServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelsResponse(MutateCustomerLabelsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelsResponse Clone() { + return new MutateCustomerLabelsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerLabelsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerLabelsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerLabelsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for a customer label mutate. + /// + public sealed partial class MutateCustomerLabelResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerLabelResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerLabelServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelResult(MutateCustomerLabelResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerLabelResult Clone() { + return new MutateCustomerLabelResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerLabelResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerLabelResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerLabelResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerLabelServiceClient.cs b/src/V3/Stubs/CustomerLabelServiceClient.cs new file mode 100644 index 000000000..30de149c2 --- /dev/null +++ b/src/V3/Stubs/CustomerLabelServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomerLabelServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomerLabelServiceSettings GetDefault() => new CustomerLabelServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomerLabelServiceSettings() { } + + private CustomerLabelServiceSettings(CustomerLabelServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomerLabelSettings = existing.GetCustomerLabelSettings; + MutateCustomerLabelsSettings = existing.MutateCustomerLabelsSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomerLabelServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomerLabelServiceClient.GetCustomerLabel and CustomerLabelServiceClient.GetCustomerLabelAsync. + /// + /// + /// The default CustomerLabelServiceClient.GetCustomerLabel and + /// CustomerLabelServiceClient.GetCustomerLabelAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomerLabelSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerLabelServiceClient.MutateCustomerLabels and CustomerLabelServiceClient.MutateCustomerLabelsAsync. + /// + /// + /// The default CustomerLabelServiceClient.MutateCustomerLabels and + /// CustomerLabelServiceClient.MutateCustomerLabelsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCustomerLabelsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomerLabelServiceSettings Clone() => new CustomerLabelServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomerLabelServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomerLabelServiceSettings Settings { get; set; } + + /// + public override CustomerLabelServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomerLabelServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomerLabelServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomerLabelServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomerLabelServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomerLabelServiceClient.ChannelPool; + } + + /// + /// CustomerLabelService client wrapper, for convenient use. + /// + public abstract partial class CustomerLabelServiceClient + { + /// + /// The default endpoint for the CustomerLabelService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomerLabelService scopes. + /// + /// + /// The default CustomerLabelService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerLabelServiceClient client = await CustomerLabelServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerLabelServiceClient.DefaultEndpoint.Host, CustomerLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerLabelServiceClient client = CustomerLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomerLabelServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerLabelServiceClient client = CustomerLabelServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerLabelServiceClient.DefaultEndpoint.Host, CustomerLabelServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerLabelServiceClient client = CustomerLabelServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomerLabelServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomerLabelServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerLabelServiceClient Create(grpccore::Channel channel, CustomerLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerLabelServiceClient Create(grpccore::CallInvoker callInvoker, CustomerLabelServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomerLabelService.CustomerLabelServiceClient grpcClient = new CustomerLabelService.CustomerLabelServiceClient(callInvoker); + return new CustomerLabelServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomerLabelService client. + /// + public virtual CustomerLabelService.CustomerLabelServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// + /// Required. The resource name of the customer-label relationship to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerLabelAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerLabelAsync( + new GetCustomerLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// + /// Required. The resource name of the customer-label relationship to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerLabelAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomerLabelAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// + /// Required. The resource name of the customer-label relationship to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerLabel GetCustomerLabel( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerLabel( + new GetCustomerLabelRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerLabelAsync( + GetCustomerLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerLabelAsync( + GetCustomerLabelRequest request, + st::CancellationToken cancellationToken) => GetCustomerLabelAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerLabel GetCustomerLabel( + GetCustomerLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose customer-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on customer-label relationships. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerLabelsAsync( + new MutateCustomerLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose customer-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on customer-label relationships. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerLabelsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCustomerLabelsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose customer-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on customer-label relationships. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerLabelsResponse MutateCustomerLabels( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerLabels( + new MutateCustomerLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose customer-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on customer-label relationships. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerLabelsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerLabelsAsync( + new MutateCustomerLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose customer-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on customer-label relationships. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerLabelsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCustomerLabelsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// Required. ID of the customer whose customer-label relationships are being modified. + /// + /// + /// Required. The list of operations to perform on customer-label relationships. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerLabelsResponse MutateCustomerLabels( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerLabels( + new MutateCustomerLabelsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerLabelsAsync( + MutateCustomerLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerLabelsAsync( + MutateCustomerLabelsRequest request, + st::CancellationToken cancellationToken) => MutateCustomerLabelsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerLabelsResponse MutateCustomerLabels( + MutateCustomerLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomerLabelService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomerLabelServiceClientImpl : CustomerLabelServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomerLabel; + private readonly gaxgrpc::ApiCall _callMutateCustomerLabels; + + /// + /// Constructs a client wrapper for the CustomerLabelService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomerLabelServiceClientImpl(CustomerLabelService.CustomerLabelServiceClient grpcClient, CustomerLabelServiceSettings settings) + { + GrpcClient = grpcClient; + CustomerLabelServiceSettings effectiveSettings = settings ?? CustomerLabelServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomerLabel = clientHelper.BuildApiCall( + GrpcClient.GetCustomerLabelAsync, GrpcClient.GetCustomerLabel, effectiveSettings.GetCustomerLabelSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCustomerLabels = clientHelper.BuildApiCall( + GrpcClient.MutateCustomerLabelsAsync, GrpcClient.MutateCustomerLabels, effectiveSettings.MutateCustomerLabelsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCustomerLabel); + Modify_GetCustomerLabelApiCall(ref _callGetCustomerLabel); + Modify_ApiCall(ref _callMutateCustomerLabels); + Modify_MutateCustomerLabelsApiCall(ref _callMutateCustomerLabels); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomerLabelApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCustomerLabelsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomerLabelService.CustomerLabelServiceClient grpcClient, CustomerLabelServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomerLabelService client. + /// + public override CustomerLabelService.CustomerLabelServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomerLabelRequest(ref GetCustomerLabelRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCustomerLabelsRequest(ref MutateCustomerLabelsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomerLabelAsync( + GetCustomerLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerLabelRequest(ref request, ref callSettings); + return _callGetCustomerLabel.Async(request, callSettings); + } + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CustomerLabel GetCustomerLabel( + GetCustomerLabelRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerLabelRequest(ref request, ref callSettings); + return _callGetCustomerLabel.Sync(request, callSettings); + } + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCustomerLabelsAsync( + MutateCustomerLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerLabelsRequest(ref request, ref callSettings); + return _callMutateCustomerLabels.Async(request, callSettings); + } + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCustomerLabelsResponse MutateCustomerLabels( + MutateCustomerLabelsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerLabelsRequest(ref request, ref callSettings); + return _callMutateCustomerLabels.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomerLabelServiceGrpc.cs b/src/V3/Stubs/CustomerLabelServiceGrpc.cs new file mode 100644 index 000000000..0b8d3db5c --- /dev/null +++ b/src/V3/Stubs/CustomerLabelServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_label_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage labels on customers. + /// + public static partial class CustomerLabelService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomerLabelService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomerLabelRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomerLabelRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CustomerLabel = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerLabelsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerLabelsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomerLabel = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomerLabel", + __Marshaller_google_ads_googleads_v3_services_GetCustomerLabelRequest, + __Marshaller_google_ads_googleads_v3_resources_CustomerLabel); + + static readonly grpc::Method __Method_MutateCustomerLabels = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCustomerLabels", + __Marshaller_google_ads_googleads_v3_services_MutateCustomerLabelsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCustomerLabelsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerLabelServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomerLabelService + public abstract partial class CustomerLabelServiceBase + { + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomerLabel(global::Google.Ads.GoogleAds.V3.Services.GetCustomerLabelRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCustomerLabels(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomerLabelService + public partial class CustomerLabelServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomerLabelService + /// The channel to use to make remote calls. + public CustomerLabelServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomerLabelService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomerLabelServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomerLabelServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomerLabelServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel GetCustomerLabel(global::Google.Ads.GoogleAds.V3.Services.GetCustomerLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerLabel(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel GetCustomerLabel(global::Google.Ads.GoogleAds.V3.Services.GetCustomerLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomerLabel, null, options, request); + } + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerLabelRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerLabelAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested customer-label relationship in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerLabelAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerLabelRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomerLabel, null, options, request); + } + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsResponse MutateCustomerLabels(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerLabels(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsResponse MutateCustomerLabels(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCustomerLabels, null, options, request); + } + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerLabelsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates and removes customer-label relationships. + /// Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerLabelsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCustomerLabels, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomerLabelServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomerLabelServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomerLabelServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomerLabel, serviceImpl.GetCustomerLabel) + .AddMethod(__Method_MutateCustomerLabels, serviceImpl.MutateCustomerLabels).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomerLabelServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomerLabel, serviceImpl.GetCustomerLabel); + serviceBinder.AddMethod(__Method_MutateCustomerLabels, serviceImpl.MutateCustomerLabels); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomerManagerLink.cs b/src/V3/Stubs/CustomerManagerLink.cs new file mode 100644 index 000000000..6a77f7ce6 --- /dev/null +++ b/src/V3/Stubs/CustomerManagerLink.cs @@ -0,0 +1,305 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/customer_manager_link.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/customer_manager_link.proto + public static partial class CustomerManagerLinkReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/customer_manager_link.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerManagerLinkReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJf", + "bWFuYWdlcl9saW5rLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMaN2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL21hbmFn", + "ZXJfbGlua19zdGF0dXMucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZp", + "b3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9w", + "cm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90byKoAwoTQ3VzdG9tZXJNYW5hZ2VyTGluaxJLCg1yZXNvdXJjZV9u", + "YW1lGAEgASgJQjTgQQX6QS4KLGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9D", + "dXN0b21lck1hbmFnZXJMaW5rEjsKEG1hbmFnZXJfY3VzdG9tZXIYAyABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxI5Cg9tYW5hZ2Vy", + "X2xpbmtfaWQYBCABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID", + "4EEDElYKBnN0YXR1cxgFIAEoDjJGLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zLk1hbmFnZXJMaW5rU3RhdHVzRW51bS5NYW5hZ2VyTGlua1N0YXR1", + "czp06kFxCixnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ3VzdG9tZXJNYW5h", + "Z2VyTGluaxJBY3VzdG9tZXJzL3tjdXN0b21lcn0vY3VzdG9tZXJNYW5hZ2Vy", + "TGlua3Mve2N1c3RvbWVyX21hbmFnZXJfbGlua31ChQIKJWNvbS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNCGEN1c3RvbWVyTWFuYWdlckxp", + "bmtQcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dB", + "QaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2ds", + "ZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink), global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink.Parser, new[]{ "ResourceName", "ManagerCustomer", "ManagerLinkId", "Status" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents customer-manager link relationship. + /// + public sealed partial class CustomerManagerLink : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerManagerLink()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLinkReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLink() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLink(CustomerManagerLink other) : this() { + resourceName_ = other.resourceName_; + ManagerCustomer = other.ManagerCustomer; + ManagerLinkId = other.ManagerLinkId; + status_ = other.status_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLink Clone() { + return new CustomerManagerLink(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. Name of the resource. + /// CustomerManagerLink resource names have the form: + /// `customers/{customer_id}/customerManagerLinks/{manager_customer_id}~{manager_link_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "manager_customer" field. + public const int ManagerCustomerFieldNumber = 3; + private static readonly pb::FieldCodec _single_managerCustomer_codec = pb::FieldCodec.ForClassWrapper(26); + private string managerCustomer_; + /// + /// Output only. The manager customer linked to the customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ManagerCustomer { + get { return managerCustomer_; } + set { + managerCustomer_ = value; + } + } + + + /// Field number for the "manager_link_id" field. + public const int ManagerLinkIdFieldNumber = 4; + private static readonly pb::FieldCodec _single_managerLinkId_codec = pb::FieldCodec.ForStructWrapper(34); + private long? managerLinkId_; + /// + /// Output only. ID of the customer-manager link. This field is read only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ManagerLinkId { + get { return managerLinkId_; } + set { + managerLinkId_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusEnum.Types.ManagerLinkStatus status_ = 0; + /// + /// Status of the link between the customer and the manager. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusEnum.Types.ManagerLinkStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerManagerLink); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerManagerLink other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (ManagerCustomer != other.ManagerCustomer) return false; + if (ManagerLinkId != other.ManagerLinkId) return false; + if (Status != other.Status) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (managerCustomer_ != null) hash ^= ManagerCustomer.GetHashCode(); + if (managerLinkId_ != null) hash ^= ManagerLinkId.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (managerCustomer_ != null) { + _single_managerCustomer_codec.WriteTagAndValue(output, ManagerCustomer); + } + if (managerLinkId_ != null) { + _single_managerLinkId_codec.WriteTagAndValue(output, ManagerLinkId); + } + if (Status != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Status); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (managerCustomer_ != null) { + size += _single_managerCustomer_codec.CalculateSizeWithTag(ManagerCustomer); + } + if (managerLinkId_ != null) { + size += _single_managerLinkId_codec.CalculateSizeWithTag(ManagerLinkId); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerManagerLink other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.managerCustomer_ != null) { + if (managerCustomer_ == null || other.ManagerCustomer != "") { + ManagerCustomer = other.ManagerCustomer; + } + } + if (other.managerLinkId_ != null) { + if (managerLinkId_ == null || other.ManagerLinkId != 0L) { + ManagerLinkId = other.ManagerLinkId; + } + } + if (other.Status != 0) { + Status = other.Status; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + string value = _single_managerCustomer_codec.Read(input); + if (managerCustomer_ == null || value != "") { + ManagerCustomer = value; + } + break; + } + case 34: { + long? value = _single_managerLinkId_codec.Read(input); + if (managerLinkId_ == null || value != 0L) { + ManagerLinkId = value; + } + break; + } + case 40: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.ManagerLinkStatusEnum.Types.ManagerLinkStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerManagerLinkError.cs b/src/V3/Stubs/CustomerManagerLinkError.cs new file mode 100644 index 000000000..43bd8c0e5 --- /dev/null +++ b/src/V3/Stubs/CustomerManagerLinkError.cs @@ -0,0 +1,225 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/customer_manager_link_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/customer_manager_link_error.proto + public static partial class CustomerManagerLinkErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/customer_manager_link_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerManagerLinkErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY3VzdG9tZXJfbWFu", + "YWdlcl9saW5rX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lcnJvcnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i0AMKHEN1", + "c3RvbWVyTWFuYWdlckxpbmtFcnJvckVudW0irwMKGEN1c3RvbWVyTWFuYWdl", + "ckxpbmtFcnJvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIVChFO", + "T19QRU5ESU5HX0lOVklURRACEicKI1NBTUVfQ0xJRU5UX01PUkVfVEhBTl9P", + "TkNFX1BFUl9DQUxMEAMSLQopTUFOQUdFUl9IQVNfTUFYX05VTUJFUl9PRl9M", + "SU5LRURfQUNDT1VOVFMQBBItCilDQU5OT1RfVU5MSU5LX0FDQ09VTlRfV0lU", + "SE9VVF9BQ1RJVkVfVVNFUhAFEisKJ0NBTk5PVF9SRU1PVkVfTEFTVF9DTElF", + "TlRfQUNDT1VOVF9PV05FUhAGEisKJ0NBTk5PVF9DSEFOR0VfUk9MRV9CWV9O", + "T05fQUNDT1VOVF9PV05FUhAHEjIKLkNBTk5PVF9DSEFOR0VfUk9MRV9GT1Jf", + "Tk9OX0FDVElWRV9MSU5LX0FDQ09VTlQQCBIZChVEVVBMSUNBVEVfQ0hJTERf", + "Rk9VTkQQCRIuCipURVNUX0FDQ09VTlRfTElOS1NfVE9PX01BTllfQ0hJTERf", + "QUNDT1VOVFMQCkL4AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9yc0IdQ3VzdG9tZXJNYW5hZ2VyTGlua0Vycm9yUHJvdG9QAVpEZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPq", + "AiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomerManagerLinkErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.CustomerManagerLinkErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.CustomerManagerLinkErrorEnum.Types.CustomerManagerLinkError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible CustomerManagerLink errors. + /// + public sealed partial class CustomerManagerLinkErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerManagerLinkErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.CustomerManagerLinkErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLinkErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLinkErrorEnum(CustomerManagerLinkErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLinkErrorEnum Clone() { + return new CustomerManagerLinkErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerManagerLinkErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerManagerLinkErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerManagerLinkErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomerManagerLinkErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible CustomerManagerLink errors. + /// + public enum CustomerManagerLinkError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// No pending invitation. + /// + [pbr::OriginalName("NO_PENDING_INVITE")] NoPendingInvite = 2, + /// + /// Attempt to operate on the same client more than once in the same call. + /// + [pbr::OriginalName("SAME_CLIENT_MORE_THAN_ONCE_PER_CALL")] SameClientMoreThanOncePerCall = 3, + /// + /// Manager account has the maximum number of linked accounts. + /// + [pbr::OriginalName("MANAGER_HAS_MAX_NUMBER_OF_LINKED_ACCOUNTS")] ManagerHasMaxNumberOfLinkedAccounts = 4, + /// + /// If no active user on account it cannot be unlinked from its manager. + /// + [pbr::OriginalName("CANNOT_UNLINK_ACCOUNT_WITHOUT_ACTIVE_USER")] CannotUnlinkAccountWithoutActiveUser = 5, + /// + /// Account should have at least one active owner on it before being + /// unlinked. + /// + [pbr::OriginalName("CANNOT_REMOVE_LAST_CLIENT_ACCOUNT_OWNER")] CannotRemoveLastClientAccountOwner = 6, + /// + /// Only account owners may change their permission role. + /// + [pbr::OriginalName("CANNOT_CHANGE_ROLE_BY_NON_ACCOUNT_OWNER")] CannotChangeRoleByNonAccountOwner = 7, + /// + /// When a client's link to its manager is not active, the link role cannot + /// be changed. + /// + [pbr::OriginalName("CANNOT_CHANGE_ROLE_FOR_NON_ACTIVE_LINK_ACCOUNT")] CannotChangeRoleForNonActiveLinkAccount = 8, + /// + /// Attempt to link a child to a parent that contains or will contain + /// duplicate children. + /// + [pbr::OriginalName("DUPLICATE_CHILD_FOUND")] DuplicateChildFound = 9, + /// + /// The authorized customer is a test account. It can add no more than the + /// allowed number of accounts + /// + [pbr::OriginalName("TEST_ACCOUNT_LINKS_TOO_MANY_CHILD_ACCOUNTS")] TestAccountLinksTooManyChildAccounts = 10, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerManagerLinkService.cs b/src/V3/Stubs/CustomerManagerLinkService.cs new file mode 100644 index 000000000..ac1e421fd --- /dev/null +++ b/src/V3/Stubs/CustomerManagerLinkService.cs @@ -0,0 +1,1199 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_manager_link_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/customer_manager_link_service.proto + public static partial class CustomerManagerLinkServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/customer_manager_link_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerManagerLinkServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9t", + "YW5hZ2VyX2xpbmtfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMaPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcy9jdXN0b21lcl9tYW5hZ2VyX2xpbmsucHJvdG8aHGdvb2dsZS9hcGkv", + "YW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9n", + "b29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9i", + "dWYvZmllbGRfbWFzay5wcm90byI7Ch1HZXRDdXN0b21lck1hbmFnZXJMaW5r", + "UmVxdWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIilQEKIE11dGF0", + "ZUN1c3RvbWVyTWFuYWdlckxpbmtSZXF1ZXN0EhgKC2N1c3RvbWVyX2lkGAEg", + "ASgJQgPgQQISVwoKb3BlcmF0aW9ucxgCIAMoCzI+Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLkN1c3RvbWVyTWFuYWdlckxpbmtPcGVyYXRp", + "b25CA+BBAiJ5ChZNb3ZlTWFuYWdlckxpbmtSZXF1ZXN0EhgKC2N1c3RvbWVy", + "X2lkGAEgASgJQgPgQQISKwoecHJldmlvdXNfY3VzdG9tZXJfbWFuYWdlcl9s", + "aW5rGAIgASgJQgPgQQISGAoLbmV3X21hbmFnZXIYAyABKAlCA+BBAiKmAQoc", + "Q3VzdG9tZXJNYW5hZ2VyTGlua09wZXJhdGlvbhIvCgt1cGRhdGVfbWFzaxgE", + "IAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5GaWVsZE1hc2sSSAoGdXBkYXRlGAIg", + "ASgLMjYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkN1c3Rv", + "bWVyTWFuYWdlckxpbmtIAEILCglvcGVyYXRpb24idwohTXV0YXRlQ3VzdG9t", + "ZXJNYW5hZ2VyTGlua1Jlc3BvbnNlElIKB3Jlc3VsdHMYASADKAsyQS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDdXN0b21lck1h", + "bmFnZXJMaW5rUmVzdWx0IjAKF01vdmVNYW5hZ2VyTGlua1Jlc3BvbnNlEhUK", + "DXJlc291cmNlX25hbWUYASABKAkiOAofTXV0YXRlQ3VzdG9tZXJNYW5hZ2Vy", + "TGlua1Jlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJMrUGChpDdXN0b21l", + "ck1hbmFnZXJMaW5rU2VydmljZRLhAQoWR2V0Q3VzdG9tZXJNYW5hZ2VyTGlu", + "axI/Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEN1c3Rv", + "bWVyTWFuYWdlckxpbmtSZXF1ZXN0GjYuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzLkN1c3RvbWVyTWFuYWdlckxpbmsiToLT5JMCOBI2L3Yz", + "L3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2N1c3RvbWVyTWFuYWdlckxp", + "bmtzLyp92kENcmVzb3VyY2VfbmFtZRKDAgoZTXV0YXRlQ3VzdG9tZXJNYW5h", + "Z2VyTGluaxJCLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11", + "dGF0ZUN1c3RvbWVyTWFuYWdlckxpbmtSZXF1ZXN0GkMuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ3VzdG9tZXJNYW5hZ2VyTGlu", + "a1Jlc3BvbnNlIl2C0+STAj4iOS92My9jdXN0b21lcnMve2N1c3RvbWVyX2lk", + "PSp9L2N1c3RvbWVyTWFuYWdlckxpbmtzOm11dGF0ZToBKtpBFmN1c3RvbWVy", + "X2lkLG9wZXJhdGlvbnMSjwIKD01vdmVNYW5hZ2VyTGluaxI4Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk1vdmVNYW5hZ2VyTGlua1JlcXVl", + "c3QaOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5Nb3ZlTWFu", + "YWdlckxpbmtSZXNwb25zZSKGAYLT5JMCRyJCL3YzL2N1c3RvbWVycy97Y3Vz", + "dG9tZXJfaWQ9Kn0vY3VzdG9tZXJNYW5hZ2VyTGlua3M6bW92ZU1hbmFnZXJM", + "aW5rOgEq2kE2Y3VzdG9tZXJfaWQscHJldmlvdXNfY3VzdG9tZXJfbWFuYWdl", + "cl9saW5rLG5ld19tYW5hZ2VyGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b21ChgIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0If", + "Q3VzdG9tZXJNYW5hZ2VyTGlua1NlcnZpY2VQcm90b1ABWkhnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "c2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZp", + "Y2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZpY2VzYgZw", + "cm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLinkReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomerManagerLinkRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomerManagerLinkRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkRequest.Parser, new[]{ "CustomerId", "Operations" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkRequest), global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkRequest.Parser, new[]{ "CustomerId", "PreviousCustomerManagerLink", "NewManager" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkOperation), global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkOperation.Parser, new[]{ "UpdateMask", "Update" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkResponse.Parser, new[]{ "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkResponse), global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkResponse.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkResult), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CustomerManagerLinkService.GetCustomerManagerLink][google.ads.googleads.v3.services.CustomerManagerLinkService.GetCustomerManagerLink]. + /// + public sealed partial class GetCustomerManagerLinkRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomerManagerLinkRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerManagerLinkRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerManagerLinkRequest(GetCustomerManagerLinkRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerManagerLinkRequest Clone() { + return new GetCustomerManagerLinkRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the CustomerManagerLink to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomerManagerLinkRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomerManagerLinkRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomerManagerLinkRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomerManagerLinkService.MutateCustomerManagerLink][google.ads.googleads.v3.services.CustomerManagerLinkService.MutateCustomerManagerLink]. + /// + public sealed partial class MutateCustomerManagerLinkRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerManagerLinkRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkRequest(MutateCustomerManagerLinkRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkRequest Clone() { + return new MutateCustomerManagerLinkRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose customer manager links are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual customer manager links. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerManagerLinkRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerManagerLinkRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerManagerLinkRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomerManagerLinkService.MoveManagerLink][google.ads.googleads.v3.services.CustomerManagerLinkService.MoveManagerLink]. + /// + public sealed partial class MoveManagerLinkRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MoveManagerLinkRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MoveManagerLinkRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MoveManagerLinkRequest(MoveManagerLinkRequest other) : this() { + customerId_ = other.customerId_; + previousCustomerManagerLink_ = other.previousCustomerManagerLink_; + newManager_ = other.newManager_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MoveManagerLinkRequest Clone() { + return new MoveManagerLinkRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the client customer that is being moved. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "previous_customer_manager_link" field. + public const int PreviousCustomerManagerLinkFieldNumber = 2; + private string previousCustomerManagerLink_ = ""; + /// + /// Required. The resource name of the previous CustomerManagerLink. + /// The resource name has the form: + /// `customers/{customer_id}/customerManagerLinks/{manager_customer_id}~{manager_link_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PreviousCustomerManagerLink { + get { return previousCustomerManagerLink_; } + set { + previousCustomerManagerLink_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "new_manager" field. + public const int NewManagerFieldNumber = 3; + private string newManager_ = ""; + /// + /// Required. The resource name of the new manager customer that the client wants to move + /// to. Customer resource names have the format: "customers/{customer_id}" + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string NewManager { + get { return newManager_; } + set { + newManager_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MoveManagerLinkRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MoveManagerLinkRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (PreviousCustomerManagerLink != other.PreviousCustomerManagerLink) return false; + if (NewManager != other.NewManager) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (PreviousCustomerManagerLink.Length != 0) hash ^= PreviousCustomerManagerLink.GetHashCode(); + if (NewManager.Length != 0) hash ^= NewManager.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (PreviousCustomerManagerLink.Length != 0) { + output.WriteRawTag(18); + output.WriteString(PreviousCustomerManagerLink); + } + if (NewManager.Length != 0) { + output.WriteRawTag(26); + output.WriteString(NewManager); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (PreviousCustomerManagerLink.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(PreviousCustomerManagerLink); + } + if (NewManager.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(NewManager); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MoveManagerLinkRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.PreviousCustomerManagerLink.Length != 0) { + PreviousCustomerManagerLink = other.PreviousCustomerManagerLink; + } + if (other.NewManager.Length != 0) { + NewManager = other.NewManager; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + PreviousCustomerManagerLink = input.ReadString(); + break; + } + case 26: { + NewManager = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Updates the status of a CustomerManagerLink. + /// The following actions are possible: + /// 1. Update operation with status ACTIVE accepts a pending invitation. + /// 2. Update operation with status REFUSED declines a pending invitation. + /// 3. Update operation with status INACTIVE terminates link to manager. + /// + public sealed partial class CustomerManagerLinkOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerManagerLinkOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLinkOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLinkOperation(CustomerManagerLinkOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerManagerLinkOperation Clone() { + return new CustomerManagerLinkOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The link is expected to have a valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Update = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerManagerLinkOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerManagerLinkOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerManagerLinkOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink(); + } + Update.MergeFrom(other.Update); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a CustomerManagerLink mutate. + /// + public sealed partial class MutateCustomerManagerLinkResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerManagerLinkResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkResponse(MutateCustomerManagerLinkResponse other) : this() { + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkResponse Clone() { + return new MutateCustomerManagerLinkResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// A result that identifies the resource affected by the mutate request. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerManagerLinkResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerManagerLinkResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerManagerLinkResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// Response message for a CustomerManagerLink moveManagerLink. + /// + public sealed partial class MoveManagerLinkResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MoveManagerLinkResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MoveManagerLinkResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MoveManagerLinkResponse(MoveManagerLinkResponse other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MoveManagerLinkResponse Clone() { + return new MoveManagerLinkResponse(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. Represents a CustomerManagerLink + /// resource of the newly created link between client customer and new manager + /// customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MoveManagerLinkResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MoveManagerLinkResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MoveManagerLinkResponse other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// The result for the customer manager link mutate. + /// + public sealed partial class MutateCustomerManagerLinkResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerManagerLinkResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkServiceReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkResult(MutateCustomerManagerLinkResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerManagerLinkResult Clone() { + return new MutateCustomerManagerLinkResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerManagerLinkResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerManagerLinkResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerManagerLinkResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerManagerLinkServiceClient.cs b/src/V3/Stubs/CustomerManagerLinkServiceClient.cs new file mode 100644 index 000000000..cd7b70ba9 --- /dev/null +++ b/src/V3/Stubs/CustomerManagerLinkServiceClient.cs @@ -0,0 +1,1035 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomerManagerLinkServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomerManagerLinkServiceSettings GetDefault() => new CustomerManagerLinkServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomerManagerLinkServiceSettings() { } + + private CustomerManagerLinkServiceSettings(CustomerManagerLinkServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomerManagerLinkSettings = existing.GetCustomerManagerLinkSettings; + MutateCustomerManagerLinkSettings = existing.MutateCustomerManagerLinkSettings; + MoveManagerLinkSettings = existing.MoveManagerLinkSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomerManagerLinkServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomerManagerLinkServiceClient.GetCustomerManagerLink and CustomerManagerLinkServiceClient.GetCustomerManagerLinkAsync. + /// + /// + /// The default CustomerManagerLinkServiceClient.GetCustomerManagerLink and + /// CustomerManagerLinkServiceClient.GetCustomerManagerLinkAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomerManagerLinkSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerManagerLinkServiceClient.MutateCustomerManagerLink and CustomerManagerLinkServiceClient.MutateCustomerManagerLinkAsync. + /// + /// + /// The default CustomerManagerLinkServiceClient.MutateCustomerManagerLink and + /// CustomerManagerLinkServiceClient.MutateCustomerManagerLinkAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCustomerManagerLinkSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerManagerLinkServiceClient.MoveManagerLink and CustomerManagerLinkServiceClient.MoveManagerLinkAsync. + /// + /// + /// The default CustomerManagerLinkServiceClient.MoveManagerLink and + /// CustomerManagerLinkServiceClient.MoveManagerLinkAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MoveManagerLinkSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomerManagerLinkServiceSettings Clone() => new CustomerManagerLinkServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomerManagerLinkServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomerManagerLinkServiceSettings Settings { get; set; } + + /// + public override CustomerManagerLinkServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomerManagerLinkServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomerManagerLinkServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomerManagerLinkServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomerManagerLinkServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomerManagerLinkServiceClient.ChannelPool; + } + + /// + /// CustomerManagerLinkService client wrapper, for convenient use. + /// + public abstract partial class CustomerManagerLinkServiceClient + { + /// + /// The default endpoint for the CustomerManagerLinkService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomerManagerLinkService scopes. + /// + /// + /// The default CustomerManagerLinkService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerManagerLinkServiceClient client = await CustomerManagerLinkServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerManagerLinkServiceClient.DefaultEndpoint.Host, CustomerManagerLinkServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerManagerLinkServiceClient client = CustomerManagerLinkServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomerManagerLinkServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerManagerLinkServiceClient client = CustomerManagerLinkServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerManagerLinkServiceClient.DefaultEndpoint.Host, CustomerManagerLinkServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerManagerLinkServiceClient client = CustomerManagerLinkServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomerManagerLinkServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomerManagerLinkServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerManagerLinkServiceClient Create(grpccore::Channel channel, CustomerManagerLinkServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerManagerLinkServiceClient Create(grpccore::CallInvoker callInvoker, CustomerManagerLinkServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomerManagerLinkService.CustomerManagerLinkServiceClient grpcClient = new CustomerManagerLinkService.CustomerManagerLinkServiceClient(callInvoker); + return new CustomerManagerLinkServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomerManagerLinkService client. + /// + public virtual CustomerManagerLinkService.CustomerManagerLinkServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// + /// Required. The resource name of the CustomerManagerLink to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerManagerLinkAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerManagerLinkAsync( + new GetCustomerManagerLinkRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// + /// Required. The resource name of the CustomerManagerLink to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerManagerLinkAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomerManagerLinkAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// + /// Required. The resource name of the CustomerManagerLink to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerManagerLink GetCustomerManagerLink( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerManagerLink( + new GetCustomerManagerLinkRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerManagerLinkAsync( + GetCustomerManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerManagerLinkAsync( + GetCustomerManagerLinkRequest request, + st::CancellationToken cancellationToken) => GetCustomerManagerLinkAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerManagerLink GetCustomerManagerLink( + GetCustomerManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer manager links are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer manager links. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerManagerLinkAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerManagerLinkAsync( + new MutateCustomerManagerLinkRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer manager links are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer manager links. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerManagerLinkAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCustomerManagerLinkAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose customer manager links are being modified. + /// + /// + /// Required. The list of operations to perform on individual customer manager links. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerManagerLinkResponse MutateCustomerManagerLink( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerManagerLink( + new MutateCustomerManagerLinkRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerManagerLinkAsync( + MutateCustomerManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerManagerLinkAsync( + MutateCustomerManagerLinkRequest request, + st::CancellationToken cancellationToken) => MutateCustomerManagerLinkAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerManagerLinkResponse MutateCustomerManagerLink( + MutateCustomerManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// + /// Required. The ID of the client customer that is being moved. + /// + /// + /// Required. The resource name of the previous CustomerManagerLink. + /// The resource name has the form: + /// `customers/{customer_id}/customerManagerLinks/{manager_customer_id}~{manager_link_id}` + /// + /// + /// Required. The resource name of the new manager customer that the client wants to move + /// to. Customer resource names have the format: "customers/{customer_id}" + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MoveManagerLinkAsync( + string customerId, + string previousCustomerManagerLink, + string newManager, + gaxgrpc::CallSettings callSettings = null) => MoveManagerLinkAsync( + new MoveManagerLinkRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + PreviousCustomerManagerLink = gax::GaxPreconditions.CheckNotNullOrEmpty(previousCustomerManagerLink, nameof(previousCustomerManagerLink)), + NewManager = gax::GaxPreconditions.CheckNotNullOrEmpty(newManager, nameof(newManager)), + }, + callSettings); + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// + /// Required. The ID of the client customer that is being moved. + /// + /// + /// Required. The resource name of the previous CustomerManagerLink. + /// The resource name has the form: + /// `customers/{customer_id}/customerManagerLinks/{manager_customer_id}~{manager_link_id}` + /// + /// + /// Required. The resource name of the new manager customer that the client wants to move + /// to. Customer resource names have the format: "customers/{customer_id}" + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MoveManagerLinkAsync( + string customerId, + string previousCustomerManagerLink, + string newManager, + st::CancellationToken cancellationToken) => MoveManagerLinkAsync( + customerId, + previousCustomerManagerLink, + newManager, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// + /// Required. The ID of the client customer that is being moved. + /// + /// + /// Required. The resource name of the previous CustomerManagerLink. + /// The resource name has the form: + /// `customers/{customer_id}/customerManagerLinks/{manager_customer_id}~{manager_link_id}` + /// + /// + /// Required. The resource name of the new manager customer that the client wants to move + /// to. Customer resource names have the format: "customers/{customer_id}" + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MoveManagerLinkResponse MoveManagerLink( + string customerId, + string previousCustomerManagerLink, + string newManager, + gaxgrpc::CallSettings callSettings = null) => MoveManagerLink( + new MoveManagerLinkRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + PreviousCustomerManagerLink = gax::GaxPreconditions.CheckNotNullOrEmpty(previousCustomerManagerLink, nameof(previousCustomerManagerLink)), + NewManager = gax::GaxPreconditions.CheckNotNullOrEmpty(newManager, nameof(newManager)), + }, + callSettings); + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MoveManagerLinkAsync( + MoveManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MoveManagerLinkAsync( + MoveManagerLinkRequest request, + st::CancellationToken cancellationToken) => MoveManagerLinkAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MoveManagerLinkResponse MoveManagerLink( + MoveManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomerManagerLinkService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomerManagerLinkServiceClientImpl : CustomerManagerLinkServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomerManagerLink; + private readonly gaxgrpc::ApiCall _callMutateCustomerManagerLink; + private readonly gaxgrpc::ApiCall _callMoveManagerLink; + + /// + /// Constructs a client wrapper for the CustomerManagerLinkService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomerManagerLinkServiceClientImpl(CustomerManagerLinkService.CustomerManagerLinkServiceClient grpcClient, CustomerManagerLinkServiceSettings settings) + { + GrpcClient = grpcClient; + CustomerManagerLinkServiceSettings effectiveSettings = settings ?? CustomerManagerLinkServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomerManagerLink = clientHelper.BuildApiCall( + GrpcClient.GetCustomerManagerLinkAsync, GrpcClient.GetCustomerManagerLink, effectiveSettings.GetCustomerManagerLinkSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCustomerManagerLink = clientHelper.BuildApiCall( + GrpcClient.MutateCustomerManagerLinkAsync, GrpcClient.MutateCustomerManagerLink, effectiveSettings.MutateCustomerManagerLinkSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callMoveManagerLink = clientHelper.BuildApiCall( + GrpcClient.MoveManagerLinkAsync, GrpcClient.MoveManagerLink, effectiveSettings.MoveManagerLinkSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCustomerManagerLink); + Modify_GetCustomerManagerLinkApiCall(ref _callGetCustomerManagerLink); + Modify_ApiCall(ref _callMutateCustomerManagerLink); + Modify_MutateCustomerManagerLinkApiCall(ref _callMutateCustomerManagerLink); + Modify_ApiCall(ref _callMoveManagerLink); + Modify_MoveManagerLinkApiCall(ref _callMoveManagerLink); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomerManagerLinkApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCustomerManagerLinkApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MoveManagerLinkApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomerManagerLinkService.CustomerManagerLinkServiceClient grpcClient, CustomerManagerLinkServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomerManagerLinkService client. + /// + public override CustomerManagerLinkService.CustomerManagerLinkServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomerManagerLinkRequest(ref GetCustomerManagerLinkRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCustomerManagerLinkRequest(ref MutateCustomerManagerLinkRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MoveManagerLinkRequest(ref MoveManagerLinkRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomerManagerLinkAsync( + GetCustomerManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerManagerLinkRequest(ref request, ref callSettings); + return _callGetCustomerManagerLink.Async(request, callSettings); + } + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CustomerManagerLink GetCustomerManagerLink( + GetCustomerManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerManagerLinkRequest(ref request, ref callSettings); + return _callGetCustomerManagerLink.Sync(request, callSettings); + } + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCustomerManagerLinkAsync( + MutateCustomerManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerManagerLinkRequest(ref request, ref callSettings); + return _callMutateCustomerManagerLink.Async(request, callSettings); + } + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCustomerManagerLinkResponse MutateCustomerManagerLink( + MutateCustomerManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerManagerLinkRequest(ref request, ref callSettings); + return _callMutateCustomerManagerLink.Sync(request, callSettings); + } + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MoveManagerLinkAsync( + MoveManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MoveManagerLinkRequest(ref request, ref callSettings); + return _callMoveManagerLink.Async(request, callSettings); + } + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MoveManagerLinkResponse MoveManagerLink( + MoveManagerLinkRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MoveManagerLinkRequest(ref request, ref callSettings); + return _callMoveManagerLink.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomerManagerLinkServiceGrpc.cs b/src/V3/Stubs/CustomerManagerLinkServiceGrpc.cs new file mode 100644 index 000000000..d52460aea --- /dev/null +++ b/src/V3/Stubs/CustomerManagerLinkServiceGrpc.cs @@ -0,0 +1,310 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_manager_link_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage customer-manager links. + /// + public static partial class CustomerManagerLinkService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomerManagerLinkService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomerManagerLinkRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomerManagerLinkRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CustomerManagerLink = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerManagerLinkRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerManagerLinkResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MoveManagerLinkRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MoveManagerLinkResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomerManagerLink = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomerManagerLink", + __Marshaller_google_ads_googleads_v3_services_GetCustomerManagerLinkRequest, + __Marshaller_google_ads_googleads_v3_resources_CustomerManagerLink); + + static readonly grpc::Method __Method_MutateCustomerManagerLink = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCustomerManagerLink", + __Marshaller_google_ads_googleads_v3_services_MutateCustomerManagerLinkRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCustomerManagerLinkResponse); + + static readonly grpc::Method __Method_MoveManagerLink = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MoveManagerLink", + __Marshaller_google_ads_googleads_v3_services_MoveManagerLinkRequest, + __Marshaller_google_ads_googleads_v3_services_MoveManagerLinkResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerManagerLinkServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomerManagerLinkService + public abstract partial class CustomerManagerLinkServiceBase + { + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomerManagerLink(global::Google.Ads.GoogleAds.V3.Services.GetCustomerManagerLinkRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCustomerManagerLink(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MoveManagerLink(global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomerManagerLinkService + public partial class CustomerManagerLinkServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomerManagerLinkService + /// The channel to use to make remote calls. + public CustomerManagerLinkServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomerManagerLinkService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomerManagerLinkServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomerManagerLinkServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomerManagerLinkServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink GetCustomerManagerLink(global::Google.Ads.GoogleAds.V3.Services.GetCustomerManagerLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerManagerLink(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink GetCustomerManagerLink(global::Google.Ads.GoogleAds.V3.Services.GetCustomerManagerLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomerManagerLink, null, options, request); + } + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerManagerLinkAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerManagerLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerManagerLinkAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested CustomerManagerLink in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerManagerLinkAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerManagerLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomerManagerLink, null, options, request); + } + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkResponse MutateCustomerManagerLink(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerManagerLink(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkResponse MutateCustomerManagerLink(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCustomerManagerLink, null, options, request); + } + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerManagerLinkAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerManagerLinkAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or updates customer manager links. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerManagerLinkAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerManagerLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCustomerManagerLink, null, options, request); + } + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkResponse MoveManagerLink(global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MoveManagerLink(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkResponse MoveManagerLink(global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MoveManagerLink, null, options, request); + } + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MoveManagerLinkAsync(global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MoveManagerLinkAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Moves a client customer to a new manager customer. + /// This simplifies the complex request that requires two operations to move + /// a client customer to a new manager. i.e: + /// 1. Update operation with Status INACTIVE (previous manager) and, + /// 2. Update operation with Status ACTIVE (new manager). + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MoveManagerLinkAsync(global::Google.Ads.GoogleAds.V3.Services.MoveManagerLinkRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MoveManagerLink, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomerManagerLinkServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomerManagerLinkServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomerManagerLinkServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomerManagerLink, serviceImpl.GetCustomerManagerLink) + .AddMethod(__Method_MutateCustomerManagerLink, serviceImpl.MutateCustomerManagerLink) + .AddMethod(__Method_MoveManagerLink, serviceImpl.MoveManagerLink).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomerManagerLinkServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomerManagerLink, serviceImpl.GetCustomerManagerLink); + serviceBinder.AddMethod(__Method_MutateCustomerManagerLink, serviceImpl.MutateCustomerManagerLink); + serviceBinder.AddMethod(__Method_MoveManagerLink, serviceImpl.MoveManagerLink); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomerMatchUploadKeyType.cs b/src/V3/Stubs/CustomerMatchUploadKeyType.cs new file mode 100644 index 000000000..5c7baec25 --- /dev/null +++ b/src/V3/Stubs/CustomerMatchUploadKeyType.cs @@ -0,0 +1,192 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/customer_match_upload_key_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/customer_match_upload_key_type.proto + public static partial class CustomerMatchUploadKeyTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/customer_match_upload_key_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerMatchUploadKeyTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jdXN0b21lcl9tYXRj", + "aF91cGxvYWRfa2V5X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIpUBCh5D", + "dXN0b21lck1hdGNoVXBsb2FkS2V5VHlwZUVudW0icwoaQ3VzdG9tZXJNYXRj", + "aFVwbG9hZEtleVR5cGUSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAES", + "EAoMQ09OVEFDVF9JTkZPEAISCgoGQ1JNX0lEEAMSGQoVTU9CSUxFX0FEVkVS", + "VElTSU5HX0lEEARC9AEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtc0IfQ3VzdG9tZXJNYXRjaFVwbG9hZEtleVR5cGVQcm90b1ABWkJnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIh", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomerMatchUploadKeyTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.CustomerMatchUploadKeyTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomerMatchUploadKeyTypeEnum.Types.CustomerMatchUploadKeyType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Indicates what type of data are the user list's members matched from. + /// + public sealed partial class CustomerMatchUploadKeyTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerMatchUploadKeyTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CustomerMatchUploadKeyTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerMatchUploadKeyTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerMatchUploadKeyTypeEnum(CustomerMatchUploadKeyTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerMatchUploadKeyTypeEnum Clone() { + return new CustomerMatchUploadKeyTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerMatchUploadKeyTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerMatchUploadKeyTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerMatchUploadKeyTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomerMatchUploadKeyTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible customer match upload key types. + /// + public enum CustomerMatchUploadKeyType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Members are matched from customer info such as email address, phone + /// number or physical address. + /// + [pbr::OriginalName("CONTACT_INFO")] ContactInfo = 2, + /// + /// Members are matched from a user id generated and assigned by the + /// advertiser. + /// + [pbr::OriginalName("CRM_ID")] CrmId = 3, + /// + /// Members are matched from mobile advertising ids. + /// + [pbr::OriginalName("MOBILE_ADVERTISING_ID")] MobileAdvertisingId = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerNegativeCriterion.cs b/src/V3/Stubs/CustomerNegativeCriterion.cs new file mode 100644 index 000000000..8c517e54f --- /dev/null +++ b/src/V3/Stubs/CustomerNegativeCriterion.cs @@ -0,0 +1,558 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/customer_negative_criterion.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/customer_negative_criterion.proto + public static partial class CustomerNegativeCriterionReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/customer_negative_criterion.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerNegativeCriterionReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJf", + "bmVnYXRpdmVfY3JpdGVyaW9uLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXMaLWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1v", + "bi9jcml0ZXJpYS5wcm90bxoyZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXMvY3JpdGVyaW9uX3R5cGUucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVo", + "YXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2ds", + "ZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0", + "aW9ucy5wcm90byL2BgoZQ3VzdG9tZXJOZWdhdGl2ZUNyaXRlcmlvbhJRCg1y", + "ZXNvdXJjZV9uYW1lGAEgASgJQjrgQQX6QTQKMmdvb2dsZWFkcy5nb29nbGVh", + "cGlzLmNvbS9DdXN0b21lck5lZ2F0aXZlQ3JpdGVyaW9uEiwKAmlkGAIgASgL", + "MhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWVCA+BBAxJRCgR0eXBlGAMg", + "ASgOMj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQ3JpdGVyaW9u", + "VHlwZUVudW0uQ3JpdGVyaW9uVHlwZUID4EEDEk4KDWNvbnRlbnRfbGFiZWwY", + "BCABKAsyMC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQ29udGVu", + "dExhYmVsSW5mb0ID4EEFSAASWAoSbW9iaWxlX2FwcGxpY2F0aW9uGAUgASgL", + "MjUuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLk1vYmlsZUFwcGxp", + "Y2F0aW9uSW5mb0ID4EEFSAASWQoTbW9iaWxlX2FwcF9jYXRlZ29yeRgGIAEo", + "CzI1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5Nb2JpbGVBcHBD", + "YXRlZ29yeUluZm9CA+BBBUgAEkcKCXBsYWNlbWVudBgHIAEoCzItLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5QbGFjZW1lbnRJbmZvQgPgQQVI", + "ABJOCg15b3V0dWJlX3ZpZGVvGAggASgLMjAuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuY29tbW9uLllvdVR1YmVWaWRlb0luZm9CA+BBBUgAElIKD3lvdXR1", + "YmVfY2hhbm5lbBgJIAEoCzIyLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNv", + "bW1vbi5Zb3VUdWJlQ2hhbm5lbEluZm9CA+BBBUgAOoUB6kGBAQoyZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tL0N1c3RvbWVyTmVnYXRpdmVDcml0ZXJpb24S", + "S2N1c3RvbWVycy97Y3VzdG9tZXJ9L2N1c3RvbWVyTmVnYXRpdmVDcml0ZXJp", + "YS97Y3VzdG9tZXJfbmVnYXRpdmVfY3JpdGVyaW9ufUILCgljcml0ZXJpb25C", + "iwIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNCHkN1", + "c3RvbWVyTmVnYXRpdmVDcml0ZXJpb25Qcm90b1ABWkpnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVz", + "b3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291", + "cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNi", + "BnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion), global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion.Parser, new[]{ "ResourceName", "Id", "Type", "ContentLabel", "MobileApplication", "MobileAppCategory", "Placement", "YoutubeVideo", "YoutubeChannel" }, new[]{ "Criterion" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A negative criterion for exclusions at the customer level. + /// + public sealed partial class CustomerNegativeCriterion : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerNegativeCriterion()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterionReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerNegativeCriterion() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerNegativeCriterion(CustomerNegativeCriterion other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + type_ = other.type_; + switch (other.CriterionCase) { + case CriterionOneofCase.ContentLabel: + ContentLabel = other.ContentLabel.Clone(); + break; + case CriterionOneofCase.MobileApplication: + MobileApplication = other.MobileApplication.Clone(); + break; + case CriterionOneofCase.MobileAppCategory: + MobileAppCategory = other.MobileAppCategory.Clone(); + break; + case CriterionOneofCase.Placement: + Placement = other.Placement.Clone(); + break; + case CriterionOneofCase.YoutubeVideo: + YoutubeVideo = other.YoutubeVideo.Clone(); + break; + case CriterionOneofCase.YoutubeChannel: + YoutubeChannel = other.YoutubeChannel.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerNegativeCriterion Clone() { + return new CustomerNegativeCriterion(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the customer negative criterion. + /// Customer negative criterion resource names have the form: + /// + /// `customers/{customer_id}/customerNegativeCriteria/{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType type_ = 0; + /// + /// Output only. The type of the criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "content_label" field. + public const int ContentLabelFieldNumber = 4; + /// + /// Immutable. ContentLabel. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo ContentLabel { + get { return criterionCase_ == CriterionOneofCase.ContentLabel ? (global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.ContentLabel; + } + } + + /// Field number for the "mobile_application" field. + public const int MobileApplicationFieldNumber = 5; + /// + /// Immutable. MobileApplication. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo MobileApplication { + get { return criterionCase_ == CriterionOneofCase.MobileApplication ? (global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.MobileApplication; + } + } + + /// Field number for the "mobile_app_category" field. + public const int MobileAppCategoryFieldNumber = 6; + /// + /// Immutable. MobileAppCategory. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo MobileAppCategory { + get { return criterionCase_ == CriterionOneofCase.MobileAppCategory ? (global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.MobileAppCategory; + } + } + + /// Field number for the "placement" field. + public const int PlacementFieldNumber = 7; + /// + /// Immutable. Placement. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PlacementInfo Placement { + get { return criterionCase_ == CriterionOneofCase.Placement ? (global::Google.Ads.GoogleAds.V3.Common.PlacementInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.Placement; + } + } + + /// Field number for the "youtube_video" field. + public const int YoutubeVideoFieldNumber = 8; + /// + /// Immutable. YouTube Video. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo YoutubeVideo { + get { return criterionCase_ == CriterionOneofCase.YoutubeVideo ? (global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.YoutubeVideo; + } + } + + /// Field number for the "youtube_channel" field. + public const int YoutubeChannelFieldNumber = 9; + /// + /// Immutable. YouTube Channel. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo YoutubeChannel { + get { return criterionCase_ == CriterionOneofCase.YoutubeChannel ? (global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo) criterion_ : null; } + set { + criterion_ = value; + criterionCase_ = value == null ? CriterionOneofCase.None : CriterionOneofCase.YoutubeChannel; + } + } + + private object criterion_; + /// Enum of possible cases for the "criterion" oneof. + public enum CriterionOneofCase { + None = 0, + ContentLabel = 4, + MobileApplication = 5, + MobileAppCategory = 6, + Placement = 7, + YoutubeVideo = 8, + YoutubeChannel = 9, + } + private CriterionOneofCase criterionCase_ = CriterionOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CriterionOneofCase CriterionCase { + get { return criterionCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearCriterion() { + criterionCase_ = CriterionOneofCase.None; + criterion_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerNegativeCriterion); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerNegativeCriterion other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Type != other.Type) return false; + if (!object.Equals(ContentLabel, other.ContentLabel)) return false; + if (!object.Equals(MobileApplication, other.MobileApplication)) return false; + if (!object.Equals(MobileAppCategory, other.MobileAppCategory)) return false; + if (!object.Equals(Placement, other.Placement)) return false; + if (!object.Equals(YoutubeVideo, other.YoutubeVideo)) return false; + if (!object.Equals(YoutubeChannel, other.YoutubeChannel)) return false; + if (CriterionCase != other.CriterionCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.ContentLabel) hash ^= ContentLabel.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.MobileApplication) hash ^= MobileApplication.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) hash ^= MobileAppCategory.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.Placement) hash ^= Placement.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) hash ^= YoutubeVideo.GetHashCode(); + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) hash ^= YoutubeChannel.GetHashCode(); + hash ^= (int) criterionCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (Type != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Type); + } + if (criterionCase_ == CriterionOneofCase.ContentLabel) { + output.WriteRawTag(34); + output.WriteMessage(ContentLabel); + } + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + output.WriteRawTag(42); + output.WriteMessage(MobileApplication); + } + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + output.WriteRawTag(50); + output.WriteMessage(MobileAppCategory); + } + if (criterionCase_ == CriterionOneofCase.Placement) { + output.WriteRawTag(58); + output.WriteMessage(Placement); + } + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + output.WriteRawTag(66); + output.WriteMessage(YoutubeVideo); + } + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + output.WriteRawTag(74); + output.WriteMessage(YoutubeChannel); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (criterionCase_ == CriterionOneofCase.ContentLabel) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ContentLabel); + } + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MobileApplication); + } + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MobileAppCategory); + } + if (criterionCase_ == CriterionOneofCase.Placement) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Placement); + } + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(YoutubeVideo); + } + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(YoutubeChannel); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerNegativeCriterion other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.Type != 0) { + Type = other.Type; + } + switch (other.CriterionCase) { + case CriterionOneofCase.ContentLabel: + if (ContentLabel == null) { + ContentLabel = new global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo(); + } + ContentLabel.MergeFrom(other.ContentLabel); + break; + case CriterionOneofCase.MobileApplication: + if (MobileApplication == null) { + MobileApplication = new global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo(); + } + MobileApplication.MergeFrom(other.MobileApplication); + break; + case CriterionOneofCase.MobileAppCategory: + if (MobileAppCategory == null) { + MobileAppCategory = new global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo(); + } + MobileAppCategory.MergeFrom(other.MobileAppCategory); + break; + case CriterionOneofCase.Placement: + if (Placement == null) { + Placement = new global::Google.Ads.GoogleAds.V3.Common.PlacementInfo(); + } + Placement.MergeFrom(other.Placement); + break; + case CriterionOneofCase.YoutubeVideo: + if (YoutubeVideo == null) { + YoutubeVideo = new global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo(); + } + YoutubeVideo.MergeFrom(other.YoutubeVideo); + break; + case CriterionOneofCase.YoutubeChannel: + if (YoutubeChannel == null) { + YoutubeChannel = new global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo(); + } + YoutubeChannel.MergeFrom(other.YoutubeChannel); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 24: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.CriterionTypeEnum.Types.CriterionType) input.ReadEnum(); + break; + } + case 34: { + global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.ContentLabelInfo(); + if (criterionCase_ == CriterionOneofCase.ContentLabel) { + subBuilder.MergeFrom(ContentLabel); + } + input.ReadMessage(subBuilder); + ContentLabel = subBuilder; + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MobileApplicationInfo(); + if (criterionCase_ == CriterionOneofCase.MobileApplication) { + subBuilder.MergeFrom(MobileApplication); + } + input.ReadMessage(subBuilder); + MobileApplication = subBuilder; + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.MobileAppCategoryInfo(); + if (criterionCase_ == CriterionOneofCase.MobileAppCategory) { + subBuilder.MergeFrom(MobileAppCategory); + } + input.ReadMessage(subBuilder); + MobileAppCategory = subBuilder; + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Common.PlacementInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.PlacementInfo(); + if (criterionCase_ == CriterionOneofCase.Placement) { + subBuilder.MergeFrom(Placement); + } + input.ReadMessage(subBuilder); + Placement = subBuilder; + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.YouTubeVideoInfo(); + if (criterionCase_ == CriterionOneofCase.YoutubeVideo) { + subBuilder.MergeFrom(YoutubeVideo); + } + input.ReadMessage(subBuilder); + YoutubeVideo = subBuilder; + break; + } + case 74: { + global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.YouTubeChannelInfo(); + if (criterionCase_ == CriterionOneofCase.YoutubeChannel) { + subBuilder.MergeFrom(YoutubeChannel); + } + input.ReadMessage(subBuilder); + YoutubeChannel = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerNegativeCriterionService.cs b/src/V3/Stubs/CustomerNegativeCriterionService.cs new file mode 100644 index 000000000..98692b291 --- /dev/null +++ b/src/V3/Stubs/CustomerNegativeCriterionService.cs @@ -0,0 +1,957 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_negative_criterion_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/customer_negative_criterion_service.proto + public static partial class CustomerNegativeCriterionServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/customer_negative_criterion_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerNegativeCriterionServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9u", + "ZWdhdGl2ZV9jcml0ZXJpb25fc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMaQ2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L3Jlc291cmNlcy9jdXN0b21lcl9uZWdhdGl2ZV9jcml0ZXJpb24ucHJvdG8a", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xp", + "ZW50LnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhdn", + "b29nbGUvcnBjL3N0YXR1cy5wcm90byJBCiNHZXRDdXN0b21lck5lZ2F0aXZl", + "Q3JpdGVyaW9uUmVxdWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIi", + "0AEKJU11dGF0ZUN1c3RvbWVyTmVnYXRpdmVDcml0ZXJpYVJlcXVlc3QSGAoL", + "Y3VzdG9tZXJfaWQYASABKAlCA+BBAhJdCgpvcGVyYXRpb25zGAIgAygLMkQu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ3VzdG9tZXJOZWdh", + "dGl2ZUNyaXRlcmlvbk9wZXJhdGlvbkID4EECEhcKD3BhcnRpYWxfZmFpbHVy", + "ZRgDIAEoCBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIpMBCiJDdXN0b21lck5l", + "Z2F0aXZlQ3JpdGVyaW9uT3BlcmF0aW9uEk4KBmNyZWF0ZRgBIAEoCzI8Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DdXN0b21lck5lZ2F0", + "aXZlQ3JpdGVyaW9uSAASEAoGcmVtb3ZlGAIgASgJSABCCwoJb3BlcmF0aW9u", + "IrQBCiZNdXRhdGVDdXN0b21lck5lZ2F0aXZlQ3JpdGVyaWFSZXNwb25zZRIx", + "ChVwYXJ0aWFsX2ZhaWx1cmVfZXJyb3IYAyABKAsyEi5nb29nbGUucnBjLlN0", + "YXR1cxJXCgdyZXN1bHRzGAIgAygLMkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMuTXV0YXRlQ3VzdG9tZXJOZWdhdGl2ZUNyaXRlcmlhUmVz", + "dWx0Ij0KJE11dGF0ZUN1c3RvbWVyTmVnYXRpdmVDcml0ZXJpYVJlc3VsdBIV", + "Cg1yZXNvdXJjZV9uYW1lGAEgASgJMtIECiBDdXN0b21lck5lZ2F0aXZlQ3Jp", + "dGVyaW9uU2VydmljZRL3AQocR2V0Q3VzdG9tZXJOZWdhdGl2ZUNyaXRlcmlv", + "bhJFLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEN1c3Rv", + "bWVyTmVnYXRpdmVDcml0ZXJpb25SZXF1ZXN0GjwuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMucmVzb3VyY2VzLkN1c3RvbWVyTmVnYXRpdmVDcml0ZXJpb24i", + "UoLT5JMCPBI6L3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2N1c3Rv", + "bWVyTmVnYXRpdmVDcml0ZXJpYS8qfdpBDXJlc291cmNlX25hbWUSlgIKHk11", + "dGF0ZUN1c3RvbWVyTmVnYXRpdmVDcml0ZXJpYRJHLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUN1c3RvbWVyTmVnYXRpdmVDcml0", + "ZXJpYVJlcXVlc3QaSC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5NdXRhdGVDdXN0b21lck5lZ2F0aXZlQ3JpdGVyaWFSZXNwb25zZSJhgtPk", + "kwJCIj0vdjMvY3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfS9jdXN0b21lck5l", + "Z2F0aXZlQ3JpdGVyaWE6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0", + "aW9ucxobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQowCCiRjb20uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCJUN1c3RvbWVyTmVnYXRp", + "dmVDcml0ZXJpb25TZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2Vz", + "O3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2Vy", + "dmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterionReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomerNegativeCriterionRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomerNegativeCriterionRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionOperation), global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResult), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [CustomerNegativeCriterionService.GetCustomerNegativeCriterion][google.ads.googleads.v3.services.CustomerNegativeCriterionService.GetCustomerNegativeCriterion]. + /// + public sealed partial class GetCustomerNegativeCriterionRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomerNegativeCriterionRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerNegativeCriterionRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerNegativeCriterionRequest(GetCustomerNegativeCriterionRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerNegativeCriterionRequest Clone() { + return new GetCustomerNegativeCriterionRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the criterion to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomerNegativeCriterionRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomerNegativeCriterionRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomerNegativeCriterionRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [CustomerNegativeCriterionService.MutateCustomerNegativeCriteria][google.ads.googleads.v3.services.CustomerNegativeCriterionService.MutateCustomerNegativeCriteria]. + /// + public sealed partial class MutateCustomerNegativeCriteriaRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerNegativeCriteriaRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaRequest(MutateCustomerNegativeCriteriaRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaRequest Clone() { + return new MutateCustomerNegativeCriteriaRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual criteria. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerNegativeCriteriaRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerNegativeCriteriaRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerNegativeCriteriaRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create or remove) on a customer level negative criterion. + /// + public sealed partial class CustomerNegativeCriterionOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerNegativeCriterionOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerNegativeCriterionOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerNegativeCriterionOperation(CustomerNegativeCriterionOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerNegativeCriterionOperation Clone() { + return new CustomerNegativeCriterionOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new criterion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 2; + /// + /// Remove operation: A resource name for the removed criterion is expected, + /// in this format: + /// + /// `customers/{customer_id}/customerNegativeCriteria/{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerNegativeCriterionOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerNegativeCriterionOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(18); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerNegativeCriterionOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for customer negative criterion mutate. + /// + public sealed partial class MutateCustomerNegativeCriteriaResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerNegativeCriteriaResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaResponse(MutateCustomerNegativeCriteriaResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaResponse Clone() { + return new MutateCustomerNegativeCriteriaResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerNegativeCriteriaResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerNegativeCriteriaResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerNegativeCriteriaResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the criterion mutate. + /// + public sealed partial class MutateCustomerNegativeCriteriaResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerNegativeCriteriaResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaResult(MutateCustomerNegativeCriteriaResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerNegativeCriteriaResult Clone() { + return new MutateCustomerNegativeCriteriaResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerNegativeCriteriaResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerNegativeCriteriaResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerNegativeCriteriaResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerNegativeCriterionServiceClient.cs b/src/V3/Stubs/CustomerNegativeCriterionServiceClient.cs new file mode 100644 index 000000000..fb17a9423 --- /dev/null +++ b/src/V3/Stubs/CustomerNegativeCriterionServiceClient.cs @@ -0,0 +1,887 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomerNegativeCriterionServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomerNegativeCriterionServiceSettings GetDefault() => new CustomerNegativeCriterionServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomerNegativeCriterionServiceSettings() { } + + private CustomerNegativeCriterionServiceSettings(CustomerNegativeCriterionServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomerNegativeCriterionSettings = existing.GetCustomerNegativeCriterionSettings; + MutateCustomerNegativeCriteriaSettings = existing.MutateCustomerNegativeCriteriaSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomerNegativeCriterionServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomerNegativeCriterionServiceClient.GetCustomerNegativeCriterion and CustomerNegativeCriterionServiceClient.GetCustomerNegativeCriterionAsync. + /// + /// + /// The default CustomerNegativeCriterionServiceClient.GetCustomerNegativeCriterion and + /// CustomerNegativeCriterionServiceClient.GetCustomerNegativeCriterionAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomerNegativeCriterionSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerNegativeCriterionServiceClient.MutateCustomerNegativeCriteria and CustomerNegativeCriterionServiceClient.MutateCustomerNegativeCriteriaAsync. + /// + /// + /// The default CustomerNegativeCriterionServiceClient.MutateCustomerNegativeCriteria and + /// CustomerNegativeCriterionServiceClient.MutateCustomerNegativeCriteriaAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCustomerNegativeCriteriaSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomerNegativeCriterionServiceSettings Clone() => new CustomerNegativeCriterionServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomerNegativeCriterionServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomerNegativeCriterionServiceSettings Settings { get; set; } + + /// + public override CustomerNegativeCriterionServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomerNegativeCriterionServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomerNegativeCriterionServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomerNegativeCriterionServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomerNegativeCriterionServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomerNegativeCriterionServiceClient.ChannelPool; + } + + /// + /// CustomerNegativeCriterionService client wrapper, for convenient use. + /// + public abstract partial class CustomerNegativeCriterionServiceClient + { + /// + /// The default endpoint for the CustomerNegativeCriterionService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomerNegativeCriterionService scopes. + /// + /// + /// The default CustomerNegativeCriterionService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerNegativeCriterionServiceClient client = await CustomerNegativeCriterionServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerNegativeCriterionServiceClient.DefaultEndpoint.Host, CustomerNegativeCriterionServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerNegativeCriterionServiceClient client = CustomerNegativeCriterionServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomerNegativeCriterionServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerNegativeCriterionServiceClient client = CustomerNegativeCriterionServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerNegativeCriterionServiceClient.DefaultEndpoint.Host, CustomerNegativeCriterionServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerNegativeCriterionServiceClient client = CustomerNegativeCriterionServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomerNegativeCriterionServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomerNegativeCriterionServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerNegativeCriterionServiceClient Create(grpccore::Channel channel, CustomerNegativeCriterionServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerNegativeCriterionServiceClient Create(grpccore::CallInvoker callInvoker, CustomerNegativeCriterionServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomerNegativeCriterionService.CustomerNegativeCriterionServiceClient grpcClient = new CustomerNegativeCriterionService.CustomerNegativeCriterionServiceClient(callInvoker); + return new CustomerNegativeCriterionServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomerNegativeCriterionService client. + /// + public virtual CustomerNegativeCriterionService.CustomerNegativeCriterionServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerNegativeCriterionAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerNegativeCriterionAsync( + new GetCustomerNegativeCriterionRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerNegativeCriterionAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomerNegativeCriterionAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// Required. The resource name of the criterion to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerNegativeCriterion GetCustomerNegativeCriterion( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerNegativeCriterion( + new GetCustomerNegativeCriterionRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerNegativeCriterionAsync( + GetCustomerNegativeCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerNegativeCriterionAsync( + GetCustomerNegativeCriterionRequest request, + st::CancellationToken cancellationToken) => GetCustomerNegativeCriterionAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::CustomerNegativeCriterion GetCustomerNegativeCriterion( + GetCustomerNegativeCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerNegativeCriteriaAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerNegativeCriteriaAsync( + new MutateCustomerNegativeCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerNegativeCriteriaAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCustomerNegativeCriteriaAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerNegativeCriteriaResponse MutateCustomerNegativeCriteria( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerNegativeCriteria( + new MutateCustomerNegativeCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerNegativeCriteriaAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerNegativeCriteriaAsync( + new MutateCustomerNegativeCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerNegativeCriteriaAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateCustomerNegativeCriteriaAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose criteria are being modified. + /// + /// + /// Required. The list of operations to perform on individual criteria. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerNegativeCriteriaResponse MutateCustomerNegativeCriteria( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerNegativeCriteria( + new MutateCustomerNegativeCriteriaRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerNegativeCriteriaAsync( + MutateCustomerNegativeCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerNegativeCriteriaAsync( + MutateCustomerNegativeCriteriaRequest request, + st::CancellationToken cancellationToken) => MutateCustomerNegativeCriteriaAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerNegativeCriteriaResponse MutateCustomerNegativeCriteria( + MutateCustomerNegativeCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomerNegativeCriterionService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomerNegativeCriterionServiceClientImpl : CustomerNegativeCriterionServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomerNegativeCriterion; + private readonly gaxgrpc::ApiCall _callMutateCustomerNegativeCriteria; + + /// + /// Constructs a client wrapper for the CustomerNegativeCriterionService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomerNegativeCriterionServiceClientImpl(CustomerNegativeCriterionService.CustomerNegativeCriterionServiceClient grpcClient, CustomerNegativeCriterionServiceSettings settings) + { + GrpcClient = grpcClient; + CustomerNegativeCriterionServiceSettings effectiveSettings = settings ?? CustomerNegativeCriterionServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomerNegativeCriterion = clientHelper.BuildApiCall( + GrpcClient.GetCustomerNegativeCriterionAsync, GrpcClient.GetCustomerNegativeCriterion, effectiveSettings.GetCustomerNegativeCriterionSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCustomerNegativeCriteria = clientHelper.BuildApiCall( + GrpcClient.MutateCustomerNegativeCriteriaAsync, GrpcClient.MutateCustomerNegativeCriteria, effectiveSettings.MutateCustomerNegativeCriteriaSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCustomerNegativeCriterion); + Modify_GetCustomerNegativeCriterionApiCall(ref _callGetCustomerNegativeCriterion); + Modify_ApiCall(ref _callMutateCustomerNegativeCriteria); + Modify_MutateCustomerNegativeCriteriaApiCall(ref _callMutateCustomerNegativeCriteria); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomerNegativeCriterionApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCustomerNegativeCriteriaApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomerNegativeCriterionService.CustomerNegativeCriterionServiceClient grpcClient, CustomerNegativeCriterionServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomerNegativeCriterionService client. + /// + public override CustomerNegativeCriterionService.CustomerNegativeCriterionServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomerNegativeCriterionRequest(ref GetCustomerNegativeCriterionRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCustomerNegativeCriteriaRequest(ref MutateCustomerNegativeCriteriaRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomerNegativeCriterionAsync( + GetCustomerNegativeCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerNegativeCriterionRequest(ref request, ref callSettings); + return _callGetCustomerNegativeCriterion.Async(request, callSettings); + } + + /// + /// Returns the requested criterion in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::CustomerNegativeCriterion GetCustomerNegativeCriterion( + GetCustomerNegativeCriterionRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerNegativeCriterionRequest(ref request, ref callSettings); + return _callGetCustomerNegativeCriterion.Sync(request, callSettings); + } + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCustomerNegativeCriteriaAsync( + MutateCustomerNegativeCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerNegativeCriteriaRequest(ref request, ref callSettings); + return _callMutateCustomerNegativeCriteria.Async(request, callSettings); + } + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCustomerNegativeCriteriaResponse MutateCustomerNegativeCriteria( + MutateCustomerNegativeCriteriaRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerNegativeCriteriaRequest(ref request, ref callSettings); + return _callMutateCustomerNegativeCriteria.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomerNegativeCriterionServiceGrpc.cs b/src/V3/Stubs/CustomerNegativeCriterionServiceGrpc.cs new file mode 100644 index 000000000..ebe26a73a --- /dev/null +++ b/src/V3/Stubs/CustomerNegativeCriterionServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_negative_criterion_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage customer negative criteria. + /// + public static partial class CustomerNegativeCriterionService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomerNegativeCriterionService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomerNegativeCriterionRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomerNegativeCriterionRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_CustomerNegativeCriterion = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerNegativeCriteriaRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerNegativeCriteriaResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomerNegativeCriterion = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomerNegativeCriterion", + __Marshaller_google_ads_googleads_v3_services_GetCustomerNegativeCriterionRequest, + __Marshaller_google_ads_googleads_v3_resources_CustomerNegativeCriterion); + + static readonly grpc::Method __Method_MutateCustomerNegativeCriteria = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCustomerNegativeCriteria", + __Marshaller_google_ads_googleads_v3_services_MutateCustomerNegativeCriteriaRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCustomerNegativeCriteriaResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomerNegativeCriterionService + public abstract partial class CustomerNegativeCriterionServiceBase + { + /// + /// Returns the requested criterion in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomerNegativeCriterion(global::Google.Ads.GoogleAds.V3.Services.GetCustomerNegativeCriterionRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCustomerNegativeCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomerNegativeCriterionService + public partial class CustomerNegativeCriterionServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomerNegativeCriterionService + /// The channel to use to make remote calls. + public CustomerNegativeCriterionServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomerNegativeCriterionService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomerNegativeCriterionServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomerNegativeCriterionServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomerNegativeCriterionServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion GetCustomerNegativeCriterion(global::Google.Ads.GoogleAds.V3.Services.GetCustomerNegativeCriterionRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerNegativeCriterion(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion GetCustomerNegativeCriterion(global::Google.Ads.GoogleAds.V3.Services.GetCustomerNegativeCriterionRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomerNegativeCriterion, null, options, request); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerNegativeCriterionAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerNegativeCriterionRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerNegativeCriterionAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested criterion in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerNegativeCriterionAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerNegativeCriterionRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomerNegativeCriterion, null, options, request); + } + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResponse MutateCustomerNegativeCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerNegativeCriteria(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResponse MutateCustomerNegativeCriteria(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCustomerNegativeCriteria, null, options, request); + } + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerNegativeCriteriaAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerNegativeCriteriaAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or removes criteria. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerNegativeCriteriaAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCustomerNegativeCriteria, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomerNegativeCriterionServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomerNegativeCriterionServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomerNegativeCriterionServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomerNegativeCriterion, serviceImpl.GetCustomerNegativeCriterion) + .AddMethod(__Method_MutateCustomerNegativeCriteria, serviceImpl.MutateCustomerNegativeCriteria).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomerNegativeCriterionServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomerNegativeCriterion, serviceImpl.GetCustomerNegativeCriterion); + serviceBinder.AddMethod(__Method_MutateCustomerNegativeCriteria, serviceImpl.MutateCustomerNegativeCriteria); + } + + } +} +#endregion diff --git a/src/V3/Stubs/CustomerPayPerConversionEligibilityFailureReason.cs b/src/V3/Stubs/CustomerPayPerConversionEligibilityFailureReason.cs new file mode 100644 index 000000000..1a6f296b7 --- /dev/null +++ b/src/V3/Stubs/CustomerPayPerConversionEligibilityFailureReason.cs @@ -0,0 +1,215 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/customer_pay_per_conversion_eligibility_failure_reason.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/customer_pay_per_conversion_eligibility_failure_reason.proto + public static partial class CustomerPayPerConversionEligibilityFailureReasonReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/customer_pay_per_conversion_eligibility_failure_reason.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerPayPerConversionEligibilityFailureReasonReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Clpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jdXN0b21lcl9wYXlf", + "cGVyX2NvbnZlcnNpb25fZWxpZ2liaWxpdHlfZmFpbHVyZV9yZWFzb24ucHJv", + "dG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29nbGUvYXBp", + "L2Fubm90YXRpb25zLnByb3RvItECCjRDdXN0b21lclBheVBlckNvbnZlcnNp", + "b25FbGlnaWJpbGl0eUZhaWx1cmVSZWFzb25FbnVtIpgCCjBDdXN0b21lclBh", + "eVBlckNvbnZlcnNpb25FbGlnaWJpbGl0eUZhaWx1cmVSZWFzb24SDwoLVU5T", + "UEVDSUZJRUQQABILCgdVTktOT1dOEAESGgoWTk9UX0VOT1VHSF9DT05WRVJT", + "SU9OUxACEhsKF0NPTlZFUlNJT05fTEFHX1RPT19ISUdIEAMSIwofSEFTX0NB", + "TVBBSUdOX1dJVEhfU0hBUkVEX0JVREdFVBAEEiAKHEhBU19VUExPQURfQ0xJ", + "Q0tTX0NPTlZFUlNJT04QBRIgChxBVkVSQUdFX0RBSUxZX1NQRU5EX1RPT19I", + "SUdIEAYSGQoVQU5BTFlTSVNfTk9UX0NPTVBMRVRFEAcSCQoFT1RIRVIQCEKK", + "AgohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQjVDdXN0b21l", + "clBheVBlckNvbnZlcnNpb25FbGlnaWJpbGl0eUZhaWx1cmVSZWFzb25Qcm90", + "b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRz", + "Lkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYz", + "XEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZw", + "cm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomerPayPerConversionEligibilityFailureReasonEnum), global::Google.Ads.GoogleAds.V3.Enums.CustomerPayPerConversionEligibilityFailureReasonEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.CustomerPayPerConversionEligibilityFailureReasonEnum.Types.CustomerPayPerConversionEligibilityFailureReason) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing reasons why a customer is not eligible to use + /// PaymentMode.CONVERSIONS. + /// + public sealed partial class CustomerPayPerConversionEligibilityFailureReasonEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerPayPerConversionEligibilityFailureReasonEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.CustomerPayPerConversionEligibilityFailureReasonReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerPayPerConversionEligibilityFailureReasonEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerPayPerConversionEligibilityFailureReasonEnum(CustomerPayPerConversionEligibilityFailureReasonEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerPayPerConversionEligibilityFailureReasonEnum Clone() { + return new CustomerPayPerConversionEligibilityFailureReasonEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerPayPerConversionEligibilityFailureReasonEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerPayPerConversionEligibilityFailureReasonEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerPayPerConversionEligibilityFailureReasonEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the CustomerPayPerConversionEligibilityFailureReasonEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible reasons a customer is not eligible to use + /// PaymentMode.CONVERSIONS. + /// + public enum CustomerPayPerConversionEligibilityFailureReason { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Customer does not have enough conversions. + /// + [pbr::OriginalName("NOT_ENOUGH_CONVERSIONS")] NotEnoughConversions = 2, + /// + /// Customer's conversion lag is too high. + /// + [pbr::OriginalName("CONVERSION_LAG_TOO_HIGH")] ConversionLagTooHigh = 3, + /// + /// Customer uses shared budgets. + /// + [pbr::OriginalName("HAS_CAMPAIGN_WITH_SHARED_BUDGET")] HasCampaignWithSharedBudget = 4, + /// + /// Customer has conversions with ConversionActionType.UPLOAD_CLICKS. + /// + [pbr::OriginalName("HAS_UPLOAD_CLICKS_CONVERSION")] HasUploadClicksConversion = 5, + /// + /// Customer's average daily spend is too high. + /// + [pbr::OriginalName("AVERAGE_DAILY_SPEND_TOO_HIGH")] AverageDailySpendTooHigh = 6, + /// + /// Customer's eligibility has not yet been calculated by the Google Ads + /// backend. Check back soon. + /// + [pbr::OriginalName("ANALYSIS_NOT_COMPLETE")] AnalysisNotComplete = 7, + /// + /// Customer is not eligible due to other reasons. + /// + [pbr::OriginalName("OTHER")] Other = 8, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerService.cs b/src/V3/Stubs/CustomerService.cs new file mode 100644 index 000000000..3eb577795 --- /dev/null +++ b/src/V3/Stubs/CustomerService.cs @@ -0,0 +1,1505 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/customer_service.proto + public static partial class CustomerServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/customer_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static CustomerServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9z", + "ZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cxovZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvYWNjZXNzX3JvbGUu", + "cHJvdG8aMGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9jdXN0", + "b21lci5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90bxoXZ29v", + "Z2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZp", + "b3IucHJvdG8aIGdvb2dsZS9wcm90b2J1Zi9maWVsZF9tYXNrLnByb3RvGh5n", + "b29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8iMAoSR2V0Q3VzdG9tZXJS", + "ZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiKVAQoVTXV0YXRl", + "Q3VzdG9tZXJSZXF1ZXN0EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPgQQISSwoJ", + "b3BlcmF0aW9uGAQgASgLMjMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuQ3VzdG9tZXJPcGVyYXRpb25CA+BBAhIVCg12YWxpZGF0ZV9vbmx5", + "GAUgASgIIoYCChtDcmVhdGVDdXN0b21lckNsaWVudFJlcXVlc3QSGAoLY3Vz", + "dG9tZXJfaWQYASABKAlCA+BBAhJJCg9jdXN0b21lcl9jbGllbnQYAiABKAsy", + "Ky5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ3VzdG9tZXJC", + "A+BBAhIzCg1lbWFpbF9hZGRyZXNzGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVm", + "LlN0cmluZ1ZhbHVlEk0KC2FjY2Vzc19yb2xlGAQgASgOMjguZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMuQWNjZXNzUm9sZUVudW0uQWNjZXNzUm9s", + "ZSKBAQoRQ3VzdG9tZXJPcGVyYXRpb24SOwoGdXBkYXRlGAEgASgLMisuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkN1c3RvbWVyEi8KC3Vw", + "ZGF0ZV9tYXNrGAIgASgLMhouZ29vZ2xlLnByb3RvYnVmLkZpZWxkTWFzayI1", + "ChxDcmVhdGVDdXN0b21lckNsaWVudFJlc3BvbnNlEhUKDXJlc291cmNlX25h", + "bWUYAiABKAkiYAoWTXV0YXRlQ3VzdG9tZXJSZXNwb25zZRJGCgZyZXN1bHQY", + "AiABKAsyNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRh", + "dGVDdXN0b21lclJlc3VsdCItChRNdXRhdGVDdXN0b21lclJlc3VsdBIVCg1y", + "ZXNvdXJjZV9uYW1lGAEgASgJIiAKHkxpc3RBY2Nlc3NpYmxlQ3VzdG9tZXJz", + "UmVxdWVzdCI5Ch9MaXN0QWNjZXNzaWJsZUN1c3RvbWVyc1Jlc3BvbnNlEhYK", + "DnJlc291cmNlX25hbWVzGAEgAygJMu4GCg9DdXN0b21lclNlcnZpY2USqQEK", + "C0dldEN1c3RvbWVyEjQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuR2V0Q3VzdG9tZXJSZXF1ZXN0GisuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzLkN1c3RvbWVyIjeC0+STAiESHy92My97cmVzb3VyY2Vf", + "bmFtZT1jdXN0b21lcnMvKn3aQQ1yZXNvdXJjZV9uYW1lEswBCg5NdXRhdGVD", + "dXN0b21lchI3Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11", + "dGF0ZUN1c3RvbWVyUmVxdWVzdBo4Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLk11dGF0ZUN1c3RvbWVyUmVzcG9uc2UiR4LT5JMCKSIkL3Yz", + "L2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn06bXV0YXRlOgEq2kEVY3VzdG9t", + "ZXJfaWQsb3BlcmF0aW9uEs0BChdMaXN0QWNjZXNzaWJsZUN1c3RvbWVycxJA", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkxpc3RBY2Nlc3Np", + "YmxlQ3VzdG9tZXJzUmVxdWVzdBpBLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLkxpc3RBY2Nlc3NpYmxlQ3VzdG9tZXJzUmVzcG9uc2UiLYLT", + "5JMCJxIlL3YzL2N1c3RvbWVyczpsaXN0QWNjZXNzaWJsZUN1c3RvbWVycxLy", + "AQoUQ3JlYXRlQ3VzdG9tZXJDbGllbnQSPS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5DcmVhdGVDdXN0b21lckNsaWVudFJlcXVlc3QaPi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5DcmVhdGVDdXN0b21l", + "ckNsaWVudFJlc3BvbnNlIluC0+STAjciMi92My9jdXN0b21lcnMve2N1c3Rv", + "bWVyX2lkPSp9OmNyZWF0ZUN1c3RvbWVyQ2xpZW50OgEq2kEbY3VzdG9tZXJf", + "aWQsY3VzdG9tZXJfY2xpZW50GhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b21C+wEKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0IU", + "Q3VzdG9tZXJTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2Vu", + "cHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3Nl", + "cnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2Vydmlj", + "ZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2ds", + "ZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.AccessRoleReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetCustomerRequest), global::Google.Ads.GoogleAds.V3.Services.GetCustomerRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerRequest), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerRequest.Parser, new[]{ "CustomerId", "Operation", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientRequest), global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientRequest.Parser, new[]{ "CustomerId", "CustomerClient", "EmailAddress", "AccessRole" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CustomerOperation), global::Google.Ads.GoogleAds.V3.Services.CustomerOperation.Parser, new[]{ "Update", "UpdateMask" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientResponse), global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientResponse.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResponse), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResponse.Parser, new[]{ "Result" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersRequest), global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersRequest.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersResponse), global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersResponse.Parser, new[]{ "ResourceNames" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [CustomerService.GetCustomer][google.ads.googleads.v3.services.CustomerService.GetCustomer]. + /// + public sealed partial class GetCustomerRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetCustomerRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerRequest(GetCustomerRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetCustomerRequest Clone() { + return new GetCustomerRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the customer to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetCustomerRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetCustomerRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetCustomerRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomerService.MutateCustomer][google.ads.googleads.v3.services.CustomerService.MutateCustomer]. + /// + public sealed partial class MutateCustomerRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerRequest(MutateCustomerRequest other) : this() { + customerId_ = other.customerId_; + operation_ = other.operation_ != null ? other.operation_.Clone() : null; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerRequest Clone() { + return new MutateCustomerRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operation" field. + public const int OperationFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Services.CustomerOperation operation_; + /// + /// Required. The operation to perform on the customer + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CustomerOperation Operation { + get { return operation_; } + set { + operation_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 5; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (!object.Equals(Operation, other.Operation)) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (operation_ != null) hash ^= Operation.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (operation_ != null) { + output.WriteRawTag(34); + output.WriteMessage(Operation); + } + if (ValidateOnly != false) { + output.WriteRawTag(40); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (operation_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Operation); + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.operation_ != null) { + if (operation_ == null) { + Operation = new global::Google.Ads.GoogleAds.V3.Services.CustomerOperation(); + } + Operation.MergeFrom(other.Operation); + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 34: { + if (operation_ == null) { + Operation = new global::Google.Ads.GoogleAds.V3.Services.CustomerOperation(); + } + input.ReadMessage(Operation); + break; + } + case 40: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomerService.CreateCustomerClient][google.ads.googleads.v3.services.CustomerService.CreateCustomerClient]. + /// + public sealed partial class CreateCustomerClientRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CreateCustomerClientRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCustomerClientRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCustomerClientRequest(CreateCustomerClientRequest other) : this() { + customerId_ = other.customerId_; + customerClient_ = other.customerClient_ != null ? other.customerClient_.Clone() : null; + EmailAddress = other.EmailAddress; + accessRole_ = other.accessRole_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCustomerClientRequest Clone() { + return new CreateCustomerClientRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the Manager under whom client customer is being created. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "customer_client" field. + public const int CustomerClientFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Resources.Customer customerClient_; + /// + /// Required. The new client customer to create. The resource name on this customer + /// will be ignored. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Customer CustomerClient { + get { return customerClient_; } + set { + customerClient_ = value; + } + } + + /// Field number for the "email_address" field. + public const int EmailAddressFieldNumber = 3; + private static readonly pb::FieldCodec _single_emailAddress_codec = pb::FieldCodec.ForClassWrapper(26); + private string emailAddress_; + /// + /// Email address of the user who should be invited on the created client + /// customer. Accessible to whitelisted customers only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EmailAddress { + get { return emailAddress_; } + set { + emailAddress_ = value; + } + } + + + /// Field number for the "access_role" field. + public const int AccessRoleFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.AccessRoleEnum.Types.AccessRole accessRole_ = 0; + /// + /// The proposed role of user on the created client customer. + /// Accessible to whitelisted customers only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AccessRoleEnum.Types.AccessRole AccessRole { + get { return accessRole_; } + set { + accessRole_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CreateCustomerClientRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CreateCustomerClientRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (!object.Equals(CustomerClient, other.CustomerClient)) return false; + if (EmailAddress != other.EmailAddress) return false; + if (AccessRole != other.AccessRole) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (customerClient_ != null) hash ^= CustomerClient.GetHashCode(); + if (emailAddress_ != null) hash ^= EmailAddress.GetHashCode(); + if (AccessRole != 0) hash ^= AccessRole.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (customerClient_ != null) { + output.WriteRawTag(18); + output.WriteMessage(CustomerClient); + } + if (emailAddress_ != null) { + _single_emailAddress_codec.WriteTagAndValue(output, EmailAddress); + } + if (AccessRole != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) AccessRole); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (customerClient_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CustomerClient); + } + if (emailAddress_ != null) { + size += _single_emailAddress_codec.CalculateSizeWithTag(EmailAddress); + } + if (AccessRole != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AccessRole); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CreateCustomerClientRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.customerClient_ != null) { + if (customerClient_ == null) { + CustomerClient = new global::Google.Ads.GoogleAds.V3.Resources.Customer(); + } + CustomerClient.MergeFrom(other.CustomerClient); + } + if (other.emailAddress_ != null) { + if (emailAddress_ == null || other.EmailAddress != "") { + EmailAddress = other.EmailAddress; + } + } + if (other.AccessRole != 0) { + AccessRole = other.AccessRole; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + if (customerClient_ == null) { + CustomerClient = new global::Google.Ads.GoogleAds.V3.Resources.Customer(); + } + input.ReadMessage(CustomerClient); + break; + } + case 26: { + string value = _single_emailAddress_codec.Read(input); + if (emailAddress_ == null || value != "") { + EmailAddress = value; + } + break; + } + case 32: { + AccessRole = (global::Google.Ads.GoogleAds.V3.Enums.AccessRoleEnum.Types.AccessRole) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// A single update on a customer. + /// + public sealed partial class CustomerOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CustomerOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerOperation(CustomerOperation other) : this() { + update_ = other.update_ != null ? other.update_.Clone() : null; + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CustomerOperation Clone() { + return new CustomerOperation(this); + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Resources.Customer update_; + /// + /// Mutate operation. Only updates are supported for customer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Customer Update { + get { return update_; } + set { + update_ = value; + } + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 2; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CustomerOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CustomerOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Update, other.Update)) return false; + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (update_ != null) hash ^= Update.GetHashCode(); + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (update_ != null) { + output.WriteRawTag(10); + output.WriteMessage(Update); + } + if (updateMask_ != null) { + output.WriteRawTag(18); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (update_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CustomerOperation other) { + if (other == null) { + return; + } + if (other.update_ != null) { + if (update_ == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.Customer(); + } + Update.MergeFrom(other.Update); + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (update_ == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.Customer(); + } + input.ReadMessage(Update); + break; + } + case 18: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for CreateCustomerClient mutate. + /// + public sealed partial class CreateCustomerClientResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CreateCustomerClientResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCustomerClientResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCustomerClientResponse(CreateCustomerClientResponse other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CreateCustomerClientResponse Clone() { + return new CreateCustomerClientResponse(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 2; + private string resourceName_ = ""; + /// + /// The resource name of the newly created customer client. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CreateCustomerClientResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CreateCustomerClientResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(18); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CreateCustomerClientResponse other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for customer mutate. + /// + public sealed partial class MutateCustomerResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerResponse(MutateCustomerResponse other) : this() { + result_ = other.result_ != null ? other.result_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerResponse Clone() { + return new MutateCustomerResponse(this); + } + + /// Field number for the "result" field. + public const int ResultFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult result_; + /// + /// Result for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult Result { + get { return result_; } + set { + result_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Result, other.Result)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (result_ != null) hash ^= Result.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (result_ != null) { + output.WriteRawTag(18); + output.WriteMessage(Result); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (result_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Result); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerResponse other) { + if (other == null) { + return; + } + if (other.result_ != null) { + if (result_ == null) { + Result = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult(); + } + Result.MergeFrom(other.Result); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + if (result_ == null) { + Result = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult(); + } + input.ReadMessage(Result); + break; + } + } + } + } + + } + + /// + /// The result for the customer mutate. + /// + public sealed partial class MutateCustomerResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateCustomerResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerResult(MutateCustomerResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateCustomerResult Clone() { + return new MutateCustomerResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateCustomerResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateCustomerResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateCustomerResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [CustomerService.ListAccessibleCustomers][google.ads.googleads.v3.services.CustomerService.ListAccessibleCustomers]. + /// + public sealed partial class ListAccessibleCustomersRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListAccessibleCustomersRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListAccessibleCustomersRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListAccessibleCustomersRequest(ListAccessibleCustomersRequest other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListAccessibleCustomersRequest Clone() { + return new ListAccessibleCustomersRequest(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListAccessibleCustomersRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListAccessibleCustomersRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListAccessibleCustomersRequest other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + /// + /// Response message for [CustomerService.ListAccessibleCustomers][google.ads.googleads.v3.services.CustomerService.ListAccessibleCustomers]. + /// + public sealed partial class ListAccessibleCustomersResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListAccessibleCustomersResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListAccessibleCustomersResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListAccessibleCustomersResponse(ListAccessibleCustomersResponse other) : this() { + resourceNames_ = other.resourceNames_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListAccessibleCustomersResponse Clone() { + return new ListAccessibleCustomersResponse(this); + } + + /// Field number for the "resource_names" field. + public const int ResourceNamesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_resourceNames_codec + = pb::FieldCodec.ForString(10); + private readonly pbc::RepeatedField resourceNames_ = new pbc::RepeatedField(); + /// + /// Resource name of customers directly accessible by the + /// user authenticating the call. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ResourceNames { + get { return resourceNames_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListAccessibleCustomersResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListAccessibleCustomersResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!resourceNames_.Equals(other.resourceNames_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= resourceNames_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + resourceNames_.WriteTo(output, _repeated_resourceNames_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += resourceNames_.CalculateSize(_repeated_resourceNames_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListAccessibleCustomersResponse other) { + if (other == null) { + return; + } + resourceNames_.Add(other.resourceNames_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + resourceNames_.AddEntriesFrom(input, _repeated_resourceNames_codec); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/CustomerServiceClient.cs b/src/V3/Stubs/CustomerServiceClient.cs new file mode 100644 index 000000000..e7ce6313d --- /dev/null +++ b/src/V3/Stubs/CustomerServiceClient.cs @@ -0,0 +1,1329 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagve = Google.Ads.GoogleAds.V3.Enums; +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class CustomerServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static CustomerServiceSettings GetDefault() => new CustomerServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public CustomerServiceSettings() { } + + private CustomerServiceSettings(CustomerServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetCustomerSettings = existing.GetCustomerSettings; + MutateCustomerSettings = existing.MutateCustomerSettings; + ListAccessibleCustomersSettings = existing.ListAccessibleCustomersSettings; + CreateCustomerClientSettings = existing.CreateCustomerClientSettings; + OnCopy(existing); + } + + partial void OnCopy(CustomerServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// CustomerServiceClient.GetCustomer and CustomerServiceClient.GetCustomerAsync. + /// + /// + /// The default CustomerServiceClient.GetCustomer and + /// CustomerServiceClient.GetCustomerAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetCustomerSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerServiceClient.MutateCustomer and CustomerServiceClient.MutateCustomerAsync. + /// + /// + /// The default CustomerServiceClient.MutateCustomer and + /// CustomerServiceClient.MutateCustomerAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateCustomerSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerServiceClient.ListAccessibleCustomers and CustomerServiceClient.ListAccessibleCustomersAsync. + /// + /// + /// The default CustomerServiceClient.ListAccessibleCustomers and + /// CustomerServiceClient.ListAccessibleCustomersAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings ListAccessibleCustomersSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// CustomerServiceClient.CreateCustomerClient and CustomerServiceClient.CreateCustomerClientAsync. + /// + /// + /// The default CustomerServiceClient.CreateCustomerClient and + /// CustomerServiceClient.CreateCustomerClientAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings CreateCustomerClientSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public CustomerServiceSettings Clone() => new CustomerServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class CustomerServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public CustomerServiceSettings Settings { get; set; } + + /// + public override CustomerServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return CustomerServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return CustomerServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => CustomerServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => CustomerServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => CustomerServiceClient.ChannelPool; + } + + /// + /// CustomerService client wrapper, for convenient use. + /// + public abstract partial class CustomerServiceClient + { + /// + /// The default endpoint for the CustomerService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default CustomerService scopes. + /// + /// + /// The default CustomerService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerServiceClient client = await CustomerServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerServiceClient.DefaultEndpoint.Host, CustomerServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerServiceClient client = CustomerServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, CustomerServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// CustomerServiceClient client = CustomerServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// CustomerServiceClient.DefaultEndpoint.Host, CustomerServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// CustomerServiceClient client = CustomerServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static CustomerServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, CustomerServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerServiceClient Create(grpccore::Channel channel, CustomerServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static CustomerServiceClient Create(grpccore::CallInvoker callInvoker, CustomerServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + CustomerService.CustomerServiceClient grpcClient = new CustomerService.CustomerServiceClient(callInvoker); + return new CustomerServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC CustomerService client. + /// + public virtual CustomerService.CustomerServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested customer in full detail. + /// + /// + /// Required. The resource name of the customer to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomerAsync( + new GetCustomerRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested customer in full detail. + /// + /// + /// Required. The resource name of the customer to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetCustomerAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested customer in full detail. + /// + /// + /// Required. The resource name of the customer to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Customer GetCustomer( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetCustomer( + new GetCustomerRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested customer in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerAsync( + GetCustomerRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested customer in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetCustomerAsync( + GetCustomerRequest request, + st::CancellationToken cancellationToken) => GetCustomerAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested customer in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Customer GetCustomer( + GetCustomerRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer being modified. + /// + /// + /// Required. The operation to perform on the customer + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerAsync( + string customerId, + CustomerOperation operation, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerAsync( + new MutateCustomerRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer being modified. + /// + /// + /// Required. The operation to perform on the customer + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerAsync( + string customerId, + CustomerOperation operation, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateCustomerAsync( + customerId, + operation, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer being modified. + /// + /// + /// Required. The operation to perform on the customer + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerResponse MutateCustomer( + string customerId, + CustomerOperation operation, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateCustomer( + new MutateCustomerRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer being modified. + /// + /// + /// Required. The operation to perform on the customer + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerAsync( + string customerId, + CustomerOperation operation, + gaxgrpc::CallSettings callSettings = null) => MutateCustomerAsync( + new MutateCustomerRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + }, + callSettings); + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer being modified. + /// + /// + /// Required. The operation to perform on the customer + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerAsync( + string customerId, + CustomerOperation operation, + st::CancellationToken cancellationToken) => MutateCustomerAsync( + customerId, + operation, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer being modified. + /// + /// + /// Required. The operation to perform on the customer + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerResponse MutateCustomer( + string customerId, + CustomerOperation operation, + gaxgrpc::CallSettings callSettings = null) => MutateCustomer( + new MutateCustomerRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operation = gax::GaxPreconditions.CheckNotNull(operation, nameof(operation)), + }, + callSettings); + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerAsync( + MutateCustomerRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateCustomerAsync( + MutateCustomerRequest request, + st::CancellationToken cancellationToken) => MutateCustomerAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateCustomerResponse MutateCustomer( + MutateCustomerRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task ListAccessibleCustomersAsync( + ListAccessibleCustomersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task ListAccessibleCustomersAsync( + ListAccessibleCustomersRequest request, + st::CancellationToken cancellationToken) => ListAccessibleCustomersAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual ListAccessibleCustomersResponse ListAccessibleCustomers( + ListAccessibleCustomersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// Required. The ID of the Manager under whom client customer is being created. + /// + /// + /// Required. The new client customer to create. The resource name on this customer + /// will be ignored. + /// + /// + /// Email address of the user who should be invited on the created client + /// customer. Accessible to whitelisted customers only. + /// + /// + /// The proposed role of user on the created client customer. + /// Accessible to whitelisted customers only. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task CreateCustomerClientAsync( + string customerId, + gagvr::Customer customerClient, + string emailAddress, + gagve::AccessRoleEnum.Types.AccessRole? accessRole, + gaxgrpc::CallSettings callSettings = null) => CreateCustomerClientAsync( + new CreateCustomerClientRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + CustomerClient = gax::GaxPreconditions.CheckNotNull(customerClient, nameof(customerClient)), + EmailAddress = emailAddress, // Optional + AccessRole = accessRole ?? gagve::AccessRoleEnum.Types.AccessRole.Unspecified, // Optional + }, + callSettings); + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// Required. The ID of the Manager under whom client customer is being created. + /// + /// + /// Required. The new client customer to create. The resource name on this customer + /// will be ignored. + /// + /// + /// Email address of the user who should be invited on the created client + /// customer. Accessible to whitelisted customers only. + /// + /// + /// The proposed role of user on the created client customer. + /// Accessible to whitelisted customers only. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task CreateCustomerClientAsync( + string customerId, + gagvr::Customer customerClient, + string emailAddress, + gagve::AccessRoleEnum.Types.AccessRole? accessRole, + st::CancellationToken cancellationToken) => CreateCustomerClientAsync( + customerId, + customerClient, + emailAddress, + accessRole, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// Required. The ID of the Manager under whom client customer is being created. + /// + /// + /// Required. The new client customer to create. The resource name on this customer + /// will be ignored. + /// + /// + /// Email address of the user who should be invited on the created client + /// customer. Accessible to whitelisted customers only. + /// + /// + /// The proposed role of user on the created client customer. + /// Accessible to whitelisted customers only. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual CreateCustomerClientResponse CreateCustomerClient( + string customerId, + gagvr::Customer customerClient, + string emailAddress, + gagve::AccessRoleEnum.Types.AccessRole? accessRole, + gaxgrpc::CallSettings callSettings = null) => CreateCustomerClient( + new CreateCustomerClientRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + CustomerClient = gax::GaxPreconditions.CheckNotNull(customerClient, nameof(customerClient)), + EmailAddress = emailAddress, // Optional + AccessRole = accessRole ?? gagve::AccessRoleEnum.Types.AccessRole.Unspecified, // Optional + }, + callSettings); + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// Required. The ID of the Manager under whom client customer is being created. + /// + /// + /// Required. The new client customer to create. The resource name on this customer + /// will be ignored. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task CreateCustomerClientAsync( + string customerId, + gagvr::Customer customerClient, + gaxgrpc::CallSettings callSettings = null) => CreateCustomerClientAsync( + new CreateCustomerClientRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + CustomerClient = gax::GaxPreconditions.CheckNotNull(customerClient, nameof(customerClient)), + }, + callSettings); + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// Required. The ID of the Manager under whom client customer is being created. + /// + /// + /// Required. The new client customer to create. The resource name on this customer + /// will be ignored. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task CreateCustomerClientAsync( + string customerId, + gagvr::Customer customerClient, + st::CancellationToken cancellationToken) => CreateCustomerClientAsync( + customerId, + customerClient, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// Required. The ID of the Manager under whom client customer is being created. + /// + /// + /// Required. The new client customer to create. The resource name on this customer + /// will be ignored. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual CreateCustomerClientResponse CreateCustomerClient( + string customerId, + gagvr::Customer customerClient, + gaxgrpc::CallSettings callSettings = null) => CreateCustomerClient( + new CreateCustomerClientRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + CustomerClient = gax::GaxPreconditions.CheckNotNull(customerClient, nameof(customerClient)), + }, + callSettings); + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task CreateCustomerClientAsync( + CreateCustomerClientRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task CreateCustomerClientAsync( + CreateCustomerClientRequest request, + st::CancellationToken cancellationToken) => CreateCustomerClientAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual CreateCustomerClientResponse CreateCustomerClient( + CreateCustomerClientRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// CustomerService client wrapper implementation, for convenient use. + /// + public sealed partial class CustomerServiceClientImpl : CustomerServiceClient + { + private readonly gaxgrpc::ApiCall _callGetCustomer; + private readonly gaxgrpc::ApiCall _callMutateCustomer; + private readonly gaxgrpc::ApiCall _callListAccessibleCustomers; + private readonly gaxgrpc::ApiCall _callCreateCustomerClient; + + /// + /// Constructs a client wrapper for the CustomerService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public CustomerServiceClientImpl(CustomerService.CustomerServiceClient grpcClient, CustomerServiceSettings settings) + { + GrpcClient = grpcClient; + CustomerServiceSettings effectiveSettings = settings ?? CustomerServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetCustomer = clientHelper.BuildApiCall( + GrpcClient.GetCustomerAsync, GrpcClient.GetCustomer, effectiveSettings.GetCustomerSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateCustomer = clientHelper.BuildApiCall( + GrpcClient.MutateCustomerAsync, GrpcClient.MutateCustomer, effectiveSettings.MutateCustomerSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callListAccessibleCustomers = clientHelper.BuildApiCall( + GrpcClient.ListAccessibleCustomersAsync, GrpcClient.ListAccessibleCustomers, effectiveSettings.ListAccessibleCustomersSettings); + _callCreateCustomerClient = clientHelper.BuildApiCall( + GrpcClient.CreateCustomerClientAsync, GrpcClient.CreateCustomerClient, effectiveSettings.CreateCustomerClientSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetCustomer); + Modify_GetCustomerApiCall(ref _callGetCustomer); + Modify_ApiCall(ref _callMutateCustomer); + Modify_MutateCustomerApiCall(ref _callMutateCustomer); + Modify_ApiCall(ref _callListAccessibleCustomers); + Modify_ListAccessibleCustomersApiCall(ref _callListAccessibleCustomers); + Modify_ApiCall(ref _callCreateCustomerClient); + Modify_CreateCustomerClientApiCall(ref _callCreateCustomerClient); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetCustomerApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateCustomerApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_ListAccessibleCustomersApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_CreateCustomerClientApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(CustomerService.CustomerServiceClient grpcClient, CustomerServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC CustomerService client. + /// + public override CustomerService.CustomerServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetCustomerRequest(ref GetCustomerRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateCustomerRequest(ref MutateCustomerRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_ListAccessibleCustomersRequest(ref ListAccessibleCustomersRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_CreateCustomerClientRequest(ref CreateCustomerClientRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested customer in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetCustomerAsync( + GetCustomerRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerRequest(ref request, ref callSettings); + return _callGetCustomer.Async(request, callSettings); + } + + /// + /// Returns the requested customer in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::Customer GetCustomer( + GetCustomerRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetCustomerRequest(ref request, ref callSettings); + return _callGetCustomer.Sync(request, callSettings); + } + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateCustomerAsync( + MutateCustomerRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerRequest(ref request, ref callSettings); + return _callMutateCustomer.Async(request, callSettings); + } + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateCustomerResponse MutateCustomer( + MutateCustomerRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateCustomerRequest(ref request, ref callSettings); + return _callMutateCustomer.Sync(request, callSettings); + } + + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task ListAccessibleCustomersAsync( + ListAccessibleCustomersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_ListAccessibleCustomersRequest(ref request, ref callSettings); + return _callListAccessibleCustomers.Async(request, callSettings); + } + + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override ListAccessibleCustomersResponse ListAccessibleCustomers( + ListAccessibleCustomersRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_ListAccessibleCustomersRequest(ref request, ref callSettings); + return _callListAccessibleCustomers.Sync(request, callSettings); + } + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task CreateCustomerClientAsync( + CreateCustomerClientRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_CreateCustomerClientRequest(ref request, ref callSettings); + return _callCreateCustomerClient.Async(request, callSettings); + } + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override CreateCustomerClientResponse CreateCustomerClient( + CreateCustomerClientRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_CreateCustomerClientRequest(ref request, ref callSettings); + return _callCreateCustomerClient.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/CustomerServiceGrpc.cs b/src/V3/Stubs/CustomerServiceGrpc.cs new file mode 100644 index 000000000..d6093fad4 --- /dev/null +++ b/src/V3/Stubs/CustomerServiceGrpc.cs @@ -0,0 +1,361 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/customer_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage customers. + /// + public static partial class CustomerService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.CustomerService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetCustomerRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetCustomerRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_Customer = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.Customer.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateCustomerResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_ListAccessibleCustomersRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_ListAccessibleCustomersResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_CreateCustomerClientRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_CreateCustomerClientResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetCustomer = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetCustomer", + __Marshaller_google_ads_googleads_v3_services_GetCustomerRequest, + __Marshaller_google_ads_googleads_v3_resources_Customer); + + static readonly grpc::Method __Method_MutateCustomer = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateCustomer", + __Marshaller_google_ads_googleads_v3_services_MutateCustomerRequest, + __Marshaller_google_ads_googleads_v3_services_MutateCustomerResponse); + + static readonly grpc::Method __Method_ListAccessibleCustomers = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "ListAccessibleCustomers", + __Marshaller_google_ads_googleads_v3_services_ListAccessibleCustomersRequest, + __Marshaller_google_ads_googleads_v3_services_ListAccessibleCustomersResponse); + + static readonly grpc::Method __Method_CreateCustomerClient = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "CreateCustomerClient", + __Marshaller_google_ads_googleads_v3_services_CreateCustomerClientRequest, + __Marshaller_google_ads_googleads_v3_services_CreateCustomerClientResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of CustomerService + public abstract partial class CustomerServiceBase + { + /// + /// Returns the requested customer in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetCustomer(global::Google.Ads.GoogleAds.V3.Services.GetCustomerRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Updates a customer. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateCustomer(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task ListAccessibleCustomers(global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task CreateCustomerClient(global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for CustomerService + public partial class CustomerServiceClient : grpc::ClientBase + { + /// Creates a new client for CustomerService + /// The channel to use to make remote calls. + public CustomerServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for CustomerService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public CustomerServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected CustomerServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected CustomerServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested customer in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Customer GetCustomer(global::Google.Ads.GoogleAds.V3.Services.GetCustomerRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomer(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested customer in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Customer GetCustomer(global::Google.Ads.GoogleAds.V3.Services.GetCustomerRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetCustomer, null, options, request); + } + /// + /// Returns the requested customer in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetCustomerAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested customer in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetCustomerAsync(global::Google.Ads.GoogleAds.V3.Services.GetCustomerRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetCustomer, null, options, request); + } + /// + /// Updates a customer. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResponse MutateCustomer(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomer(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Updates a customer. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResponse MutateCustomer(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateCustomer, null, options, request); + } + /// + /// Updates a customer. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateCustomerAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Updates a customer. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateCustomerAsync(global::Google.Ads.GoogleAds.V3.Services.MutateCustomerRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateCustomer, null, options, request); + } + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersResponse ListAccessibleCustomers(global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return ListAccessibleCustomers(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersResponse ListAccessibleCustomers(global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_ListAccessibleCustomers, null, options, request); + } + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall ListAccessibleCustomersAsync(global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return ListAccessibleCustomersAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns resource names of customers directly accessible by the + /// user authenticating the call. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall ListAccessibleCustomersAsync(global::Google.Ads.GoogleAds.V3.Services.ListAccessibleCustomersRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_ListAccessibleCustomers, null, options, request); + } + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientResponse CreateCustomerClient(global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return CreateCustomerClient(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientResponse CreateCustomerClient(global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_CreateCustomerClient, null, options, request); + } + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall CreateCustomerClientAsync(global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return CreateCustomerClientAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates a new client under manager. The new client customer is returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall CreateCustomerClientAsync(global::Google.Ads.GoogleAds.V3.Services.CreateCustomerClientRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_CreateCustomerClient, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override CustomerServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new CustomerServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(CustomerServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetCustomer, serviceImpl.GetCustomer) + .AddMethod(__Method_MutateCustomer, serviceImpl.MutateCustomer) + .AddMethod(__Method_ListAccessibleCustomers, serviceImpl.ListAccessibleCustomers) + .AddMethod(__Method_CreateCustomerClient, serviceImpl.CreateCustomerClient).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, CustomerServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetCustomer, serviceImpl.GetCustomer); + serviceBinder.AddMethod(__Method_MutateCustomer, serviceImpl.MutateCustomer); + serviceBinder.AddMethod(__Method_ListAccessibleCustomers, serviceImpl.ListAccessibleCustomers); + serviceBinder.AddMethod(__Method_CreateCustomerClient, serviceImpl.CreateCustomerClient); + } + + } +} +#endregion diff --git a/src/V3/Stubs/DataDrivenModelStatus.cs b/src/V3/Stubs/DataDrivenModelStatus.cs new file mode 100644 index 000000000..2013c4d9c --- /dev/null +++ b/src/V3/Stubs/DataDrivenModelStatus.cs @@ -0,0 +1,200 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/data_driven_model_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/data_driven_model_status.proto + public static partial class DataDrivenModelStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/data_driven_model_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DataDrivenModelStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9kYXRhX2RyaXZlbl9t", + "b2RlbF9zdGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIo4BChlEYXRhRHJp", + "dmVuTW9kZWxTdGF0dXNFbnVtInEKFURhdGFEcml2ZW5Nb2RlbFN0YXR1cxIP", + "CgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARINCglBVkFJTEFCTEUQAhIJ", + "CgVTVEFMRRADEgsKB0VYUElSRUQQBBITCg9ORVZFUl9HRU5FUkFURUQQBULv", + "AQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhpEYXRhRHJp", + "dmVuTW9kZWxTdGF0dXNQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5w", + "cm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOi", + "AgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2ds", + "ZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2ds", + "ZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.DataDrivenModelStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.DataDrivenModelStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.DataDrivenModelStatusEnum.Types.DataDrivenModelStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum indicating data driven model status. + /// + public sealed partial class DataDrivenModelStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DataDrivenModelStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.DataDrivenModelStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DataDrivenModelStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DataDrivenModelStatusEnum(DataDrivenModelStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DataDrivenModelStatusEnum Clone() { + return new DataDrivenModelStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DataDrivenModelStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DataDrivenModelStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DataDrivenModelStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DataDrivenModelStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates data driven model statuses. + /// + public enum DataDrivenModelStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The data driven model is available. + /// + [pbr::OriginalName("AVAILABLE")] Available = 2, + /// + /// The data driven model is stale. It hasn't been updated for at least 7 + /// days. It is still being used, but will become expired if it does not get + /// updated for 30 days. + /// + [pbr::OriginalName("STALE")] Stale = 3, + /// + /// The data driven model expired. It hasn't been updated for at least 30 + /// days and cannot be used. Most commonly this is because there hasn't been + /// the required number of events in a recent 30-day period. + /// + [pbr::OriginalName("EXPIRED")] Expired = 4, + /// + /// The data driven model has never been generated. Most commonly this is + /// because there has never been the required number of events in any 30-day + /// period. + /// + [pbr::OriginalName("NEVER_GENERATED")] NeverGenerated = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DatabaseError.cs b/src/V3/Stubs/DatabaseError.cs new file mode 100644 index 000000000..0a85ca64d --- /dev/null +++ b/src/V3/Stubs/DatabaseError.cs @@ -0,0 +1,193 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/database_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/database_error.proto + public static partial class DatabaseErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/database_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DatabaseErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZGF0YWJhc2VfZXJy", + "b3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKWAQoRRGF0YWJhc2VFcnJvckVu", + "dW0igAEKDURhdGFiYXNlRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktO", + "T1dOEAESGwoXQ09OQ1VSUkVOVF9NT0RJRklDQVRJT04QAhIdChlEQVRBX0NP", + "TlNUUkFJTlRfVklPTEFUSU9OEAMSFQoRUkVRVUVTVF9UT09fTEFSR0UQBELt", + "AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0ISRGF0YWJh", + "c2VFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJyb3JzogIDR0FB", + "qgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIeR29vZ2xlXEFk", + "c1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFk", + "czo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.DatabaseErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.DatabaseErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.DatabaseErrorEnum.Types.DatabaseError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible database errors. + /// + public sealed partial class DatabaseErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DatabaseErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.DatabaseErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DatabaseErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DatabaseErrorEnum(DatabaseErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DatabaseErrorEnum Clone() { + return new DatabaseErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DatabaseErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DatabaseErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DatabaseErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DatabaseErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible database errors. + /// + public enum DatabaseError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Multiple requests were attempting to modify the same resource at once. + /// Please retry the request. + /// + [pbr::OriginalName("CONCURRENT_MODIFICATION")] ConcurrentModification = 2, + /// + /// The request conflicted with existing data. This error will usually be + /// replaced with a more specific error if the request is retried. + /// + [pbr::OriginalName("DATA_CONSTRAINT_VIOLATION")] DataConstraintViolation = 3, + /// + /// The data written is too large. Please split the request into smaller + /// requests. + /// + [pbr::OriginalName("REQUEST_TOO_LARGE")] RequestTooLarge = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DateError.cs b/src/V3/Stubs/DateError.cs new file mode 100644 index 000000000..16f487bd8 --- /dev/null +++ b/src/V3/Stubs/DateError.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/date_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/date_error.proto + public static partial class DateErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/date_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DateErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZGF0ZV9lcnJvci5w", + "cm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxnb29nbGUv", + "YXBpL2Fubm90YXRpb25zLnByb3RvIr8DCg1EYXRlRXJyb3JFbnVtIq0DCglE", + "YXRlRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESIAocSU5W", + "QUxJRF9GSUVMRF9WQUxVRVNfSU5fREFURRACEiUKIUlOVkFMSURfRklFTERf", + "VkFMVUVTX0lOX0RBVEVfVElNRRADEhcKE0lOVkFMSURfU1RSSU5HX0RBVEUQ", + "BBIjCh9JTlZBTElEX1NUUklOR19EQVRFX1RJTUVfTUlDUk9TEAYSJAogSU5W", + "QUxJRF9TVFJJTkdfREFURV9USU1FX1NFQ09ORFMQCxIwCixJTlZBTElEX1NU", + "UklOR19EQVRFX1RJTUVfU0VDT05EU19XSVRIX09GRlNFVBAMEh0KGUVBUkxJ", + "RVJfVEhBTl9NSU5JTVVNX0RBVEUQBxIbChdMQVRFUl9USEFOX01BWElNVU1f", + "REFURRAIEjMKL0RBVEVfUkFOR0VfTUlOSU1VTV9EQVRFX0xBVEVSX1RIQU5f", + "TUFYSU1VTV9EQVRFEAkSMgouREFURV9SQU5HRV9NSU5JTVVNX0FORF9NQVhJ", + "TVVNX0RBVEVTX0JPVEhfTlVMTBAKQukBCiJjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZXJyb3JzQg5EYXRlRXJyb3JQcm90b1ABWkRnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "ZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.DateErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.DateErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.DateErrorEnum.Types.DateError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible date errors. + /// + public sealed partial class DateErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DateErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.DateErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateErrorEnum(DateErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateErrorEnum Clone() { + return new DateErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DateErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DateErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DateErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DateErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible date errors. + /// + public enum DateError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Given field values do not correspond to a valid date. + /// + [pbr::OriginalName("INVALID_FIELD_VALUES_IN_DATE")] InvalidFieldValuesInDate = 2, + /// + /// Given field values do not correspond to a valid date time. + /// + [pbr::OriginalName("INVALID_FIELD_VALUES_IN_DATE_TIME")] InvalidFieldValuesInDateTime = 3, + /// + /// The string date's format should be yyyy-mm-dd. + /// + [pbr::OriginalName("INVALID_STRING_DATE")] InvalidStringDate = 4, + /// + /// The string date time's format should be yyyy-mm-dd hh:mm:ss.ssssss. + /// + [pbr::OriginalName("INVALID_STRING_DATE_TIME_MICROS")] InvalidStringDateTimeMicros = 6, + /// + /// The string date time's format should be yyyy-mm-dd hh:mm:ss. + /// + [pbr::OriginalName("INVALID_STRING_DATE_TIME_SECONDS")] InvalidStringDateTimeSeconds = 11, + /// + /// The string date time's format should be yyyy-mm-dd hh:mm:ss+|-hh:mm. + /// + [pbr::OriginalName("INVALID_STRING_DATE_TIME_SECONDS_WITH_OFFSET")] InvalidStringDateTimeSecondsWithOffset = 12, + /// + /// Date is before allowed minimum. + /// + [pbr::OriginalName("EARLIER_THAN_MINIMUM_DATE")] EarlierThanMinimumDate = 7, + /// + /// Date is after allowed maximum. + /// + [pbr::OriginalName("LATER_THAN_MAXIMUM_DATE")] LaterThanMaximumDate = 8, + /// + /// Date range bounds are not in order. + /// + [pbr::OriginalName("DATE_RANGE_MINIMUM_DATE_LATER_THAN_MAXIMUM_DATE")] DateRangeMinimumDateLaterThanMaximumDate = 9, + /// + /// Both dates in range are null. + /// + [pbr::OriginalName("DATE_RANGE_MINIMUM_AND_MAXIMUM_DATES_BOTH_NULL")] DateRangeMinimumAndMaximumDatesBothNull = 10, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DateRangeError.cs b/src/V3/Stubs/DateRangeError.cs new file mode 100644 index 000000000..e6643fa49 --- /dev/null +++ b/src/V3/Stubs/DateRangeError.cs @@ -0,0 +1,200 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/date_range_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/date_range_error.proto + public static partial class DateRangeErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/date_range_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DateRangeErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZGF0ZV9yYW5nZV9l", + "cnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIuYBChJEYXRlUmFuZ2VFcnJv", + "ckVudW0izwEKDkRhdGVSYW5nZUVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoH", + "VU5LTk9XThABEhAKDElOVkFMSURfREFURRACEh0KGVNUQVJUX0RBVEVfQUZU", + "RVJfRU5EX0RBVEUQAxIbChdDQU5OT1RfU0VUX0RBVEVfVE9fUEFTVBAEEiAK", + "HEFGVEVSX01BWElNVU1fQUxMT1dBQkxFX0RBVEUQBRIvCitDQU5OT1RfTU9E", + "SUZZX1NUQVJUX0RBVEVfSUZfQUxSRUFEWV9TVEFSVEVEEAZC7gEKImNvbS5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNCE0RhdGVSYW5nZUVycm9y", + "UHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBp", + "cy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2ds", + "ZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6", + "RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.DateRangeErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.DateRangeErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.DateRangeErrorEnum.Types.DateRangeError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible date range errors. + /// + public sealed partial class DateRangeErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DateRangeErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.DateRangeErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateRangeErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateRangeErrorEnum(DateRangeErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateRangeErrorEnum Clone() { + return new DateRangeErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DateRangeErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DateRangeErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DateRangeErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DateRangeErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible date range errors. + /// + public enum DateRangeError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Invalid date. + /// + [pbr::OriginalName("INVALID_DATE")] InvalidDate = 2, + /// + /// The start date was after the end date. + /// + [pbr::OriginalName("START_DATE_AFTER_END_DATE")] StartDateAfterEndDate = 3, + /// + /// Cannot set date to past time + /// + [pbr::OriginalName("CANNOT_SET_DATE_TO_PAST")] CannotSetDateToPast = 4, + /// + /// A date was used that is past the system "last" date. + /// + [pbr::OriginalName("AFTER_MAXIMUM_ALLOWABLE_DATE")] AfterMaximumAllowableDate = 5, + /// + /// Trying to change start date on a resource that has started. + /// + [pbr::OriginalName("CANNOT_MODIFY_START_DATE_IF_ALREADY_STARTED")] CannotModifyStartDateIfAlreadyStarted = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Dates.cs b/src/V3/Stubs/Dates.cs new file mode 100644 index 000000000..8f3b524e2 --- /dev/null +++ b/src/V3/Stubs/Dates.cs @@ -0,0 +1,230 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/dates.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/dates.proto + public static partial class DatesReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/dates.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DatesReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cipnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZGF0ZXMucHJvdG8S", + "Hmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbhoeZ29vZ2xlL3Byb3Rv", + "YnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvIm0KCURhdGVSYW5nZRIwCgpzdGFydF9kYXRlGAEgASgLMhwuZ29vZ2xl", + "LnByb3RvYnVmLlN0cmluZ1ZhbHVlEi4KCGVuZF9kYXRlGAIgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQuUBCiJjb20uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuY29tbW9uQgpEYXRlc1Byb3RvUAFaRGdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9j", + "b21tb247Y29tbW9uogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMu", + "Q29tbW9uygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcQ29tbW9u6gIiR29v", + "Z2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkNvbW1vbmIGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.DateRange), global::Google.Ads.GoogleAds.V3.Common.DateRange.Parser, new[]{ "StartDate", "EndDate" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A date range. + /// + public sealed partial class DateRange : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DateRange()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.DatesReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateRange() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateRange(DateRange other) : this() { + StartDate = other.StartDate; + EndDate = other.EndDate; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DateRange Clone() { + return new DateRange(this); + } + + /// Field number for the "start_date" field. + public const int StartDateFieldNumber = 1; + private static readonly pb::FieldCodec _single_startDate_codec = pb::FieldCodec.ForClassWrapper(10); + private string startDate_; + /// + /// The start date, in yyyy-mm-dd format. This date is inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDate { + get { return startDate_; } + set { + startDate_ = value; + } + } + + + /// Field number for the "end_date" field. + public const int EndDateFieldNumber = 2; + private static readonly pb::FieldCodec _single_endDate_codec = pb::FieldCodec.ForClassWrapper(18); + private string endDate_; + /// + /// The end date, in yyyy-mm-dd format. This date is inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDate { + get { return endDate_; } + set { + endDate_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DateRange); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DateRange other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (StartDate != other.StartDate) return false; + if (EndDate != other.EndDate) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (startDate_ != null) hash ^= StartDate.GetHashCode(); + if (endDate_ != null) hash ^= EndDate.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (startDate_ != null) { + _single_startDate_codec.WriteTagAndValue(output, StartDate); + } + if (endDate_ != null) { + _single_endDate_codec.WriteTagAndValue(output, EndDate); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (startDate_ != null) { + size += _single_startDate_codec.CalculateSizeWithTag(StartDate); + } + if (endDate_ != null) { + size += _single_endDate_codec.CalculateSizeWithTag(EndDate); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DateRange other) { + if (other == null) { + return; + } + if (other.startDate_ != null) { + if (startDate_ == null || other.StartDate != "") { + StartDate = other.StartDate; + } + } + if (other.endDate_ != null) { + if (endDate_ == null || other.EndDate != "") { + EndDate = other.EndDate; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_startDate_codec.Read(input); + if (startDate_ == null || value != "") { + StartDate = value; + } + break; + } + case 18: { + string value = _single_endDate_codec.Read(input); + if (endDate_ == null || value != "") { + EndDate = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DayOfWeek.cs b/src/V3/Stubs/DayOfWeek.cs new file mode 100644 index 000000000..73854fd9e --- /dev/null +++ b/src/V3/Stubs/DayOfWeek.cs @@ -0,0 +1,206 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/day_of_week.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/day_of_week.proto + public static partial class DayOfWeekReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/day_of_week.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DayOfWeekReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9kYXlfb2Zfd2Vlay5w", + "cm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8ilwEKDURheU9mV2Vla0VudW0ihQEKCURh", + "eU9mV2VlaxIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIKCgZNT05E", + "QVkQAhILCgdUVUVTREFZEAMSDQoJV0VETkVTREFZEAQSDAoIVEhVUlNEQVkQ", + "BRIKCgZGUklEQVkQBhIMCghTQVRVUkRBWRAHEgoKBlNVTkRBWRAIQuMBCiFj", + "b20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCDkRheU9mV2Vla1By", + "b3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5B", + "ZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNi", + "BnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum), global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekEnum.Types.DayOfWeek) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enumeration of days of the week, e.g., "Monday". + /// + public sealed partial class DayOfWeekEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DayOfWeekEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.DayOfWeekReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DayOfWeekEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DayOfWeekEnum(DayOfWeekEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DayOfWeekEnum Clone() { + return new DayOfWeekEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DayOfWeekEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DayOfWeekEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DayOfWeekEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DayOfWeekEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates days of the week, e.g., "Monday". + /// + public enum DayOfWeek { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Monday. + /// + [pbr::OriginalName("MONDAY")] Monday = 2, + /// + /// Tuesday. + /// + [pbr::OriginalName("TUESDAY")] Tuesday = 3, + /// + /// Wednesday. + /// + [pbr::OriginalName("WEDNESDAY")] Wednesday = 4, + /// + /// Thursday. + /// + [pbr::OriginalName("THURSDAY")] Thursday = 5, + /// + /// Friday. + /// + [pbr::OriginalName("FRIDAY")] Friday = 6, + /// + /// Saturday. + /// + [pbr::OriginalName("SATURDAY")] Saturday = 7, + /// + /// Sunday. + /// + [pbr::OriginalName("SUNDAY")] Sunday = 8, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DetailPlacementView.cs b/src/V3/Stubs/DetailPlacementView.cs new file mode 100644 index 000000000..95b076346 --- /dev/null +++ b/src/V3/Stubs/DetailPlacementView.cs @@ -0,0 +1,387 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/detail_placement_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/detail_placement_view.proto + public static partial class DetailPlacementViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/detail_placement_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DetailPlacementViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZGV0YWlsX3Bs", + "YWNlbWVudF92aWV3LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMaMmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3BsYWNl", + "bWVudF90eXBlLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnBy", + "b3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9i", + "dWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJv", + "dG8iogQKE0RldGFpbFBsYWNlbWVudFZpZXcSSwoNcmVzb3VyY2VfbmFtZRgB", + "IAEoCUI04EEF+kEuCixnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRGV0YWls", + "UGxhY2VtZW50VmlldxI0CglwbGFjZW1lbnQYAiABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWVCA+BBAxI3CgxkaXNwbGF5X25hbWUYAyABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxJFChpncm91cF9w", + "bGFjZW1lbnRfdGFyZ2V0X3VybBgEIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZUID4EEDEjUKCnRhcmdldF91cmwYBSABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxJbCg5wbGFjZW1lbnRfdHlwZRgG", + "IAEoDjI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLlBsYWNlbWVu", + "dFR5cGVFbnVtLlBsYWNlbWVudFR5cGVCA+BBAzp06kFxCixnb29nbGVhZHMu", + "Z29vZ2xlYXBpcy5jb20vRGV0YWlsUGxhY2VtZW50VmlldxJBY3VzdG9tZXJz", + "L3tjdXN0b21lcn0vZGV0YWlsUGxhY2VtZW50Vmlld3Mve2RldGFpbF9wbGFj", + "ZW1lbnRfdmlld31ChQIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXNCGERldGFpbFBsYWNlbWVudFZpZXdQcm90b1ABWkpnb29nbGUu", + "Z29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMv", + "djMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYz", + "XFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNv", + "dXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.PlacementTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView), global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView.Parser, new[]{ "ResourceName", "Placement", "DisplayName", "GroupPlacementTargetUrl", "TargetUrl", "PlacementType" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A view with metrics aggregated by ad group and URL or YouTube video. + /// + public sealed partial class DetailPlacementView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DetailPlacementView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DetailPlacementView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DetailPlacementView(DetailPlacementView other) : this() { + resourceName_ = other.resourceName_; + Placement = other.Placement; + DisplayName = other.DisplayName; + GroupPlacementTargetUrl = other.GroupPlacementTargetUrl; + TargetUrl = other.TargetUrl; + placementType_ = other.placementType_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DetailPlacementView Clone() { + return new DetailPlacementView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the detail placement view. + /// Detail placement view resource names have the form: + /// + /// `customers/{customer_id}/detailPlacementViews/{ad_group_id}~{base64_placement}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "placement" field. + public const int PlacementFieldNumber = 2; + private static readonly pb::FieldCodec _single_placement_codec = pb::FieldCodec.ForClassWrapper(18); + private string placement_; + /// + /// Output only. The automatic placement string at detail level, e. g. website URL, mobile + /// application ID, or a YouTube video ID. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Placement { + get { return placement_; } + set { + placement_ = value; + } + } + + + /// Field number for the "display_name" field. + public const int DisplayNameFieldNumber = 3; + private static readonly pb::FieldCodec _single_displayName_codec = pb::FieldCodec.ForClassWrapper(26); + private string displayName_; + /// + /// Output only. The display name is URL name for websites, YouTube video name for YouTube + /// videos, and translated mobile app name for mobile apps. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DisplayName { + get { return displayName_; } + set { + displayName_ = value; + } + } + + + /// Field number for the "group_placement_target_url" field. + public const int GroupPlacementTargetUrlFieldNumber = 4; + private static readonly pb::FieldCodec _single_groupPlacementTargetUrl_codec = pb::FieldCodec.ForClassWrapper(34); + private string groupPlacementTargetUrl_; + /// + /// Output only. URL of the group placement, e.g. domain, link to the mobile application in + /// app store, or a YouTube channel URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string GroupPlacementTargetUrl { + get { return groupPlacementTargetUrl_; } + set { + groupPlacementTargetUrl_ = value; + } + } + + + /// Field number for the "target_url" field. + public const int TargetUrlFieldNumber = 5; + private static readonly pb::FieldCodec _single_targetUrl_codec = pb::FieldCodec.ForClassWrapper(42); + private string targetUrl_; + /// + /// Output only. URL of the placement, e.g. website, link to the mobile application in app + /// store, or a YouTube video URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TargetUrl { + get { return targetUrl_; } + set { + targetUrl_ = value; + } + } + + + /// Field number for the "placement_type" field. + public const int PlacementTypeFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.PlacementTypeEnum.Types.PlacementType placementType_ = 0; + /// + /// Output only. Type of the placement, e.g. Website, YouTube Video, and Mobile Application. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PlacementTypeEnum.Types.PlacementType PlacementType { + get { return placementType_; } + set { + placementType_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DetailPlacementView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DetailPlacementView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Placement != other.Placement) return false; + if (DisplayName != other.DisplayName) return false; + if (GroupPlacementTargetUrl != other.GroupPlacementTargetUrl) return false; + if (TargetUrl != other.TargetUrl) return false; + if (PlacementType != other.PlacementType) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (placement_ != null) hash ^= Placement.GetHashCode(); + if (displayName_ != null) hash ^= DisplayName.GetHashCode(); + if (groupPlacementTargetUrl_ != null) hash ^= GroupPlacementTargetUrl.GetHashCode(); + if (targetUrl_ != null) hash ^= TargetUrl.GetHashCode(); + if (PlacementType != 0) hash ^= PlacementType.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (placement_ != null) { + _single_placement_codec.WriteTagAndValue(output, Placement); + } + if (displayName_ != null) { + _single_displayName_codec.WriteTagAndValue(output, DisplayName); + } + if (groupPlacementTargetUrl_ != null) { + _single_groupPlacementTargetUrl_codec.WriteTagAndValue(output, GroupPlacementTargetUrl); + } + if (targetUrl_ != null) { + _single_targetUrl_codec.WriteTagAndValue(output, TargetUrl); + } + if (PlacementType != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) PlacementType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (placement_ != null) { + size += _single_placement_codec.CalculateSizeWithTag(Placement); + } + if (displayName_ != null) { + size += _single_displayName_codec.CalculateSizeWithTag(DisplayName); + } + if (groupPlacementTargetUrl_ != null) { + size += _single_groupPlacementTargetUrl_codec.CalculateSizeWithTag(GroupPlacementTargetUrl); + } + if (targetUrl_ != null) { + size += _single_targetUrl_codec.CalculateSizeWithTag(TargetUrl); + } + if (PlacementType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PlacementType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DetailPlacementView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.placement_ != null) { + if (placement_ == null || other.Placement != "") { + Placement = other.Placement; + } + } + if (other.displayName_ != null) { + if (displayName_ == null || other.DisplayName != "") { + DisplayName = other.DisplayName; + } + } + if (other.groupPlacementTargetUrl_ != null) { + if (groupPlacementTargetUrl_ == null || other.GroupPlacementTargetUrl != "") { + GroupPlacementTargetUrl = other.GroupPlacementTargetUrl; + } + } + if (other.targetUrl_ != null) { + if (targetUrl_ == null || other.TargetUrl != "") { + TargetUrl = other.TargetUrl; + } + } + if (other.PlacementType != 0) { + PlacementType = other.PlacementType; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_placement_codec.Read(input); + if (placement_ == null || value != "") { + Placement = value; + } + break; + } + case 26: { + string value = _single_displayName_codec.Read(input); + if (displayName_ == null || value != "") { + DisplayName = value; + } + break; + } + case 34: { + string value = _single_groupPlacementTargetUrl_codec.Read(input); + if (groupPlacementTargetUrl_ == null || value != "") { + GroupPlacementTargetUrl = value; + } + break; + } + case 42: { + string value = _single_targetUrl_codec.Read(input); + if (targetUrl_ == null || value != "") { + TargetUrl = value; + } + break; + } + case 48: { + PlacementType = (global::Google.Ads.GoogleAds.V3.Enums.PlacementTypeEnum.Types.PlacementType) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DetailPlacementViewService.cs b/src/V3/Stubs/DetailPlacementViewService.cs new file mode 100644 index 000000000..63dbde35b --- /dev/null +++ b/src/V3/Stubs/DetailPlacementViewService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/detail_placement_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/detail_placement_view_service.proto + public static partial class DetailPlacementViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/detail_placement_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DetailPlacementViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9kZXRhaWxfcGxh", + "Y2VtZW50X3ZpZXdfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMaPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcy9kZXRhaWxfcGxhY2VtZW50X3ZpZXcucHJvdG8aHGdvb2dsZS9hcGkv", + "YW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9n", + "b29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvIjsKHUdldERldGFpbFBs", + "YWNlbWVudFZpZXdSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BB", + "AjKdAgoaRGV0YWlsUGxhY2VtZW50Vmlld1NlcnZpY2US4QEKFkdldERldGFp", + "bFBsYWNlbWVudFZpZXcSPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5HZXREZXRhaWxQbGFjZW1lbnRWaWV3UmVxdWVzdBo2Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5EZXRhaWxQbGFjZW1lbnRWaWV3", + "Ik6C0+STAjgSNi92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9kZXRh", + "aWxQbGFjZW1lbnRWaWV3cy8qfdpBDXJlc291cmNlX25hbWUaG8pBGGdvb2ds", + "ZWFkcy5nb29nbGVhcGlzLmNvbUKGAgokY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzQh9EZXRhaWxQbGFjZW1lbnRWaWV3U2VydmljZVBy", + "b3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetDetailPlacementViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetDetailPlacementViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [DetailPlacementViewService.GetDetailPlacementView][google.ads.googleads.v3.services.DetailPlacementViewService.GetDetailPlacementView]. + /// + public sealed partial class GetDetailPlacementViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetDetailPlacementViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.DetailPlacementViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDetailPlacementViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDetailPlacementViewRequest(GetDetailPlacementViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDetailPlacementViewRequest Clone() { + return new GetDetailPlacementViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the Detail Placement view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetDetailPlacementViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetDetailPlacementViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetDetailPlacementViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DetailPlacementViewServiceClient.cs b/src/V3/Stubs/DetailPlacementViewServiceClient.cs new file mode 100644 index 000000000..02ef16088 --- /dev/null +++ b/src/V3/Stubs/DetailPlacementViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class DetailPlacementViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static DetailPlacementViewServiceSettings GetDefault() => new DetailPlacementViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public DetailPlacementViewServiceSettings() { } + + private DetailPlacementViewServiceSettings(DetailPlacementViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetDetailPlacementViewSettings = existing.GetDetailPlacementViewSettings; + OnCopy(existing); + } + + partial void OnCopy(DetailPlacementViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// DetailPlacementViewServiceClient.GetDetailPlacementView and DetailPlacementViewServiceClient.GetDetailPlacementViewAsync. + /// + /// + /// The default DetailPlacementViewServiceClient.GetDetailPlacementView and + /// DetailPlacementViewServiceClient.GetDetailPlacementViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetDetailPlacementViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public DetailPlacementViewServiceSettings Clone() => new DetailPlacementViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class DetailPlacementViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public DetailPlacementViewServiceSettings Settings { get; set; } + + /// + public override DetailPlacementViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return DetailPlacementViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return DetailPlacementViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => DetailPlacementViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => DetailPlacementViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => DetailPlacementViewServiceClient.ChannelPool; + } + + /// + /// DetailPlacementViewService client wrapper, for convenient use. + /// + public abstract partial class DetailPlacementViewServiceClient + { + /// + /// The default endpoint for the DetailPlacementViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default DetailPlacementViewService scopes. + /// + /// + /// The default DetailPlacementViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DetailPlacementViewServiceClient client = await DetailPlacementViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DetailPlacementViewServiceClient.DefaultEndpoint.Host, DetailPlacementViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DetailPlacementViewServiceClient client = DetailPlacementViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, DetailPlacementViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DetailPlacementViewServiceClient client = DetailPlacementViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DetailPlacementViewServiceClient.DefaultEndpoint.Host, DetailPlacementViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DetailPlacementViewServiceClient client = DetailPlacementViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static DetailPlacementViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, DetailPlacementViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DetailPlacementViewServiceClient Create(grpccore::Channel channel, DetailPlacementViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DetailPlacementViewServiceClient Create(grpccore::CallInvoker callInvoker, DetailPlacementViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + DetailPlacementViewService.DetailPlacementViewServiceClient grpcClient = new DetailPlacementViewService.DetailPlacementViewServiceClient(callInvoker); + return new DetailPlacementViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC DetailPlacementViewService client. + /// + public virtual DetailPlacementViewService.DetailPlacementViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// + /// Required. The resource name of the Detail Placement view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDetailPlacementViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDetailPlacementViewAsync( + new GetDetailPlacementViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// + /// Required. The resource name of the Detail Placement view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDetailPlacementViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetDetailPlacementViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// + /// Required. The resource name of the Detail Placement view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DetailPlacementView GetDetailPlacementView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDetailPlacementView( + new GetDetailPlacementViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDetailPlacementViewAsync( + GetDetailPlacementViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDetailPlacementViewAsync( + GetDetailPlacementViewRequest request, + st::CancellationToken cancellationToken) => GetDetailPlacementViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DetailPlacementView GetDetailPlacementView( + GetDetailPlacementViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// DetailPlacementViewService client wrapper implementation, for convenient use. + /// + public sealed partial class DetailPlacementViewServiceClientImpl : DetailPlacementViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetDetailPlacementView; + + /// + /// Constructs a client wrapper for the DetailPlacementViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public DetailPlacementViewServiceClientImpl(DetailPlacementViewService.DetailPlacementViewServiceClient grpcClient, DetailPlacementViewServiceSettings settings) + { + GrpcClient = grpcClient; + DetailPlacementViewServiceSettings effectiveSettings = settings ?? DetailPlacementViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetDetailPlacementView = clientHelper.BuildApiCall( + GrpcClient.GetDetailPlacementViewAsync, GrpcClient.GetDetailPlacementView, effectiveSettings.GetDetailPlacementViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetDetailPlacementView); + Modify_GetDetailPlacementViewApiCall(ref _callGetDetailPlacementView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetDetailPlacementViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(DetailPlacementViewService.DetailPlacementViewServiceClient grpcClient, DetailPlacementViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC DetailPlacementViewService client. + /// + public override DetailPlacementViewService.DetailPlacementViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetDetailPlacementViewRequest(ref GetDetailPlacementViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetDetailPlacementViewAsync( + GetDetailPlacementViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDetailPlacementViewRequest(ref request, ref callSettings); + return _callGetDetailPlacementView.Async(request, callSettings); + } + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::DetailPlacementView GetDetailPlacementView( + GetDetailPlacementViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDetailPlacementViewRequest(ref request, ref callSettings); + return _callGetDetailPlacementView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/DetailPlacementViewServiceGrpc.cs b/src/V3/Stubs/DetailPlacementViewServiceGrpc.cs new file mode 100644 index 000000000..0e0b3af14 --- /dev/null +++ b/src/V3/Stubs/DetailPlacementViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/detail_placement_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch Detail Placement views. + /// + public static partial class DetailPlacementViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.DetailPlacementViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetDetailPlacementViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetDetailPlacementViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_DetailPlacementView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetDetailPlacementView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetDetailPlacementView", + __Marshaller_google_ads_googleads_v3_services_GetDetailPlacementViewRequest, + __Marshaller_google_ads_googleads_v3_resources_DetailPlacementView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.DetailPlacementViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of DetailPlacementViewService + public abstract partial class DetailPlacementViewServiceBase + { + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetDetailPlacementView(global::Google.Ads.GoogleAds.V3.Services.GetDetailPlacementViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for DetailPlacementViewService + public partial class DetailPlacementViewServiceClient : grpc::ClientBase + { + /// Creates a new client for DetailPlacementViewService + /// The channel to use to make remote calls. + public DetailPlacementViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for DetailPlacementViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public DetailPlacementViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected DetailPlacementViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected DetailPlacementViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView GetDetailPlacementView(global::Google.Ads.GoogleAds.V3.Services.GetDetailPlacementViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDetailPlacementView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView GetDetailPlacementView(global::Google.Ads.GoogleAds.V3.Services.GetDetailPlacementViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetDetailPlacementView, null, options, request); + } + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDetailPlacementViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetDetailPlacementViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDetailPlacementViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Detail Placement view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDetailPlacementViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetDetailPlacementViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetDetailPlacementView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override DetailPlacementViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new DetailPlacementViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(DetailPlacementViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetDetailPlacementView, serviceImpl.GetDetailPlacementView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, DetailPlacementViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetDetailPlacementView, serviceImpl.GetDetailPlacementView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/Device.cs b/src/V3/Stubs/Device.cs new file mode 100644 index 000000000..66aed6ee1 --- /dev/null +++ b/src/V3/Stubs/Device.cs @@ -0,0 +1,197 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/device.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/device.proto + public static partial class DeviceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/device.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DeviceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cipnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9kZXZpY2UucHJvdG8S", + "HWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29nbGUvYXBpL2Fu", + "bm90YXRpb25zLnByb3RvInYKCkRldmljZUVudW0iaAoGRGV2aWNlEg8KC1VO", + "U1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgoKBk1PQklMRRACEgoKBlRBQkxF", + "VBADEgsKB0RFU0tUT1AQBBIQCgxDT05ORUNURURfVFYQBhIJCgVPVEhFUhAF", + "QuABCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCC0Rldmlj", + "ZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFw", + "aXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2ds", + "ZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVB", + "ZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51", + "bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum), global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.DeviceEnum.Types.Device) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enumeration of Google Ads devices available for targeting. + /// + public sealed partial class DeviceEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DeviceEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.DeviceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DeviceEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DeviceEnum(DeviceEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DeviceEnum Clone() { + return new DeviceEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DeviceEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DeviceEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DeviceEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DeviceEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates Google Ads devices available for targeting. + /// + public enum Device { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Mobile devices with full browsers. + /// + [pbr::OriginalName("MOBILE")] Mobile = 2, + /// + /// Tablets with full browsers. + /// + [pbr::OriginalName("TABLET")] Tablet = 3, + /// + /// Computers. + /// + [pbr::OriginalName("DESKTOP")] Desktop = 4, + /// + /// Smart TVs and game consoles. + /// + [pbr::OriginalName("CONNECTED_TV")] ConnectedTv = 6, + /// + /// Other device types. + /// + [pbr::OriginalName("OTHER")] Other = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DismissRecommendationResponsePartialFailureSupport.cs b/src/V3/Stubs/DismissRecommendationResponsePartialFailureSupport.cs new file mode 100644 index 000000000..df343a7c5 --- /dev/null +++ b/src/V3/Stubs/DismissRecommendationResponsePartialFailureSupport.cs @@ -0,0 +1,46 @@ +// Copyright 2020 Google LLC. All Rights Reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// Generated code - do not edit + +using Google.Ads.GoogleAds.V3.Errors; +using System.Collections.Generic; +using Google.Protobuf.WellKnownTypes; + +namespace Google.Ads.GoogleAds.V3.Services +{ + public sealed partial class DismissRecommendationResponse + { + /// + /// Gets a GoogleAdsFailure instance that combines all the errors + /// from a failed API call. + /// + public GoogleAdsFailure PartialFailure + { + get + { + if (this.PartialFailureError == null) + { + return null; + } + GoogleAdsFailure retval = new GoogleAdsFailure(); + foreach (Any any in this.PartialFailureError.Details) + { + GoogleAdsFailure failure = any.Unpack(); + retval.Errors.AddRange(failure.Errors); + } + return retval; + } + } + } +} diff --git a/src/V3/Stubs/DisplayAdFormatSetting.cs b/src/V3/Stubs/DisplayAdFormatSetting.cs new file mode 100644 index 000000000..042f6c38b --- /dev/null +++ b/src/V3/Stubs/DisplayAdFormatSetting.cs @@ -0,0 +1,191 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/display_ad_format_setting.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/display_ad_format_setting.proto + public static partial class DisplayAdFormatSettingReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/display_ad_format_setting.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DisplayAdFormatSettingReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9kaXNwbGF5X2FkX2Zv", + "cm1hdF9zZXR0aW5nLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKBAQoaRGlzcGxh", + "eUFkRm9ybWF0U2V0dGluZ0VudW0iYwoWRGlzcGxheUFkRm9ybWF0U2V0dGlu", + "ZxIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIPCgtBTExfRk9STUFU", + "UxACEg4KCk5PTl9OQVRJVkUQAxIKCgZOQVRJVkUQBELwAQohY29tLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhtEaXNwbGF5QWRGb3JtYXRTZXR0", + "aW5nUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29v", + "Z2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2ds", + "ZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpF", + "bnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum), global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingEnum.Types.DisplayAdFormatSetting) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for display ad format settings. + /// + public sealed partial class DisplayAdFormatSettingEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DisplayAdFormatSettingEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.DisplayAdFormatSettingReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayAdFormatSettingEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayAdFormatSettingEnum(DisplayAdFormatSettingEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayAdFormatSettingEnum Clone() { + return new DisplayAdFormatSettingEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DisplayAdFormatSettingEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DisplayAdFormatSettingEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DisplayAdFormatSettingEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DisplayAdFormatSettingEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates display ad format settings. + /// + public enum DisplayAdFormatSetting { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Text, image and native formats. + /// + [pbr::OriginalName("ALL_FORMATS")] AllFormats = 2, + /// + /// Text and image formats. + /// + [pbr::OriginalName("NON_NATIVE")] NonNative = 3, + /// + /// Native format, i.e. the format rendering is controlled by the publisher + /// and not by Google. + /// + [pbr::OriginalName("NATIVE")] Native = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DisplayKeywordView.cs b/src/V3/Stubs/DisplayKeywordView.cs new file mode 100644 index 000000000..8f5bab423 --- /dev/null +++ b/src/V3/Stubs/DisplayKeywordView.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/display_keyword_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/display_keyword_view.proto + public static partial class DisplayKeywordViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/display_keyword_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DisplayKeywordViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZGlzcGxheV9r", + "ZXl3b3JkX3ZpZXcucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlcxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29v", + "Z2xlL2FwaS9yZXNvdXJjZS5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90byLTAQoSRGlzcGxheUtleXdvcmRWaWV3EkoKDXJlc291cmNlX25h", + "bWUYASABKAlCM+BBBfpBLQorZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0Rp", + "c3BsYXlLZXl3b3JkVmlldzpx6kFuCitnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b20vRGlzcGxheUtleXdvcmRWaWV3Ej9jdXN0b21lcnMve2N1c3RvbWVyfS9k", + "aXNwbGF5S2V5d29yZFZpZXdzL3tkaXNwbGF5X2tleXdvcmRfdmlld31ChAIK", + "JWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNCF0Rpc3Bs", + "YXlLZXl3b3JkVmlld1Byb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnBy", + "b3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVz", + "b3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3Vy", + "Y2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29v", + "Z2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView), global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A display keyword view. + /// + public sealed partial class DisplayKeywordView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DisplayKeywordView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayKeywordView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayKeywordView(DisplayKeywordView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayKeywordView Clone() { + return new DisplayKeywordView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the display keyword view. + /// Display Keyword view resource names have the form: + /// + /// `customers/{customer_id}/displayKeywordViews/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DisplayKeywordView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DisplayKeywordView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DisplayKeywordView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DisplayKeywordViewService.cs b/src/V3/Stubs/DisplayKeywordViewService.cs new file mode 100644 index 000000000..6e357773f --- /dev/null +++ b/src/V3/Stubs/DisplayKeywordViewService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/display_keyword_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/display_keyword_view_service.proto + public static partial class DisplayKeywordViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/display_keyword_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DisplayKeywordViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9kaXNwbGF5X2tl", + "eXdvcmRfdmlld19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzL2Rpc3BsYXlfa2V5d29yZF92aWV3LnByb3RvGhxnb29nbGUvYXBpL2Fu", + "bm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29v", + "Z2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90byI6ChxHZXREaXNwbGF5S2V5", + "d29yZFZpZXdSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAjKY", + "AgoZRGlzcGxheUtleXdvcmRWaWV3U2VydmljZRLdAQoVR2V0RGlzcGxheUtl", + "eXdvcmRWaWV3Ej4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "R2V0RGlzcGxheUtleXdvcmRWaWV3UmVxdWVzdBo1Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5EaXNwbGF5S2V5d29yZFZpZXciTYLT5JMC", + "NxI1L3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2Rpc3BsYXlLZXl3", + "b3JkVmlld3MvKn3aQQ1yZXNvdXJjZV9uYW1lGhvKQRhnb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb21ChQIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlc0IeRGlzcGxheUtleXdvcmRWaWV3U2VydmljZVByb3RvUAFaSGdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2Vy", + "dmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetDisplayKeywordViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetDisplayKeywordViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [DisplayKeywordViewService.GetDisplayKeywordView][google.ads.googleads.v3.services.DisplayKeywordViewService.GetDisplayKeywordView]. + /// + public sealed partial class GetDisplayKeywordViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetDisplayKeywordViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.DisplayKeywordViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDisplayKeywordViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDisplayKeywordViewRequest(GetDisplayKeywordViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDisplayKeywordViewRequest Clone() { + return new GetDisplayKeywordViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the display keyword view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetDisplayKeywordViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetDisplayKeywordViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetDisplayKeywordViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DisplayKeywordViewServiceClient.cs b/src/V3/Stubs/DisplayKeywordViewServiceClient.cs new file mode 100644 index 000000000..70c21b3d6 --- /dev/null +++ b/src/V3/Stubs/DisplayKeywordViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class DisplayKeywordViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static DisplayKeywordViewServiceSettings GetDefault() => new DisplayKeywordViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public DisplayKeywordViewServiceSettings() { } + + private DisplayKeywordViewServiceSettings(DisplayKeywordViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetDisplayKeywordViewSettings = existing.GetDisplayKeywordViewSettings; + OnCopy(existing); + } + + partial void OnCopy(DisplayKeywordViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// DisplayKeywordViewServiceClient.GetDisplayKeywordView and DisplayKeywordViewServiceClient.GetDisplayKeywordViewAsync. + /// + /// + /// The default DisplayKeywordViewServiceClient.GetDisplayKeywordView and + /// DisplayKeywordViewServiceClient.GetDisplayKeywordViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetDisplayKeywordViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public DisplayKeywordViewServiceSettings Clone() => new DisplayKeywordViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class DisplayKeywordViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public DisplayKeywordViewServiceSettings Settings { get; set; } + + /// + public override DisplayKeywordViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return DisplayKeywordViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return DisplayKeywordViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => DisplayKeywordViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => DisplayKeywordViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => DisplayKeywordViewServiceClient.ChannelPool; + } + + /// + /// DisplayKeywordViewService client wrapper, for convenient use. + /// + public abstract partial class DisplayKeywordViewServiceClient + { + /// + /// The default endpoint for the DisplayKeywordViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default DisplayKeywordViewService scopes. + /// + /// + /// The default DisplayKeywordViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DisplayKeywordViewServiceClient client = await DisplayKeywordViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DisplayKeywordViewServiceClient.DefaultEndpoint.Host, DisplayKeywordViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DisplayKeywordViewServiceClient client = DisplayKeywordViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, DisplayKeywordViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DisplayKeywordViewServiceClient client = DisplayKeywordViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DisplayKeywordViewServiceClient.DefaultEndpoint.Host, DisplayKeywordViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DisplayKeywordViewServiceClient client = DisplayKeywordViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static DisplayKeywordViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, DisplayKeywordViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DisplayKeywordViewServiceClient Create(grpccore::Channel channel, DisplayKeywordViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DisplayKeywordViewServiceClient Create(grpccore::CallInvoker callInvoker, DisplayKeywordViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + DisplayKeywordViewService.DisplayKeywordViewServiceClient grpcClient = new DisplayKeywordViewService.DisplayKeywordViewServiceClient(callInvoker); + return new DisplayKeywordViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC DisplayKeywordViewService client. + /// + public virtual DisplayKeywordViewService.DisplayKeywordViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested display keyword view in full detail. + /// + /// + /// Required. The resource name of the display keyword view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDisplayKeywordViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDisplayKeywordViewAsync( + new GetDisplayKeywordViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested display keyword view in full detail. + /// + /// + /// Required. The resource name of the display keyword view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDisplayKeywordViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetDisplayKeywordViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested display keyword view in full detail. + /// + /// + /// Required. The resource name of the display keyword view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DisplayKeywordView GetDisplayKeywordView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDisplayKeywordView( + new GetDisplayKeywordViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested display keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDisplayKeywordViewAsync( + GetDisplayKeywordViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested display keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDisplayKeywordViewAsync( + GetDisplayKeywordViewRequest request, + st::CancellationToken cancellationToken) => GetDisplayKeywordViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested display keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DisplayKeywordView GetDisplayKeywordView( + GetDisplayKeywordViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// DisplayKeywordViewService client wrapper implementation, for convenient use. + /// + public sealed partial class DisplayKeywordViewServiceClientImpl : DisplayKeywordViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetDisplayKeywordView; + + /// + /// Constructs a client wrapper for the DisplayKeywordViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public DisplayKeywordViewServiceClientImpl(DisplayKeywordViewService.DisplayKeywordViewServiceClient grpcClient, DisplayKeywordViewServiceSettings settings) + { + GrpcClient = grpcClient; + DisplayKeywordViewServiceSettings effectiveSettings = settings ?? DisplayKeywordViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetDisplayKeywordView = clientHelper.BuildApiCall( + GrpcClient.GetDisplayKeywordViewAsync, GrpcClient.GetDisplayKeywordView, effectiveSettings.GetDisplayKeywordViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetDisplayKeywordView); + Modify_GetDisplayKeywordViewApiCall(ref _callGetDisplayKeywordView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetDisplayKeywordViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(DisplayKeywordViewService.DisplayKeywordViewServiceClient grpcClient, DisplayKeywordViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC DisplayKeywordViewService client. + /// + public override DisplayKeywordViewService.DisplayKeywordViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetDisplayKeywordViewRequest(ref GetDisplayKeywordViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested display keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetDisplayKeywordViewAsync( + GetDisplayKeywordViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDisplayKeywordViewRequest(ref request, ref callSettings); + return _callGetDisplayKeywordView.Async(request, callSettings); + } + + /// + /// Returns the requested display keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::DisplayKeywordView GetDisplayKeywordView( + GetDisplayKeywordViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDisplayKeywordViewRequest(ref request, ref callSettings); + return _callGetDisplayKeywordView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/DisplayKeywordViewServiceGrpc.cs b/src/V3/Stubs/DisplayKeywordViewServiceGrpc.cs new file mode 100644 index 000000000..0c47fd0df --- /dev/null +++ b/src/V3/Stubs/DisplayKeywordViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/display_keyword_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage display keyword views. + /// + public static partial class DisplayKeywordViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.DisplayKeywordViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetDisplayKeywordViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetDisplayKeywordViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_DisplayKeywordView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetDisplayKeywordView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetDisplayKeywordView", + __Marshaller_google_ads_googleads_v3_services_GetDisplayKeywordViewRequest, + __Marshaller_google_ads_googleads_v3_resources_DisplayKeywordView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.DisplayKeywordViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of DisplayKeywordViewService + public abstract partial class DisplayKeywordViewServiceBase + { + /// + /// Returns the requested display keyword view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetDisplayKeywordView(global::Google.Ads.GoogleAds.V3.Services.GetDisplayKeywordViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for DisplayKeywordViewService + public partial class DisplayKeywordViewServiceClient : grpc::ClientBase + { + /// Creates a new client for DisplayKeywordViewService + /// The channel to use to make remote calls. + public DisplayKeywordViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for DisplayKeywordViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public DisplayKeywordViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected DisplayKeywordViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected DisplayKeywordViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested display keyword view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView GetDisplayKeywordView(global::Google.Ads.GoogleAds.V3.Services.GetDisplayKeywordViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDisplayKeywordView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested display keyword view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView GetDisplayKeywordView(global::Google.Ads.GoogleAds.V3.Services.GetDisplayKeywordViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetDisplayKeywordView, null, options, request); + } + /// + /// Returns the requested display keyword view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDisplayKeywordViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetDisplayKeywordViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDisplayKeywordViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested display keyword view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDisplayKeywordViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetDisplayKeywordViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetDisplayKeywordView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override DisplayKeywordViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new DisplayKeywordViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(DisplayKeywordViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetDisplayKeywordView, serviceImpl.GetDisplayKeywordView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, DisplayKeywordViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetDisplayKeywordView, serviceImpl.GetDisplayKeywordView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/DisplayUploadProductType.cs b/src/V3/Stubs/DisplayUploadProductType.cs new file mode 100644 index 000000000..3285dc611 --- /dev/null +++ b/src/V3/Stubs/DisplayUploadProductType.cs @@ -0,0 +1,246 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/display_upload_product_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/display_upload_product_type.proto + public static partial class DisplayUploadProductTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/display_upload_product_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DisplayUploadProductTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9kaXNwbGF5X3VwbG9h", + "ZF9wcm9kdWN0X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvwCChxEaXNw", + "bGF5VXBsb2FkUHJvZHVjdFR5cGVFbnVtItsCChhEaXNwbGF5VXBsb2FkUHJv", + "ZHVjdFR5cGUSDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESEwoPSFRN", + "TDVfVVBMT0FEX0FEEAISHgoaRFlOQU1JQ19IVE1MNV9FRFVDQVRJT05fQUQQ", + "AxIbChdEWU5BTUlDX0hUTUw1X0ZMSUdIVF9BRBAEEiEKHURZTkFNSUNfSFRN", + "TDVfSE9URUxfUkVOVEFMX0FEEAUSGAoURFlOQU1JQ19IVE1MNV9KT0JfQUQQ", + "BhIaChZEWU5BTUlDX0hUTUw1X0xPQ0FMX0FEEAcSIAocRFlOQU1JQ19IVE1M", + "NV9SRUFMX0VTVEFURV9BRBAIEhsKF0RZTkFNSUNfSFRNTDVfQ1VTVE9NX0FE", + "EAkSGwoXRFlOQU1JQ19IVE1MNV9UUkFWRUxfQUQQChIaChZEWU5BTUlDX0hU", + "TUw1X0hPVEVMX0FEEAtC8gEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtc0IdRGlzcGxheVVwbG9hZFByb2R1Y3RUeXBlUHJvdG9QAVpCZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVB", + "ZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oC", + "IUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.DisplayUploadProductTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.DisplayUploadProductTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.DisplayUploadProductTypeEnum.Types.DisplayUploadProductType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for display upload product types. Product types that have the word + /// "DYNAMIC" in them must be associated with a campaign that has a dynamic + /// remarketing feed. See https://support.google.com/google-ads/answer/6053288 + /// for more info about dynamic remarketing. Other product types are regarded + /// as "static" and do not have this requirement. + /// + public sealed partial class DisplayUploadProductTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DisplayUploadProductTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.DisplayUploadProductTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayUploadProductTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayUploadProductTypeEnum(DisplayUploadProductTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DisplayUploadProductTypeEnum Clone() { + return new DisplayUploadProductTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DisplayUploadProductTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DisplayUploadProductTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DisplayUploadProductTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DisplayUploadProductTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates display upload product types. + /// + public enum DisplayUploadProductType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// HTML5 upload ad. This product type requires the upload_media_bundle + /// field in DisplayUploadAdInfo to be set. + /// + [pbr::OriginalName("HTML5_UPLOAD_AD")] Html5UploadAd = 2, + /// + /// Dynamic HTML5 education ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in an education campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_EDUCATION_AD")] DynamicHtml5EducationAd = 3, + /// + /// Dynamic HTML5 flight ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in a flight campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_FLIGHT_AD")] DynamicHtml5FlightAd = 4, + /// + /// Dynamic HTML5 hotel and rental ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in a hotel campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_HOTEL_RENTAL_AD")] DynamicHtml5HotelRentalAd = 5, + /// + /// Dynamic HTML5 job ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in a job campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_JOB_AD")] DynamicHtml5JobAd = 6, + /// + /// Dynamic HTML5 local ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in a local campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_LOCAL_AD")] DynamicHtml5LocalAd = 7, + /// + /// Dynamic HTML5 real estate ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in a real estate campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_REAL_ESTATE_AD")] DynamicHtml5RealEstateAd = 8, + /// + /// Dynamic HTML5 custom ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in a custom campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_CUSTOM_AD")] DynamicHtml5CustomAd = 9, + /// + /// Dynamic HTML5 travel ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in a travel campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_TRAVEL_AD")] DynamicHtml5TravelAd = 10, + /// + /// Dynamic HTML5 hotel ad. This product type requires the + /// upload_media_bundle field in DisplayUploadAdInfo to be set. Can only be + /// used in a hotel campaign. + /// + [pbr::OriginalName("DYNAMIC_HTML5_HOTEL_AD")] DynamicHtml5HotelAd = 11, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DistanceBucket.cs b/src/V3/Stubs/DistanceBucket.cs new file mode 100644 index 000000000..f98f125ab --- /dev/null +++ b/src/V3/Stubs/DistanceBucket.cs @@ -0,0 +1,297 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/distance_bucket.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/distance_bucket.proto + public static partial class DistanceBucketReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/distance_bucket.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DistanceBucketReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9kaXN0YW5jZV9idWNr", + "ZXQucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvIq0EChJEaXN0YW5jZUJ1Y2tldEVu", + "dW0ilgQKDkRpc3RhbmNlQnVja2V0Eg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5L", + "Tk9XThABEg8KC1dJVEhJTl83MDBNEAISDgoKV0lUSElOXzFLTRADEg4KCldJ", + "VEhJTl81S00QBBIPCgtXSVRISU5fMTBLTRAFEg8KC1dJVEhJTl8xNUtNEAYS", + "DwoLV0lUSElOXzIwS00QBxIPCgtXSVRISU5fMjVLTRAIEg8KC1dJVEhJTl8z", + "MEtNEAkSDwoLV0lUSElOXzM1S00QChIPCgtXSVRISU5fNDBLTRALEg8KC1dJ", + "VEhJTl80NUtNEAwSDwoLV0lUSElOXzUwS00QDRIPCgtXSVRISU5fNTVLTRAO", + "Eg8KC1dJVEhJTl82MEtNEA8SDwoLV0lUSElOXzY1S00QEBIPCgtCRVlPTkRf", + "NjVLTRAREhMKD1dJVEhJTl8wXzdNSUxFUxASEhAKDFdJVEhJTl8xTUlMRRAT", + "EhEKDVdJVEhJTl81TUlMRVMQFBISCg5XSVRISU5fMTBNSUxFUxAVEhIKDldJ", + "VEhJTl8xNU1JTEVTEBYSEgoOV0lUSElOXzIwTUlMRVMQFxISCg5XSVRISU5f", + "MjVNSUxFUxAYEhIKDldJVEhJTl8zME1JTEVTEBkSEgoOV0lUSElOXzM1TUlM", + "RVMQGhISCg5XSVRISU5fNDBNSUxFUxAbEhIKDkJFWU9ORF80ME1JTEVTEBxC", + "6AEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0ITRGlzdGFu", + "Y2VCdWNrZXRQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9n", + "b29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGq", + "Ah1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNc", + "R29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.DistanceBucketEnum), global::Google.Ads.GoogleAds.V3.Enums.DistanceBucketEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.DistanceBucketEnum.Types.DistanceBucket) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for distance buckets of a user’s distance from an advertiser’s + /// location extension. + /// + public sealed partial class DistanceBucketEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DistanceBucketEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.DistanceBucketReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistanceBucketEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistanceBucketEnum(DistanceBucketEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistanceBucketEnum Clone() { + return new DistanceBucketEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DistanceBucketEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DistanceBucketEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DistanceBucketEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DistanceBucketEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The distance bucket for a user’s distance from an advertiser’s location + /// extension. + /// + public enum DistanceBucket { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// User was within 700m of the location. + /// + [pbr::OriginalName("WITHIN_700M")] Within700M = 2, + /// + /// User was within 1KM of the location. + /// + [pbr::OriginalName("WITHIN_1KM")] Within1Km = 3, + /// + /// User was within 5KM of the location. + /// + [pbr::OriginalName("WITHIN_5KM")] Within5Km = 4, + /// + /// User was within 10KM of the location. + /// + [pbr::OriginalName("WITHIN_10KM")] Within10Km = 5, + /// + /// User was within 15KM of the location. + /// + [pbr::OriginalName("WITHIN_15KM")] Within15Km = 6, + /// + /// User was within 20KM of the location. + /// + [pbr::OriginalName("WITHIN_20KM")] Within20Km = 7, + /// + /// User was within 25KM of the location. + /// + [pbr::OriginalName("WITHIN_25KM")] Within25Km = 8, + /// + /// User was within 30KM of the location. + /// + [pbr::OriginalName("WITHIN_30KM")] Within30Km = 9, + /// + /// User was within 35KM of the location. + /// + [pbr::OriginalName("WITHIN_35KM")] Within35Km = 10, + /// + /// User was within 40KM of the location. + /// + [pbr::OriginalName("WITHIN_40KM")] Within40Km = 11, + /// + /// User was within 45KM of the location. + /// + [pbr::OriginalName("WITHIN_45KM")] Within45Km = 12, + /// + /// User was within 50KM of the location. + /// + [pbr::OriginalName("WITHIN_50KM")] Within50Km = 13, + /// + /// User was within 55KM of the location. + /// + [pbr::OriginalName("WITHIN_55KM")] Within55Km = 14, + /// + /// User was within 60KM of the location. + /// + [pbr::OriginalName("WITHIN_60KM")] Within60Km = 15, + /// + /// User was within 65KM of the location. + /// + [pbr::OriginalName("WITHIN_65KM")] Within65Km = 16, + /// + /// User was beyond 65KM of the location. + /// + [pbr::OriginalName("BEYOND_65KM")] Beyond65Km = 17, + /// + /// User was within 0.7 miles of the location. + /// + [pbr::OriginalName("WITHIN_0_7MILES")] Within07Miles = 18, + /// + /// User was within 1 mile of the location. + /// + [pbr::OriginalName("WITHIN_1MILE")] Within1Mile = 19, + /// + /// User was within 5 miles of the location. + /// + [pbr::OriginalName("WITHIN_5MILES")] Within5Miles = 20, + /// + /// User was within 10 miles of the location. + /// + [pbr::OriginalName("WITHIN_10MILES")] Within10Miles = 21, + /// + /// User was within 15 miles of the location. + /// + [pbr::OriginalName("WITHIN_15MILES")] Within15Miles = 22, + /// + /// User was within 20 miles of the location. + /// + [pbr::OriginalName("WITHIN_20MILES")] Within20Miles = 23, + /// + /// User was within 25 miles of the location. + /// + [pbr::OriginalName("WITHIN_25MILES")] Within25Miles = 24, + /// + /// User was within 30 miles of the location. + /// + [pbr::OriginalName("WITHIN_30MILES")] Within30Miles = 25, + /// + /// User was within 35 miles of the location. + /// + [pbr::OriginalName("WITHIN_35MILES")] Within35Miles = 26, + /// + /// User was within 40 miles of the location. + /// + [pbr::OriginalName("WITHIN_40MILES")] Within40Miles = 27, + /// + /// User was beyond 40 miles of the location. + /// + [pbr::OriginalName("BEYOND_40MILES")] Beyond40Miles = 28, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DistanceView.cs b/src/V3/Stubs/DistanceView.cs new file mode 100644 index 000000000..503640a7b --- /dev/null +++ b/src/V3/Stubs/DistanceView.cs @@ -0,0 +1,271 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/distance_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/distance_view.proto + public static partial class DistanceViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/distance_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DistanceViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZGlzdGFuY2Vf", + "dmlldy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "GjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9kaXN0YW5jZV9idWNr", + "ZXQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdv", + "b2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFw", + "cGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLMAgoM", + "RGlzdGFuY2VWaWV3EkQKDXJlc291cmNlX25hbWUYASABKAlCLeBBBfpBJwol", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0Rpc3RhbmNlVmlldxJeCg9kaXN0", + "YW5jZV9idWNrZXQYAiABKA4yQC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcy5EaXN0YW5jZUJ1Y2tldEVudW0uRGlzdGFuY2VCdWNrZXRCA+BBAxI2", + "Cg1tZXRyaWNfc3lzdGVtGAMgASgLMhouZ29vZ2xlLnByb3RvYnVmLkJvb2xW", + "YWx1ZUID4EEDOl7qQVsKJWdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9EaXN0", + "YW5jZVZpZXcSMmN1c3RvbWVycy97Y3VzdG9tZXJ9L2Rpc3RhbmNlVmlld3Mv", + "e2Rpc3RhbmNlX3ZpZXd9Qv4BCiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzQhFEaXN0YW5jZVZpZXdQcm90b1ABWkpnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "cmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xl", + "QWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJl", + "c291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJj", + "ZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.DistanceBucketReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.DistanceView), global::Google.Ads.GoogleAds.V3.Resources.DistanceView.Parser, new[]{ "ResourceName", "DistanceBucket", "MetricSystem" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A distance view with metrics aggregated by the user's distance from an + /// advertiser's location extensions. Each DistanceBucket includes all + /// impressions that fall within its distance and a single impression will + /// contribute to the metrics for all DistanceBuckets that include the user's + /// distance. + /// + public sealed partial class DistanceView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DistanceView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.DistanceViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistanceView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistanceView(DistanceView other) : this() { + resourceName_ = other.resourceName_; + distanceBucket_ = other.distanceBucket_; + MetricSystem = other.MetricSystem; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistanceView Clone() { + return new DistanceView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the distance view. + /// Distance view resource names have the form: + /// + /// `customers/{customer_id}/distanceViews/1~{distance_bucket}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "distance_bucket" field. + public const int DistanceBucketFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.DistanceBucketEnum.Types.DistanceBucket distanceBucket_ = 0; + /// + /// Output only. Grouping of user distance from location extensions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DistanceBucketEnum.Types.DistanceBucket DistanceBucket { + get { return distanceBucket_; } + set { + distanceBucket_ = value; + } + } + + /// Field number for the "metric_system" field. + public const int MetricSystemFieldNumber = 3; + private static readonly pb::FieldCodec _single_metricSystem_codec = pb::FieldCodec.ForStructWrapper(26); + private bool? metricSystem_; + /// + /// Output only. True if the DistanceBucket is using the metric system, false otherwise. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? MetricSystem { + get { return metricSystem_; } + set { + metricSystem_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DistanceView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DistanceView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (DistanceBucket != other.DistanceBucket) return false; + if (MetricSystem != other.MetricSystem) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (DistanceBucket != 0) hash ^= DistanceBucket.GetHashCode(); + if (metricSystem_ != null) hash ^= MetricSystem.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (DistanceBucket != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) DistanceBucket); + } + if (metricSystem_ != null) { + _single_metricSystem_codec.WriteTagAndValue(output, MetricSystem); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (DistanceBucket != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DistanceBucket); + } + if (metricSystem_ != null) { + size += _single_metricSystem_codec.CalculateSizeWithTag(MetricSystem); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DistanceView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.DistanceBucket != 0) { + DistanceBucket = other.DistanceBucket; + } + if (other.metricSystem_ != null) { + if (metricSystem_ == null || other.MetricSystem != false) { + MetricSystem = other.MetricSystem; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 16: { + DistanceBucket = (global::Google.Ads.GoogleAds.V3.Enums.DistanceBucketEnum.Types.DistanceBucket) input.ReadEnum(); + break; + } + case 26: { + bool? value = _single_metricSystem_codec.Read(input); + if (metricSystem_ == null || value != false) { + MetricSystem = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DistanceViewService.cs b/src/V3/Stubs/DistanceViewService.cs new file mode 100644 index 000000000..c42e99abc --- /dev/null +++ b/src/V3/Stubs/DistanceViewService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/distance_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/distance_view_service.proto + public static partial class DistanceViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/distance_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DistanceViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9kaXN0YW5jZV92", + "aWV3X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzGjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZGlz", + "dGFuY2Vfdmlldy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRf", + "YmVoYXZpb3IucHJvdG8iNAoWR2V0RGlzdGFuY2VWaWV3UmVxdWVzdBIaCg1y", + "ZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIy+gEKE0Rpc3RhbmNlVmlld1NlcnZp", + "Y2USxQEKD0dldERpc3RhbmNlVmlldxI4Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLkdldERpc3RhbmNlVmlld1JlcXVlc3QaLy5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuRGlzdGFuY2VWaWV3IkeC0+ST", + "AjESLy92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9kaXN0YW5jZVZp", + "ZXdzLyp92kENcmVzb3VyY2VfbmFtZRobykEYZ29vZ2xlYWRzLmdvb2dsZWFw", + "aXMuY29tQv8BCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXNCGERpc3RhbmNlVmlld1NlcnZpY2VQcm90b1ABWkhnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvc2Vy", + "dmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdvb2dsZUFkcy5W", + "My5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz", + "6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.DistanceViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetDistanceViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetDistanceViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [DistanceViewService.GetDistanceView][google.ads.googleads.v3.services.DistanceViewService.GetDistanceView]. + /// + public sealed partial class GetDistanceViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetDistanceViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.DistanceViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDistanceViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDistanceViewRequest(GetDistanceViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDistanceViewRequest Clone() { + return new GetDistanceViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the distance view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetDistanceViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetDistanceViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetDistanceViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DistanceViewServiceClient.cs b/src/V3/Stubs/DistanceViewServiceClient.cs new file mode 100644 index 000000000..e6cde89fa --- /dev/null +++ b/src/V3/Stubs/DistanceViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class DistanceViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static DistanceViewServiceSettings GetDefault() => new DistanceViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public DistanceViewServiceSettings() { } + + private DistanceViewServiceSettings(DistanceViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetDistanceViewSettings = existing.GetDistanceViewSettings; + OnCopy(existing); + } + + partial void OnCopy(DistanceViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// DistanceViewServiceClient.GetDistanceView and DistanceViewServiceClient.GetDistanceViewAsync. + /// + /// + /// The default DistanceViewServiceClient.GetDistanceView and + /// DistanceViewServiceClient.GetDistanceViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetDistanceViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public DistanceViewServiceSettings Clone() => new DistanceViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class DistanceViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public DistanceViewServiceSettings Settings { get; set; } + + /// + public override DistanceViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return DistanceViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return DistanceViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => DistanceViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => DistanceViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => DistanceViewServiceClient.ChannelPool; + } + + /// + /// DistanceViewService client wrapper, for convenient use. + /// + public abstract partial class DistanceViewServiceClient + { + /// + /// The default endpoint for the DistanceViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default DistanceViewService scopes. + /// + /// + /// The default DistanceViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DistanceViewServiceClient client = await DistanceViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DistanceViewServiceClient.DefaultEndpoint.Host, DistanceViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DistanceViewServiceClient client = DistanceViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, DistanceViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DistanceViewServiceClient client = DistanceViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DistanceViewServiceClient.DefaultEndpoint.Host, DistanceViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DistanceViewServiceClient client = DistanceViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static DistanceViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, DistanceViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DistanceViewServiceClient Create(grpccore::Channel channel, DistanceViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DistanceViewServiceClient Create(grpccore::CallInvoker callInvoker, DistanceViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + DistanceViewService.DistanceViewServiceClient grpcClient = new DistanceViewService.DistanceViewServiceClient(callInvoker); + return new DistanceViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC DistanceViewService client. + /// + public virtual DistanceViewService.DistanceViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the attributes of the requested distance view. + /// + /// + /// Required. The resource name of the distance view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDistanceViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDistanceViewAsync( + new GetDistanceViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the attributes of the requested distance view. + /// + /// + /// Required. The resource name of the distance view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDistanceViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetDistanceViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the attributes of the requested distance view. + /// + /// + /// Required. The resource name of the distance view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DistanceView GetDistanceView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDistanceView( + new GetDistanceViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the attributes of the requested distance view. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDistanceViewAsync( + GetDistanceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the attributes of the requested distance view. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDistanceViewAsync( + GetDistanceViewRequest request, + st::CancellationToken cancellationToken) => GetDistanceViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the attributes of the requested distance view. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DistanceView GetDistanceView( + GetDistanceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// DistanceViewService client wrapper implementation, for convenient use. + /// + public sealed partial class DistanceViewServiceClientImpl : DistanceViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetDistanceView; + + /// + /// Constructs a client wrapper for the DistanceViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public DistanceViewServiceClientImpl(DistanceViewService.DistanceViewServiceClient grpcClient, DistanceViewServiceSettings settings) + { + GrpcClient = grpcClient; + DistanceViewServiceSettings effectiveSettings = settings ?? DistanceViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetDistanceView = clientHelper.BuildApiCall( + GrpcClient.GetDistanceViewAsync, GrpcClient.GetDistanceView, effectiveSettings.GetDistanceViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetDistanceView); + Modify_GetDistanceViewApiCall(ref _callGetDistanceView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetDistanceViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(DistanceViewService.DistanceViewServiceClient grpcClient, DistanceViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC DistanceViewService client. + /// + public override DistanceViewService.DistanceViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetDistanceViewRequest(ref GetDistanceViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the attributes of the requested distance view. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetDistanceViewAsync( + GetDistanceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDistanceViewRequest(ref request, ref callSettings); + return _callGetDistanceView.Async(request, callSettings); + } + + /// + /// Returns the attributes of the requested distance view. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::DistanceView GetDistanceView( + GetDistanceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDistanceViewRequest(ref request, ref callSettings); + return _callGetDistanceView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/DistanceViewServiceGrpc.cs b/src/V3/Stubs/DistanceViewServiceGrpc.cs new file mode 100644 index 000000000..6e56a8d2d --- /dev/null +++ b/src/V3/Stubs/DistanceViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/distance_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch distance views. + /// + public static partial class DistanceViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.DistanceViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetDistanceViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetDistanceViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_DistanceView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.DistanceView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetDistanceView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetDistanceView", + __Marshaller_google_ads_googleads_v3_services_GetDistanceViewRequest, + __Marshaller_google_ads_googleads_v3_resources_DistanceView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.DistanceViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of DistanceViewService + public abstract partial class DistanceViewServiceBase + { + /// + /// Returns the attributes of the requested distance view. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetDistanceView(global::Google.Ads.GoogleAds.V3.Services.GetDistanceViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for DistanceViewService + public partial class DistanceViewServiceClient : grpc::ClientBase + { + /// Creates a new client for DistanceViewService + /// The channel to use to make remote calls. + public DistanceViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for DistanceViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public DistanceViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected DistanceViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected DistanceViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the attributes of the requested distance view. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DistanceView GetDistanceView(global::Google.Ads.GoogleAds.V3.Services.GetDistanceViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDistanceView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the attributes of the requested distance view. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DistanceView GetDistanceView(global::Google.Ads.GoogleAds.V3.Services.GetDistanceViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetDistanceView, null, options, request); + } + /// + /// Returns the attributes of the requested distance view. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDistanceViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetDistanceViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDistanceViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the attributes of the requested distance view. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDistanceViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetDistanceViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetDistanceView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override DistanceViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new DistanceViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(DistanceViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetDistanceView, serviceImpl.GetDistanceView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, DistanceViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetDistanceView, serviceImpl.GetDistanceView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/DistinctError.cs b/src/V3/Stubs/DistinctError.cs new file mode 100644 index 000000000..77bc8d90c --- /dev/null +++ b/src/V3/Stubs/DistinctError.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/distinct_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/distinct_error.proto + public static partial class DistinctErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/distinct_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DistinctErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZGlzdGluY3RfZXJy", + "b3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJtChFEaXN0aW5jdEVycm9yRW51", + "bSJYCg1EaXN0aW5jdEVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9X", + "ThABEhUKEURVUExJQ0FURV9FTEVNRU5UEAISEgoORFVQTElDQVRFX1RZUEUQ", + "A0LtAQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0ISRGlz", + "dGluY3RFcnJvclByb3RvUAFaRGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3Rv", + "L2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lcnJvcnM7ZXJyb3JzogID", + "R0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRXJyb3JzygIeR29vZ2xl", + "XEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdvb2ds", + "ZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.DistinctErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.DistinctErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.DistinctErrorEnum.Types.DistinctError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible distinct errors. + /// + public sealed partial class DistinctErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DistinctErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.DistinctErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistinctErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistinctErrorEnum(DistinctErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DistinctErrorEnum Clone() { + return new DistinctErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DistinctErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DistinctErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DistinctErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DistinctErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible distinct errors. + /// + public enum DistinctError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Duplicate element. + /// + [pbr::OriginalName("DUPLICATE_ELEMENT")] DuplicateElement = 2, + /// + /// Duplicate type. + /// + [pbr::OriginalName("DUPLICATE_TYPE")] DuplicateType = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DomainCategory.cs b/src/V3/Stubs/DomainCategory.cs new file mode 100644 index 000000000..308920f9c --- /dev/null +++ b/src/V3/Stubs/DomainCategory.cs @@ -0,0 +1,512 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/domain_category.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/domain_category.proto + public static partial class DomainCategoryReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/domain_category.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DomainCategoryReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZG9tYWluX2Nh", + "dGVnb3J5LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMaH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9h", + "cGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5w", + "cm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKwBQoORG9tYWlu", + "Q2F0ZWdvcnkSRgoNcmVzb3VyY2VfbmFtZRgBIAEoCUIv4EEF+kEpCidnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb20vRG9tYWluQ2F0ZWdvcnkSWQoIY2FtcGFp", + "Z24YAiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCKeBBA/pB", + "IwohZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0NhbXBhaWduEjMKCGNhdGVn", + "b3J5GAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMS", + "OAoNbGFuZ3VhZ2VfY29kZRgEIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZUID4EEDEjEKBmRvbWFpbhgFIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZUID4EEDEjwKEWNvdmVyYWdlX2ZyYWN0aW9uGAYgASgL", + "MhwuZ29vZ2xlLnByb3RvYnVmLkRvdWJsZVZhbHVlQgPgQQMSNwoNY2F0ZWdv", + "cnlfcmFuaxgHIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPg", + "QQMSNQoMaGFzX2NoaWxkcmVuGAggASgLMhouZ29vZ2xlLnByb3RvYnVmLkJv", + "b2xWYWx1ZUID4EEDEkQKGnJlY29tbWVuZGVkX2NwY19iaWRfbWljcm9zGAkg", + "ASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWVCA+BBAzpl6kFiCidn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRG9tYWluQ2F0ZWdvcnkSN2N1c3Rv", + "bWVycy97Y3VzdG9tZXJ9L2RvbWFpbkNhdGVnb3JpZXMve2RvbWFpbl9jYXRl", + "Z29yeX1CgAIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXNCE0RvbWFpbkNhdGVnb3J5UHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNl", + "cztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5S", + "ZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPq", + "AiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.DomainCategory), global::Google.Ads.GoogleAds.V3.Resources.DomainCategory.Parser, new[]{ "ResourceName", "Campaign", "Category", "LanguageCode", "Domain", "CoverageFraction", "CategoryRank", "HasChildren", "RecommendedCpcBidMicros" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A category generated automatically by crawling a domain. If a campaign uses + /// the DynamicSearchAdsSetting, then domain categories will be generated for + /// the domain. The categories can be targeted using WebpageConditionInfo. + /// See: https://support.google.com/google-ads/answer/2471185 + /// + public sealed partial class DomainCategory : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DomainCategory()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.DomainCategoryReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DomainCategory() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DomainCategory(DomainCategory other) : this() { + resourceName_ = other.resourceName_; + Campaign = other.Campaign; + Category = other.Category; + LanguageCode = other.LanguageCode; + Domain = other.Domain; + CoverageFraction = other.CoverageFraction; + CategoryRank = other.CategoryRank; + HasChildren = other.HasChildren; + RecommendedCpcBidMicros = other.RecommendedCpcBidMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DomainCategory Clone() { + return new DomainCategory(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the domain category. + /// Domain category resource names have the form: + /// + /// `customers/{customer_id}/domainCategories/{campaign_id}~{category_base64}~{language_code}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 2; + private static readonly pb::FieldCodec _single_campaign_codec = pb::FieldCodec.ForClassWrapper(18); + private string campaign_; + /// + /// Output only. The campaign this category is recommended for. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + + /// Field number for the "category" field. + public const int CategoryFieldNumber = 3; + private static readonly pb::FieldCodec _single_category_codec = pb::FieldCodec.ForClassWrapper(26); + private string category_; + /// + /// Output only. Recommended category for the website domain. e.g. if you have a website + /// about electronics, the categories could be "cameras", "televisions", etc. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Category { + get { return category_; } + set { + category_ = value; + } + } + + + /// Field number for the "language_code" field. + public const int LanguageCodeFieldNumber = 4; + private static readonly pb::FieldCodec _single_languageCode_codec = pb::FieldCodec.ForClassWrapper(34); + private string languageCode_; + /// + /// Output only. The language code specifying the language of the website. e.g. "en" for + /// English. The language can be specified in the DynamicSearchAdsSetting + /// required for dynamic search ads. This is the language of the pages from + /// your website that you want Google Ads to find, create ads for, + /// and match searches with. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LanguageCode { + get { return languageCode_; } + set { + languageCode_ = value; + } + } + + + /// Field number for the "domain" field. + public const int DomainFieldNumber = 5; + private static readonly pb::FieldCodec _single_domain_codec = pb::FieldCodec.ForClassWrapper(42); + private string domain_; + /// + /// Output only. The domain for the website. The domain can be specified in the + /// DynamicSearchAdsSetting required for dynamic search ads. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Domain { + get { return domain_; } + set { + domain_ = value; + } + } + + + /// Field number for the "coverage_fraction" field. + public const int CoverageFractionFieldNumber = 6; + private static readonly pb::FieldCodec _single_coverageFraction_codec = pb::FieldCodec.ForStructWrapper(50); + private double? coverageFraction_; + /// + /// Output only. Fraction of pages on your site that this category matches. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? CoverageFraction { + get { return coverageFraction_; } + set { + coverageFraction_ = value; + } + } + + + /// Field number for the "category_rank" field. + public const int CategoryRankFieldNumber = 7; + private static readonly pb::FieldCodec _single_categoryRank_codec = pb::FieldCodec.ForStructWrapper(58); + private long? categoryRank_; + /// + /// Output only. The position of this category in the set of categories. Lower numbers + /// indicate a better match for the domain. null indicates not recommended. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CategoryRank { + get { return categoryRank_; } + set { + categoryRank_ = value; + } + } + + + /// Field number for the "has_children" field. + public const int HasChildrenFieldNumber = 8; + private static readonly pb::FieldCodec _single_hasChildren_codec = pb::FieldCodec.ForStructWrapper(66); + private bool? hasChildren_; + /// + /// Output only. Indicates whether this category has sub-categories. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? HasChildren { + get { return hasChildren_; } + set { + hasChildren_ = value; + } + } + + + /// Field number for the "recommended_cpc_bid_micros" field. + public const int RecommendedCpcBidMicrosFieldNumber = 9; + private static readonly pb::FieldCodec _single_recommendedCpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(74); + private long? recommendedCpcBidMicros_; + /// + /// Output only. The recommended cost per click for the category. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? RecommendedCpcBidMicros { + get { return recommendedCpcBidMicros_; } + set { + recommendedCpcBidMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DomainCategory); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DomainCategory other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Campaign != other.Campaign) return false; + if (Category != other.Category) return false; + if (LanguageCode != other.LanguageCode) return false; + if (Domain != other.Domain) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(CoverageFraction, other.CoverageFraction)) return false; + if (CategoryRank != other.CategoryRank) return false; + if (HasChildren != other.HasChildren) return false; + if (RecommendedCpcBidMicros != other.RecommendedCpcBidMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + if (category_ != null) hash ^= Category.GetHashCode(); + if (languageCode_ != null) hash ^= LanguageCode.GetHashCode(); + if (domain_ != null) hash ^= Domain.GetHashCode(); + if (coverageFraction_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(CoverageFraction); + if (categoryRank_ != null) hash ^= CategoryRank.GetHashCode(); + if (hasChildren_ != null) hash ^= HasChildren.GetHashCode(); + if (recommendedCpcBidMicros_ != null) hash ^= RecommendedCpcBidMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (campaign_ != null) { + _single_campaign_codec.WriteTagAndValue(output, Campaign); + } + if (category_ != null) { + _single_category_codec.WriteTagAndValue(output, Category); + } + if (languageCode_ != null) { + _single_languageCode_codec.WriteTagAndValue(output, LanguageCode); + } + if (domain_ != null) { + _single_domain_codec.WriteTagAndValue(output, Domain); + } + if (coverageFraction_ != null) { + _single_coverageFraction_codec.WriteTagAndValue(output, CoverageFraction); + } + if (categoryRank_ != null) { + _single_categoryRank_codec.WriteTagAndValue(output, CategoryRank); + } + if (hasChildren_ != null) { + _single_hasChildren_codec.WriteTagAndValue(output, HasChildren); + } + if (recommendedCpcBidMicros_ != null) { + _single_recommendedCpcBidMicros_codec.WriteTagAndValue(output, RecommendedCpcBidMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (campaign_ != null) { + size += _single_campaign_codec.CalculateSizeWithTag(Campaign); + } + if (category_ != null) { + size += _single_category_codec.CalculateSizeWithTag(Category); + } + if (languageCode_ != null) { + size += _single_languageCode_codec.CalculateSizeWithTag(LanguageCode); + } + if (domain_ != null) { + size += _single_domain_codec.CalculateSizeWithTag(Domain); + } + if (coverageFraction_ != null) { + size += _single_coverageFraction_codec.CalculateSizeWithTag(CoverageFraction); + } + if (categoryRank_ != null) { + size += _single_categoryRank_codec.CalculateSizeWithTag(CategoryRank); + } + if (hasChildren_ != null) { + size += _single_hasChildren_codec.CalculateSizeWithTag(HasChildren); + } + if (recommendedCpcBidMicros_ != null) { + size += _single_recommendedCpcBidMicros_codec.CalculateSizeWithTag(RecommendedCpcBidMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DomainCategory other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.campaign_ != null) { + if (campaign_ == null || other.Campaign != "") { + Campaign = other.Campaign; + } + } + if (other.category_ != null) { + if (category_ == null || other.Category != "") { + Category = other.Category; + } + } + if (other.languageCode_ != null) { + if (languageCode_ == null || other.LanguageCode != "") { + LanguageCode = other.LanguageCode; + } + } + if (other.domain_ != null) { + if (domain_ == null || other.Domain != "") { + Domain = other.Domain; + } + } + if (other.coverageFraction_ != null) { + if (coverageFraction_ == null || other.CoverageFraction != 0D) { + CoverageFraction = other.CoverageFraction; + } + } + if (other.categoryRank_ != null) { + if (categoryRank_ == null || other.CategoryRank != 0L) { + CategoryRank = other.CategoryRank; + } + } + if (other.hasChildren_ != null) { + if (hasChildren_ == null || other.HasChildren != false) { + HasChildren = other.HasChildren; + } + } + if (other.recommendedCpcBidMicros_ != null) { + if (recommendedCpcBidMicros_ == null || other.RecommendedCpcBidMicros != 0L) { + RecommendedCpcBidMicros = other.RecommendedCpcBidMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_campaign_codec.Read(input); + if (campaign_ == null || value != "") { + Campaign = value; + } + break; + } + case 26: { + string value = _single_category_codec.Read(input); + if (category_ == null || value != "") { + Category = value; + } + break; + } + case 34: { + string value = _single_languageCode_codec.Read(input); + if (languageCode_ == null || value != "") { + LanguageCode = value; + } + break; + } + case 42: { + string value = _single_domain_codec.Read(input); + if (domain_ == null || value != "") { + Domain = value; + } + break; + } + case 50: { + double? value = _single_coverageFraction_codec.Read(input); + if (coverageFraction_ == null || value != 0D) { + CoverageFraction = value; + } + break; + } + case 58: { + long? value = _single_categoryRank_codec.Read(input); + if (categoryRank_ == null || value != 0L) { + CategoryRank = value; + } + break; + } + case 66: { + bool? value = _single_hasChildren_codec.Read(input); + if (hasChildren_ == null || value != false) { + HasChildren = value; + } + break; + } + case 74: { + long? value = _single_recommendedCpcBidMicros_codec.Read(input); + if (recommendedCpcBidMicros_ == null || value != 0L) { + RecommendedCpcBidMicros = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DomainCategoryService.cs b/src/V3/Stubs/DomainCategoryService.cs new file mode 100644 index 000000000..576acd752 --- /dev/null +++ b/src/V3/Stubs/DomainCategoryService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/domain_category_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/domain_category_service.proto + public static partial class DomainCategoryServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/domain_category_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DomainCategoryServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9kb21haW5fY2F0", + "ZWdvcnlfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXMaN2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9k", + "b21haW5fY2F0ZWdvcnkucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMu", + "cHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2Zp", + "ZWxkX2JlaGF2aW9yLnByb3RvIjYKGEdldERvbWFpbkNhdGVnb3J5UmVxdWVz", + "dBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIyhQIKFURvbWFpbkNhdGVn", + "b3J5U2VydmljZRLOAQoRR2V0RG9tYWluQ2F0ZWdvcnkSOi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXREb21haW5DYXRlZ29yeVJlcXVl", + "c3QaMS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuRG9tYWlu", + "Q2F0ZWdvcnkiSoLT5JMCNBIyL3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVy", + "cy8qL2RvbWFpbkNhdGVnb3JpZXMvKn3aQQ1yZXNvdXJjZV9uYW1lGhvKQRhn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb21CgQIKJGNvbS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlc0IaRG9tYWluQ2F0ZWdvcnlTZXJ2aWNlUHJv", + "dG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9h", + "ZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29v", + "Z2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.DomainCategoryReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetDomainCategoryRequest), global::Google.Ads.GoogleAds.V3.Services.GetDomainCategoryRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [DomainCategoryService.GetDomainCategory][google.ads.googleads.v3.services.DomainCategoryService.GetDomainCategory]. + /// + public sealed partial class GetDomainCategoryRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetDomainCategoryRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.DomainCategoryServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDomainCategoryRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDomainCategoryRequest(GetDomainCategoryRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDomainCategoryRequest Clone() { + return new GetDomainCategoryRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. Resource name of the domain category to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetDomainCategoryRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetDomainCategoryRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetDomainCategoryRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DomainCategoryServiceClient.cs b/src/V3/Stubs/DomainCategoryServiceClient.cs new file mode 100644 index 000000000..dafee25af --- /dev/null +++ b/src/V3/Stubs/DomainCategoryServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class DomainCategoryServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static DomainCategoryServiceSettings GetDefault() => new DomainCategoryServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public DomainCategoryServiceSettings() { } + + private DomainCategoryServiceSettings(DomainCategoryServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetDomainCategorySettings = existing.GetDomainCategorySettings; + OnCopy(existing); + } + + partial void OnCopy(DomainCategoryServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// DomainCategoryServiceClient.GetDomainCategory and DomainCategoryServiceClient.GetDomainCategoryAsync. + /// + /// + /// The default DomainCategoryServiceClient.GetDomainCategory and + /// DomainCategoryServiceClient.GetDomainCategoryAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetDomainCategorySettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public DomainCategoryServiceSettings Clone() => new DomainCategoryServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class DomainCategoryServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public DomainCategoryServiceSettings Settings { get; set; } + + /// + public override DomainCategoryServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return DomainCategoryServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return DomainCategoryServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => DomainCategoryServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => DomainCategoryServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => DomainCategoryServiceClient.ChannelPool; + } + + /// + /// DomainCategoryService client wrapper, for convenient use. + /// + public abstract partial class DomainCategoryServiceClient + { + /// + /// The default endpoint for the DomainCategoryService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default DomainCategoryService scopes. + /// + /// + /// The default DomainCategoryService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DomainCategoryServiceClient client = await DomainCategoryServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DomainCategoryServiceClient.DefaultEndpoint.Host, DomainCategoryServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DomainCategoryServiceClient client = DomainCategoryServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, DomainCategoryServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DomainCategoryServiceClient client = DomainCategoryServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DomainCategoryServiceClient.DefaultEndpoint.Host, DomainCategoryServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DomainCategoryServiceClient client = DomainCategoryServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static DomainCategoryServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, DomainCategoryServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DomainCategoryServiceClient Create(grpccore::Channel channel, DomainCategoryServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DomainCategoryServiceClient Create(grpccore::CallInvoker callInvoker, DomainCategoryServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + DomainCategoryService.DomainCategoryServiceClient grpcClient = new DomainCategoryService.DomainCategoryServiceClient(callInvoker); + return new DomainCategoryServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC DomainCategoryService client. + /// + public virtual DomainCategoryService.DomainCategoryServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested domain category. + /// + /// + /// Required. Resource name of the domain category to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDomainCategoryAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDomainCategoryAsync( + new GetDomainCategoryRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested domain category. + /// + /// + /// Required. Resource name of the domain category to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDomainCategoryAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetDomainCategoryAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested domain category. + /// + /// + /// Required. Resource name of the domain category to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DomainCategory GetDomainCategory( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDomainCategory( + new GetDomainCategoryRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested domain category. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDomainCategoryAsync( + GetDomainCategoryRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested domain category. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDomainCategoryAsync( + GetDomainCategoryRequest request, + st::CancellationToken cancellationToken) => GetDomainCategoryAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested domain category. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DomainCategory GetDomainCategory( + GetDomainCategoryRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// DomainCategoryService client wrapper implementation, for convenient use. + /// + public sealed partial class DomainCategoryServiceClientImpl : DomainCategoryServiceClient + { + private readonly gaxgrpc::ApiCall _callGetDomainCategory; + + /// + /// Constructs a client wrapper for the DomainCategoryService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public DomainCategoryServiceClientImpl(DomainCategoryService.DomainCategoryServiceClient grpcClient, DomainCategoryServiceSettings settings) + { + GrpcClient = grpcClient; + DomainCategoryServiceSettings effectiveSettings = settings ?? DomainCategoryServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetDomainCategory = clientHelper.BuildApiCall( + GrpcClient.GetDomainCategoryAsync, GrpcClient.GetDomainCategory, effectiveSettings.GetDomainCategorySettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetDomainCategory); + Modify_GetDomainCategoryApiCall(ref _callGetDomainCategory); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetDomainCategoryApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(DomainCategoryService.DomainCategoryServiceClient grpcClient, DomainCategoryServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC DomainCategoryService client. + /// + public override DomainCategoryService.DomainCategoryServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetDomainCategoryRequest(ref GetDomainCategoryRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested domain category. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetDomainCategoryAsync( + GetDomainCategoryRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDomainCategoryRequest(ref request, ref callSettings); + return _callGetDomainCategory.Async(request, callSettings); + } + + /// + /// Returns the requested domain category. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::DomainCategory GetDomainCategory( + GetDomainCategoryRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDomainCategoryRequest(ref request, ref callSettings); + return _callGetDomainCategory.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/DomainCategoryServiceGrpc.cs b/src/V3/Stubs/DomainCategoryServiceGrpc.cs new file mode 100644 index 000000000..d5d57e939 --- /dev/null +++ b/src/V3/Stubs/DomainCategoryServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/domain_category_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch domain categories. + /// + public static partial class DomainCategoryService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.DomainCategoryService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetDomainCategoryRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetDomainCategoryRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_DomainCategory = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.DomainCategory.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetDomainCategory = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetDomainCategory", + __Marshaller_google_ads_googleads_v3_services_GetDomainCategoryRequest, + __Marshaller_google_ads_googleads_v3_resources_DomainCategory); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.DomainCategoryServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of DomainCategoryService + public abstract partial class DomainCategoryServiceBase + { + /// + /// Returns the requested domain category. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetDomainCategory(global::Google.Ads.GoogleAds.V3.Services.GetDomainCategoryRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for DomainCategoryService + public partial class DomainCategoryServiceClient : grpc::ClientBase + { + /// Creates a new client for DomainCategoryService + /// The channel to use to make remote calls. + public DomainCategoryServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for DomainCategoryService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public DomainCategoryServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected DomainCategoryServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected DomainCategoryServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested domain category. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DomainCategory GetDomainCategory(global::Google.Ads.GoogleAds.V3.Services.GetDomainCategoryRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDomainCategory(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested domain category. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DomainCategory GetDomainCategory(global::Google.Ads.GoogleAds.V3.Services.GetDomainCategoryRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetDomainCategory, null, options, request); + } + /// + /// Returns the requested domain category. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDomainCategoryAsync(global::Google.Ads.GoogleAds.V3.Services.GetDomainCategoryRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDomainCategoryAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested domain category. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDomainCategoryAsync(global::Google.Ads.GoogleAds.V3.Services.GetDomainCategoryRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetDomainCategory, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override DomainCategoryServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new DomainCategoryServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(DomainCategoryServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetDomainCategory, serviceImpl.GetDomainCategory).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, DomainCategoryServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetDomainCategory, serviceImpl.GetDomainCategory); + } + + } +} +#endregion diff --git a/src/V3/Stubs/DsaPageFeedCriterionField.cs b/src/V3/Stubs/DsaPageFeedCriterionField.cs new file mode 100644 index 000000000..008f78ead --- /dev/null +++ b/src/V3/Stubs/DsaPageFeedCriterionField.cs @@ -0,0 +1,187 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/dsa_page_feed_criterion_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/dsa_page_feed_criterion_field.proto + public static partial class DsaPageFeedCriterionFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/dsa_page_feed_criterion_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DsaPageFeedCriterionFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9kc2FfcGFnZV9mZWVk", + "X2NyaXRlcmlvbl9maWVsZC5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8icwodRHNh", + "UGFnZUZlZWRDcml0ZXJpb25GaWVsZEVudW0iUgoZRHNhUGFnZUZlZWRDcml0", + "ZXJpb25GaWVsZBIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIMCghQ", + "QUdFX1VSTBACEgkKBUxBQkVMEANC8wEKIWNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lbnVtc0IeRHNhUGFnZUZlZWRDcml0ZXJpb25GaWVsZFByb3Rv", + "UAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "RW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.DsaPageFeedCriterionFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.DsaPageFeedCriterionFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.DsaPageFeedCriterionFieldEnum.Types.DsaPageFeedCriterionField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Dynamic Search Ad Page Feed criterion fields. + /// + public sealed partial class DsaPageFeedCriterionFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DsaPageFeedCriterionFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.DsaPageFeedCriterionFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DsaPageFeedCriterionFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DsaPageFeedCriterionFieldEnum(DsaPageFeedCriterionFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DsaPageFeedCriterionFieldEnum Clone() { + return new DsaPageFeedCriterionFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DsaPageFeedCriterionFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DsaPageFeedCriterionFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DsaPageFeedCriterionFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the DsaPageFeedCriterionFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Dynamic Search Ad Page Feed criterion fields. + /// + public enum DsaPageFeedCriterionField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: URL or URL_LIST. URL of the web page you want to target. + /// + [pbr::OriginalName("PAGE_URL")] PageUrl = 2, + /// + /// Data Type: STRING_LIST. The labels that will help you target ads within + /// your page feed. + /// + [pbr::OriginalName("LABEL")] Label = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DynamicSearchAdsSearchTermView.cs b/src/V3/Stubs/DynamicSearchAdsSearchTermView.cs new file mode 100644 index 000000000..3627d26db --- /dev/null +++ b/src/V3/Stubs/DynamicSearchAdsSearchTermView.cs @@ -0,0 +1,479 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/dynamic_search_ads_search_term_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/dynamic_search_ads_search_term_view.proto + public static partial class DynamicSearchAdsSearchTermViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/dynamic_search_ads_search_term_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DynamicSearchAdsSearchTermViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cktnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZHluYW1pY19z", + "ZWFyY2hfYWRzX3NlYXJjaF90ZXJtX3ZpZXcucHJvdG8SIWdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnJlc291cmNlcxofZ29vZ2xlL2FwaS9maWVsZF9iZWhh", + "dmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xl", + "L3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvIqgFCh5EeW5hbWljU2VhcmNoQWRzU2VhcmNoVGVybVZpZXcS", + "VgoNcmVzb3VyY2VfbmFtZRgBIAEoCUI/4EEF+kE5Cjdnb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb20vRHluYW1pY1NlYXJjaEFkc1NlYXJjaFRlcm1WaWV3EjYK", + "C3NlYXJjaF90ZXJtGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1Zh", + "bHVlQgPgQQMSMwoIaGVhZGxpbmUYAyABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWVCA+BBAxI3CgxsYW5kaW5nX3BhZ2UYBCABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxIzCghwYWdlX3VybBgFIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEj0KFGhhc19u", + "ZWdhdGl2ZV9rZXl3b3JkGAYgASgLMhouZ29vZ2xlLnByb3RvYnVmLkJvb2xW", + "YWx1ZUID4EEDEj0KFGhhc19tYXRjaGluZ19rZXl3b3JkGAcgASgLMhouZ29v", + "Z2xlLnByb3RvYnVmLkJvb2xWYWx1ZUID4EEDEjkKEGhhc19uZWdhdGl2ZV91", + "cmwYCCABKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlQgPgQQM6mQHq", + "QZUBCjdnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRHluYW1pY1NlYXJjaEFk", + "c1NlYXJjaFRlcm1WaWV3ElpjdXN0b21lcnMve2N1c3RvbWVyfS9keW5hbWlj", + "U2VhcmNoQWRzU2VhcmNoVGVybVZpZXdzL3tkeW5hbWljX3NlYXJjaF9hZHNf", + "c2VhcmNoX3Rlcm1fdmlld31CkAIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXNCI0R5bmFtaWNTZWFyY2hBZHNTZWFyY2hUZXJtVmll", + "d1Byb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFw", + "aXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FB", + "qgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xl", + "XEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdv", + "b2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView), global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView.Parser, new[]{ "ResourceName", "SearchTerm", "Headline", "LandingPage", "PageUrl", "HasNegativeKeyword", "HasMatchingKeyword", "HasNegativeUrl" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A dynamic search ads search term view. + /// + public sealed partial class DynamicSearchAdsSearchTermView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DynamicSearchAdsSearchTermView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DynamicSearchAdsSearchTermView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DynamicSearchAdsSearchTermView(DynamicSearchAdsSearchTermView other) : this() { + resourceName_ = other.resourceName_; + SearchTerm = other.SearchTerm; + Headline = other.Headline; + LandingPage = other.LandingPage; + PageUrl = other.PageUrl; + HasNegativeKeyword = other.HasNegativeKeyword; + HasMatchingKeyword = other.HasMatchingKeyword; + HasNegativeUrl = other.HasNegativeUrl; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DynamicSearchAdsSearchTermView Clone() { + return new DynamicSearchAdsSearchTermView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the dynamic search ads search term view. + /// Dynamic search ads search term view resource names have the form: + /// + /// `customers/{customer_id}/dynamicSearchAdsSearchTermViews/{ad_group_id}~{search_term_fp}~{headline_fp}~{landing_page_fp}~{page_url_fp}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "search_term" field. + public const int SearchTermFieldNumber = 2; + private static readonly pb::FieldCodec _single_searchTerm_codec = pb::FieldCodec.ForClassWrapper(18); + private string searchTerm_; + /// + /// Output only. Search term + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string SearchTerm { + get { return searchTerm_; } + set { + searchTerm_ = value; + } + } + + + /// Field number for the "headline" field. + public const int HeadlineFieldNumber = 3; + private static readonly pb::FieldCodec _single_headline_codec = pb::FieldCodec.ForClassWrapper(26); + private string headline_; + /// + /// Output only. The dynamically generated headline of the Dynamic Search Ad. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Headline { + get { return headline_; } + set { + headline_ = value; + } + } + + + /// Field number for the "landing_page" field. + public const int LandingPageFieldNumber = 4; + private static readonly pb::FieldCodec _single_landingPage_codec = pb::FieldCodec.ForClassWrapper(34); + private string landingPage_; + /// + /// Output only. The dynamically selected landing page URL of the impression. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LandingPage { + get { return landingPage_; } + set { + landingPage_ = value; + } + } + + + /// Field number for the "page_url" field. + public const int PageUrlFieldNumber = 5; + private static readonly pb::FieldCodec _single_pageUrl_codec = pb::FieldCodec.ForClassWrapper(42); + private string pageUrl_; + /// + /// Output only. The URL of page feed item served for the impression. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PageUrl { + get { return pageUrl_; } + set { + pageUrl_ = value; + } + } + + + /// Field number for the "has_negative_keyword" field. + public const int HasNegativeKeywordFieldNumber = 6; + private static readonly pb::FieldCodec _single_hasNegativeKeyword_codec = pb::FieldCodec.ForStructWrapper(50); + private bool? hasNegativeKeyword_; + /// + /// Output only. True if query matches a negative keyword. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? HasNegativeKeyword { + get { return hasNegativeKeyword_; } + set { + hasNegativeKeyword_ = value; + } + } + + + /// Field number for the "has_matching_keyword" field. + public const int HasMatchingKeywordFieldNumber = 7; + private static readonly pb::FieldCodec _single_hasMatchingKeyword_codec = pb::FieldCodec.ForStructWrapper(58); + private bool? hasMatchingKeyword_; + /// + /// Output only. True if query is added to targeted keywords. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? HasMatchingKeyword { + get { return hasMatchingKeyword_; } + set { + hasMatchingKeyword_ = value; + } + } + + + /// Field number for the "has_negative_url" field. + public const int HasNegativeUrlFieldNumber = 8; + private static readonly pb::FieldCodec _single_hasNegativeUrl_codec = pb::FieldCodec.ForStructWrapper(66); + private bool? hasNegativeUrl_; + /// + /// Output only. True if query matches a negative url. + /// + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? HasNegativeUrl { + get { return hasNegativeUrl_; } + set { + hasNegativeUrl_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as DynamicSearchAdsSearchTermView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(DynamicSearchAdsSearchTermView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (SearchTerm != other.SearchTerm) return false; + if (Headline != other.Headline) return false; + if (LandingPage != other.LandingPage) return false; + if (PageUrl != other.PageUrl) return false; + if (HasNegativeKeyword != other.HasNegativeKeyword) return false; + if (HasMatchingKeyword != other.HasMatchingKeyword) return false; + if (HasNegativeUrl != other.HasNegativeUrl) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (searchTerm_ != null) hash ^= SearchTerm.GetHashCode(); + if (headline_ != null) hash ^= Headline.GetHashCode(); + if (landingPage_ != null) hash ^= LandingPage.GetHashCode(); + if (pageUrl_ != null) hash ^= PageUrl.GetHashCode(); + if (hasNegativeKeyword_ != null) hash ^= HasNegativeKeyword.GetHashCode(); + if (hasMatchingKeyword_ != null) hash ^= HasMatchingKeyword.GetHashCode(); + if (hasNegativeUrl_ != null) hash ^= HasNegativeUrl.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (searchTerm_ != null) { + _single_searchTerm_codec.WriteTagAndValue(output, SearchTerm); + } + if (headline_ != null) { + _single_headline_codec.WriteTagAndValue(output, Headline); + } + if (landingPage_ != null) { + _single_landingPage_codec.WriteTagAndValue(output, LandingPage); + } + if (pageUrl_ != null) { + _single_pageUrl_codec.WriteTagAndValue(output, PageUrl); + } + if (hasNegativeKeyword_ != null) { + _single_hasNegativeKeyword_codec.WriteTagAndValue(output, HasNegativeKeyword); + } + if (hasMatchingKeyword_ != null) { + _single_hasMatchingKeyword_codec.WriteTagAndValue(output, HasMatchingKeyword); + } + if (hasNegativeUrl_ != null) { + _single_hasNegativeUrl_codec.WriteTagAndValue(output, HasNegativeUrl); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (searchTerm_ != null) { + size += _single_searchTerm_codec.CalculateSizeWithTag(SearchTerm); + } + if (headline_ != null) { + size += _single_headline_codec.CalculateSizeWithTag(Headline); + } + if (landingPage_ != null) { + size += _single_landingPage_codec.CalculateSizeWithTag(LandingPage); + } + if (pageUrl_ != null) { + size += _single_pageUrl_codec.CalculateSizeWithTag(PageUrl); + } + if (hasNegativeKeyword_ != null) { + size += _single_hasNegativeKeyword_codec.CalculateSizeWithTag(HasNegativeKeyword); + } + if (hasMatchingKeyword_ != null) { + size += _single_hasMatchingKeyword_codec.CalculateSizeWithTag(HasMatchingKeyword); + } + if (hasNegativeUrl_ != null) { + size += _single_hasNegativeUrl_codec.CalculateSizeWithTag(HasNegativeUrl); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(DynamicSearchAdsSearchTermView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.searchTerm_ != null) { + if (searchTerm_ == null || other.SearchTerm != "") { + SearchTerm = other.SearchTerm; + } + } + if (other.headline_ != null) { + if (headline_ == null || other.Headline != "") { + Headline = other.Headline; + } + } + if (other.landingPage_ != null) { + if (landingPage_ == null || other.LandingPage != "") { + LandingPage = other.LandingPage; + } + } + if (other.pageUrl_ != null) { + if (pageUrl_ == null || other.PageUrl != "") { + PageUrl = other.PageUrl; + } + } + if (other.hasNegativeKeyword_ != null) { + if (hasNegativeKeyword_ == null || other.HasNegativeKeyword != false) { + HasNegativeKeyword = other.HasNegativeKeyword; + } + } + if (other.hasMatchingKeyword_ != null) { + if (hasMatchingKeyword_ == null || other.HasMatchingKeyword != false) { + HasMatchingKeyword = other.HasMatchingKeyword; + } + } + if (other.hasNegativeUrl_ != null) { + if (hasNegativeUrl_ == null || other.HasNegativeUrl != false) { + HasNegativeUrl = other.HasNegativeUrl; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_searchTerm_codec.Read(input); + if (searchTerm_ == null || value != "") { + SearchTerm = value; + } + break; + } + case 26: { + string value = _single_headline_codec.Read(input); + if (headline_ == null || value != "") { + Headline = value; + } + break; + } + case 34: { + string value = _single_landingPage_codec.Read(input); + if (landingPage_ == null || value != "") { + LandingPage = value; + } + break; + } + case 42: { + string value = _single_pageUrl_codec.Read(input); + if (pageUrl_ == null || value != "") { + PageUrl = value; + } + break; + } + case 50: { + bool? value = _single_hasNegativeKeyword_codec.Read(input); + if (hasNegativeKeyword_ == null || value != false) { + HasNegativeKeyword = value; + } + break; + } + case 58: { + bool? value = _single_hasMatchingKeyword_codec.Read(input); + if (hasMatchingKeyword_ == null || value != false) { + HasMatchingKeyword = value; + } + break; + } + case 66: { + bool? value = _single_hasNegativeUrl_codec.Read(input); + if (hasNegativeUrl_ == null || value != false) { + HasNegativeUrl = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DynamicSearchAdsSearchTermViewService.cs b/src/V3/Stubs/DynamicSearchAdsSearchTermViewService.cs new file mode 100644 index 000000000..eb25f7f40 --- /dev/null +++ b/src/V3/Stubs/DynamicSearchAdsSearchTermViewService.cs @@ -0,0 +1,199 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/dynamic_search_ads_search_term_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/dynamic_search_ads_search_term_view_service.proto + public static partial class DynamicSearchAdsSearchTermViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/dynamic_search_ads_search_term_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static DynamicSearchAdsSearchTermViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "ClJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9keW5hbWljX3Nl", + "YXJjaF9hZHNfc2VhcmNoX3Rlcm1fdmlld19zZXJ2aWNlLnByb3RvEiBnb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcxpLZ29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvcmVzb3VyY2VzL2R5bmFtaWNfc2VhcmNoX2Fkc19zZWFyY2hf", + "dGVybV92aWV3LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3Rv", + "Ghdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9i", + "ZWhhdmlvci5wcm90byJGCihHZXREeW5hbWljU2VhcmNoQWRzU2VhcmNoVGVy", + "bVZpZXdSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAjLUAgol", + "RHluYW1pY1NlYXJjaEFkc1NlYXJjaFRlcm1WaWV3U2VydmljZRKNAgohR2V0", + "RHluYW1pY1NlYXJjaEFkc1NlYXJjaFRlcm1WaWV3EkouZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuR2V0RHluYW1pY1NlYXJjaEFkc1NlYXJj", + "aFRlcm1WaWV3UmVxdWVzdBpBLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlcy5EeW5hbWljU2VhcmNoQWRzU2VhcmNoVGVybVZpZXciWYLT5JMC", + "QxJBL3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2R5bmFtaWNTZWFy", + "Y2hBZHNTZWFyY2hUZXJtVmlld3MvKn3aQQ1yZXNvdXJjZV9uYW1lGhvKQRhn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb21CkQIKJGNvbS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlc0IqRHluYW1pY1NlYXJjaEFkc1NlYXJjaFRl", + "cm1WaWV3U2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnBy", + "b3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2", + "aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2Vz", + "ygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetDynamicSearchAdsSearchTermViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetDynamicSearchAdsSearchTermViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [DynamicSearchAdsSearchTermViewService.GetDynamicSearchAdsSearchTermView][google.ads.googleads.v3.services.DynamicSearchAdsSearchTermViewService.GetDynamicSearchAdsSearchTermView]. + /// + public sealed partial class GetDynamicSearchAdsSearchTermViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetDynamicSearchAdsSearchTermViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.DynamicSearchAdsSearchTermViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDynamicSearchAdsSearchTermViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDynamicSearchAdsSearchTermViewRequest(GetDynamicSearchAdsSearchTermViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetDynamicSearchAdsSearchTermViewRequest Clone() { + return new GetDynamicSearchAdsSearchTermViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the dynamic search ads search term view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetDynamicSearchAdsSearchTermViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetDynamicSearchAdsSearchTermViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetDynamicSearchAdsSearchTermViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/DynamicSearchAdsSearchTermViewServiceClient.cs b/src/V3/Stubs/DynamicSearchAdsSearchTermViewServiceClient.cs new file mode 100644 index 000000000..1adb75e07 --- /dev/null +++ b/src/V3/Stubs/DynamicSearchAdsSearchTermViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class DynamicSearchAdsSearchTermViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static DynamicSearchAdsSearchTermViewServiceSettings GetDefault() => new DynamicSearchAdsSearchTermViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public DynamicSearchAdsSearchTermViewServiceSettings() { } + + private DynamicSearchAdsSearchTermViewServiceSettings(DynamicSearchAdsSearchTermViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetDynamicSearchAdsSearchTermViewSettings = existing.GetDynamicSearchAdsSearchTermViewSettings; + OnCopy(existing); + } + + partial void OnCopy(DynamicSearchAdsSearchTermViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// DynamicSearchAdsSearchTermViewServiceClient.GetDynamicSearchAdsSearchTermView and DynamicSearchAdsSearchTermViewServiceClient.GetDynamicSearchAdsSearchTermViewAsync. + /// + /// + /// The default DynamicSearchAdsSearchTermViewServiceClient.GetDynamicSearchAdsSearchTermView and + /// DynamicSearchAdsSearchTermViewServiceClient.GetDynamicSearchAdsSearchTermViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetDynamicSearchAdsSearchTermViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public DynamicSearchAdsSearchTermViewServiceSettings Clone() => new DynamicSearchAdsSearchTermViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class DynamicSearchAdsSearchTermViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public DynamicSearchAdsSearchTermViewServiceSettings Settings { get; set; } + + /// + public override DynamicSearchAdsSearchTermViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return DynamicSearchAdsSearchTermViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return DynamicSearchAdsSearchTermViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => DynamicSearchAdsSearchTermViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => DynamicSearchAdsSearchTermViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => DynamicSearchAdsSearchTermViewServiceClient.ChannelPool; + } + + /// + /// DynamicSearchAdsSearchTermViewService client wrapper, for convenient use. + /// + public abstract partial class DynamicSearchAdsSearchTermViewServiceClient + { + /// + /// The default endpoint for the DynamicSearchAdsSearchTermViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default DynamicSearchAdsSearchTermViewService scopes. + /// + /// + /// The default DynamicSearchAdsSearchTermViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DynamicSearchAdsSearchTermViewServiceClient client = await DynamicSearchAdsSearchTermViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DynamicSearchAdsSearchTermViewServiceClient.DefaultEndpoint.Host, DynamicSearchAdsSearchTermViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DynamicSearchAdsSearchTermViewServiceClient client = DynamicSearchAdsSearchTermViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, DynamicSearchAdsSearchTermViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// DynamicSearchAdsSearchTermViewServiceClient client = DynamicSearchAdsSearchTermViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// DynamicSearchAdsSearchTermViewServiceClient.DefaultEndpoint.Host, DynamicSearchAdsSearchTermViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// DynamicSearchAdsSearchTermViewServiceClient client = DynamicSearchAdsSearchTermViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static DynamicSearchAdsSearchTermViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, DynamicSearchAdsSearchTermViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DynamicSearchAdsSearchTermViewServiceClient Create(grpccore::Channel channel, DynamicSearchAdsSearchTermViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static DynamicSearchAdsSearchTermViewServiceClient Create(grpccore::CallInvoker callInvoker, DynamicSearchAdsSearchTermViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + DynamicSearchAdsSearchTermViewService.DynamicSearchAdsSearchTermViewServiceClient grpcClient = new DynamicSearchAdsSearchTermViewService.DynamicSearchAdsSearchTermViewServiceClient(callInvoker); + return new DynamicSearchAdsSearchTermViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC DynamicSearchAdsSearchTermViewService client. + /// + public virtual DynamicSearchAdsSearchTermViewService.DynamicSearchAdsSearchTermViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// + /// Required. The resource name of the dynamic search ads search term view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDynamicSearchAdsSearchTermViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDynamicSearchAdsSearchTermViewAsync( + new GetDynamicSearchAdsSearchTermViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// + /// Required. The resource name of the dynamic search ads search term view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDynamicSearchAdsSearchTermViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetDynamicSearchAdsSearchTermViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// + /// Required. The resource name of the dynamic search ads search term view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DynamicSearchAdsSearchTermView GetDynamicSearchAdsSearchTermView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetDynamicSearchAdsSearchTermView( + new GetDynamicSearchAdsSearchTermViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDynamicSearchAdsSearchTermViewAsync( + GetDynamicSearchAdsSearchTermViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetDynamicSearchAdsSearchTermViewAsync( + GetDynamicSearchAdsSearchTermViewRequest request, + st::CancellationToken cancellationToken) => GetDynamicSearchAdsSearchTermViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::DynamicSearchAdsSearchTermView GetDynamicSearchAdsSearchTermView( + GetDynamicSearchAdsSearchTermViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// DynamicSearchAdsSearchTermViewService client wrapper implementation, for convenient use. + /// + public sealed partial class DynamicSearchAdsSearchTermViewServiceClientImpl : DynamicSearchAdsSearchTermViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetDynamicSearchAdsSearchTermView; + + /// + /// Constructs a client wrapper for the DynamicSearchAdsSearchTermViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public DynamicSearchAdsSearchTermViewServiceClientImpl(DynamicSearchAdsSearchTermViewService.DynamicSearchAdsSearchTermViewServiceClient grpcClient, DynamicSearchAdsSearchTermViewServiceSettings settings) + { + GrpcClient = grpcClient; + DynamicSearchAdsSearchTermViewServiceSettings effectiveSettings = settings ?? DynamicSearchAdsSearchTermViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetDynamicSearchAdsSearchTermView = clientHelper.BuildApiCall( + GrpcClient.GetDynamicSearchAdsSearchTermViewAsync, GrpcClient.GetDynamicSearchAdsSearchTermView, effectiveSettings.GetDynamicSearchAdsSearchTermViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetDynamicSearchAdsSearchTermView); + Modify_GetDynamicSearchAdsSearchTermViewApiCall(ref _callGetDynamicSearchAdsSearchTermView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetDynamicSearchAdsSearchTermViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(DynamicSearchAdsSearchTermViewService.DynamicSearchAdsSearchTermViewServiceClient grpcClient, DynamicSearchAdsSearchTermViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC DynamicSearchAdsSearchTermViewService client. + /// + public override DynamicSearchAdsSearchTermViewService.DynamicSearchAdsSearchTermViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetDynamicSearchAdsSearchTermViewRequest(ref GetDynamicSearchAdsSearchTermViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetDynamicSearchAdsSearchTermViewAsync( + GetDynamicSearchAdsSearchTermViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDynamicSearchAdsSearchTermViewRequest(ref request, ref callSettings); + return _callGetDynamicSearchAdsSearchTermView.Async(request, callSettings); + } + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::DynamicSearchAdsSearchTermView GetDynamicSearchAdsSearchTermView( + GetDynamicSearchAdsSearchTermViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetDynamicSearchAdsSearchTermViewRequest(ref request, ref callSettings); + return _callGetDynamicSearchAdsSearchTermView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/DynamicSearchAdsSearchTermViewServiceGrpc.cs b/src/V3/Stubs/DynamicSearchAdsSearchTermViewServiceGrpc.cs new file mode 100644 index 000000000..ddc5df30a --- /dev/null +++ b/src/V3/Stubs/DynamicSearchAdsSearchTermViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/dynamic_search_ads_search_term_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch dynamic search ads views. + /// + public static partial class DynamicSearchAdsSearchTermViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.DynamicSearchAdsSearchTermViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetDynamicSearchAdsSearchTermViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetDynamicSearchAdsSearchTermViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_DynamicSearchAdsSearchTermView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetDynamicSearchAdsSearchTermView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetDynamicSearchAdsSearchTermView", + __Marshaller_google_ads_googleads_v3_services_GetDynamicSearchAdsSearchTermViewRequest, + __Marshaller_google_ads_googleads_v3_resources_DynamicSearchAdsSearchTermView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.DynamicSearchAdsSearchTermViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of DynamicSearchAdsSearchTermViewService + public abstract partial class DynamicSearchAdsSearchTermViewServiceBase + { + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetDynamicSearchAdsSearchTermView(global::Google.Ads.GoogleAds.V3.Services.GetDynamicSearchAdsSearchTermViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for DynamicSearchAdsSearchTermViewService + public partial class DynamicSearchAdsSearchTermViewServiceClient : grpc::ClientBase + { + /// Creates a new client for DynamicSearchAdsSearchTermViewService + /// The channel to use to make remote calls. + public DynamicSearchAdsSearchTermViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for DynamicSearchAdsSearchTermViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public DynamicSearchAdsSearchTermViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected DynamicSearchAdsSearchTermViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected DynamicSearchAdsSearchTermViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView GetDynamicSearchAdsSearchTermView(global::Google.Ads.GoogleAds.V3.Services.GetDynamicSearchAdsSearchTermViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDynamicSearchAdsSearchTermView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView GetDynamicSearchAdsSearchTermView(global::Google.Ads.GoogleAds.V3.Services.GetDynamicSearchAdsSearchTermViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetDynamicSearchAdsSearchTermView, null, options, request); + } + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDynamicSearchAdsSearchTermViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetDynamicSearchAdsSearchTermViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetDynamicSearchAdsSearchTermViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested dynamic search ads search term view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetDynamicSearchAdsSearchTermViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetDynamicSearchAdsSearchTermViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetDynamicSearchAdsSearchTermView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override DynamicSearchAdsSearchTermViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new DynamicSearchAdsSearchTermViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(DynamicSearchAdsSearchTermViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetDynamicSearchAdsSearchTermView, serviceImpl.GetDynamicSearchAdsSearchTermView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, DynamicSearchAdsSearchTermViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetDynamicSearchAdsSearchTermView, serviceImpl.GetDynamicSearchAdsSearchTermView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/EducationPlaceholderField.cs b/src/V3/Stubs/EducationPlaceholderField.cs new file mode 100644 index 000000000..f365a6362 --- /dev/null +++ b/src/V3/Stubs/EducationPlaceholderField.cs @@ -0,0 +1,269 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/education_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/education_placeholder_field.proto + public static partial class EducationPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/education_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static EducationPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9lZHVjYXRpb25fcGxh", + "Y2Vob2xkZXJfZmllbGQucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIr8DCh1FZHVj", + "YXRpb25QbGFjZWhvbGRlckZpZWxkRW51bSKdAwoZRWR1Y2F0aW9uUGxhY2Vo", + "b2xkZXJGaWVsZBIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIOCgpQ", + "Uk9HUkFNX0lEEAISDwoLTE9DQVRJT05fSUQQAxIQCgxQUk9HUkFNX05BTUUQ", + "BBIRCg1BUkVBX09GX1NUVURZEAUSFwoTUFJPR1JBTV9ERVNDUklQVElPThAG", + "Eg8KC1NDSE9PTF9OQU1FEAcSCwoHQUREUkVTUxAIEhcKE1RIVU1CTkFJTF9J", + "TUFHRV9VUkwQCRIjCh9BTFRFUk5BVElWRV9USFVNQk5BSUxfSU1BR0VfVVJM", + "EAoSDgoKRklOQUxfVVJMUxALEhUKEUZJTkFMX01PQklMRV9VUkxTEAwSEAoM", + "VFJBQ0tJTkdfVVJMEA0SFwoTQ09OVEVYVFVBTF9LRVlXT1JEUxAOEhQKEEFO", + "RFJPSURfQVBQX0xJTksQDxIXChNTSU1JTEFSX1BST0dSQU1fSURTEBASEAoM", + "SU9TX0FQUF9MSU5LEBESFAoQSU9TX0FQUF9TVE9SRV9JRBASQvMBCiFjb20u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCHkVkdWNhdGlvblBsYWNl", + "aG9sZGVyRmllbGRQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90", + "by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNH", + "QUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxB", + "ZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFk", + "czo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.EducationPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.EducationPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.EducationPlaceholderFieldEnum.Types.EducationPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Education placeholder fields. + /// For more information about dynamic remarketing feeds, see + /// https://support.google.com/google-ads/answer/6053288. + /// + public sealed partial class EducationPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new EducationPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.EducationPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EducationPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EducationPlaceholderFieldEnum(EducationPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EducationPlaceholderFieldEnum Clone() { + return new EducationPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as EducationPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(EducationPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(EducationPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the EducationPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Education placeholder fields. + /// + public enum EducationPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: STRING. Required. Combination of PROGRAM ID and LOCATION ID + /// must be unique per offer. + /// + [pbr::OriginalName("PROGRAM_ID")] ProgramId = 2, + /// + /// Data Type: STRING. Combination of PROGRAM ID and LOCATION ID must be + /// unique per offer. + /// + [pbr::OriginalName("LOCATION_ID")] LocationId = 3, + /// + /// Data Type: STRING. Required. Main headline with program name to be shown + /// in dynamic ad. + /// + [pbr::OriginalName("PROGRAM_NAME")] ProgramName = 4, + /// + /// Data Type: STRING. Area of study that can be shown in dynamic ad. + /// + [pbr::OriginalName("AREA_OF_STUDY")] AreaOfStudy = 5, + /// + /// Data Type: STRING. Description of program that can be shown in dynamic + /// ad. + /// + [pbr::OriginalName("PROGRAM_DESCRIPTION")] ProgramDescription = 6, + /// + /// Data Type: STRING. Name of school that can be shown in dynamic ad. + /// + [pbr::OriginalName("SCHOOL_NAME")] SchoolName = 7, + /// + /// Data Type: STRING. Complete school address, including postal code. + /// + [pbr::OriginalName("ADDRESS")] Address = 8, + /// + /// Data Type: URL. Image to be displayed in ads. + /// + [pbr::OriginalName("THUMBNAIL_IMAGE_URL")] ThumbnailImageUrl = 9, + /// + /// Data Type: URL. Alternative hosted file of image to be used in the ad. + /// + [pbr::OriginalName("ALTERNATIVE_THUMBNAIL_IMAGE_URL")] AlternativeThumbnailImageUrl = 10, + /// + /// Data Type: URL_LIST. Required. Final URLs to be used in ad when using + /// Upgraded URLs; the more specific the better (e.g. the individual URL of a + /// specific program and its location). + /// + [pbr::OriginalName("FINAL_URLS")] FinalUrls = 11, + /// + /// Data Type: URL_LIST. Final mobile URLs for the ad when using Upgraded + /// URLs. + /// + [pbr::OriginalName("FINAL_MOBILE_URLS")] FinalMobileUrls = 12, + /// + /// Data Type: URL. Tracking template for the ad when using Upgraded URLs. + /// + [pbr::OriginalName("TRACKING_URL")] TrackingUrl = 13, + /// + /// Data Type: STRING_LIST. Keywords used for product retrieval. + /// + [pbr::OriginalName("CONTEXTUAL_KEYWORDS")] ContextualKeywords = 14, + /// + /// Data Type: STRING. Android app link. Must be formatted as: + /// android-app://{package_id}/{scheme}/{host_path}. + /// The components are defined as follows: + /// package_id: app ID as specified in Google Play. + /// scheme: the scheme to pass to the application. Can be HTTP, or a custom + /// scheme. + /// host_path: identifies the specific content within your application. + /// + [pbr::OriginalName("ANDROID_APP_LINK")] AndroidAppLink = 15, + /// + /// Data Type: STRING_LIST. List of recommended program IDs to show together + /// with this item. + /// + [pbr::OriginalName("SIMILAR_PROGRAM_IDS")] SimilarProgramIds = 16, + /// + /// Data Type: STRING. iOS app link. + /// + [pbr::OriginalName("IOS_APP_LINK")] IosAppLink = 17, + /// + /// Data Type: INT64. iOS app store ID. + /// + [pbr::OriginalName("IOS_APP_STORE_ID")] IosAppStoreId = 18, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/EnumError.cs b/src/V3/Stubs/EnumError.cs new file mode 100644 index 000000000..059b83e09 --- /dev/null +++ b/src/V3/Stubs/EnumError.cs @@ -0,0 +1,180 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/enum_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/enum_error.proto + public static partial class EnumErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/enum_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static EnumErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZW51bV9lcnJvci5w", + "cm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxnb29nbGUv", + "YXBpL2Fubm90YXRpb25zLnByb3RvIlgKDUVudW1FcnJvckVudW0iRwoJRW51", + "bUVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhwKGEVOVU1f", + "VkFMVUVfTk9UX1BFUk1JVFRFRBADQukBCiJjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZXJyb3JzQg5FbnVtRXJyb3JQcm90b1ABWkRnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "ZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.EnumErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.EnumErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.EnumErrorEnum.Types.EnumError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible enum errors. + /// + public sealed partial class EnumErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new EnumErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.EnumErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EnumErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EnumErrorEnum(EnumErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public EnumErrorEnum Clone() { + return new EnumErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as EnumErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(EnumErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(EnumErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the EnumErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible enum errors. + /// + public enum EnumError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The enum value is not permitted. + /// + [pbr::OriginalName("ENUM_VALUE_NOT_PERMITTED")] EnumValueNotPermitted = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Errors.cs b/src/V3/Stubs/Errors.cs new file mode 100644 index 000000000..775b50095 --- /dev/null +++ b/src/V3/Stubs/Errors.cs @@ -0,0 +1,5677 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/errors.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/errors.proto + public static partial class ErrorsReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/errors.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ErrorsReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Citnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZXJyb3JzLnByb3Rv", + "Eh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMaK2dvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2NvbW1vbi9wb2xpY3kucHJvdG8aKmdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2NvbW1vbi92YWx1ZS5wcm90bxo8Z29vZ2xlL2Fkcy9n", + "b29nbGVhZHMvdjMvZXJyb3JzL2FjY2Vzc19pbnZpdGF0aW9uX2Vycm9yLnBy", + "b3RvGkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWNjb3VudF9i", + "dWRnZXRfcHJvcG9zYWxfZXJyb3IucHJvdG8aOGdvb2dsZS9hZHMvZ29vZ2xl", + "YWRzL3YzL2Vycm9ycy9hZF9jdXN0b21pemVyX2Vycm9yLnByb3RvGi1nb29n", + "bGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRfZXJyb3IucHJvdG8aNmdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9hZF9ncm91cF9hZF9lcnJv", + "ci5wcm90bxpAZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2FkX2dy", + "b3VwX2JpZF9tb2RpZmllcl9lcnJvci5wcm90bxo9Z29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvZXJyb3JzL2FkX2dyb3VwX2NyaXRlcmlvbl9lcnJvci5wcm90", + "bxozZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2FkX2dyb3VwX2Vy", + "cm9yLnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvYWRf", + "Z3JvdXBfZmVlZF9lcnJvci5wcm90bxo3Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZXJyb3JzL2FkX3BhcmFtZXRlcl9lcnJvci5wcm90bxo1Z29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZXJyb3JzL2FkX3NoYXJpbmdfZXJyb3IucHJvdG8a", + "Lmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9hZHhfZXJyb3IucHJv", + "dG8aMGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9hc3NldF9lcnJv", + "ci5wcm90bxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2F1dGhl", + "bnRpY2F0aW9uX2Vycm9yLnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lcnJvcnMvYXV0aG9yaXphdGlvbl9lcnJvci5wcm90bxoyZ29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZXJyb3JzL2JpZGRpbmdfZXJyb3IucHJvdG8aO2dv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9iaWRkaW5nX3N0cmF0ZWd5", + "X2Vycm9yLnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMv", + "YmlsbGluZ19zZXR1cF9lcnJvci5wcm90bxo6Z29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvZXJyb3JzL2NhbXBhaWduX2J1ZGdldF9lcnJvci5wcm90bxo9Z29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2NhbXBhaWduX2NyaXRlcmlv", + "bl9lcnJvci5wcm90bxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3Jz", + "L2NhbXBhaWduX2RyYWZ0X2Vycm9yLnByb3RvGjNnb29nbGUvYWRzL2dvb2ds", + "ZWFkcy92My9lcnJvcnMvY2FtcGFpZ25fZXJyb3IucHJvdG8aPmdvb2dsZS9h", + "ZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9jYW1wYWlnbl9leHBlcmltZW50X2Vy", + "cm9yLnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY2Ft", + "cGFpZ25fZmVlZF9lcnJvci5wcm90bxo+Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZXJyb3JzL2NhbXBhaWduX3NoYXJlZF9zZXRfZXJyb3IucHJvdG8aOGdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9jaGFuZ2Vfc3RhdHVzX2Vy", + "cm9yLnByb3RvGjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY29s", + "bGVjdGlvbl9zaXplX2Vycm9yLnByb3RvGjJnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9lcnJvcnMvY29udGV4dF9lcnJvci5wcm90bxo8Z29vZ2xlL2Fkcy9n", + "b29nbGVhZHMvdjMvZXJyb3JzL2NvbnZlcnNpb25fYWN0aW9uX2Vycm9yLnBy", + "b3RvGkdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY29udmVyc2lv", + "bl9hZGp1c3RtZW50X3VwbG9hZF9lcnJvci5wcm90bxo8Z29vZ2xlL2Fkcy9n", + "b29nbGVhZHMvdjMvZXJyb3JzL2NvbnZlcnNpb25fdXBsb2FkX2Vycm9yLnBy", + "b3RvGjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY291bnRyeV9j", + "b2RlX2Vycm9yLnByb3RvGjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJv", + "cnMvY3JpdGVyaW9uX2Vycm9yLnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9lcnJvcnMvY3VycmVuY3lfY29kZV9lcnJvci5wcm90bxo6Z29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2N1c3RvbV9pbnRlcmVzdF9lcnJv", + "ci5wcm90bxo/Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2N1c3Rv", + "bWVyX2NsaWVudF9saW5rX2Vycm9yLnByb3RvGjNnb29nbGUvYWRzL2dvb2ds", + "ZWFkcy92My9lcnJvcnMvY3VzdG9tZXJfZXJyb3IucHJvdG8aOGdvb2dsZS9h", + "ZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9jdXN0b21lcl9mZWVkX2Vycm9yLnBy", + "b3RvGkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvY3VzdG9tZXJf", + "bWFuYWdlcl9saW5rX2Vycm9yLnByb3RvGjNnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9lcnJvcnMvZGF0YWJhc2VfZXJyb3IucHJvdG8aL2dvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2Vycm9ycy9kYXRlX2Vycm9yLnByb3RvGjVnb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZGF0ZV9yYW5nZV9lcnJvci5wcm90", + "bxozZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2Rpc3RpbmN0X2Vy", + "cm9yLnByb3RvGi9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZW51", + "bV9lcnJvci5wcm90bxo+Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3Jz", + "L2V4dGVuc2lvbl9mZWVkX2l0ZW1fZXJyb3IucHJvdG8aPGdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2Vycm9ycy9leHRlbnNpb25fc2V0dGluZ19lcnJvci5w", + "cm90bxpDZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2ZlZWRfYXR0", + "cmlidXRlX3JlZmVyZW5jZV9lcnJvci5wcm90bxovZ29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvZXJyb3JzL2ZlZWRfZXJyb3IucHJvdG8aNGdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2Vycm9ycy9mZWVkX2l0ZW1fZXJyb3IucHJvdG8aO2dv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9mZWVkX2l0ZW1fdGFyZ2V0", + "X2Vycm9yLnByb3RvGj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMv", + "ZmVlZF9pdGVtX3ZhbGlkYXRpb25fZXJyb3IucHJvdG8aN2dvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2Vycm9ycy9mZWVkX21hcHBpbmdfZXJyb3IucHJvdG8a", + "MGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9maWVsZF9lcnJvci5w", + "cm90bxo1Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2ZpZWxkX21h", + "c2tfZXJyb3IucHJvdG8aM2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9y", + "cy9mdW5jdGlvbl9lcnJvci5wcm90bxo7Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZXJyb3JzL2Z1bmN0aW9uX3BhcnNpbmdfZXJyb3IucHJvdG8aSWdvb2ds", + "ZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9nZW9fdGFyZ2V0X2NvbnN0YW50", + "X3N1Z2dlc3Rpb25fZXJyb3IucHJvdG8aMWdvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL2Vycm9ycy9oZWFkZXJfZXJyb3IucHJvdG8aLWdvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL2Vycm9ycy9pZF9lcnJvci5wcm90bxowZ29vZ2xlL2Fkcy9n", + "b29nbGVhZHMvdjMvZXJyb3JzL2ltYWdlX2Vycm9yLnByb3RvGjNnb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9lcnJvcnMvaW50ZXJuYWxfZXJyb3IucHJvdG8a", + "Mmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9pbnZvaWNlX2Vycm9y", + "LnByb3RvGkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMva2V5d29y", + "ZF9wbGFuX2FkX2dyb3VwX2Vycm9yLnByb3RvGkBnb29nbGUvYWRzL2dvb2ds", + "ZWFkcy92My9lcnJvcnMva2V5d29yZF9wbGFuX2NhbXBhaWduX2Vycm9yLnBy", + "b3RvGjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMva2V5d29yZF9w", + "bGFuX2Vycm9yLnByb3RvGjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJv", + "cnMva2V5d29yZF9wbGFuX2lkZWFfZXJyb3IucHJvdG8aP2dvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2Vycm9ycy9rZXl3b3JkX3BsYW5fa2V5d29yZF9lcnJv", + "ci5wcm90bxpIZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL2tleXdv", + "cmRfcGxhbl9uZWdhdGl2ZV9rZXl3b3JkX2Vycm9yLnByb3RvGjBnb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9lcnJvcnMvbGFiZWxfZXJyb3IucHJvdG8aOGdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9sYW5ndWFnZV9jb2RlX2Vy", + "cm9yLnByb3RvGjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvbGlz", + "dF9vcGVyYXRpb25fZXJyb3IucHJvdG8aN2dvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL2Vycm9ycy9tYW5hZ2VyX2xpbmtfZXJyb3IucHJvdG8aN2dvb2dsZS9h", + "ZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9tZWRpYV9idW5kbGVfZXJyb3IucHJv", + "dG8aNWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9tZWRpYV9maWxl", + "X2Vycm9yLnByb3RvGjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMv", + "bWVkaWFfdXBsb2FkX2Vycm9yLnByb3RvGjVnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9lcnJvcnMvbXVsdGlwbGllcl9lcnJvci5wcm90bxoxZ29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZXJyb3JzL211dGF0ZV9lcnJvci5wcm90bxo1Z29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL211dGF0ZV9qb2JfZXJyb3Iu", + "cHJvdG8aQGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9uZXdfcmVz", + "b3VyY2VfY3JlYXRpb25fZXJyb3IucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xl", + "YWRzL3YzL2Vycm9ycy9ub3RfZW1wdHlfZXJyb3IucHJvdG8aOmdvb2dsZS9h", + "ZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9ub3Rfd2hpdGVsaXN0ZWRfZXJyb3Iu", + "cHJvdG8aL2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9udWxsX2Vy", + "cm9yLnByb3RvGkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvb3Bl", + "cmF0aW9uX2FjY2Vzc19kZW5pZWRfZXJyb3IucHJvdG8aM2dvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2Vycm9ycy9vcGVyYXRvcl9lcnJvci5wcm90bxo6Z29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL3BhcnRpYWxfZmFpbHVyZV9l", + "cnJvci5wcm90bxo7Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL3Bh", + "eW1lbnRzX2FjY291bnRfZXJyb3IucHJvdG8aOWdvb2dsZS9hZHMvZ29vZ2xl", + "YWRzL3YzL2Vycm9ycy9wb2xpY3lfZmluZGluZ19lcnJvci5wcm90bxpGZ29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL3BvbGljeV92YWxpZGF0aW9u", + "X3BhcmFtZXRlcl9lcnJvci5wcm90bxo7Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZXJyb3JzL3BvbGljeV92aW9sYXRpb25fZXJyb3IucHJvdG8aMGdvb2ds", + "ZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9xdWVyeV9lcnJvci5wcm90bxow", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL3F1b3RhX2Vycm9yLnBy", + "b3RvGjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvcmFuZ2VfZXJy", + "b3IucHJvdG8aNWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9yZWFj", + "aF9wbGFuX2Vycm9yLnByb3RvGjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9l", + "cnJvcnMvcmVjb21tZW5kYXRpb25fZXJyb3IucHJvdG8aNmdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2Vycm9ycy9yZWdpb25fY29kZV9lcnJvci5wcm90bxoy", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzL3JlcXVlc3RfZXJyb3Iu", + "cHJvdG8aQWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9yZXNvdXJj", + "ZV9hY2Nlc3NfZGVuaWVkX2Vycm9yLnByb3RvGkhnb29nbGUvYWRzL2dvb2ds", + "ZWFkcy92My9lcnJvcnMvcmVzb3VyY2VfY291bnRfbGltaXRfZXhjZWVkZWRf", + "ZXJyb3IucHJvdG8aMmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9z", + "ZXR0aW5nX2Vycm9yLnByb3RvGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9l", + "cnJvcnMvc2hhcmVkX2NyaXRlcmlvbl9lcnJvci5wcm90bxo1Z29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZXJyb3JzL3NoYXJlZF9zZXRfZXJyb3IucHJvdG8a", + "NWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy9zaXplX2xpbWl0X2Vy", + "cm9yLnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvc3Ry", + "aW5nX2Zvcm1hdF9lcnJvci5wcm90bxo4Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvZXJyb3JzL3N0cmluZ19sZW5ndGhfZXJyb3IucHJvdG8aNGdvb2dsZS9h", + "ZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy90aW1lX3pvbmVfZXJyb3IucHJvdG8a", + "NGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy91cmxfZmllbGRfZXJy", + "b3IucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycy91c2Vy", + "X2xpc3RfZXJyb3IucHJvdG8aRWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2Vy", + "cm9ycy95b3V0dWJlX3ZpZGVvX3JlZ2lzdHJhdGlvbl9lcnJvci5wcm90bxoe", + "Z29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fu", + "bm90YXRpb25zLnByb3RvIlIKEEdvb2dsZUFkc0ZhaWx1cmUSPgoGZXJyb3Jz", + "GAEgAygLMi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkdvb2ds", + "ZUFkc0Vycm9yIpgCCg5Hb29nbGVBZHNFcnJvchI9CgplcnJvcl9jb2RlGAEg", + "ASgLMikuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkVycm9yQ29k", + "ZRIPCgdtZXNzYWdlGAIgASgJEjYKB3RyaWdnZXIYAyABKAsyJS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5jb21tb24uVmFsdWUSPwoIbG9jYXRpb24YBCAB", + "KAsyLS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuRXJyb3JMb2Nh", + "dGlvbhI9CgdkZXRhaWxzGAUgASgLMiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZXJyb3JzLkVycm9yRGV0YWlscyKSWAoJRXJyb3JDb2RlElYKDXJlcXVl", + "c3RfZXJyb3IYASABKA4yPS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJv", + "cnMuUmVxdWVzdEVycm9yRW51bS5SZXF1ZXN0RXJyb3JIABJvChZiaWRkaW5n", + "X3N0cmF0ZWd5X2Vycm9yGAIgASgOMk0uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZXJyb3JzLkJpZGRpbmdTdHJhdGVneUVycm9yRW51bS5CaWRkaW5nU3Ry", + "YXRlZ3lFcnJvckgAEloKD3VybF9maWVsZF9lcnJvchgDIAEoDjI/Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5VcmxGaWVsZEVycm9yRW51bS5V", + "cmxGaWVsZEVycm9ySAASaQoUbGlzdF9vcGVyYXRpb25fZXJyb3IYBCABKA4y", + "SS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuTGlzdE9wZXJhdGlv", + "bkVycm9yRW51bS5MaXN0T3BlcmF0aW9uRXJyb3JIABJQCgtxdWVyeV9lcnJv", + "chgFIAEoDjI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5RdWVy", + "eUVycm9yRW51bS5RdWVyeUVycm9ySAASUwoMbXV0YXRlX2Vycm9yGAcgASgO", + "MjsuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLk11dGF0ZUVycm9y", + "RW51bS5NdXRhdGVFcnJvckgAEl0KEGZpZWxkX21hc2tfZXJyb3IYCCABKA4y", + "QS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuRmllbGRNYXNrRXJy", + "b3JFbnVtLkZpZWxkTWFza0Vycm9ySAASaAoTYXV0aG9yaXphdGlvbl9lcnJv", + "chgJIAEoDjJJLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5BdXRo", + "b3JpemF0aW9uRXJyb3JFbnVtLkF1dGhvcml6YXRpb25FcnJvckgAElkKDmlu", + "dGVybmFsX2Vycm9yGAogASgOMj8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZXJyb3JzLkludGVybmFsRXJyb3JFbnVtLkludGVybmFsRXJyb3JIABJQCgtx", + "dW90YV9lcnJvchgLIAEoDjI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycy5RdW90YUVycm9yRW51bS5RdW90YUVycm9ySAASRwoIYWRfZXJyb3IY", + "DCABKA4yMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuQWRFcnJv", + "ckVudW0uQWRFcnJvckgAElcKDmFkX2dyb3VwX2Vycm9yGA0gASgOMj0uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkFkR3JvdXBFcnJvckVudW0u", + "QWRHcm91cEVycm9ySAASbAoVY2FtcGFpZ25fYnVkZ2V0X2Vycm9yGA4gASgO", + "MksuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkNhbXBhaWduQnVk", + "Z2V0RXJyb3JFbnVtLkNhbXBhaWduQnVkZ2V0RXJyb3JIABJZCg5jYW1wYWln", + "bl9lcnJvchgPIAEoDjI/Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9y", + "cy5DYW1wYWlnbkVycm9yRW51bS5DYW1wYWlnbkVycm9ySAASawoUYXV0aGVu", + "dGljYXRpb25fZXJyb3IYESABKA4ySy5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lcnJvcnMuQXV0aGVudGljYXRpb25FcnJvckVudW0uQXV0aGVudGljYXRp", + "b25FcnJvckgAEnMKGGFkX2dyb3VwX2NyaXRlcmlvbl9lcnJvchgSIAEoDjJP", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5BZEdyb3VwQ3JpdGVy", + "aW9uRXJyb3JFbnVtLkFkR3JvdXBDcml0ZXJpb25FcnJvckgAEmYKE2FkX2N1", + "c3RvbWl6ZXJfZXJyb3IYEyABKA4yRy5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lcnJvcnMuQWRDdXN0b21pemVyRXJyb3JFbnVtLkFkQ3VzdG9taXplckVy", + "cm9ySAASXgoRYWRfZ3JvdXBfYWRfZXJyb3IYFSABKA4yQS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5lcnJvcnMuQWRHcm91cEFkRXJyb3JFbnVtLkFkR3Jv", + "dXBBZEVycm9ySAASXQoQYWRfc2hhcmluZ19lcnJvchgYIAEoDjJBLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5BZFNoYXJpbmdFcnJvckVudW0u", + "QWRTaGFyaW5nRXJyb3JIABJKCglhZHhfZXJyb3IYGSABKA4yNS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lcnJvcnMuQWR4RXJyb3JFbnVtLkFkeEVycm9y", + "SAASUAoLYXNzZXRfZXJyb3IYayABKA4yOS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lcnJvcnMuQXNzZXRFcnJvckVudW0uQXNzZXRFcnJvckgAElYKDWJp", + "ZGRpbmdfZXJyb3IYGiABKA4yPS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnMuQmlkZGluZ0Vycm9yRW51bS5CaWRkaW5nRXJyb3JIABJ1ChhjYW1w", + "YWlnbl9jcml0ZXJpb25fZXJyb3IYHSABKA4yUS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnMuQ2FtcGFpZ25Dcml0ZXJpb25FcnJvckVudW0uQ2Ft", + "cGFpZ25Dcml0ZXJpb25FcnJvckgAEmwKFWNvbGxlY3Rpb25fc2l6ZV9lcnJv", + "chgfIAEoDjJLLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5Db2xs", + "ZWN0aW9uU2l6ZUVycm9yRW51bS5Db2xsZWN0aW9uU2l6ZUVycm9ySAASYwoS", + "Y291bnRyeV9jb2RlX2Vycm9yGG0gASgOMkUuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZXJyb3JzLkNvdW50cnlDb2RlRXJyb3JFbnVtLkNvdW50cnlDb2Rl", + "RXJyb3JIABJcCg9jcml0ZXJpb25fZXJyb3IYICABKA4yQS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5lcnJvcnMuQ3JpdGVyaW9uRXJyb3JFbnVtLkNyaXRl", + "cmlvbkVycm9ySAASWQoOY3VzdG9tZXJfZXJyb3IYWiABKA4yPy5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lcnJvcnMuQ3VzdG9tZXJFcnJvckVudW0uQ3Vz", + "dG9tZXJFcnJvckgAEk0KCmRhdGVfZXJyb3IYISABKA4yNy5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5lcnJvcnMuRGF0ZUVycm9yRW51bS5EYXRlRXJyb3JI", + "ABJdChBkYXRlX3JhbmdlX2Vycm9yGCIgASgOMkEuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZXJyb3JzLkRhdGVSYW5nZUVycm9yRW51bS5EYXRlUmFuZ2VF", + "cnJvckgAElkKDmRpc3RpbmN0X2Vycm9yGCMgASgOMj8uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuZXJyb3JzLkRpc3RpbmN0RXJyb3JFbnVtLkRpc3RpbmN0", + "RXJyb3JIABKFAQoeZmVlZF9hdHRyaWJ1dGVfcmVmZXJlbmNlX2Vycm9yGCQg", + "ASgOMlsuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkZlZWRBdHRy", + "aWJ1dGVSZWZlcmVuY2VFcnJvckVudW0uRmVlZEF0dHJpYnV0ZVJlZmVyZW5j", + "ZUVycm9ySAASWQoOZnVuY3Rpb25fZXJyb3IYJSABKA4yPy5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5lcnJvcnMuRnVuY3Rpb25FcnJvckVudW0uRnVuY3Rp", + "b25FcnJvckgAEm8KFmZ1bmN0aW9uX3BhcnNpbmdfZXJyb3IYJiABKA4yTS5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuRnVuY3Rpb25QYXJzaW5n", + "RXJyb3JFbnVtLkZ1bmN0aW9uUGFyc2luZ0Vycm9ySAASRwoIaWRfZXJyb3IY", + "JyABKA4yMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuSWRFcnJv", + "ckVudW0uSWRFcnJvckgAElAKC2ltYWdlX2Vycm9yGCggASgOMjkuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkltYWdlRXJyb3JFbnVtLkltYWdl", + "RXJyb3JIABJmChNsYW5ndWFnZV9jb2RlX2Vycm9yGG4gASgOMkcuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkxhbmd1YWdlQ29kZUVycm9yRW51", + "bS5MYW5ndWFnZUNvZGVFcnJvckgAEmMKEm1lZGlhX2J1bmRsZV9lcnJvchgq", + "IAEoDjJFLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5NZWRpYUJ1", + "bmRsZUVycm9yRW51bS5NZWRpYUJ1bmRsZUVycm9ySAASYwoSbWVkaWFfdXBs", + "b2FkX2Vycm9yGHQgASgOMkUuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJy", + "b3JzLk1lZGlhVXBsb2FkRXJyb3JFbnVtLk1lZGlhVXBsb2FkRXJyb3JIABJd", + "ChBtZWRpYV9maWxlX2Vycm9yGFYgASgOMkEuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZXJyb3JzLk1lZGlhRmlsZUVycm9yRW51bS5NZWRpYUZpbGVFcnJv", + "ckgAEl8KEG11bHRpcGxpZXJfZXJyb3IYLCABKA4yQy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lcnJvcnMuTXVsdGlwbGllckVycm9yRW51bS5NdWx0aXBs", + "aWVyRXJyb3JIABJ8ChtuZXdfcmVzb3VyY2VfY3JlYXRpb25fZXJyb3IYLSAB", + "KA4yVS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuTmV3UmVzb3Vy", + "Y2VDcmVhdGlvbkVycm9yRW51bS5OZXdSZXNvdXJjZUNyZWF0aW9uRXJyb3JI", + "ABJaCg9ub3RfZW1wdHlfZXJyb3IYLiABKA4yPy5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnMuTm90RW1wdHlFcnJvckVudW0uTm90RW1wdHlFcnJv", + "ckgAEk0KCm51bGxfZXJyb3IYLyABKA4yNy5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lcnJvcnMuTnVsbEVycm9yRW51bS5OdWxsRXJyb3JIABJZCg5vcGVy", + "YXRvcl9lcnJvchgwIAEoDjI/Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycy5PcGVyYXRvckVycm9yRW51bS5PcGVyYXRvckVycm9ySAASUAoLcmFu", + "Z2VfZXJyb3IYMSABKA4yOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJv", + "cnMuUmFuZ2VFcnJvckVudW0uUmFuZ2VFcnJvckgAEmsKFHJlY29tbWVuZGF0", + "aW9uX2Vycm9yGDogASgOMksuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJy", + "b3JzLlJlY29tbWVuZGF0aW9uRXJyb3JFbnVtLlJlY29tbWVuZGF0aW9uRXJy", + "b3JIABJgChFyZWdpb25fY29kZV9lcnJvchgzIAEoDjJDLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVycm9ycy5SZWdpb25Db2RlRXJyb3JFbnVtLlJlZ2lv", + "bkNvZGVFcnJvckgAElYKDXNldHRpbmdfZXJyb3IYNCABKA4yPS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lcnJvcnMuU2V0dGluZ0Vycm9yRW51bS5TZXR0", + "aW5nRXJyb3JIABJmChNzdHJpbmdfZm9ybWF0X2Vycm9yGDUgASgOMkcuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLlN0cmluZ0Zvcm1hdEVycm9y", + "RW51bS5TdHJpbmdGb3JtYXRFcnJvckgAEmYKE3N0cmluZ19sZW5ndGhfZXJy", + "b3IYNiABKA4yRy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuU3Ry", + "aW5nTGVuZ3RoRXJyb3JFbnVtLlN0cmluZ0xlbmd0aEVycm9ySAASggEKHW9w", + "ZXJhdGlvbl9hY2Nlc3NfZGVuaWVkX2Vycm9yGDcgASgOMlkuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZXJyb3JzLk9wZXJhdGlvbkFjY2Vzc0RlbmllZEVy", + "cm9yRW51bS5PcGVyYXRpb25BY2Nlc3NEZW5pZWRFcnJvckgAEn8KHHJlc291", + "cmNlX2FjY2Vzc19kZW5pZWRfZXJyb3IYOCABKA4yVy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lcnJvcnMuUmVzb3VyY2VBY2Nlc3NEZW5pZWRFcnJvckVu", + "dW0uUmVzb3VyY2VBY2Nlc3NEZW5pZWRFcnJvckgAEpIBCiNyZXNvdXJjZV9j", + "b3VudF9saW1pdF9leGNlZWRlZF9lcnJvchg5IAEoDjJjLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVycm9ycy5SZXNvdXJjZUNvdW50TGltaXRFeGNlZWRl", + "ZEVycm9yRW51bS5SZXNvdXJjZUNvdW50TGltaXRFeGNlZWRlZEVycm9ySAAS", + "iwEKIHlvdXR1YmVfdmlkZW9fcmVnaXN0cmF0aW9uX2Vycm9yGHUgASgOMl8u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLllvdXR1YmVWaWRlb1Jl", + "Z2lzdHJhdGlvbkVycm9yRW51bS5Zb3V0dWJlVmlkZW9SZWdpc3RyYXRpb25F", + "cnJvckgAEnoKG2FkX2dyb3VwX2JpZF9tb2RpZmllcl9lcnJvchg7IAEoDjJT", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5BZEdyb3VwQmlkTW9k", + "aWZpZXJFcnJvckVudW0uQWRHcm91cEJpZE1vZGlmaWVyRXJyb3JIABJWCg1j", + "b250ZXh0X2Vycm9yGDwgASgOMj0uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZXJyb3JzLkNvbnRleHRFcnJvckVudW0uQ29udGV4dEVycm9ySAASUAoLZmll", + "bGRfZXJyb3IYPSABKA4yOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJv", + "cnMuRmllbGRFcnJvckVudW0uRmllbGRFcnJvckgAEl0KEHNoYXJlZF9zZXRf", + "ZXJyb3IYPiABKA4yQS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMu", + "U2hhcmVkU2V0RXJyb3JFbnVtLlNoYXJlZFNldEVycm9ySAASbwoWc2hhcmVk", + "X2NyaXRlcmlvbl9lcnJvchg/IAEoDjJNLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVycm9ycy5TaGFyZWRDcml0ZXJpb25FcnJvckVudW0uU2hhcmVkQ3Jp", + "dGVyaW9uRXJyb3JIABJ2ChljYW1wYWlnbl9zaGFyZWRfc2V0X2Vycm9yGEAg", + "ASgOMlEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkNhbXBhaWdu", + "U2hhcmVkU2V0RXJyb3JFbnVtLkNhbXBhaWduU2hhcmVkU2V0RXJyb3JIABJy", + "Chdjb252ZXJzaW9uX2FjdGlvbl9lcnJvchhBIAEoDjJPLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVycm9ycy5Db252ZXJzaW9uQWN0aW9uRXJyb3JFbnVt", + "LkNvbnZlcnNpb25BY3Rpb25FcnJvckgAEpEBCiJjb252ZXJzaW9uX2FkanVz", + "dG1lbnRfdXBsb2FkX2Vycm9yGHMgASgOMmMuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZXJyb3JzLkNvbnZlcnNpb25BZGp1c3RtZW50VXBsb2FkRXJyb3JF", + "bnVtLkNvbnZlcnNpb25BZGp1c3RtZW50VXBsb2FkRXJyb3JIABJyChdjb252", + "ZXJzaW9uX3VwbG9hZF9lcnJvchhvIAEoDjJPLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVycm9ycy5Db252ZXJzaW9uVXBsb2FkRXJyb3JFbnVtLkNvbnZl", + "cnNpb25VcGxvYWRFcnJvckgAElMKDGhlYWRlcl9lcnJvchhCIAEoDjI7Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5IZWFkZXJFcnJvckVudW0u", + "SGVhZGVyRXJyb3JIABJZCg5kYXRhYmFzZV9lcnJvchhDIAEoDjI/Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5EYXRhYmFzZUVycm9yRW51bS5E", + "YXRhYmFzZUVycm9ySAASaQoUcG9saWN5X2ZpbmRpbmdfZXJyb3IYRCABKA4y", + "SS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuUG9saWN5RmluZGlu", + "Z0Vycm9yRW51bS5Qb2xpY3lGaW5kaW5nRXJyb3JIABJNCgplbnVtX2Vycm9y", + "GEYgASgOMjcuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkVudW1F", + "cnJvckVudW0uRW51bUVycm9ySAASYwoSa2V5d29yZF9wbGFuX2Vycm9yGEcg", + "ASgOMkUuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLktleXdvcmRQ", + "bGFuRXJyb3JFbnVtLktleXdvcmRQbGFuRXJyb3JIABJ8ChtrZXl3b3JkX3Bs", + "YW5fY2FtcGFpZ25fZXJyb3IYSCABKA4yVS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lcnJvcnMuS2V5d29yZFBsYW5DYW1wYWlnbkVycm9yRW51bS5LZXl3", + "b3JkUGxhbkNhbXBhaWduRXJyb3JIABKSAQoja2V5d29yZF9wbGFuX25lZ2F0", + "aXZlX2tleXdvcmRfZXJyb3IYSSABKA4yYy5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lcnJvcnMuS2V5d29yZFBsYW5OZWdhdGl2ZUtleXdvcmRFcnJvckVu", + "dW0uS2V5d29yZFBsYW5OZWdhdGl2ZUtleXdvcmRFcnJvckgAEnoKG2tleXdv", + "cmRfcGxhbl9hZF9ncm91cF9lcnJvchhKIAEoDjJTLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVycm9ycy5LZXl3b3JkUGxhbkFkR3JvdXBFcnJvckVudW0u", + "S2V5d29yZFBsYW5BZEdyb3VwRXJyb3JIABJ5ChprZXl3b3JkX3BsYW5fa2V5", + "d29yZF9lcnJvchhLIAEoDjJTLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycy5LZXl3b3JkUGxhbktleXdvcmRFcnJvckVudW0uS2V5d29yZFBsYW5L", + "ZXl3b3JkRXJyb3JIABJwChdrZXl3b3JkX3BsYW5faWRlYV9lcnJvchhMIAEo", + "DjJNLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5LZXl3b3JkUGxh", + "bklkZWFFcnJvckVudW0uS2V5d29yZFBsYW5JZGVhRXJyb3JIABKCAQodYWNj", + "b3VudF9idWRnZXRfcHJvcG9zYWxfZXJyb3IYTSABKA4yWS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5lcnJvcnMuQWNjb3VudEJ1ZGdldFByb3Bvc2FsRXJy", + "b3JFbnVtLkFjY291bnRCdWRnZXRQcm9wb3NhbEVycm9ySAASWgoPdXNlcl9s", + "aXN0X2Vycm9yGE4gASgOMj8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJy", + "b3JzLlVzZXJMaXN0RXJyb3JFbnVtLlVzZXJMaXN0RXJyb3JIABJmChNjaGFu", + "Z2Vfc3RhdHVzX2Vycm9yGE8gASgOMkcuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZXJyb3JzLkNoYW5nZVN0YXR1c0Vycm9yRW51bS5DaGFuZ2VTdGF0dXNF", + "cnJvckgAEk0KCmZlZWRfZXJyb3IYUCABKA4yNy5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnMuRmVlZEVycm9yRW51bS5GZWVkRXJyb3JIABKVAQok", + "Z2VvX3RhcmdldF9jb25zdGFudF9zdWdnZXN0aW9uX2Vycm9yGFEgASgOMmUu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkdlb1RhcmdldENvbnN0", + "YW50U3VnZ2VzdGlvbkVycm9yRW51bS5HZW9UYXJnZXRDb25zdGFudFN1Z2dl", + "c3Rpb25FcnJvckgAEmkKFGNhbXBhaWduX2RyYWZ0X2Vycm9yGFIgASgOMkku", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkNhbXBhaWduRHJhZnRF", + "cnJvckVudW0uQ2FtcGFpZ25EcmFmdEVycm9ySAASWgoPZmVlZF9pdGVtX2Vy", + "cm9yGFMgASgOMj8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkZl", + "ZWRJdGVtRXJyb3JFbnVtLkZlZWRJdGVtRXJyb3JIABJQCgtsYWJlbF9lcnJv", + "chhUIAEoDjI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5MYWJl", + "bEVycm9yRW51bS5MYWJlbEVycm9ySAASZgoTYmlsbGluZ19zZXR1cF9lcnJv", + "chhXIAEoDjJHLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5CaWxs", + "aW5nU2V0dXBFcnJvckVudW0uQmlsbGluZ1NldHVwRXJyb3JIABJ5ChpjdXN0", + "b21lcl9jbGllbnRfbGlua19lcnJvchhYIAEoDjJTLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVycm9ycy5DdXN0b21lckNsaWVudExpbmtFcnJvckVudW0u", + "Q3VzdG9tZXJDbGllbnRMaW5rRXJyb3JIABJ8ChtjdXN0b21lcl9tYW5hZ2Vy", + "X2xpbmtfZXJyb3IYWyABKA4yVS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnMuQ3VzdG9tZXJNYW5hZ2VyTGlua0Vycm9yRW51bS5DdXN0b21lck1h", + "bmFnZXJMaW5rRXJyb3JIABJjChJmZWVkX21hcHBpbmdfZXJyb3IYXCABKA4y", + "RS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuRmVlZE1hcHBpbmdF", + "cnJvckVudW0uRmVlZE1hcHBpbmdFcnJvckgAEmYKE2N1c3RvbWVyX2ZlZWRf", + "ZXJyb3IYXSABKA4yRy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMu", + "Q3VzdG9tZXJGZWVkRXJyb3JFbnVtLkN1c3RvbWVyRmVlZEVycm9ySAASZAoT", + "YWRfZ3JvdXBfZmVlZF9lcnJvchheIAEoDjJFLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVycm9ycy5BZEdyb3VwRmVlZEVycm9yRW51bS5BZEdyb3VwRmVl", + "ZEVycm9ySAASZgoTY2FtcGFpZ25fZmVlZF9lcnJvchhgIAEoDjJHLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5DYW1wYWlnbkZlZWRFcnJvckVu", + "dW0uQ2FtcGFpZ25GZWVkRXJyb3JIABJsChVjdXN0b21faW50ZXJlc3RfZXJy", + "b3IYYSABKA4ySy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuQ3Vz", + "dG9tSW50ZXJlc3RFcnJvckVudW0uQ3VzdG9tSW50ZXJlc3RFcnJvckgAEngK", + "GWNhbXBhaWduX2V4cGVyaW1lbnRfZXJyb3IYYiABKA4yUy5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5lcnJvcnMuQ2FtcGFpZ25FeHBlcmltZW50RXJyb3JF", + "bnVtLkNhbXBhaWduRXhwZXJpbWVudEVycm9ySAASdgoZZXh0ZW5zaW9uX2Zl", + "ZWRfaXRlbV9lcnJvchhkIAEoDjJRLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9ycy5FeHRlbnNpb25GZWVkSXRlbUVycm9yRW51bS5FeHRlbnNpb25G", + "ZWVkSXRlbUVycm9ySAASYwoSYWRfcGFyYW1ldGVyX2Vycm9yGGUgASgOMkUu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkFkUGFyYW1ldGVyRXJy", + "b3JFbnVtLkFkUGFyYW1ldGVyRXJyb3JIABJ5ChpmZWVkX2l0ZW1fdmFsaWRh", + "dGlvbl9lcnJvchhmIAEoDjJTLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycy5GZWVkSXRlbVZhbGlkYXRpb25FcnJvckVudW0uRmVlZEl0ZW1WYWxp", + "ZGF0aW9uRXJyb3JIABJyChdleHRlbnNpb25fc2V0dGluZ19lcnJvchhnIAEo", + "DjJPLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5FeHRlbnNpb25T", + "ZXR0aW5nRXJyb3JFbnVtLkV4dGVuc2lvblNldHRpbmdFcnJvckgAEm0KFmZl", + "ZWRfaXRlbV90YXJnZXRfZXJyb3IYaCABKA4ySy5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnMuRmVlZEl0ZW1UYXJnZXRFcnJvckVudW0uRmVlZEl0", + "ZW1UYXJnZXRFcnJvckgAEm8KFnBvbGljeV92aW9sYXRpb25fZXJyb3IYaSAB", + "KA4yTS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMuUG9saWN5Vmlv", + "bGF0aW9uRXJyb3JFbnVtLlBvbGljeVZpb2xhdGlvbkVycm9ySAASXQoQbXV0", + "YXRlX2pvYl9lcnJvchhsIAEoDjJBLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9ycy5NdXRhdGVKb2JFcnJvckVudW0uTXV0YXRlSm9iRXJyb3JIABJs", + "ChVwYXJ0aWFsX2ZhaWx1cmVfZXJyb3IYcCABKA4ySy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lcnJvcnMuUGFydGlhbEZhaWx1cmVFcnJvckVudW0uUGFy", + "dGlhbEZhaWx1cmVFcnJvckgAEo4BCiFwb2xpY3lfdmFsaWRhdGlvbl9wYXJh", + "bWV0ZXJfZXJyb3IYciABKA4yYS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnMuUG9saWN5VmFsaWRhdGlvblBhcmFtZXRlckVycm9yRW51bS5Qb2xp", + "Y3lWYWxpZGF0aW9uUGFyYW1ldGVyRXJyb3JIABJdChBzaXplX2xpbWl0X2Vy", + "cm9yGHYgASgOMkEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLlNp", + "emVMaW1pdEVycm9yRW51bS5TaXplTGltaXRFcnJvckgAEmwKFW5vdF93aGl0", + "ZWxpc3RlZF9lcnJvchh4IAEoDjJLLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9ycy5Ob3RXaGl0ZWxpc3RlZEVycm9yRW51bS5Ob3RXaGl0ZWxpc3Rl", + "ZEVycm9ySAASYwoSbWFuYWdlcl9saW5rX2Vycm9yGHkgASgOMkUuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLk1hbmFnZXJMaW5rRXJyb3JFbnVt", + "Lk1hbmFnZXJMaW5rRXJyb3JIABJmChNjdXJyZW5jeV9jb2RlX2Vycm9yGHog", + "ASgOMkcuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkN1cnJlbmN5", + "Q29kZUVycm9yRW51bS5DdXJyZW5jeUNvZGVFcnJvckgAEnIKF2FjY2Vzc19p", + "bnZpdGF0aW9uX2Vycm9yGHwgASgOMk8uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZXJyb3JzLkFjY2Vzc0ludml0YXRpb25FcnJvckVudW0uQWNjZXNzSW52", + "aXRhdGlvbkVycm9ySAASXQoQcmVhY2hfcGxhbl9lcnJvchh9IAEoDjJBLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5SZWFjaFBsYW5FcnJvckVu", + "dW0uUmVhY2hQbGFuRXJyb3JIABJWCg1pbnZvaWNlX2Vycm9yGH4gASgOMj0u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzLkludm9pY2VFcnJvckVu", + "dW0uSW52b2ljZUVycm9ySAASbwoWcGF5bWVudHNfYWNjb3VudF9lcnJvchh/", + "IAEoDjJNLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycy5QYXltZW50", + "c0FjY291bnRFcnJvckVudW0uUGF5bWVudHNBY2NvdW50RXJyb3JIABJbCg90", + "aW1lX3pvbmVfZXJyb3IYgAEgASgOMj8uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZXJyb3JzLlRpbWVab25lRXJyb3JFbnVtLlRpbWVab25lRXJyb3JIAEIM", + "CgplcnJvcl9jb2RlIsABCg1FcnJvckxvY2F0aW9uElsKE2ZpZWxkX3BhdGhf", + "ZWxlbWVudHMYAiADKAsyPi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJv", + "cnMuRXJyb3JMb2NhdGlvbi5GaWVsZFBhdGhFbGVtZW50GlIKEEZpZWxkUGF0", + "aEVsZW1lbnQSEgoKZmllbGRfbmFtZRgBIAEoCRIqCgVpbmRleBgCIAEoCzIb", + "Lmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlIt4BCgxFcnJvckRldGFpbHMS", + "HgoWdW5wdWJsaXNoZWRfZXJyb3JfY29kZRgBIAEoCRJYChhwb2xpY3lfdmlv", + "bGF0aW9uX2RldGFpbHMYAiABKAsyNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lcnJvcnMuUG9saWN5VmlvbGF0aW9uRGV0YWlscxJUChZwb2xpY3lfZmlu", + "ZGluZ19kZXRhaWxzGAMgASgLMjQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZXJyb3JzLlBvbGljeUZpbmRpbmdEZXRhaWxzIrMBChZQb2xpY3lWaW9sYXRp", + "b25EZXRhaWxzEiMKG2V4dGVybmFsX3BvbGljeV9kZXNjcmlwdGlvbhgCIAEo", + "CRI/CgNrZXkYBCABKAsyMi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21t", + "b24uUG9saWN5VmlvbGF0aW9uS2V5EhwKFGV4dGVybmFsX3BvbGljeV9uYW1l", + "GAUgASgJEhUKDWlzX2V4ZW1wdGlibGUYBiABKAgiZgoUUG9saWN5RmluZGlu", + "Z0RldGFpbHMSTgoUcG9saWN5X3RvcGljX2VudHJpZXMYASADKAsyMC5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uUG9saWN5VG9waWNFbnRyeULm", + "AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0ILRXJyb3Jz", + "UHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBp", + "cy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2ds", + "ZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6", + "RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.PolicyReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.ValueReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AccessInvitationErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AccountBudgetProposalErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdCustomizerErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdGroupAdErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdGroupBidModifierErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdGroupCriterionErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdGroupErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdGroupFeedErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdParameterErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdSharingErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AdxErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AssetErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AuthenticationErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.AuthorizationErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.BiddingErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.BiddingStrategyErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.BillingSetupErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CampaignBudgetErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CampaignCriterionErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CampaignDraftErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CampaignErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CampaignExperimentErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CampaignFeedErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CampaignSharedSetErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ChangeStatusErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CollectionSizeErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ContextErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ConversionActionErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ConversionAdjustmentUploadErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ConversionUploadErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CountryCodeErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CriterionErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CurrencyCodeErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CustomInterestErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CustomerClientLinkErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CustomerErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CustomerFeedErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.CustomerManagerLinkErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.DatabaseErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.DateErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.DateRangeErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.DistinctErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.EnumErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ExtensionFeedItemErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ExtensionSettingErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FeedAttributeReferenceErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FeedErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FeedItemErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FeedItemTargetErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FeedMappingErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FieldErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FieldMaskErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FunctionErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FunctionParsingErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.GeoTargetConstantSuggestionErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.HeaderErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.IdErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ImageErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.InternalErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.InvoiceErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanAdGroupErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanCampaignErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanIdeaErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanKeywordErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanNegativeKeywordErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.LabelErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.LanguageCodeErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ListOperationErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ManagerLinkErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.MediaBundleErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.MediaFileErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.MediaUploadErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.MultiplierErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.MutateErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.MutateJobErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.NewResourceCreationErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.NotEmptyErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.NotWhitelistedErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.NullErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.OperationAccessDeniedErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.OperatorErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.PartialFailureErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.PaymentsAccountErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.PolicyValidationParameterErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.QueryErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.QuotaErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.RangeErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ReachPlanErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.RecommendationErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.RegionCodeErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.RequestErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ResourceAccessDeniedErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.ResourceCountLimitExceededErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.SettingErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.SharedCriterionErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.SharedSetErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.SizeLimitErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.StringFormatErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.StringLengthErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.TimeZoneErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.UrlFieldErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.UserListErrorReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.YoutubeVideoRegistrationErrorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.GoogleAdsFailure), global::Google.Ads.GoogleAds.V3.Errors.GoogleAdsFailure.Parser, new[]{ "Errors" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.GoogleAdsError), global::Google.Ads.GoogleAds.V3.Errors.GoogleAdsError.Parser, new[]{ "ErrorCode", "Message", "Trigger", "Location", "Details" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ErrorCode), global::Google.Ads.GoogleAds.V3.Errors.ErrorCode.Parser, new[]{ "RequestError", "BiddingStrategyError", "UrlFieldError", "ListOperationError", "QueryError", "MutateError", "FieldMaskError", "AuthorizationError", "InternalError", "QuotaError", "AdError", "AdGroupError", "CampaignBudgetError", "CampaignError", "AuthenticationError", "AdGroupCriterionError", "AdCustomizerError", "AdGroupAdError", "AdSharingError", "AdxError", "AssetError", "BiddingError", "CampaignCriterionError", "CollectionSizeError", "CountryCodeError", "CriterionError", "CustomerError", "DateError", "DateRangeError", "DistinctError", "FeedAttributeReferenceError", "FunctionError", "FunctionParsingError", "IdError", "ImageError", "LanguageCodeError", "MediaBundleError", "MediaUploadError", "MediaFileError", "MultiplierError", "NewResourceCreationError", "NotEmptyError", "NullError", "OperatorError", "RangeError", "RecommendationError", "RegionCodeError", "SettingError", "StringFormatError", "StringLengthError", "OperationAccessDeniedError", "ResourceAccessDeniedError", "ResourceCountLimitExceededError", "YoutubeVideoRegistrationError", "AdGroupBidModifierError", "ContextError", "FieldError", "SharedSetError", "SharedCriterionError", "CampaignSharedSetError", "ConversionActionError", "ConversionAdjustmentUploadError", "ConversionUploadError", "HeaderError", "DatabaseError", "PolicyFindingError", "EnumError", "KeywordPlanError", "KeywordPlanCampaignError", "KeywordPlanNegativeKeywordError", "KeywordPlanAdGroupError", "KeywordPlanKeywordError", "KeywordPlanIdeaError", "AccountBudgetProposalError", "UserListError", "ChangeStatusError", "FeedError", "GeoTargetConstantSuggestionError", "CampaignDraftError", "FeedItemError", "LabelError", "BillingSetupError", "CustomerClientLinkError", "CustomerManagerLinkError", "FeedMappingError", "CustomerFeedError", "AdGroupFeedError", "CampaignFeedError", "CustomInterestError", "CampaignExperimentError", "ExtensionFeedItemError", "AdParameterError", "FeedItemValidationError", "ExtensionSettingError", "FeedItemTargetError", "PolicyViolationError", "MutateJobError", "PartialFailureError", "PolicyValidationParameterError", "SizeLimitError", "NotWhitelistedError", "ManagerLinkError", "CurrencyCodeError", "AccessInvitationError", "ReachPlanError", "InvoiceError", "PaymentsAccountError", "TimeZoneError" }, new[]{ "ErrorCode" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation), global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation.Parser, new[]{ "FieldPathElements" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation.Types.FieldPathElement), global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation.Types.FieldPathElement.Parser, new[]{ "FieldName", "Index" }, null, null, null)}), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ErrorDetails), global::Google.Ads.GoogleAds.V3.Errors.ErrorDetails.Parser, new[]{ "UnpublishedErrorCode", "PolicyViolationDetails", "PolicyFindingDetails" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationDetails), global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationDetails.Parser, new[]{ "ExternalPolicyDescription", "Key", "ExternalPolicyName", "IsExemptible" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingDetails), global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingDetails.Parser, new[]{ "PolicyTopicEntries" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Describes how a GoogleAds API call failed. It's returned inside + /// google.rpc.Status.details when a call fails. + /// + public sealed partial class GoogleAdsFailure : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GoogleAdsFailure()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ErrorsReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFailure() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFailure(GoogleAdsFailure other) : this() { + errors_ = other.errors_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFailure Clone() { + return new GoogleAdsFailure(this); + } + + /// Field number for the "errors" field. + public const int ErrorsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_errors_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Errors.GoogleAdsError.Parser); + private readonly pbc::RepeatedField errors_ = new pbc::RepeatedField(); + /// + /// The list of errors that occurred. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Errors { + get { return errors_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GoogleAdsFailure); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GoogleAdsFailure other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!errors_.Equals(other.errors_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= errors_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + errors_.WriteTo(output, _repeated_errors_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += errors_.CalculateSize(_repeated_errors_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GoogleAdsFailure other) { + if (other == null) { + return; + } + errors_.Add(other.errors_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + errors_.AddEntriesFrom(input, _repeated_errors_codec); + break; + } + } + } + } + + } + + /// + /// GoogleAds-specific error. + /// + public sealed partial class GoogleAdsError : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GoogleAdsError()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ErrorsReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsError() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsError(GoogleAdsError other) : this() { + errorCode_ = other.errorCode_ != null ? other.errorCode_.Clone() : null; + message_ = other.message_; + trigger_ = other.trigger_ != null ? other.trigger_.Clone() : null; + location_ = other.location_ != null ? other.location_.Clone() : null; + details_ = other.details_ != null ? other.details_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsError Clone() { + return new GoogleAdsError(this); + } + + /// Field number for the "error_code" field. + public const int ErrorCodeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Errors.ErrorCode errorCode_; + /// + /// An enum value that indicates which error occurred. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ErrorCode ErrorCode { + get { return errorCode_; } + set { + errorCode_ = value; + } + } + + /// Field number for the "message" field. + public const int MessageFieldNumber = 2; + private string message_ = ""; + /// + /// A human-readable description of the error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Message { + get { return message_; } + set { + message_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "trigger" field. + public const int TriggerFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Common.Value trigger_; + /// + /// The value that triggered the error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.Value Trigger { + get { return trigger_; } + set { + trigger_ = value; + } + } + + /// Field number for the "location" field. + public const int LocationFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation location_; + /// + /// Describes the part of the request proto that caused the error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation Location { + get { return location_; } + set { + location_ = value; + } + } + + /// Field number for the "details" field. + public const int DetailsFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Errors.ErrorDetails details_; + /// + /// Additional error details, which are returned by certain error codes. Most + /// error codes do not include details. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ErrorDetails Details { + get { return details_; } + set { + details_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GoogleAdsError); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GoogleAdsError other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(ErrorCode, other.ErrorCode)) return false; + if (Message != other.Message) return false; + if (!object.Equals(Trigger, other.Trigger)) return false; + if (!object.Equals(Location, other.Location)) return false; + if (!object.Equals(Details, other.Details)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (errorCode_ != null) hash ^= ErrorCode.GetHashCode(); + if (Message.Length != 0) hash ^= Message.GetHashCode(); + if (trigger_ != null) hash ^= Trigger.GetHashCode(); + if (location_ != null) hash ^= Location.GetHashCode(); + if (details_ != null) hash ^= Details.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (errorCode_ != null) { + output.WriteRawTag(10); + output.WriteMessage(ErrorCode); + } + if (Message.Length != 0) { + output.WriteRawTag(18); + output.WriteString(Message); + } + if (trigger_ != null) { + output.WriteRawTag(26); + output.WriteMessage(Trigger); + } + if (location_ != null) { + output.WriteRawTag(34); + output.WriteMessage(Location); + } + if (details_ != null) { + output.WriteRawTag(42); + output.WriteMessage(Details); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (errorCode_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ErrorCode); + } + if (Message.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Message); + } + if (trigger_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Trigger); + } + if (location_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Location); + } + if (details_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Details); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GoogleAdsError other) { + if (other == null) { + return; + } + if (other.errorCode_ != null) { + if (errorCode_ == null) { + ErrorCode = new global::Google.Ads.GoogleAds.V3.Errors.ErrorCode(); + } + ErrorCode.MergeFrom(other.ErrorCode); + } + if (other.Message.Length != 0) { + Message = other.Message; + } + if (other.trigger_ != null) { + if (trigger_ == null) { + Trigger = new global::Google.Ads.GoogleAds.V3.Common.Value(); + } + Trigger.MergeFrom(other.Trigger); + } + if (other.location_ != null) { + if (location_ == null) { + Location = new global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation(); + } + Location.MergeFrom(other.Location); + } + if (other.details_ != null) { + if (details_ == null) { + Details = new global::Google.Ads.GoogleAds.V3.Errors.ErrorDetails(); + } + Details.MergeFrom(other.Details); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (errorCode_ == null) { + ErrorCode = new global::Google.Ads.GoogleAds.V3.Errors.ErrorCode(); + } + input.ReadMessage(ErrorCode); + break; + } + case 18: { + Message = input.ReadString(); + break; + } + case 26: { + if (trigger_ == null) { + Trigger = new global::Google.Ads.GoogleAds.V3.Common.Value(); + } + input.ReadMessage(Trigger); + break; + } + case 34: { + if (location_ == null) { + Location = new global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation(); + } + input.ReadMessage(Location); + break; + } + case 42: { + if (details_ == null) { + Details = new global::Google.Ads.GoogleAds.V3.Errors.ErrorDetails(); + } + input.ReadMessage(Details); + break; + } + } + } + } + + } + + /// + /// The error reason represented by type and enum. + /// + public sealed partial class ErrorCode : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ErrorCode()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ErrorsReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorCode() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorCode(ErrorCode other) : this() { + switch (other.ErrorCodeCase) { + case ErrorCodeOneofCase.RequestError: + RequestError = other.RequestError; + break; + case ErrorCodeOneofCase.BiddingStrategyError: + BiddingStrategyError = other.BiddingStrategyError; + break; + case ErrorCodeOneofCase.UrlFieldError: + UrlFieldError = other.UrlFieldError; + break; + case ErrorCodeOneofCase.ListOperationError: + ListOperationError = other.ListOperationError; + break; + case ErrorCodeOneofCase.QueryError: + QueryError = other.QueryError; + break; + case ErrorCodeOneofCase.MutateError: + MutateError = other.MutateError; + break; + case ErrorCodeOneofCase.FieldMaskError: + FieldMaskError = other.FieldMaskError; + break; + case ErrorCodeOneofCase.AuthorizationError: + AuthorizationError = other.AuthorizationError; + break; + case ErrorCodeOneofCase.InternalError: + InternalError = other.InternalError; + break; + case ErrorCodeOneofCase.QuotaError: + QuotaError = other.QuotaError; + break; + case ErrorCodeOneofCase.AdError: + AdError = other.AdError; + break; + case ErrorCodeOneofCase.AdGroupError: + AdGroupError = other.AdGroupError; + break; + case ErrorCodeOneofCase.CampaignBudgetError: + CampaignBudgetError = other.CampaignBudgetError; + break; + case ErrorCodeOneofCase.CampaignError: + CampaignError = other.CampaignError; + break; + case ErrorCodeOneofCase.AuthenticationError: + AuthenticationError = other.AuthenticationError; + break; + case ErrorCodeOneofCase.AdGroupCriterionError: + AdGroupCriterionError = other.AdGroupCriterionError; + break; + case ErrorCodeOneofCase.AdCustomizerError: + AdCustomizerError = other.AdCustomizerError; + break; + case ErrorCodeOneofCase.AdGroupAdError: + AdGroupAdError = other.AdGroupAdError; + break; + case ErrorCodeOneofCase.AdSharingError: + AdSharingError = other.AdSharingError; + break; + case ErrorCodeOneofCase.AdxError: + AdxError = other.AdxError; + break; + case ErrorCodeOneofCase.AssetError: + AssetError = other.AssetError; + break; + case ErrorCodeOneofCase.BiddingError: + BiddingError = other.BiddingError; + break; + case ErrorCodeOneofCase.CampaignCriterionError: + CampaignCriterionError = other.CampaignCriterionError; + break; + case ErrorCodeOneofCase.CollectionSizeError: + CollectionSizeError = other.CollectionSizeError; + break; + case ErrorCodeOneofCase.CountryCodeError: + CountryCodeError = other.CountryCodeError; + break; + case ErrorCodeOneofCase.CriterionError: + CriterionError = other.CriterionError; + break; + case ErrorCodeOneofCase.CustomerError: + CustomerError = other.CustomerError; + break; + case ErrorCodeOneofCase.DateError: + DateError = other.DateError; + break; + case ErrorCodeOneofCase.DateRangeError: + DateRangeError = other.DateRangeError; + break; + case ErrorCodeOneofCase.DistinctError: + DistinctError = other.DistinctError; + break; + case ErrorCodeOneofCase.FeedAttributeReferenceError: + FeedAttributeReferenceError = other.FeedAttributeReferenceError; + break; + case ErrorCodeOneofCase.FunctionError: + FunctionError = other.FunctionError; + break; + case ErrorCodeOneofCase.FunctionParsingError: + FunctionParsingError = other.FunctionParsingError; + break; + case ErrorCodeOneofCase.IdError: + IdError = other.IdError; + break; + case ErrorCodeOneofCase.ImageError: + ImageError = other.ImageError; + break; + case ErrorCodeOneofCase.LanguageCodeError: + LanguageCodeError = other.LanguageCodeError; + break; + case ErrorCodeOneofCase.MediaBundleError: + MediaBundleError = other.MediaBundleError; + break; + case ErrorCodeOneofCase.MediaUploadError: + MediaUploadError = other.MediaUploadError; + break; + case ErrorCodeOneofCase.MediaFileError: + MediaFileError = other.MediaFileError; + break; + case ErrorCodeOneofCase.MultiplierError: + MultiplierError = other.MultiplierError; + break; + case ErrorCodeOneofCase.NewResourceCreationError: + NewResourceCreationError = other.NewResourceCreationError; + break; + case ErrorCodeOneofCase.NotEmptyError: + NotEmptyError = other.NotEmptyError; + break; + case ErrorCodeOneofCase.NullError: + NullError = other.NullError; + break; + case ErrorCodeOneofCase.OperatorError: + OperatorError = other.OperatorError; + break; + case ErrorCodeOneofCase.RangeError: + RangeError = other.RangeError; + break; + case ErrorCodeOneofCase.RecommendationError: + RecommendationError = other.RecommendationError; + break; + case ErrorCodeOneofCase.RegionCodeError: + RegionCodeError = other.RegionCodeError; + break; + case ErrorCodeOneofCase.SettingError: + SettingError = other.SettingError; + break; + case ErrorCodeOneofCase.StringFormatError: + StringFormatError = other.StringFormatError; + break; + case ErrorCodeOneofCase.StringLengthError: + StringLengthError = other.StringLengthError; + break; + case ErrorCodeOneofCase.OperationAccessDeniedError: + OperationAccessDeniedError = other.OperationAccessDeniedError; + break; + case ErrorCodeOneofCase.ResourceAccessDeniedError: + ResourceAccessDeniedError = other.ResourceAccessDeniedError; + break; + case ErrorCodeOneofCase.ResourceCountLimitExceededError: + ResourceCountLimitExceededError = other.ResourceCountLimitExceededError; + break; + case ErrorCodeOneofCase.YoutubeVideoRegistrationError: + YoutubeVideoRegistrationError = other.YoutubeVideoRegistrationError; + break; + case ErrorCodeOneofCase.AdGroupBidModifierError: + AdGroupBidModifierError = other.AdGroupBidModifierError; + break; + case ErrorCodeOneofCase.ContextError: + ContextError = other.ContextError; + break; + case ErrorCodeOneofCase.FieldError: + FieldError = other.FieldError; + break; + case ErrorCodeOneofCase.SharedSetError: + SharedSetError = other.SharedSetError; + break; + case ErrorCodeOneofCase.SharedCriterionError: + SharedCriterionError = other.SharedCriterionError; + break; + case ErrorCodeOneofCase.CampaignSharedSetError: + CampaignSharedSetError = other.CampaignSharedSetError; + break; + case ErrorCodeOneofCase.ConversionActionError: + ConversionActionError = other.ConversionActionError; + break; + case ErrorCodeOneofCase.ConversionAdjustmentUploadError: + ConversionAdjustmentUploadError = other.ConversionAdjustmentUploadError; + break; + case ErrorCodeOneofCase.ConversionUploadError: + ConversionUploadError = other.ConversionUploadError; + break; + case ErrorCodeOneofCase.HeaderError: + HeaderError = other.HeaderError; + break; + case ErrorCodeOneofCase.DatabaseError: + DatabaseError = other.DatabaseError; + break; + case ErrorCodeOneofCase.PolicyFindingError: + PolicyFindingError = other.PolicyFindingError; + break; + case ErrorCodeOneofCase.EnumError: + EnumError = other.EnumError; + break; + case ErrorCodeOneofCase.KeywordPlanError: + KeywordPlanError = other.KeywordPlanError; + break; + case ErrorCodeOneofCase.KeywordPlanCampaignError: + KeywordPlanCampaignError = other.KeywordPlanCampaignError; + break; + case ErrorCodeOneofCase.KeywordPlanNegativeKeywordError: + KeywordPlanNegativeKeywordError = other.KeywordPlanNegativeKeywordError; + break; + case ErrorCodeOneofCase.KeywordPlanAdGroupError: + KeywordPlanAdGroupError = other.KeywordPlanAdGroupError; + break; + case ErrorCodeOneofCase.KeywordPlanKeywordError: + KeywordPlanKeywordError = other.KeywordPlanKeywordError; + break; + case ErrorCodeOneofCase.KeywordPlanIdeaError: + KeywordPlanIdeaError = other.KeywordPlanIdeaError; + break; + case ErrorCodeOneofCase.AccountBudgetProposalError: + AccountBudgetProposalError = other.AccountBudgetProposalError; + break; + case ErrorCodeOneofCase.UserListError: + UserListError = other.UserListError; + break; + case ErrorCodeOneofCase.ChangeStatusError: + ChangeStatusError = other.ChangeStatusError; + break; + case ErrorCodeOneofCase.FeedError: + FeedError = other.FeedError; + break; + case ErrorCodeOneofCase.GeoTargetConstantSuggestionError: + GeoTargetConstantSuggestionError = other.GeoTargetConstantSuggestionError; + break; + case ErrorCodeOneofCase.CampaignDraftError: + CampaignDraftError = other.CampaignDraftError; + break; + case ErrorCodeOneofCase.FeedItemError: + FeedItemError = other.FeedItemError; + break; + case ErrorCodeOneofCase.LabelError: + LabelError = other.LabelError; + break; + case ErrorCodeOneofCase.BillingSetupError: + BillingSetupError = other.BillingSetupError; + break; + case ErrorCodeOneofCase.CustomerClientLinkError: + CustomerClientLinkError = other.CustomerClientLinkError; + break; + case ErrorCodeOneofCase.CustomerManagerLinkError: + CustomerManagerLinkError = other.CustomerManagerLinkError; + break; + case ErrorCodeOneofCase.FeedMappingError: + FeedMappingError = other.FeedMappingError; + break; + case ErrorCodeOneofCase.CustomerFeedError: + CustomerFeedError = other.CustomerFeedError; + break; + case ErrorCodeOneofCase.AdGroupFeedError: + AdGroupFeedError = other.AdGroupFeedError; + break; + case ErrorCodeOneofCase.CampaignFeedError: + CampaignFeedError = other.CampaignFeedError; + break; + case ErrorCodeOneofCase.CustomInterestError: + CustomInterestError = other.CustomInterestError; + break; + case ErrorCodeOneofCase.CampaignExperimentError: + CampaignExperimentError = other.CampaignExperimentError; + break; + case ErrorCodeOneofCase.ExtensionFeedItemError: + ExtensionFeedItemError = other.ExtensionFeedItemError; + break; + case ErrorCodeOneofCase.AdParameterError: + AdParameterError = other.AdParameterError; + break; + case ErrorCodeOneofCase.FeedItemValidationError: + FeedItemValidationError = other.FeedItemValidationError; + break; + case ErrorCodeOneofCase.ExtensionSettingError: + ExtensionSettingError = other.ExtensionSettingError; + break; + case ErrorCodeOneofCase.FeedItemTargetError: + FeedItemTargetError = other.FeedItemTargetError; + break; + case ErrorCodeOneofCase.PolicyViolationError: + PolicyViolationError = other.PolicyViolationError; + break; + case ErrorCodeOneofCase.MutateJobError: + MutateJobError = other.MutateJobError; + break; + case ErrorCodeOneofCase.PartialFailureError: + PartialFailureError = other.PartialFailureError; + break; + case ErrorCodeOneofCase.PolicyValidationParameterError: + PolicyValidationParameterError = other.PolicyValidationParameterError; + break; + case ErrorCodeOneofCase.SizeLimitError: + SizeLimitError = other.SizeLimitError; + break; + case ErrorCodeOneofCase.NotWhitelistedError: + NotWhitelistedError = other.NotWhitelistedError; + break; + case ErrorCodeOneofCase.ManagerLinkError: + ManagerLinkError = other.ManagerLinkError; + break; + case ErrorCodeOneofCase.CurrencyCodeError: + CurrencyCodeError = other.CurrencyCodeError; + break; + case ErrorCodeOneofCase.AccessInvitationError: + AccessInvitationError = other.AccessInvitationError; + break; + case ErrorCodeOneofCase.ReachPlanError: + ReachPlanError = other.ReachPlanError; + break; + case ErrorCodeOneofCase.InvoiceError: + InvoiceError = other.InvoiceError; + break; + case ErrorCodeOneofCase.PaymentsAccountError: + PaymentsAccountError = other.PaymentsAccountError; + break; + case ErrorCodeOneofCase.TimeZoneError: + TimeZoneError = other.TimeZoneError; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorCode Clone() { + return new ErrorCode(this); + } + + /// Field number for the "request_error" field. + public const int RequestErrorFieldNumber = 1; + /// + /// An error caused by the request + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.RequestErrorEnum.Types.RequestError RequestError { + get { return errorCodeCase_ == ErrorCodeOneofCase.RequestError ? (global::Google.Ads.GoogleAds.V3.Errors.RequestErrorEnum.Types.RequestError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.RequestError; + } + } + + /// Field number for the "bidding_strategy_error" field. + public const int BiddingStrategyErrorFieldNumber = 2; + /// + /// An error with a Bidding Strategy mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.BiddingStrategyErrorEnum.Types.BiddingStrategyError BiddingStrategyError { + get { return errorCodeCase_ == ErrorCodeOneofCase.BiddingStrategyError ? (global::Google.Ads.GoogleAds.V3.Errors.BiddingStrategyErrorEnum.Types.BiddingStrategyError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.BiddingStrategyError; + } + } + + /// Field number for the "url_field_error" field. + public const int UrlFieldErrorFieldNumber = 3; + /// + /// An error with a URL field mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.UrlFieldErrorEnum.Types.UrlFieldError UrlFieldError { + get { return errorCodeCase_ == ErrorCodeOneofCase.UrlFieldError ? (global::Google.Ads.GoogleAds.V3.Errors.UrlFieldErrorEnum.Types.UrlFieldError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.UrlFieldError; + } + } + + /// Field number for the "list_operation_error" field. + public const int ListOperationErrorFieldNumber = 4; + /// + /// An error with a list operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ListOperationErrorEnum.Types.ListOperationError ListOperationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ListOperationError ? (global::Google.Ads.GoogleAds.V3.Errors.ListOperationErrorEnum.Types.ListOperationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ListOperationError; + } + } + + /// Field number for the "query_error" field. + public const int QueryErrorFieldNumber = 5; + /// + /// An error with an AWQL query + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.QueryErrorEnum.Types.QueryError QueryError { + get { return errorCodeCase_ == ErrorCodeOneofCase.QueryError ? (global::Google.Ads.GoogleAds.V3.Errors.QueryErrorEnum.Types.QueryError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.QueryError; + } + } + + /// Field number for the "mutate_error" field. + public const int MutateErrorFieldNumber = 7; + /// + /// An error with a mutate + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.MutateErrorEnum.Types.MutateError MutateError { + get { return errorCodeCase_ == ErrorCodeOneofCase.MutateError ? (global::Google.Ads.GoogleAds.V3.Errors.MutateErrorEnum.Types.MutateError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.MutateError; + } + } + + /// Field number for the "field_mask_error" field. + public const int FieldMaskErrorFieldNumber = 8; + /// + /// An error with a field mask + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FieldMaskErrorEnum.Types.FieldMaskError FieldMaskError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FieldMaskError ? (global::Google.Ads.GoogleAds.V3.Errors.FieldMaskErrorEnum.Types.FieldMaskError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FieldMaskError; + } + } + + /// Field number for the "authorization_error" field. + public const int AuthorizationErrorFieldNumber = 9; + /// + /// An error encountered when trying to authorize a user. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AuthorizationErrorEnum.Types.AuthorizationError AuthorizationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AuthorizationError ? (global::Google.Ads.GoogleAds.V3.Errors.AuthorizationErrorEnum.Types.AuthorizationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AuthorizationError; + } + } + + /// Field number for the "internal_error" field. + public const int InternalErrorFieldNumber = 10; + /// + /// An unexpected server-side error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.InternalErrorEnum.Types.InternalError InternalError { + get { return errorCodeCase_ == ErrorCodeOneofCase.InternalError ? (global::Google.Ads.GoogleAds.V3.Errors.InternalErrorEnum.Types.InternalError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.InternalError; + } + } + + /// Field number for the "quota_error" field. + public const int QuotaErrorFieldNumber = 11; + /// + /// An error with the amonut of quota remaining. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.QuotaErrorEnum.Types.QuotaError QuotaError { + get { return errorCodeCase_ == ErrorCodeOneofCase.QuotaError ? (global::Google.Ads.GoogleAds.V3.Errors.QuotaErrorEnum.Types.QuotaError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.QuotaError; + } + } + + /// Field number for the "ad_error" field. + public const int AdErrorFieldNumber = 12; + /// + /// An error with an Ad Group Ad mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdErrorEnum.Types.AdError AdError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdError ? (global::Google.Ads.GoogleAds.V3.Errors.AdErrorEnum.Types.AdError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdError; + } + } + + /// Field number for the "ad_group_error" field. + public const int AdGroupErrorFieldNumber = 13; + /// + /// An error with an Ad Group mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdGroupErrorEnum.Types.AdGroupError AdGroupError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdGroupError ? (global::Google.Ads.GoogleAds.V3.Errors.AdGroupErrorEnum.Types.AdGroupError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdGroupError; + } + } + + /// Field number for the "campaign_budget_error" field. + public const int CampaignBudgetErrorFieldNumber = 14; + /// + /// An error with a Campaign Budget mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CampaignBudgetErrorEnum.Types.CampaignBudgetError CampaignBudgetError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CampaignBudgetError ? (global::Google.Ads.GoogleAds.V3.Errors.CampaignBudgetErrorEnum.Types.CampaignBudgetError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CampaignBudgetError; + } + } + + /// Field number for the "campaign_error" field. + public const int CampaignErrorFieldNumber = 15; + /// + /// An error with a Campaign mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CampaignErrorEnum.Types.CampaignError CampaignError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CampaignError ? (global::Google.Ads.GoogleAds.V3.Errors.CampaignErrorEnum.Types.CampaignError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CampaignError; + } + } + + /// Field number for the "authentication_error" field. + public const int AuthenticationErrorFieldNumber = 17; + /// + /// Indicates failure to properly authenticate user. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AuthenticationErrorEnum.Types.AuthenticationError AuthenticationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AuthenticationError ? (global::Google.Ads.GoogleAds.V3.Errors.AuthenticationErrorEnum.Types.AuthenticationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AuthenticationError; + } + } + + /// Field number for the "ad_group_criterion_error" field. + public const int AdGroupCriterionErrorFieldNumber = 18; + /// + /// Indicates failure to properly authenticate user. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdGroupCriterionErrorEnum.Types.AdGroupCriterionError AdGroupCriterionError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdGroupCriterionError ? (global::Google.Ads.GoogleAds.V3.Errors.AdGroupCriterionErrorEnum.Types.AdGroupCriterionError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdGroupCriterionError; + } + } + + /// Field number for the "ad_customizer_error" field. + public const int AdCustomizerErrorFieldNumber = 19; + /// + /// The reasons for the ad customizer error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdCustomizerErrorEnum.Types.AdCustomizerError AdCustomizerError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdCustomizerError ? (global::Google.Ads.GoogleAds.V3.Errors.AdCustomizerErrorEnum.Types.AdCustomizerError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdCustomizerError; + } + } + + /// Field number for the "ad_group_ad_error" field. + public const int AdGroupAdErrorFieldNumber = 21; + /// + /// The reasons for the ad group ad error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdGroupAdErrorEnum.Types.AdGroupAdError AdGroupAdError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdGroupAdError ? (global::Google.Ads.GoogleAds.V3.Errors.AdGroupAdErrorEnum.Types.AdGroupAdError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdGroupAdError; + } + } + + /// Field number for the "ad_sharing_error" field. + public const int AdSharingErrorFieldNumber = 24; + /// + /// The reasons for the ad sharing error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdSharingErrorEnum.Types.AdSharingError AdSharingError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdSharingError ? (global::Google.Ads.GoogleAds.V3.Errors.AdSharingErrorEnum.Types.AdSharingError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdSharingError; + } + } + + /// Field number for the "adx_error" field. + public const int AdxErrorFieldNumber = 25; + /// + /// The reasons for the adx error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdxErrorEnum.Types.AdxError AdxError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdxError ? (global::Google.Ads.GoogleAds.V3.Errors.AdxErrorEnum.Types.AdxError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdxError; + } + } + + /// Field number for the "asset_error" field. + public const int AssetErrorFieldNumber = 107; + /// + /// The reasons for the asset error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AssetErrorEnum.Types.AssetError AssetError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AssetError ? (global::Google.Ads.GoogleAds.V3.Errors.AssetErrorEnum.Types.AssetError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AssetError; + } + } + + /// Field number for the "bidding_error" field. + public const int BiddingErrorFieldNumber = 26; + /// + /// The reasons for the bidding errors + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.BiddingErrorEnum.Types.BiddingError BiddingError { + get { return errorCodeCase_ == ErrorCodeOneofCase.BiddingError ? (global::Google.Ads.GoogleAds.V3.Errors.BiddingErrorEnum.Types.BiddingError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.BiddingError; + } + } + + /// Field number for the "campaign_criterion_error" field. + public const int CampaignCriterionErrorFieldNumber = 29; + /// + /// The reasons for the campaign criterion error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CampaignCriterionErrorEnum.Types.CampaignCriterionError CampaignCriterionError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CampaignCriterionError ? (global::Google.Ads.GoogleAds.V3.Errors.CampaignCriterionErrorEnum.Types.CampaignCriterionError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CampaignCriterionError; + } + } + + /// Field number for the "collection_size_error" field. + public const int CollectionSizeErrorFieldNumber = 31; + /// + /// The reasons for the collection size error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CollectionSizeErrorEnum.Types.CollectionSizeError CollectionSizeError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CollectionSizeError ? (global::Google.Ads.GoogleAds.V3.Errors.CollectionSizeErrorEnum.Types.CollectionSizeError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CollectionSizeError; + } + } + + /// Field number for the "country_code_error" field. + public const int CountryCodeErrorFieldNumber = 109; + /// + /// The reasons for the country code error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CountryCodeErrorEnum.Types.CountryCodeError CountryCodeError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CountryCodeError ? (global::Google.Ads.GoogleAds.V3.Errors.CountryCodeErrorEnum.Types.CountryCodeError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CountryCodeError; + } + } + + /// Field number for the "criterion_error" field. + public const int CriterionErrorFieldNumber = 32; + /// + /// The reasons for the criterion error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CriterionErrorEnum.Types.CriterionError CriterionError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CriterionError ? (global::Google.Ads.GoogleAds.V3.Errors.CriterionErrorEnum.Types.CriterionError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CriterionError; + } + } + + /// Field number for the "customer_error" field. + public const int CustomerErrorFieldNumber = 90; + /// + /// The reasons for the customer error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CustomerErrorEnum.Types.CustomerError CustomerError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CustomerError ? (global::Google.Ads.GoogleAds.V3.Errors.CustomerErrorEnum.Types.CustomerError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CustomerError; + } + } + + /// Field number for the "date_error" field. + public const int DateErrorFieldNumber = 33; + /// + /// The reasons for the date error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.DateErrorEnum.Types.DateError DateError { + get { return errorCodeCase_ == ErrorCodeOneofCase.DateError ? (global::Google.Ads.GoogleAds.V3.Errors.DateErrorEnum.Types.DateError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.DateError; + } + } + + /// Field number for the "date_range_error" field. + public const int DateRangeErrorFieldNumber = 34; + /// + /// The reasons for the date range error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.DateRangeErrorEnum.Types.DateRangeError DateRangeError { + get { return errorCodeCase_ == ErrorCodeOneofCase.DateRangeError ? (global::Google.Ads.GoogleAds.V3.Errors.DateRangeErrorEnum.Types.DateRangeError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.DateRangeError; + } + } + + /// Field number for the "distinct_error" field. + public const int DistinctErrorFieldNumber = 35; + /// + /// The reasons for the distinct error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.DistinctErrorEnum.Types.DistinctError DistinctError { + get { return errorCodeCase_ == ErrorCodeOneofCase.DistinctError ? (global::Google.Ads.GoogleAds.V3.Errors.DistinctErrorEnum.Types.DistinctError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.DistinctError; + } + } + + /// Field number for the "feed_attribute_reference_error" field. + public const int FeedAttributeReferenceErrorFieldNumber = 36; + /// + /// The reasons for the feed attribute reference error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FeedAttributeReferenceErrorEnum.Types.FeedAttributeReferenceError FeedAttributeReferenceError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FeedAttributeReferenceError ? (global::Google.Ads.GoogleAds.V3.Errors.FeedAttributeReferenceErrorEnum.Types.FeedAttributeReferenceError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FeedAttributeReferenceError; + } + } + + /// Field number for the "function_error" field. + public const int FunctionErrorFieldNumber = 37; + /// + /// The reasons for the function error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FunctionErrorEnum.Types.FunctionError FunctionError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FunctionError ? (global::Google.Ads.GoogleAds.V3.Errors.FunctionErrorEnum.Types.FunctionError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FunctionError; + } + } + + /// Field number for the "function_parsing_error" field. + public const int FunctionParsingErrorFieldNumber = 38; + /// + /// The reasons for the function parsing error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FunctionParsingErrorEnum.Types.FunctionParsingError FunctionParsingError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FunctionParsingError ? (global::Google.Ads.GoogleAds.V3.Errors.FunctionParsingErrorEnum.Types.FunctionParsingError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FunctionParsingError; + } + } + + /// Field number for the "id_error" field. + public const int IdErrorFieldNumber = 39; + /// + /// The reasons for the id error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.IdErrorEnum.Types.IdError IdError { + get { return errorCodeCase_ == ErrorCodeOneofCase.IdError ? (global::Google.Ads.GoogleAds.V3.Errors.IdErrorEnum.Types.IdError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.IdError; + } + } + + /// Field number for the "image_error" field. + public const int ImageErrorFieldNumber = 40; + /// + /// The reasons for the image error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ImageErrorEnum.Types.ImageError ImageError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ImageError ? (global::Google.Ads.GoogleAds.V3.Errors.ImageErrorEnum.Types.ImageError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ImageError; + } + } + + /// Field number for the "language_code_error" field. + public const int LanguageCodeErrorFieldNumber = 110; + /// + /// The reasons for the language code error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.LanguageCodeErrorEnum.Types.LanguageCodeError LanguageCodeError { + get { return errorCodeCase_ == ErrorCodeOneofCase.LanguageCodeError ? (global::Google.Ads.GoogleAds.V3.Errors.LanguageCodeErrorEnum.Types.LanguageCodeError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.LanguageCodeError; + } + } + + /// Field number for the "media_bundle_error" field. + public const int MediaBundleErrorFieldNumber = 42; + /// + /// The reasons for the media bundle error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.MediaBundleErrorEnum.Types.MediaBundleError MediaBundleError { + get { return errorCodeCase_ == ErrorCodeOneofCase.MediaBundleError ? (global::Google.Ads.GoogleAds.V3.Errors.MediaBundleErrorEnum.Types.MediaBundleError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.MediaBundleError; + } + } + + /// Field number for the "media_upload_error" field. + public const int MediaUploadErrorFieldNumber = 116; + /// + /// The reasons for media uploading errors. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.MediaUploadErrorEnum.Types.MediaUploadError MediaUploadError { + get { return errorCodeCase_ == ErrorCodeOneofCase.MediaUploadError ? (global::Google.Ads.GoogleAds.V3.Errors.MediaUploadErrorEnum.Types.MediaUploadError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.MediaUploadError; + } + } + + /// Field number for the "media_file_error" field. + public const int MediaFileErrorFieldNumber = 86; + /// + /// The reasons for the media file error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.MediaFileErrorEnum.Types.MediaFileError MediaFileError { + get { return errorCodeCase_ == ErrorCodeOneofCase.MediaFileError ? (global::Google.Ads.GoogleAds.V3.Errors.MediaFileErrorEnum.Types.MediaFileError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.MediaFileError; + } + } + + /// Field number for the "multiplier_error" field. + public const int MultiplierErrorFieldNumber = 44; + /// + /// The reasons for the multiplier error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.MultiplierErrorEnum.Types.MultiplierError MultiplierError { + get { return errorCodeCase_ == ErrorCodeOneofCase.MultiplierError ? (global::Google.Ads.GoogleAds.V3.Errors.MultiplierErrorEnum.Types.MultiplierError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.MultiplierError; + } + } + + /// Field number for the "new_resource_creation_error" field. + public const int NewResourceCreationErrorFieldNumber = 45; + /// + /// The reasons for the new resource creation error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.NewResourceCreationErrorEnum.Types.NewResourceCreationError NewResourceCreationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.NewResourceCreationError ? (global::Google.Ads.GoogleAds.V3.Errors.NewResourceCreationErrorEnum.Types.NewResourceCreationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.NewResourceCreationError; + } + } + + /// Field number for the "not_empty_error" field. + public const int NotEmptyErrorFieldNumber = 46; + /// + /// The reasons for the not empty error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.NotEmptyErrorEnum.Types.NotEmptyError NotEmptyError { + get { return errorCodeCase_ == ErrorCodeOneofCase.NotEmptyError ? (global::Google.Ads.GoogleAds.V3.Errors.NotEmptyErrorEnum.Types.NotEmptyError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.NotEmptyError; + } + } + + /// Field number for the "null_error" field. + public const int NullErrorFieldNumber = 47; + /// + /// The reasons for the null error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.NullErrorEnum.Types.NullError NullError { + get { return errorCodeCase_ == ErrorCodeOneofCase.NullError ? (global::Google.Ads.GoogleAds.V3.Errors.NullErrorEnum.Types.NullError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.NullError; + } + } + + /// Field number for the "operator_error" field. + public const int OperatorErrorFieldNumber = 48; + /// + /// The reasons for the operator error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.OperatorErrorEnum.Types.OperatorError OperatorError { + get { return errorCodeCase_ == ErrorCodeOneofCase.OperatorError ? (global::Google.Ads.GoogleAds.V3.Errors.OperatorErrorEnum.Types.OperatorError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.OperatorError; + } + } + + /// Field number for the "range_error" field. + public const int RangeErrorFieldNumber = 49; + /// + /// The reasons for the range error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.RangeErrorEnum.Types.RangeError RangeError { + get { return errorCodeCase_ == ErrorCodeOneofCase.RangeError ? (global::Google.Ads.GoogleAds.V3.Errors.RangeErrorEnum.Types.RangeError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.RangeError; + } + } + + /// Field number for the "recommendation_error" field. + public const int RecommendationErrorFieldNumber = 58; + /// + /// The reasons for error in applying a recommendation + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.RecommendationErrorEnum.Types.RecommendationError RecommendationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.RecommendationError ? (global::Google.Ads.GoogleAds.V3.Errors.RecommendationErrorEnum.Types.RecommendationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.RecommendationError; + } + } + + /// Field number for the "region_code_error" field. + public const int RegionCodeErrorFieldNumber = 51; + /// + /// The reasons for the region code error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.RegionCodeErrorEnum.Types.RegionCodeError RegionCodeError { + get { return errorCodeCase_ == ErrorCodeOneofCase.RegionCodeError ? (global::Google.Ads.GoogleAds.V3.Errors.RegionCodeErrorEnum.Types.RegionCodeError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.RegionCodeError; + } + } + + /// Field number for the "setting_error" field. + public const int SettingErrorFieldNumber = 52; + /// + /// The reasons for the setting error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.SettingErrorEnum.Types.SettingError SettingError { + get { return errorCodeCase_ == ErrorCodeOneofCase.SettingError ? (global::Google.Ads.GoogleAds.V3.Errors.SettingErrorEnum.Types.SettingError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.SettingError; + } + } + + /// Field number for the "string_format_error" field. + public const int StringFormatErrorFieldNumber = 53; + /// + /// The reasons for the string format error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.StringFormatErrorEnum.Types.StringFormatError StringFormatError { + get { return errorCodeCase_ == ErrorCodeOneofCase.StringFormatError ? (global::Google.Ads.GoogleAds.V3.Errors.StringFormatErrorEnum.Types.StringFormatError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.StringFormatError; + } + } + + /// Field number for the "string_length_error" field. + public const int StringLengthErrorFieldNumber = 54; + /// + /// The reasons for the string length error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.StringLengthErrorEnum.Types.StringLengthError StringLengthError { + get { return errorCodeCase_ == ErrorCodeOneofCase.StringLengthError ? (global::Google.Ads.GoogleAds.V3.Errors.StringLengthErrorEnum.Types.StringLengthError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.StringLengthError; + } + } + + /// Field number for the "operation_access_denied_error" field. + public const int OperationAccessDeniedErrorFieldNumber = 55; + /// + /// The reasons for the operation access denied error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.OperationAccessDeniedErrorEnum.Types.OperationAccessDeniedError OperationAccessDeniedError { + get { return errorCodeCase_ == ErrorCodeOneofCase.OperationAccessDeniedError ? (global::Google.Ads.GoogleAds.V3.Errors.OperationAccessDeniedErrorEnum.Types.OperationAccessDeniedError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.OperationAccessDeniedError; + } + } + + /// Field number for the "resource_access_denied_error" field. + public const int ResourceAccessDeniedErrorFieldNumber = 56; + /// + /// The reasons for the resource access denied error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ResourceAccessDeniedErrorEnum.Types.ResourceAccessDeniedError ResourceAccessDeniedError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ResourceAccessDeniedError ? (global::Google.Ads.GoogleAds.V3.Errors.ResourceAccessDeniedErrorEnum.Types.ResourceAccessDeniedError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ResourceAccessDeniedError; + } + } + + /// Field number for the "resource_count_limit_exceeded_error" field. + public const int ResourceCountLimitExceededErrorFieldNumber = 57; + /// + /// The reasons for the resource count limit exceeded error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ResourceCountLimitExceededErrorEnum.Types.ResourceCountLimitExceededError ResourceCountLimitExceededError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ResourceCountLimitExceededError ? (global::Google.Ads.GoogleAds.V3.Errors.ResourceCountLimitExceededErrorEnum.Types.ResourceCountLimitExceededError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ResourceCountLimitExceededError; + } + } + + /// Field number for the "youtube_video_registration_error" field. + public const int YoutubeVideoRegistrationErrorFieldNumber = 117; + /// + /// The reasons for YouTube video registration errors. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.YoutubeVideoRegistrationErrorEnum.Types.YoutubeVideoRegistrationError YoutubeVideoRegistrationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.YoutubeVideoRegistrationError ? (global::Google.Ads.GoogleAds.V3.Errors.YoutubeVideoRegistrationErrorEnum.Types.YoutubeVideoRegistrationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.YoutubeVideoRegistrationError; + } + } + + /// Field number for the "ad_group_bid_modifier_error" field. + public const int AdGroupBidModifierErrorFieldNumber = 59; + /// + /// The reasons for the ad group bid modifier error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdGroupBidModifierErrorEnum.Types.AdGroupBidModifierError AdGroupBidModifierError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdGroupBidModifierError ? (global::Google.Ads.GoogleAds.V3.Errors.AdGroupBidModifierErrorEnum.Types.AdGroupBidModifierError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdGroupBidModifierError; + } + } + + /// Field number for the "context_error" field. + public const int ContextErrorFieldNumber = 60; + /// + /// The reasons for the context error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ContextErrorEnum.Types.ContextError ContextError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ContextError ? (global::Google.Ads.GoogleAds.V3.Errors.ContextErrorEnum.Types.ContextError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ContextError; + } + } + + /// Field number for the "field_error" field. + public const int FieldErrorFieldNumber = 61; + /// + /// The reasons for the field error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FieldErrorEnum.Types.FieldError FieldError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FieldError ? (global::Google.Ads.GoogleAds.V3.Errors.FieldErrorEnum.Types.FieldError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FieldError; + } + } + + /// Field number for the "shared_set_error" field. + public const int SharedSetErrorFieldNumber = 62; + /// + /// The reasons for the shared set error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.SharedSetErrorEnum.Types.SharedSetError SharedSetError { + get { return errorCodeCase_ == ErrorCodeOneofCase.SharedSetError ? (global::Google.Ads.GoogleAds.V3.Errors.SharedSetErrorEnum.Types.SharedSetError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.SharedSetError; + } + } + + /// Field number for the "shared_criterion_error" field. + public const int SharedCriterionErrorFieldNumber = 63; + /// + /// The reasons for the shared criterion error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.SharedCriterionErrorEnum.Types.SharedCriterionError SharedCriterionError { + get { return errorCodeCase_ == ErrorCodeOneofCase.SharedCriterionError ? (global::Google.Ads.GoogleAds.V3.Errors.SharedCriterionErrorEnum.Types.SharedCriterionError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.SharedCriterionError; + } + } + + /// Field number for the "campaign_shared_set_error" field. + public const int CampaignSharedSetErrorFieldNumber = 64; + /// + /// The reasons for the campaign shared set error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CampaignSharedSetErrorEnum.Types.CampaignSharedSetError CampaignSharedSetError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CampaignSharedSetError ? (global::Google.Ads.GoogleAds.V3.Errors.CampaignSharedSetErrorEnum.Types.CampaignSharedSetError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CampaignSharedSetError; + } + } + + /// Field number for the "conversion_action_error" field. + public const int ConversionActionErrorFieldNumber = 65; + /// + /// The reasons for the conversion action error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ConversionActionErrorEnum.Types.ConversionActionError ConversionActionError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ConversionActionError ? (global::Google.Ads.GoogleAds.V3.Errors.ConversionActionErrorEnum.Types.ConversionActionError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ConversionActionError; + } + } + + /// Field number for the "conversion_adjustment_upload_error" field. + public const int ConversionAdjustmentUploadErrorFieldNumber = 115; + /// + /// The reasons for the conversion adjustment upload error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ConversionAdjustmentUploadErrorEnum.Types.ConversionAdjustmentUploadError ConversionAdjustmentUploadError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ConversionAdjustmentUploadError ? (global::Google.Ads.GoogleAds.V3.Errors.ConversionAdjustmentUploadErrorEnum.Types.ConversionAdjustmentUploadError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ConversionAdjustmentUploadError; + } + } + + /// Field number for the "conversion_upload_error" field. + public const int ConversionUploadErrorFieldNumber = 111; + /// + /// The reasons for the conversion upload error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ConversionUploadErrorEnum.Types.ConversionUploadError ConversionUploadError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ConversionUploadError ? (global::Google.Ads.GoogleAds.V3.Errors.ConversionUploadErrorEnum.Types.ConversionUploadError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ConversionUploadError; + } + } + + /// Field number for the "header_error" field. + public const int HeaderErrorFieldNumber = 66; + /// + /// The reasons for the header error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.HeaderErrorEnum.Types.HeaderError HeaderError { + get { return errorCodeCase_ == ErrorCodeOneofCase.HeaderError ? (global::Google.Ads.GoogleAds.V3.Errors.HeaderErrorEnum.Types.HeaderError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.HeaderError; + } + } + + /// Field number for the "database_error" field. + public const int DatabaseErrorFieldNumber = 67; + /// + /// The reasons for the database error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.DatabaseErrorEnum.Types.DatabaseError DatabaseError { + get { return errorCodeCase_ == ErrorCodeOneofCase.DatabaseError ? (global::Google.Ads.GoogleAds.V3.Errors.DatabaseErrorEnum.Types.DatabaseError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.DatabaseError; + } + } + + /// Field number for the "policy_finding_error" field. + public const int PolicyFindingErrorFieldNumber = 68; + /// + /// The reasons for the policy finding error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingErrorEnum.Types.PolicyFindingError PolicyFindingError { + get { return errorCodeCase_ == ErrorCodeOneofCase.PolicyFindingError ? (global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingErrorEnum.Types.PolicyFindingError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.PolicyFindingError; + } + } + + /// Field number for the "enum_error" field. + public const int EnumErrorFieldNumber = 70; + /// + /// The reason for enum error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.EnumErrorEnum.Types.EnumError EnumError { + get { return errorCodeCase_ == ErrorCodeOneofCase.EnumError ? (global::Google.Ads.GoogleAds.V3.Errors.EnumErrorEnum.Types.EnumError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.EnumError; + } + } + + /// Field number for the "keyword_plan_error" field. + public const int KeywordPlanErrorFieldNumber = 71; + /// + /// The reason for keyword plan error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanErrorEnum.Types.KeywordPlanError KeywordPlanError { + get { return errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanError ? (global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanErrorEnum.Types.KeywordPlanError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanError; + } + } + + /// Field number for the "keyword_plan_campaign_error" field. + public const int KeywordPlanCampaignErrorFieldNumber = 72; + /// + /// The reason for keyword plan campaign error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanCampaignErrorEnum.Types.KeywordPlanCampaignError KeywordPlanCampaignError { + get { return errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanCampaignError ? (global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanCampaignErrorEnum.Types.KeywordPlanCampaignError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanCampaignError; + } + } + + /// Field number for the "keyword_plan_negative_keyword_error" field. + public const int KeywordPlanNegativeKeywordErrorFieldNumber = 73; + /// + /// The reason for keyword plan negative keyword error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanNegativeKeywordErrorEnum.Types.KeywordPlanNegativeKeywordError KeywordPlanNegativeKeywordError { + get { return errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanNegativeKeywordError ? (global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanNegativeKeywordErrorEnum.Types.KeywordPlanNegativeKeywordError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanNegativeKeywordError; + } + } + + /// Field number for the "keyword_plan_ad_group_error" field. + public const int KeywordPlanAdGroupErrorFieldNumber = 74; + /// + /// The reason for keyword plan ad group error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanAdGroupErrorEnum.Types.KeywordPlanAdGroupError KeywordPlanAdGroupError { + get { return errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanAdGroupError ? (global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanAdGroupErrorEnum.Types.KeywordPlanAdGroupError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanAdGroupError; + } + } + + /// Field number for the "keyword_plan_keyword_error" field. + public const int KeywordPlanKeywordErrorFieldNumber = 75; + /// + /// The reason for keyword plan keyword error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanKeywordErrorEnum.Types.KeywordPlanKeywordError KeywordPlanKeywordError { + get { return errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanKeywordError ? (global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanKeywordErrorEnum.Types.KeywordPlanKeywordError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanKeywordError; + } + } + + /// Field number for the "keyword_plan_idea_error" field. + public const int KeywordPlanIdeaErrorFieldNumber = 76; + /// + /// The reason for keyword idea error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanIdeaErrorEnum.Types.KeywordPlanIdeaError KeywordPlanIdeaError { + get { return errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanIdeaError ? (global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanIdeaErrorEnum.Types.KeywordPlanIdeaError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanIdeaError; + } + } + + /// Field number for the "account_budget_proposal_error" field. + public const int AccountBudgetProposalErrorFieldNumber = 77; + /// + /// The reasons for account budget proposal errors. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AccountBudgetProposalErrorEnum.Types.AccountBudgetProposalError AccountBudgetProposalError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AccountBudgetProposalError ? (global::Google.Ads.GoogleAds.V3.Errors.AccountBudgetProposalErrorEnum.Types.AccountBudgetProposalError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AccountBudgetProposalError; + } + } + + /// Field number for the "user_list_error" field. + public const int UserListErrorFieldNumber = 78; + /// + /// The reasons for the user list error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.UserListErrorEnum.Types.UserListError UserListError { + get { return errorCodeCase_ == ErrorCodeOneofCase.UserListError ? (global::Google.Ads.GoogleAds.V3.Errors.UserListErrorEnum.Types.UserListError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.UserListError; + } + } + + /// Field number for the "change_status_error" field. + public const int ChangeStatusErrorFieldNumber = 79; + /// + /// The reasons for the change status error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ChangeStatusErrorEnum.Types.ChangeStatusError ChangeStatusError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ChangeStatusError ? (global::Google.Ads.GoogleAds.V3.Errors.ChangeStatusErrorEnum.Types.ChangeStatusError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ChangeStatusError; + } + } + + /// Field number for the "feed_error" field. + public const int FeedErrorFieldNumber = 80; + /// + /// The reasons for the feed error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FeedErrorEnum.Types.FeedError FeedError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FeedError ? (global::Google.Ads.GoogleAds.V3.Errors.FeedErrorEnum.Types.FeedError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FeedError; + } + } + + /// Field number for the "geo_target_constant_suggestion_error" field. + public const int GeoTargetConstantSuggestionErrorFieldNumber = 81; + /// + /// The reasons for the geo target constant suggestion error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.GeoTargetConstantSuggestionErrorEnum.Types.GeoTargetConstantSuggestionError GeoTargetConstantSuggestionError { + get { return errorCodeCase_ == ErrorCodeOneofCase.GeoTargetConstantSuggestionError ? (global::Google.Ads.GoogleAds.V3.Errors.GeoTargetConstantSuggestionErrorEnum.Types.GeoTargetConstantSuggestionError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.GeoTargetConstantSuggestionError; + } + } + + /// Field number for the "campaign_draft_error" field. + public const int CampaignDraftErrorFieldNumber = 82; + /// + /// The reasons for the campaign draft error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CampaignDraftErrorEnum.Types.CampaignDraftError CampaignDraftError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CampaignDraftError ? (global::Google.Ads.GoogleAds.V3.Errors.CampaignDraftErrorEnum.Types.CampaignDraftError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CampaignDraftError; + } + } + + /// Field number for the "feed_item_error" field. + public const int FeedItemErrorFieldNumber = 83; + /// + /// The reasons for the feed item error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FeedItemErrorEnum.Types.FeedItemError FeedItemError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FeedItemError ? (global::Google.Ads.GoogleAds.V3.Errors.FeedItemErrorEnum.Types.FeedItemError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FeedItemError; + } + } + + /// Field number for the "label_error" field. + public const int LabelErrorFieldNumber = 84; + /// + /// The reason for the label error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.LabelErrorEnum.Types.LabelError LabelError { + get { return errorCodeCase_ == ErrorCodeOneofCase.LabelError ? (global::Google.Ads.GoogleAds.V3.Errors.LabelErrorEnum.Types.LabelError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.LabelError; + } + } + + /// Field number for the "billing_setup_error" field. + public const int BillingSetupErrorFieldNumber = 87; + /// + /// The reasons for the billing setup error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.BillingSetupErrorEnum.Types.BillingSetupError BillingSetupError { + get { return errorCodeCase_ == ErrorCodeOneofCase.BillingSetupError ? (global::Google.Ads.GoogleAds.V3.Errors.BillingSetupErrorEnum.Types.BillingSetupError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.BillingSetupError; + } + } + + /// Field number for the "customer_client_link_error" field. + public const int CustomerClientLinkErrorFieldNumber = 88; + /// + /// The reasons for the customer client link error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CustomerClientLinkErrorEnum.Types.CustomerClientLinkError CustomerClientLinkError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CustomerClientLinkError ? (global::Google.Ads.GoogleAds.V3.Errors.CustomerClientLinkErrorEnum.Types.CustomerClientLinkError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CustomerClientLinkError; + } + } + + /// Field number for the "customer_manager_link_error" field. + public const int CustomerManagerLinkErrorFieldNumber = 91; + /// + /// The reasons for the customer manager link error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CustomerManagerLinkErrorEnum.Types.CustomerManagerLinkError CustomerManagerLinkError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CustomerManagerLinkError ? (global::Google.Ads.GoogleAds.V3.Errors.CustomerManagerLinkErrorEnum.Types.CustomerManagerLinkError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CustomerManagerLinkError; + } + } + + /// Field number for the "feed_mapping_error" field. + public const int FeedMappingErrorFieldNumber = 92; + /// + /// The reasons for the feed mapping error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FeedMappingErrorEnum.Types.FeedMappingError FeedMappingError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FeedMappingError ? (global::Google.Ads.GoogleAds.V3.Errors.FeedMappingErrorEnum.Types.FeedMappingError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FeedMappingError; + } + } + + /// Field number for the "customer_feed_error" field. + public const int CustomerFeedErrorFieldNumber = 93; + /// + /// The reasons for the customer feed error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CustomerFeedErrorEnum.Types.CustomerFeedError CustomerFeedError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CustomerFeedError ? (global::Google.Ads.GoogleAds.V3.Errors.CustomerFeedErrorEnum.Types.CustomerFeedError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CustomerFeedError; + } + } + + /// Field number for the "ad_group_feed_error" field. + public const int AdGroupFeedErrorFieldNumber = 94; + /// + /// The reasons for the ad group feed error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdGroupFeedErrorEnum.Types.AdGroupFeedError AdGroupFeedError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdGroupFeedError ? (global::Google.Ads.GoogleAds.V3.Errors.AdGroupFeedErrorEnum.Types.AdGroupFeedError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdGroupFeedError; + } + } + + /// Field number for the "campaign_feed_error" field. + public const int CampaignFeedErrorFieldNumber = 96; + /// + /// The reasons for the campaign feed error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CampaignFeedErrorEnum.Types.CampaignFeedError CampaignFeedError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CampaignFeedError ? (global::Google.Ads.GoogleAds.V3.Errors.CampaignFeedErrorEnum.Types.CampaignFeedError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CampaignFeedError; + } + } + + /// Field number for the "custom_interest_error" field. + public const int CustomInterestErrorFieldNumber = 97; + /// + /// The reasons for the custom interest error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CustomInterestErrorEnum.Types.CustomInterestError CustomInterestError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CustomInterestError ? (global::Google.Ads.GoogleAds.V3.Errors.CustomInterestErrorEnum.Types.CustomInterestError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CustomInterestError; + } + } + + /// Field number for the "campaign_experiment_error" field. + public const int CampaignExperimentErrorFieldNumber = 98; + /// + /// The reasons for the campaign experiment error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CampaignExperimentErrorEnum.Types.CampaignExperimentError CampaignExperimentError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CampaignExperimentError ? (global::Google.Ads.GoogleAds.V3.Errors.CampaignExperimentErrorEnum.Types.CampaignExperimentError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CampaignExperimentError; + } + } + + /// Field number for the "extension_feed_item_error" field. + public const int ExtensionFeedItemErrorFieldNumber = 100; + /// + /// The reasons for the extension feed item error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ExtensionFeedItemErrorEnum.Types.ExtensionFeedItemError ExtensionFeedItemError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ExtensionFeedItemError ? (global::Google.Ads.GoogleAds.V3.Errors.ExtensionFeedItemErrorEnum.Types.ExtensionFeedItemError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ExtensionFeedItemError; + } + } + + /// Field number for the "ad_parameter_error" field. + public const int AdParameterErrorFieldNumber = 101; + /// + /// The reasons for the ad parameter error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AdParameterErrorEnum.Types.AdParameterError AdParameterError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AdParameterError ? (global::Google.Ads.GoogleAds.V3.Errors.AdParameterErrorEnum.Types.AdParameterError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AdParameterError; + } + } + + /// Field number for the "feed_item_validation_error" field. + public const int FeedItemValidationErrorFieldNumber = 102; + /// + /// The reasons for the feed item validation error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorEnum.Types.FeedItemValidationError FeedItemValidationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FeedItemValidationError ? (global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorEnum.Types.FeedItemValidationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FeedItemValidationError; + } + } + + /// Field number for the "extension_setting_error" field. + public const int ExtensionSettingErrorFieldNumber = 103; + /// + /// The reasons for the extension setting error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ExtensionSettingErrorEnum.Types.ExtensionSettingError ExtensionSettingError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ExtensionSettingError ? (global::Google.Ads.GoogleAds.V3.Errors.ExtensionSettingErrorEnum.Types.ExtensionSettingError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ExtensionSettingError; + } + } + + /// Field number for the "feed_item_target_error" field. + public const int FeedItemTargetErrorFieldNumber = 104; + /// + /// The reasons for the feed item target error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FeedItemTargetErrorEnum.Types.FeedItemTargetError FeedItemTargetError { + get { return errorCodeCase_ == ErrorCodeOneofCase.FeedItemTargetError ? (global::Google.Ads.GoogleAds.V3.Errors.FeedItemTargetErrorEnum.Types.FeedItemTargetError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.FeedItemTargetError; + } + } + + /// Field number for the "policy_violation_error" field. + public const int PolicyViolationErrorFieldNumber = 105; + /// + /// The reasons for the policy violation error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationErrorEnum.Types.PolicyViolationError PolicyViolationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.PolicyViolationError ? (global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationErrorEnum.Types.PolicyViolationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.PolicyViolationError; + } + } + + /// Field number for the "mutate_job_error" field. + public const int MutateJobErrorFieldNumber = 108; + /// + /// The reasons for the mutate job error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.MutateJobErrorEnum.Types.MutateJobError MutateJobError { + get { return errorCodeCase_ == ErrorCodeOneofCase.MutateJobError ? (global::Google.Ads.GoogleAds.V3.Errors.MutateJobErrorEnum.Types.MutateJobError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.MutateJobError; + } + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 112; + /// + /// The reasons for the mutate job error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.PartialFailureErrorEnum.Types.PartialFailureError PartialFailureError { + get { return errorCodeCase_ == ErrorCodeOneofCase.PartialFailureError ? (global::Google.Ads.GoogleAds.V3.Errors.PartialFailureErrorEnum.Types.PartialFailureError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.PartialFailureError; + } + } + + /// Field number for the "policy_validation_parameter_error" field. + public const int PolicyValidationParameterErrorFieldNumber = 114; + /// + /// The reasons for the policy validation parameter error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.PolicyValidationParameterErrorEnum.Types.PolicyValidationParameterError PolicyValidationParameterError { + get { return errorCodeCase_ == ErrorCodeOneofCase.PolicyValidationParameterError ? (global::Google.Ads.GoogleAds.V3.Errors.PolicyValidationParameterErrorEnum.Types.PolicyValidationParameterError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.PolicyValidationParameterError; + } + } + + /// Field number for the "size_limit_error" field. + public const int SizeLimitErrorFieldNumber = 118; + /// + /// The reasons for the size limit error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.SizeLimitErrorEnum.Types.SizeLimitError SizeLimitError { + get { return errorCodeCase_ == ErrorCodeOneofCase.SizeLimitError ? (global::Google.Ads.GoogleAds.V3.Errors.SizeLimitErrorEnum.Types.SizeLimitError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.SizeLimitError; + } + } + + /// Field number for the "not_whitelisted_error" field. + public const int NotWhitelistedErrorFieldNumber = 120; + /// + /// The reasons for the not whitelisted error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.NotWhitelistedErrorEnum.Types.NotWhitelistedError NotWhitelistedError { + get { return errorCodeCase_ == ErrorCodeOneofCase.NotWhitelistedError ? (global::Google.Ads.GoogleAds.V3.Errors.NotWhitelistedErrorEnum.Types.NotWhitelistedError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.NotWhitelistedError; + } + } + + /// Field number for the "manager_link_error" field. + public const int ManagerLinkErrorFieldNumber = 121; + /// + /// The reasons for the manager link error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ManagerLinkErrorEnum.Types.ManagerLinkError ManagerLinkError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ManagerLinkError ? (global::Google.Ads.GoogleAds.V3.Errors.ManagerLinkErrorEnum.Types.ManagerLinkError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ManagerLinkError; + } + } + + /// Field number for the "currency_code_error" field. + public const int CurrencyCodeErrorFieldNumber = 122; + /// + /// The reasons for the currency code error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.CurrencyCodeErrorEnum.Types.CurrencyCodeError CurrencyCodeError { + get { return errorCodeCase_ == ErrorCodeOneofCase.CurrencyCodeError ? (global::Google.Ads.GoogleAds.V3.Errors.CurrencyCodeErrorEnum.Types.CurrencyCodeError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.CurrencyCodeError; + } + } + + /// Field number for the "access_invitation_error" field. + public const int AccessInvitationErrorFieldNumber = 124; + /// + /// The reasons for the access invitation error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.AccessInvitationErrorEnum.Types.AccessInvitationError AccessInvitationError { + get { return errorCodeCase_ == ErrorCodeOneofCase.AccessInvitationError ? (global::Google.Ads.GoogleAds.V3.Errors.AccessInvitationErrorEnum.Types.AccessInvitationError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.AccessInvitationError; + } + } + + /// Field number for the "reach_plan_error" field. + public const int ReachPlanErrorFieldNumber = 125; + /// + /// The reasons for the reach plan error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.ReachPlanErrorEnum.Types.ReachPlanError ReachPlanError { + get { return errorCodeCase_ == ErrorCodeOneofCase.ReachPlanError ? (global::Google.Ads.GoogleAds.V3.Errors.ReachPlanErrorEnum.Types.ReachPlanError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.ReachPlanError; + } + } + + /// Field number for the "invoice_error" field. + public const int InvoiceErrorFieldNumber = 126; + /// + /// The reasons for the invoice error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.InvoiceErrorEnum.Types.InvoiceError InvoiceError { + get { return errorCodeCase_ == ErrorCodeOneofCase.InvoiceError ? (global::Google.Ads.GoogleAds.V3.Errors.InvoiceErrorEnum.Types.InvoiceError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.InvoiceError; + } + } + + /// Field number for the "payments_account_error" field. + public const int PaymentsAccountErrorFieldNumber = 127; + /// + /// The reasons for errors in payments accounts service + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.PaymentsAccountErrorEnum.Types.PaymentsAccountError PaymentsAccountError { + get { return errorCodeCase_ == ErrorCodeOneofCase.PaymentsAccountError ? (global::Google.Ads.GoogleAds.V3.Errors.PaymentsAccountErrorEnum.Types.PaymentsAccountError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.PaymentsAccountError; + } + } + + /// Field number for the "time_zone_error" field. + public const int TimeZoneErrorFieldNumber = 128; + /// + /// The reasons for the time zone error + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.TimeZoneErrorEnum.Types.TimeZoneError TimeZoneError { + get { return errorCodeCase_ == ErrorCodeOneofCase.TimeZoneError ? (global::Google.Ads.GoogleAds.V3.Errors.TimeZoneErrorEnum.Types.TimeZoneError) errorCode_ : 0; } + set { + errorCode_ = value; + errorCodeCase_ = ErrorCodeOneofCase.TimeZoneError; + } + } + + private object errorCode_; + /// Enum of possible cases for the "error_code" oneof. + public enum ErrorCodeOneofCase { + None = 0, + RequestError = 1, + BiddingStrategyError = 2, + UrlFieldError = 3, + ListOperationError = 4, + QueryError = 5, + MutateError = 7, + FieldMaskError = 8, + AuthorizationError = 9, + InternalError = 10, + QuotaError = 11, + AdError = 12, + AdGroupError = 13, + CampaignBudgetError = 14, + CampaignError = 15, + AuthenticationError = 17, + AdGroupCriterionError = 18, + AdCustomizerError = 19, + AdGroupAdError = 21, + AdSharingError = 24, + AdxError = 25, + AssetError = 107, + BiddingError = 26, + CampaignCriterionError = 29, + CollectionSizeError = 31, + CountryCodeError = 109, + CriterionError = 32, + CustomerError = 90, + DateError = 33, + DateRangeError = 34, + DistinctError = 35, + FeedAttributeReferenceError = 36, + FunctionError = 37, + FunctionParsingError = 38, + IdError = 39, + ImageError = 40, + LanguageCodeError = 110, + MediaBundleError = 42, + MediaUploadError = 116, + MediaFileError = 86, + MultiplierError = 44, + NewResourceCreationError = 45, + NotEmptyError = 46, + NullError = 47, + OperatorError = 48, + RangeError = 49, + RecommendationError = 58, + RegionCodeError = 51, + SettingError = 52, + StringFormatError = 53, + StringLengthError = 54, + OperationAccessDeniedError = 55, + ResourceAccessDeniedError = 56, + ResourceCountLimitExceededError = 57, + YoutubeVideoRegistrationError = 117, + AdGroupBidModifierError = 59, + ContextError = 60, + FieldError = 61, + SharedSetError = 62, + SharedCriterionError = 63, + CampaignSharedSetError = 64, + ConversionActionError = 65, + ConversionAdjustmentUploadError = 115, + ConversionUploadError = 111, + HeaderError = 66, + DatabaseError = 67, + PolicyFindingError = 68, + EnumError = 70, + KeywordPlanError = 71, + KeywordPlanCampaignError = 72, + KeywordPlanNegativeKeywordError = 73, + KeywordPlanAdGroupError = 74, + KeywordPlanKeywordError = 75, + KeywordPlanIdeaError = 76, + AccountBudgetProposalError = 77, + UserListError = 78, + ChangeStatusError = 79, + FeedError = 80, + GeoTargetConstantSuggestionError = 81, + CampaignDraftError = 82, + FeedItemError = 83, + LabelError = 84, + BillingSetupError = 87, + CustomerClientLinkError = 88, + CustomerManagerLinkError = 91, + FeedMappingError = 92, + CustomerFeedError = 93, + AdGroupFeedError = 94, + CampaignFeedError = 96, + CustomInterestError = 97, + CampaignExperimentError = 98, + ExtensionFeedItemError = 100, + AdParameterError = 101, + FeedItemValidationError = 102, + ExtensionSettingError = 103, + FeedItemTargetError = 104, + PolicyViolationError = 105, + MutateJobError = 108, + PartialFailureError = 112, + PolicyValidationParameterError = 114, + SizeLimitError = 118, + NotWhitelistedError = 120, + ManagerLinkError = 121, + CurrencyCodeError = 122, + AccessInvitationError = 124, + ReachPlanError = 125, + InvoiceError = 126, + PaymentsAccountError = 127, + TimeZoneError = 128, + } + private ErrorCodeOneofCase errorCodeCase_ = ErrorCodeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorCodeOneofCase ErrorCodeCase { + get { return errorCodeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearErrorCode() { + errorCodeCase_ = ErrorCodeOneofCase.None; + errorCode_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ErrorCode); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ErrorCode other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (RequestError != other.RequestError) return false; + if (BiddingStrategyError != other.BiddingStrategyError) return false; + if (UrlFieldError != other.UrlFieldError) return false; + if (ListOperationError != other.ListOperationError) return false; + if (QueryError != other.QueryError) return false; + if (MutateError != other.MutateError) return false; + if (FieldMaskError != other.FieldMaskError) return false; + if (AuthorizationError != other.AuthorizationError) return false; + if (InternalError != other.InternalError) return false; + if (QuotaError != other.QuotaError) return false; + if (AdError != other.AdError) return false; + if (AdGroupError != other.AdGroupError) return false; + if (CampaignBudgetError != other.CampaignBudgetError) return false; + if (CampaignError != other.CampaignError) return false; + if (AuthenticationError != other.AuthenticationError) return false; + if (AdGroupCriterionError != other.AdGroupCriterionError) return false; + if (AdCustomizerError != other.AdCustomizerError) return false; + if (AdGroupAdError != other.AdGroupAdError) return false; + if (AdSharingError != other.AdSharingError) return false; + if (AdxError != other.AdxError) return false; + if (AssetError != other.AssetError) return false; + if (BiddingError != other.BiddingError) return false; + if (CampaignCriterionError != other.CampaignCriterionError) return false; + if (CollectionSizeError != other.CollectionSizeError) return false; + if (CountryCodeError != other.CountryCodeError) return false; + if (CriterionError != other.CriterionError) return false; + if (CustomerError != other.CustomerError) return false; + if (DateError != other.DateError) return false; + if (DateRangeError != other.DateRangeError) return false; + if (DistinctError != other.DistinctError) return false; + if (FeedAttributeReferenceError != other.FeedAttributeReferenceError) return false; + if (FunctionError != other.FunctionError) return false; + if (FunctionParsingError != other.FunctionParsingError) return false; + if (IdError != other.IdError) return false; + if (ImageError != other.ImageError) return false; + if (LanguageCodeError != other.LanguageCodeError) return false; + if (MediaBundleError != other.MediaBundleError) return false; + if (MediaUploadError != other.MediaUploadError) return false; + if (MediaFileError != other.MediaFileError) return false; + if (MultiplierError != other.MultiplierError) return false; + if (NewResourceCreationError != other.NewResourceCreationError) return false; + if (NotEmptyError != other.NotEmptyError) return false; + if (NullError != other.NullError) return false; + if (OperatorError != other.OperatorError) return false; + if (RangeError != other.RangeError) return false; + if (RecommendationError != other.RecommendationError) return false; + if (RegionCodeError != other.RegionCodeError) return false; + if (SettingError != other.SettingError) return false; + if (StringFormatError != other.StringFormatError) return false; + if (StringLengthError != other.StringLengthError) return false; + if (OperationAccessDeniedError != other.OperationAccessDeniedError) return false; + if (ResourceAccessDeniedError != other.ResourceAccessDeniedError) return false; + if (ResourceCountLimitExceededError != other.ResourceCountLimitExceededError) return false; + if (YoutubeVideoRegistrationError != other.YoutubeVideoRegistrationError) return false; + if (AdGroupBidModifierError != other.AdGroupBidModifierError) return false; + if (ContextError != other.ContextError) return false; + if (FieldError != other.FieldError) return false; + if (SharedSetError != other.SharedSetError) return false; + if (SharedCriterionError != other.SharedCriterionError) return false; + if (CampaignSharedSetError != other.CampaignSharedSetError) return false; + if (ConversionActionError != other.ConversionActionError) return false; + if (ConversionAdjustmentUploadError != other.ConversionAdjustmentUploadError) return false; + if (ConversionUploadError != other.ConversionUploadError) return false; + if (HeaderError != other.HeaderError) return false; + if (DatabaseError != other.DatabaseError) return false; + if (PolicyFindingError != other.PolicyFindingError) return false; + if (EnumError != other.EnumError) return false; + if (KeywordPlanError != other.KeywordPlanError) return false; + if (KeywordPlanCampaignError != other.KeywordPlanCampaignError) return false; + if (KeywordPlanNegativeKeywordError != other.KeywordPlanNegativeKeywordError) return false; + if (KeywordPlanAdGroupError != other.KeywordPlanAdGroupError) return false; + if (KeywordPlanKeywordError != other.KeywordPlanKeywordError) return false; + if (KeywordPlanIdeaError != other.KeywordPlanIdeaError) return false; + if (AccountBudgetProposalError != other.AccountBudgetProposalError) return false; + if (UserListError != other.UserListError) return false; + if (ChangeStatusError != other.ChangeStatusError) return false; + if (FeedError != other.FeedError) return false; + if (GeoTargetConstantSuggestionError != other.GeoTargetConstantSuggestionError) return false; + if (CampaignDraftError != other.CampaignDraftError) return false; + if (FeedItemError != other.FeedItemError) return false; + if (LabelError != other.LabelError) return false; + if (BillingSetupError != other.BillingSetupError) return false; + if (CustomerClientLinkError != other.CustomerClientLinkError) return false; + if (CustomerManagerLinkError != other.CustomerManagerLinkError) return false; + if (FeedMappingError != other.FeedMappingError) return false; + if (CustomerFeedError != other.CustomerFeedError) return false; + if (AdGroupFeedError != other.AdGroupFeedError) return false; + if (CampaignFeedError != other.CampaignFeedError) return false; + if (CustomInterestError != other.CustomInterestError) return false; + if (CampaignExperimentError != other.CampaignExperimentError) return false; + if (ExtensionFeedItemError != other.ExtensionFeedItemError) return false; + if (AdParameterError != other.AdParameterError) return false; + if (FeedItemValidationError != other.FeedItemValidationError) return false; + if (ExtensionSettingError != other.ExtensionSettingError) return false; + if (FeedItemTargetError != other.FeedItemTargetError) return false; + if (PolicyViolationError != other.PolicyViolationError) return false; + if (MutateJobError != other.MutateJobError) return false; + if (PartialFailureError != other.PartialFailureError) return false; + if (PolicyValidationParameterError != other.PolicyValidationParameterError) return false; + if (SizeLimitError != other.SizeLimitError) return false; + if (NotWhitelistedError != other.NotWhitelistedError) return false; + if (ManagerLinkError != other.ManagerLinkError) return false; + if (CurrencyCodeError != other.CurrencyCodeError) return false; + if (AccessInvitationError != other.AccessInvitationError) return false; + if (ReachPlanError != other.ReachPlanError) return false; + if (InvoiceError != other.InvoiceError) return false; + if (PaymentsAccountError != other.PaymentsAccountError) return false; + if (TimeZoneError != other.TimeZoneError) return false; + if (ErrorCodeCase != other.ErrorCodeCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (errorCodeCase_ == ErrorCodeOneofCase.RequestError) hash ^= RequestError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.BiddingStrategyError) hash ^= BiddingStrategyError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.UrlFieldError) hash ^= UrlFieldError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ListOperationError) hash ^= ListOperationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.QueryError) hash ^= QueryError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.MutateError) hash ^= MutateError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FieldMaskError) hash ^= FieldMaskError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AuthorizationError) hash ^= AuthorizationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.InternalError) hash ^= InternalError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.QuotaError) hash ^= QuotaError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdError) hash ^= AdError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupError) hash ^= AdGroupError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignBudgetError) hash ^= CampaignBudgetError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignError) hash ^= CampaignError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AuthenticationError) hash ^= AuthenticationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupCriterionError) hash ^= AdGroupCriterionError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdCustomizerError) hash ^= AdCustomizerError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupAdError) hash ^= AdGroupAdError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdSharingError) hash ^= AdSharingError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdxError) hash ^= AdxError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AssetError) hash ^= AssetError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.BiddingError) hash ^= BiddingError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignCriterionError) hash ^= CampaignCriterionError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CollectionSizeError) hash ^= CollectionSizeError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CountryCodeError) hash ^= CountryCodeError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CriterionError) hash ^= CriterionError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerError) hash ^= CustomerError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.DateError) hash ^= DateError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.DateRangeError) hash ^= DateRangeError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.DistinctError) hash ^= DistinctError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FeedAttributeReferenceError) hash ^= FeedAttributeReferenceError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FunctionError) hash ^= FunctionError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FunctionParsingError) hash ^= FunctionParsingError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.IdError) hash ^= IdError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ImageError) hash ^= ImageError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.LanguageCodeError) hash ^= LanguageCodeError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.MediaBundleError) hash ^= MediaBundleError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.MediaUploadError) hash ^= MediaUploadError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.MediaFileError) hash ^= MediaFileError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.MultiplierError) hash ^= MultiplierError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.NewResourceCreationError) hash ^= NewResourceCreationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.NotEmptyError) hash ^= NotEmptyError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.NullError) hash ^= NullError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.OperatorError) hash ^= OperatorError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.RangeError) hash ^= RangeError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.RecommendationError) hash ^= RecommendationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.RegionCodeError) hash ^= RegionCodeError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.SettingError) hash ^= SettingError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.StringFormatError) hash ^= StringFormatError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.StringLengthError) hash ^= StringLengthError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.OperationAccessDeniedError) hash ^= OperationAccessDeniedError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ResourceAccessDeniedError) hash ^= ResourceAccessDeniedError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ResourceCountLimitExceededError) hash ^= ResourceCountLimitExceededError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.YoutubeVideoRegistrationError) hash ^= YoutubeVideoRegistrationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupBidModifierError) hash ^= AdGroupBidModifierError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ContextError) hash ^= ContextError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FieldError) hash ^= FieldError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.SharedSetError) hash ^= SharedSetError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.SharedCriterionError) hash ^= SharedCriterionError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignSharedSetError) hash ^= CampaignSharedSetError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionActionError) hash ^= ConversionActionError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionAdjustmentUploadError) hash ^= ConversionAdjustmentUploadError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionUploadError) hash ^= ConversionUploadError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.HeaderError) hash ^= HeaderError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.DatabaseError) hash ^= DatabaseError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyFindingError) hash ^= PolicyFindingError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.EnumError) hash ^= EnumError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanError) hash ^= KeywordPlanError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanCampaignError) hash ^= KeywordPlanCampaignError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanNegativeKeywordError) hash ^= KeywordPlanNegativeKeywordError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanAdGroupError) hash ^= KeywordPlanAdGroupError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanKeywordError) hash ^= KeywordPlanKeywordError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanIdeaError) hash ^= KeywordPlanIdeaError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AccountBudgetProposalError) hash ^= AccountBudgetProposalError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.UserListError) hash ^= UserListError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ChangeStatusError) hash ^= ChangeStatusError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FeedError) hash ^= FeedError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.GeoTargetConstantSuggestionError) hash ^= GeoTargetConstantSuggestionError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignDraftError) hash ^= CampaignDraftError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemError) hash ^= FeedItemError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.LabelError) hash ^= LabelError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.BillingSetupError) hash ^= BillingSetupError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerClientLinkError) hash ^= CustomerClientLinkError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerManagerLinkError) hash ^= CustomerManagerLinkError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FeedMappingError) hash ^= FeedMappingError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerFeedError) hash ^= CustomerFeedError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupFeedError) hash ^= AdGroupFeedError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignFeedError) hash ^= CampaignFeedError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CustomInterestError) hash ^= CustomInterestError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignExperimentError) hash ^= CampaignExperimentError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ExtensionFeedItemError) hash ^= ExtensionFeedItemError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AdParameterError) hash ^= AdParameterError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemValidationError) hash ^= FeedItemValidationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ExtensionSettingError) hash ^= ExtensionSettingError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemTargetError) hash ^= FeedItemTargetError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyViolationError) hash ^= PolicyViolationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.MutateJobError) hash ^= MutateJobError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.PartialFailureError) hash ^= PartialFailureError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyValidationParameterError) hash ^= PolicyValidationParameterError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.SizeLimitError) hash ^= SizeLimitError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.NotWhitelistedError) hash ^= NotWhitelistedError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ManagerLinkError) hash ^= ManagerLinkError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.CurrencyCodeError) hash ^= CurrencyCodeError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.AccessInvitationError) hash ^= AccessInvitationError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.ReachPlanError) hash ^= ReachPlanError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.InvoiceError) hash ^= InvoiceError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.PaymentsAccountError) hash ^= PaymentsAccountError.GetHashCode(); + if (errorCodeCase_ == ErrorCodeOneofCase.TimeZoneError) hash ^= TimeZoneError.GetHashCode(); + hash ^= (int) errorCodeCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (errorCodeCase_ == ErrorCodeOneofCase.RequestError) { + output.WriteRawTag(8); + output.WriteEnum((int) RequestError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.BiddingStrategyError) { + output.WriteRawTag(16); + output.WriteEnum((int) BiddingStrategyError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.UrlFieldError) { + output.WriteRawTag(24); + output.WriteEnum((int) UrlFieldError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ListOperationError) { + output.WriteRawTag(32); + output.WriteEnum((int) ListOperationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.QueryError) { + output.WriteRawTag(40); + output.WriteEnum((int) QueryError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MutateError) { + output.WriteRawTag(56); + output.WriteEnum((int) MutateError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FieldMaskError) { + output.WriteRawTag(64); + output.WriteEnum((int) FieldMaskError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AuthorizationError) { + output.WriteRawTag(72); + output.WriteEnum((int) AuthorizationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.InternalError) { + output.WriteRawTag(80); + output.WriteEnum((int) InternalError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.QuotaError) { + output.WriteRawTag(88); + output.WriteEnum((int) QuotaError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdError) { + output.WriteRawTag(96); + output.WriteEnum((int) AdError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupError) { + output.WriteRawTag(104); + output.WriteEnum((int) AdGroupError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignBudgetError) { + output.WriteRawTag(112); + output.WriteEnum((int) CampaignBudgetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignError) { + output.WriteRawTag(120); + output.WriteEnum((int) CampaignError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AuthenticationError) { + output.WriteRawTag(136, 1); + output.WriteEnum((int) AuthenticationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupCriterionError) { + output.WriteRawTag(144, 1); + output.WriteEnum((int) AdGroupCriterionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdCustomizerError) { + output.WriteRawTag(152, 1); + output.WriteEnum((int) AdCustomizerError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupAdError) { + output.WriteRawTag(168, 1); + output.WriteEnum((int) AdGroupAdError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdSharingError) { + output.WriteRawTag(192, 1); + output.WriteEnum((int) AdSharingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdxError) { + output.WriteRawTag(200, 1); + output.WriteEnum((int) AdxError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.BiddingError) { + output.WriteRawTag(208, 1); + output.WriteEnum((int) BiddingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignCriterionError) { + output.WriteRawTag(232, 1); + output.WriteEnum((int) CampaignCriterionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CollectionSizeError) { + output.WriteRawTag(248, 1); + output.WriteEnum((int) CollectionSizeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CriterionError) { + output.WriteRawTag(128, 2); + output.WriteEnum((int) CriterionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.DateError) { + output.WriteRawTag(136, 2); + output.WriteEnum((int) DateError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.DateRangeError) { + output.WriteRawTag(144, 2); + output.WriteEnum((int) DateRangeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.DistinctError) { + output.WriteRawTag(152, 2); + output.WriteEnum((int) DistinctError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedAttributeReferenceError) { + output.WriteRawTag(160, 2); + output.WriteEnum((int) FeedAttributeReferenceError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FunctionError) { + output.WriteRawTag(168, 2); + output.WriteEnum((int) FunctionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FunctionParsingError) { + output.WriteRawTag(176, 2); + output.WriteEnum((int) FunctionParsingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.IdError) { + output.WriteRawTag(184, 2); + output.WriteEnum((int) IdError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ImageError) { + output.WriteRawTag(192, 2); + output.WriteEnum((int) ImageError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MediaBundleError) { + output.WriteRawTag(208, 2); + output.WriteEnum((int) MediaBundleError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MultiplierError) { + output.WriteRawTag(224, 2); + output.WriteEnum((int) MultiplierError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.NewResourceCreationError) { + output.WriteRawTag(232, 2); + output.WriteEnum((int) NewResourceCreationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.NotEmptyError) { + output.WriteRawTag(240, 2); + output.WriteEnum((int) NotEmptyError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.NullError) { + output.WriteRawTag(248, 2); + output.WriteEnum((int) NullError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.OperatorError) { + output.WriteRawTag(128, 3); + output.WriteEnum((int) OperatorError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.RangeError) { + output.WriteRawTag(136, 3); + output.WriteEnum((int) RangeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.RegionCodeError) { + output.WriteRawTag(152, 3); + output.WriteEnum((int) RegionCodeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.SettingError) { + output.WriteRawTag(160, 3); + output.WriteEnum((int) SettingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.StringFormatError) { + output.WriteRawTag(168, 3); + output.WriteEnum((int) StringFormatError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.StringLengthError) { + output.WriteRawTag(176, 3); + output.WriteEnum((int) StringLengthError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.OperationAccessDeniedError) { + output.WriteRawTag(184, 3); + output.WriteEnum((int) OperationAccessDeniedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ResourceAccessDeniedError) { + output.WriteRawTag(192, 3); + output.WriteEnum((int) ResourceAccessDeniedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ResourceCountLimitExceededError) { + output.WriteRawTag(200, 3); + output.WriteEnum((int) ResourceCountLimitExceededError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.RecommendationError) { + output.WriteRawTag(208, 3); + output.WriteEnum((int) RecommendationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupBidModifierError) { + output.WriteRawTag(216, 3); + output.WriteEnum((int) AdGroupBidModifierError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ContextError) { + output.WriteRawTag(224, 3); + output.WriteEnum((int) ContextError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FieldError) { + output.WriteRawTag(232, 3); + output.WriteEnum((int) FieldError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.SharedSetError) { + output.WriteRawTag(240, 3); + output.WriteEnum((int) SharedSetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.SharedCriterionError) { + output.WriteRawTag(248, 3); + output.WriteEnum((int) SharedCriterionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignSharedSetError) { + output.WriteRawTag(128, 4); + output.WriteEnum((int) CampaignSharedSetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionActionError) { + output.WriteRawTag(136, 4); + output.WriteEnum((int) ConversionActionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.HeaderError) { + output.WriteRawTag(144, 4); + output.WriteEnum((int) HeaderError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.DatabaseError) { + output.WriteRawTag(152, 4); + output.WriteEnum((int) DatabaseError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyFindingError) { + output.WriteRawTag(160, 4); + output.WriteEnum((int) PolicyFindingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.EnumError) { + output.WriteRawTag(176, 4); + output.WriteEnum((int) EnumError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanError) { + output.WriteRawTag(184, 4); + output.WriteEnum((int) KeywordPlanError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanCampaignError) { + output.WriteRawTag(192, 4); + output.WriteEnum((int) KeywordPlanCampaignError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanNegativeKeywordError) { + output.WriteRawTag(200, 4); + output.WriteEnum((int) KeywordPlanNegativeKeywordError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanAdGroupError) { + output.WriteRawTag(208, 4); + output.WriteEnum((int) KeywordPlanAdGroupError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanKeywordError) { + output.WriteRawTag(216, 4); + output.WriteEnum((int) KeywordPlanKeywordError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanIdeaError) { + output.WriteRawTag(224, 4); + output.WriteEnum((int) KeywordPlanIdeaError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AccountBudgetProposalError) { + output.WriteRawTag(232, 4); + output.WriteEnum((int) AccountBudgetProposalError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.UserListError) { + output.WriteRawTag(240, 4); + output.WriteEnum((int) UserListError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ChangeStatusError) { + output.WriteRawTag(248, 4); + output.WriteEnum((int) ChangeStatusError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedError) { + output.WriteRawTag(128, 5); + output.WriteEnum((int) FeedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.GeoTargetConstantSuggestionError) { + output.WriteRawTag(136, 5); + output.WriteEnum((int) GeoTargetConstantSuggestionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignDraftError) { + output.WriteRawTag(144, 5); + output.WriteEnum((int) CampaignDraftError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemError) { + output.WriteRawTag(152, 5); + output.WriteEnum((int) FeedItemError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.LabelError) { + output.WriteRawTag(160, 5); + output.WriteEnum((int) LabelError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MediaFileError) { + output.WriteRawTag(176, 5); + output.WriteEnum((int) MediaFileError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.BillingSetupError) { + output.WriteRawTag(184, 5); + output.WriteEnum((int) BillingSetupError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerClientLinkError) { + output.WriteRawTag(192, 5); + output.WriteEnum((int) CustomerClientLinkError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerError) { + output.WriteRawTag(208, 5); + output.WriteEnum((int) CustomerError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerManagerLinkError) { + output.WriteRawTag(216, 5); + output.WriteEnum((int) CustomerManagerLinkError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedMappingError) { + output.WriteRawTag(224, 5); + output.WriteEnum((int) FeedMappingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerFeedError) { + output.WriteRawTag(232, 5); + output.WriteEnum((int) CustomerFeedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupFeedError) { + output.WriteRawTag(240, 5); + output.WriteEnum((int) AdGroupFeedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignFeedError) { + output.WriteRawTag(128, 6); + output.WriteEnum((int) CampaignFeedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomInterestError) { + output.WriteRawTag(136, 6); + output.WriteEnum((int) CustomInterestError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignExperimentError) { + output.WriteRawTag(144, 6); + output.WriteEnum((int) CampaignExperimentError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ExtensionFeedItemError) { + output.WriteRawTag(160, 6); + output.WriteEnum((int) ExtensionFeedItemError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdParameterError) { + output.WriteRawTag(168, 6); + output.WriteEnum((int) AdParameterError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemValidationError) { + output.WriteRawTag(176, 6); + output.WriteEnum((int) FeedItemValidationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ExtensionSettingError) { + output.WriteRawTag(184, 6); + output.WriteEnum((int) ExtensionSettingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemTargetError) { + output.WriteRawTag(192, 6); + output.WriteEnum((int) FeedItemTargetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyViolationError) { + output.WriteRawTag(200, 6); + output.WriteEnum((int) PolicyViolationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AssetError) { + output.WriteRawTag(216, 6); + output.WriteEnum((int) AssetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MutateJobError) { + output.WriteRawTag(224, 6); + output.WriteEnum((int) MutateJobError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CountryCodeError) { + output.WriteRawTag(232, 6); + output.WriteEnum((int) CountryCodeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.LanguageCodeError) { + output.WriteRawTag(240, 6); + output.WriteEnum((int) LanguageCodeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionUploadError) { + output.WriteRawTag(248, 6); + output.WriteEnum((int) ConversionUploadError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PartialFailureError) { + output.WriteRawTag(128, 7); + output.WriteEnum((int) PartialFailureError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyValidationParameterError) { + output.WriteRawTag(144, 7); + output.WriteEnum((int) PolicyValidationParameterError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionAdjustmentUploadError) { + output.WriteRawTag(152, 7); + output.WriteEnum((int) ConversionAdjustmentUploadError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MediaUploadError) { + output.WriteRawTag(160, 7); + output.WriteEnum((int) MediaUploadError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.YoutubeVideoRegistrationError) { + output.WriteRawTag(168, 7); + output.WriteEnum((int) YoutubeVideoRegistrationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.SizeLimitError) { + output.WriteRawTag(176, 7); + output.WriteEnum((int) SizeLimitError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.NotWhitelistedError) { + output.WriteRawTag(192, 7); + output.WriteEnum((int) NotWhitelistedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ManagerLinkError) { + output.WriteRawTag(200, 7); + output.WriteEnum((int) ManagerLinkError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CurrencyCodeError) { + output.WriteRawTag(208, 7); + output.WriteEnum((int) CurrencyCodeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AccessInvitationError) { + output.WriteRawTag(224, 7); + output.WriteEnum((int) AccessInvitationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ReachPlanError) { + output.WriteRawTag(232, 7); + output.WriteEnum((int) ReachPlanError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.InvoiceError) { + output.WriteRawTag(240, 7); + output.WriteEnum((int) InvoiceError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PaymentsAccountError) { + output.WriteRawTag(248, 7); + output.WriteEnum((int) PaymentsAccountError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.TimeZoneError) { + output.WriteRawTag(128, 8); + output.WriteEnum((int) TimeZoneError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (errorCodeCase_ == ErrorCodeOneofCase.RequestError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) RequestError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.BiddingStrategyError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) BiddingStrategyError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.UrlFieldError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) UrlFieldError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ListOperationError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ListOperationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.QueryError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) QueryError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MutateError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MutateError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FieldMaskError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) FieldMaskError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AuthorizationError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AuthorizationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.InternalError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) InternalError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.QuotaError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) QuotaError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdGroupError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignBudgetError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) CampaignBudgetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignError) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) CampaignError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AuthenticationError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AuthenticationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupCriterionError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdGroupCriterionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdCustomizerError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdCustomizerError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupAdError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdGroupAdError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdSharingError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdSharingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdxError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdxError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AssetError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AssetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.BiddingError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) BiddingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignCriterionError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CampaignCriterionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CollectionSizeError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CollectionSizeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CountryCodeError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CountryCodeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CriterionError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CriterionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CustomerError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.DateError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) DateError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.DateRangeError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) DateRangeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.DistinctError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) DistinctError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedAttributeReferenceError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FeedAttributeReferenceError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FunctionError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FunctionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FunctionParsingError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FunctionParsingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.IdError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) IdError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ImageError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ImageError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.LanguageCodeError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) LanguageCodeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MediaBundleError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) MediaBundleError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MediaUploadError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) MediaUploadError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MediaFileError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) MediaFileError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MultiplierError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) MultiplierError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.NewResourceCreationError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) NewResourceCreationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.NotEmptyError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) NotEmptyError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.NullError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) NullError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.OperatorError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) OperatorError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.RangeError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) RangeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.RecommendationError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) RecommendationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.RegionCodeError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) RegionCodeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.SettingError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) SettingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.StringFormatError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) StringFormatError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.StringLengthError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) StringLengthError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.OperationAccessDeniedError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) OperationAccessDeniedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ResourceAccessDeniedError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ResourceAccessDeniedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ResourceCountLimitExceededError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ResourceCountLimitExceededError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.YoutubeVideoRegistrationError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) YoutubeVideoRegistrationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupBidModifierError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdGroupBidModifierError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ContextError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ContextError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FieldError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FieldError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.SharedSetError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) SharedSetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.SharedCriterionError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) SharedCriterionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignSharedSetError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CampaignSharedSetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionActionError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ConversionActionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionAdjustmentUploadError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ConversionAdjustmentUploadError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ConversionUploadError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ConversionUploadError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.HeaderError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) HeaderError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.DatabaseError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) DatabaseError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyFindingError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) PolicyFindingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.EnumError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EnumError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) KeywordPlanError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanCampaignError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) KeywordPlanCampaignError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanNegativeKeywordError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) KeywordPlanNegativeKeywordError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanAdGroupError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) KeywordPlanAdGroupError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanKeywordError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) KeywordPlanKeywordError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.KeywordPlanIdeaError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) KeywordPlanIdeaError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AccountBudgetProposalError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AccountBudgetProposalError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.UserListError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) UserListError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ChangeStatusError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ChangeStatusError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FeedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.GeoTargetConstantSuggestionError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) GeoTargetConstantSuggestionError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignDraftError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CampaignDraftError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FeedItemError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.LabelError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) LabelError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.BillingSetupError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) BillingSetupError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerClientLinkError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CustomerClientLinkError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerManagerLinkError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CustomerManagerLinkError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedMappingError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FeedMappingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomerFeedError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CustomerFeedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdGroupFeedError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdGroupFeedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignFeedError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CampaignFeedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CustomInterestError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CustomInterestError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CampaignExperimentError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CampaignExperimentError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ExtensionFeedItemError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ExtensionFeedItemError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AdParameterError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AdParameterError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemValidationError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FeedItemValidationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ExtensionSettingError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ExtensionSettingError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.FeedItemTargetError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FeedItemTargetError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyViolationError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) PolicyViolationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.MutateJobError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) MutateJobError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PartialFailureError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) PartialFailureError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PolicyValidationParameterError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) PolicyValidationParameterError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.SizeLimitError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) SizeLimitError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.NotWhitelistedError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) NotWhitelistedError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ManagerLinkError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ManagerLinkError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.CurrencyCodeError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CurrencyCodeError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.AccessInvitationError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) AccessInvitationError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.ReachPlanError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) ReachPlanError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.InvoiceError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) InvoiceError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.PaymentsAccountError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) PaymentsAccountError); + } + if (errorCodeCase_ == ErrorCodeOneofCase.TimeZoneError) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) TimeZoneError); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ErrorCode other) { + if (other == null) { + return; + } + switch (other.ErrorCodeCase) { + case ErrorCodeOneofCase.RequestError: + RequestError = other.RequestError; + break; + case ErrorCodeOneofCase.BiddingStrategyError: + BiddingStrategyError = other.BiddingStrategyError; + break; + case ErrorCodeOneofCase.UrlFieldError: + UrlFieldError = other.UrlFieldError; + break; + case ErrorCodeOneofCase.ListOperationError: + ListOperationError = other.ListOperationError; + break; + case ErrorCodeOneofCase.QueryError: + QueryError = other.QueryError; + break; + case ErrorCodeOneofCase.MutateError: + MutateError = other.MutateError; + break; + case ErrorCodeOneofCase.FieldMaskError: + FieldMaskError = other.FieldMaskError; + break; + case ErrorCodeOneofCase.AuthorizationError: + AuthorizationError = other.AuthorizationError; + break; + case ErrorCodeOneofCase.InternalError: + InternalError = other.InternalError; + break; + case ErrorCodeOneofCase.QuotaError: + QuotaError = other.QuotaError; + break; + case ErrorCodeOneofCase.AdError: + AdError = other.AdError; + break; + case ErrorCodeOneofCase.AdGroupError: + AdGroupError = other.AdGroupError; + break; + case ErrorCodeOneofCase.CampaignBudgetError: + CampaignBudgetError = other.CampaignBudgetError; + break; + case ErrorCodeOneofCase.CampaignError: + CampaignError = other.CampaignError; + break; + case ErrorCodeOneofCase.AuthenticationError: + AuthenticationError = other.AuthenticationError; + break; + case ErrorCodeOneofCase.AdGroupCriterionError: + AdGroupCriterionError = other.AdGroupCriterionError; + break; + case ErrorCodeOneofCase.AdCustomizerError: + AdCustomizerError = other.AdCustomizerError; + break; + case ErrorCodeOneofCase.AdGroupAdError: + AdGroupAdError = other.AdGroupAdError; + break; + case ErrorCodeOneofCase.AdSharingError: + AdSharingError = other.AdSharingError; + break; + case ErrorCodeOneofCase.AdxError: + AdxError = other.AdxError; + break; + case ErrorCodeOneofCase.AssetError: + AssetError = other.AssetError; + break; + case ErrorCodeOneofCase.BiddingError: + BiddingError = other.BiddingError; + break; + case ErrorCodeOneofCase.CampaignCriterionError: + CampaignCriterionError = other.CampaignCriterionError; + break; + case ErrorCodeOneofCase.CollectionSizeError: + CollectionSizeError = other.CollectionSizeError; + break; + case ErrorCodeOneofCase.CountryCodeError: + CountryCodeError = other.CountryCodeError; + break; + case ErrorCodeOneofCase.CriterionError: + CriterionError = other.CriterionError; + break; + case ErrorCodeOneofCase.CustomerError: + CustomerError = other.CustomerError; + break; + case ErrorCodeOneofCase.DateError: + DateError = other.DateError; + break; + case ErrorCodeOneofCase.DateRangeError: + DateRangeError = other.DateRangeError; + break; + case ErrorCodeOneofCase.DistinctError: + DistinctError = other.DistinctError; + break; + case ErrorCodeOneofCase.FeedAttributeReferenceError: + FeedAttributeReferenceError = other.FeedAttributeReferenceError; + break; + case ErrorCodeOneofCase.FunctionError: + FunctionError = other.FunctionError; + break; + case ErrorCodeOneofCase.FunctionParsingError: + FunctionParsingError = other.FunctionParsingError; + break; + case ErrorCodeOneofCase.IdError: + IdError = other.IdError; + break; + case ErrorCodeOneofCase.ImageError: + ImageError = other.ImageError; + break; + case ErrorCodeOneofCase.LanguageCodeError: + LanguageCodeError = other.LanguageCodeError; + break; + case ErrorCodeOneofCase.MediaBundleError: + MediaBundleError = other.MediaBundleError; + break; + case ErrorCodeOneofCase.MediaUploadError: + MediaUploadError = other.MediaUploadError; + break; + case ErrorCodeOneofCase.MediaFileError: + MediaFileError = other.MediaFileError; + break; + case ErrorCodeOneofCase.MultiplierError: + MultiplierError = other.MultiplierError; + break; + case ErrorCodeOneofCase.NewResourceCreationError: + NewResourceCreationError = other.NewResourceCreationError; + break; + case ErrorCodeOneofCase.NotEmptyError: + NotEmptyError = other.NotEmptyError; + break; + case ErrorCodeOneofCase.NullError: + NullError = other.NullError; + break; + case ErrorCodeOneofCase.OperatorError: + OperatorError = other.OperatorError; + break; + case ErrorCodeOneofCase.RangeError: + RangeError = other.RangeError; + break; + case ErrorCodeOneofCase.RecommendationError: + RecommendationError = other.RecommendationError; + break; + case ErrorCodeOneofCase.RegionCodeError: + RegionCodeError = other.RegionCodeError; + break; + case ErrorCodeOneofCase.SettingError: + SettingError = other.SettingError; + break; + case ErrorCodeOneofCase.StringFormatError: + StringFormatError = other.StringFormatError; + break; + case ErrorCodeOneofCase.StringLengthError: + StringLengthError = other.StringLengthError; + break; + case ErrorCodeOneofCase.OperationAccessDeniedError: + OperationAccessDeniedError = other.OperationAccessDeniedError; + break; + case ErrorCodeOneofCase.ResourceAccessDeniedError: + ResourceAccessDeniedError = other.ResourceAccessDeniedError; + break; + case ErrorCodeOneofCase.ResourceCountLimitExceededError: + ResourceCountLimitExceededError = other.ResourceCountLimitExceededError; + break; + case ErrorCodeOneofCase.YoutubeVideoRegistrationError: + YoutubeVideoRegistrationError = other.YoutubeVideoRegistrationError; + break; + case ErrorCodeOneofCase.AdGroupBidModifierError: + AdGroupBidModifierError = other.AdGroupBidModifierError; + break; + case ErrorCodeOneofCase.ContextError: + ContextError = other.ContextError; + break; + case ErrorCodeOneofCase.FieldError: + FieldError = other.FieldError; + break; + case ErrorCodeOneofCase.SharedSetError: + SharedSetError = other.SharedSetError; + break; + case ErrorCodeOneofCase.SharedCriterionError: + SharedCriterionError = other.SharedCriterionError; + break; + case ErrorCodeOneofCase.CampaignSharedSetError: + CampaignSharedSetError = other.CampaignSharedSetError; + break; + case ErrorCodeOneofCase.ConversionActionError: + ConversionActionError = other.ConversionActionError; + break; + case ErrorCodeOneofCase.ConversionAdjustmentUploadError: + ConversionAdjustmentUploadError = other.ConversionAdjustmentUploadError; + break; + case ErrorCodeOneofCase.ConversionUploadError: + ConversionUploadError = other.ConversionUploadError; + break; + case ErrorCodeOneofCase.HeaderError: + HeaderError = other.HeaderError; + break; + case ErrorCodeOneofCase.DatabaseError: + DatabaseError = other.DatabaseError; + break; + case ErrorCodeOneofCase.PolicyFindingError: + PolicyFindingError = other.PolicyFindingError; + break; + case ErrorCodeOneofCase.EnumError: + EnumError = other.EnumError; + break; + case ErrorCodeOneofCase.KeywordPlanError: + KeywordPlanError = other.KeywordPlanError; + break; + case ErrorCodeOneofCase.KeywordPlanCampaignError: + KeywordPlanCampaignError = other.KeywordPlanCampaignError; + break; + case ErrorCodeOneofCase.KeywordPlanNegativeKeywordError: + KeywordPlanNegativeKeywordError = other.KeywordPlanNegativeKeywordError; + break; + case ErrorCodeOneofCase.KeywordPlanAdGroupError: + KeywordPlanAdGroupError = other.KeywordPlanAdGroupError; + break; + case ErrorCodeOneofCase.KeywordPlanKeywordError: + KeywordPlanKeywordError = other.KeywordPlanKeywordError; + break; + case ErrorCodeOneofCase.KeywordPlanIdeaError: + KeywordPlanIdeaError = other.KeywordPlanIdeaError; + break; + case ErrorCodeOneofCase.AccountBudgetProposalError: + AccountBudgetProposalError = other.AccountBudgetProposalError; + break; + case ErrorCodeOneofCase.UserListError: + UserListError = other.UserListError; + break; + case ErrorCodeOneofCase.ChangeStatusError: + ChangeStatusError = other.ChangeStatusError; + break; + case ErrorCodeOneofCase.FeedError: + FeedError = other.FeedError; + break; + case ErrorCodeOneofCase.GeoTargetConstantSuggestionError: + GeoTargetConstantSuggestionError = other.GeoTargetConstantSuggestionError; + break; + case ErrorCodeOneofCase.CampaignDraftError: + CampaignDraftError = other.CampaignDraftError; + break; + case ErrorCodeOneofCase.FeedItemError: + FeedItemError = other.FeedItemError; + break; + case ErrorCodeOneofCase.LabelError: + LabelError = other.LabelError; + break; + case ErrorCodeOneofCase.BillingSetupError: + BillingSetupError = other.BillingSetupError; + break; + case ErrorCodeOneofCase.CustomerClientLinkError: + CustomerClientLinkError = other.CustomerClientLinkError; + break; + case ErrorCodeOneofCase.CustomerManagerLinkError: + CustomerManagerLinkError = other.CustomerManagerLinkError; + break; + case ErrorCodeOneofCase.FeedMappingError: + FeedMappingError = other.FeedMappingError; + break; + case ErrorCodeOneofCase.CustomerFeedError: + CustomerFeedError = other.CustomerFeedError; + break; + case ErrorCodeOneofCase.AdGroupFeedError: + AdGroupFeedError = other.AdGroupFeedError; + break; + case ErrorCodeOneofCase.CampaignFeedError: + CampaignFeedError = other.CampaignFeedError; + break; + case ErrorCodeOneofCase.CustomInterestError: + CustomInterestError = other.CustomInterestError; + break; + case ErrorCodeOneofCase.CampaignExperimentError: + CampaignExperimentError = other.CampaignExperimentError; + break; + case ErrorCodeOneofCase.ExtensionFeedItemError: + ExtensionFeedItemError = other.ExtensionFeedItemError; + break; + case ErrorCodeOneofCase.AdParameterError: + AdParameterError = other.AdParameterError; + break; + case ErrorCodeOneofCase.FeedItemValidationError: + FeedItemValidationError = other.FeedItemValidationError; + break; + case ErrorCodeOneofCase.ExtensionSettingError: + ExtensionSettingError = other.ExtensionSettingError; + break; + case ErrorCodeOneofCase.FeedItemTargetError: + FeedItemTargetError = other.FeedItemTargetError; + break; + case ErrorCodeOneofCase.PolicyViolationError: + PolicyViolationError = other.PolicyViolationError; + break; + case ErrorCodeOneofCase.MutateJobError: + MutateJobError = other.MutateJobError; + break; + case ErrorCodeOneofCase.PartialFailureError: + PartialFailureError = other.PartialFailureError; + break; + case ErrorCodeOneofCase.PolicyValidationParameterError: + PolicyValidationParameterError = other.PolicyValidationParameterError; + break; + case ErrorCodeOneofCase.SizeLimitError: + SizeLimitError = other.SizeLimitError; + break; + case ErrorCodeOneofCase.NotWhitelistedError: + NotWhitelistedError = other.NotWhitelistedError; + break; + case ErrorCodeOneofCase.ManagerLinkError: + ManagerLinkError = other.ManagerLinkError; + break; + case ErrorCodeOneofCase.CurrencyCodeError: + CurrencyCodeError = other.CurrencyCodeError; + break; + case ErrorCodeOneofCase.AccessInvitationError: + AccessInvitationError = other.AccessInvitationError; + break; + case ErrorCodeOneofCase.ReachPlanError: + ReachPlanError = other.ReachPlanError; + break; + case ErrorCodeOneofCase.InvoiceError: + InvoiceError = other.InvoiceError; + break; + case ErrorCodeOneofCase.PaymentsAccountError: + PaymentsAccountError = other.PaymentsAccountError; + break; + case ErrorCodeOneofCase.TimeZoneError: + TimeZoneError = other.TimeZoneError; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.RequestError; + break; + } + case 16: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.BiddingStrategyError; + break; + } + case 24: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.UrlFieldError; + break; + } + case 32: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ListOperationError; + break; + } + case 40: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.QueryError; + break; + } + case 56: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.MutateError; + break; + } + case 64: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FieldMaskError; + break; + } + case 72: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AuthorizationError; + break; + } + case 80: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.InternalError; + break; + } + case 88: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.QuotaError; + break; + } + case 96: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdError; + break; + } + case 104: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdGroupError; + break; + } + case 112: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CampaignBudgetError; + break; + } + case 120: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CampaignError; + break; + } + case 136: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AuthenticationError; + break; + } + case 144: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdGroupCriterionError; + break; + } + case 152: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdCustomizerError; + break; + } + case 168: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdGroupAdError; + break; + } + case 192: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdSharingError; + break; + } + case 200: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdxError; + break; + } + case 208: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.BiddingError; + break; + } + case 232: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CampaignCriterionError; + break; + } + case 248: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CollectionSizeError; + break; + } + case 256: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CriterionError; + break; + } + case 264: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.DateError; + break; + } + case 272: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.DateRangeError; + break; + } + case 280: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.DistinctError; + break; + } + case 288: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FeedAttributeReferenceError; + break; + } + case 296: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FunctionError; + break; + } + case 304: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FunctionParsingError; + break; + } + case 312: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.IdError; + break; + } + case 320: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ImageError; + break; + } + case 336: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.MediaBundleError; + break; + } + case 352: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.MultiplierError; + break; + } + case 360: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.NewResourceCreationError; + break; + } + case 368: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.NotEmptyError; + break; + } + case 376: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.NullError; + break; + } + case 384: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.OperatorError; + break; + } + case 392: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.RangeError; + break; + } + case 408: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.RegionCodeError; + break; + } + case 416: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.SettingError; + break; + } + case 424: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.StringFormatError; + break; + } + case 432: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.StringLengthError; + break; + } + case 440: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.OperationAccessDeniedError; + break; + } + case 448: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ResourceAccessDeniedError; + break; + } + case 456: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ResourceCountLimitExceededError; + break; + } + case 464: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.RecommendationError; + break; + } + case 472: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdGroupBidModifierError; + break; + } + case 480: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ContextError; + break; + } + case 488: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FieldError; + break; + } + case 496: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.SharedSetError; + break; + } + case 504: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.SharedCriterionError; + break; + } + case 512: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CampaignSharedSetError; + break; + } + case 520: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ConversionActionError; + break; + } + case 528: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.HeaderError; + break; + } + case 536: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.DatabaseError; + break; + } + case 544: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.PolicyFindingError; + break; + } + case 560: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.EnumError; + break; + } + case 568: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanError; + break; + } + case 576: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanCampaignError; + break; + } + case 584: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanNegativeKeywordError; + break; + } + case 592: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanAdGroupError; + break; + } + case 600: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanKeywordError; + break; + } + case 608: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.KeywordPlanIdeaError; + break; + } + case 616: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AccountBudgetProposalError; + break; + } + case 624: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.UserListError; + break; + } + case 632: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ChangeStatusError; + break; + } + case 640: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FeedError; + break; + } + case 648: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.GeoTargetConstantSuggestionError; + break; + } + case 656: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CampaignDraftError; + break; + } + case 664: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FeedItemError; + break; + } + case 672: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.LabelError; + break; + } + case 688: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.MediaFileError; + break; + } + case 696: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.BillingSetupError; + break; + } + case 704: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CustomerClientLinkError; + break; + } + case 720: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CustomerError; + break; + } + case 728: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CustomerManagerLinkError; + break; + } + case 736: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FeedMappingError; + break; + } + case 744: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CustomerFeedError; + break; + } + case 752: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdGroupFeedError; + break; + } + case 768: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CampaignFeedError; + break; + } + case 776: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CustomInterestError; + break; + } + case 784: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CampaignExperimentError; + break; + } + case 800: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ExtensionFeedItemError; + break; + } + case 808: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AdParameterError; + break; + } + case 816: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FeedItemValidationError; + break; + } + case 824: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ExtensionSettingError; + break; + } + case 832: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.FeedItemTargetError; + break; + } + case 840: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.PolicyViolationError; + break; + } + case 856: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AssetError; + break; + } + case 864: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.MutateJobError; + break; + } + case 872: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CountryCodeError; + break; + } + case 880: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.LanguageCodeError; + break; + } + case 888: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ConversionUploadError; + break; + } + case 896: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.PartialFailureError; + break; + } + case 912: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.PolicyValidationParameterError; + break; + } + case 920: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ConversionAdjustmentUploadError; + break; + } + case 928: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.MediaUploadError; + break; + } + case 936: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.YoutubeVideoRegistrationError; + break; + } + case 944: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.SizeLimitError; + break; + } + case 960: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.NotWhitelistedError; + break; + } + case 968: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ManagerLinkError; + break; + } + case 976: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.CurrencyCodeError; + break; + } + case 992: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.AccessInvitationError; + break; + } + case 1000: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.ReachPlanError; + break; + } + case 1008: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.InvoiceError; + break; + } + case 1016: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.PaymentsAccountError; + break; + } + case 1024: { + errorCode_ = input.ReadEnum(); + errorCodeCase_ = ErrorCodeOneofCase.TimeZoneError; + break; + } + } + } + } + + } + + /// + /// Describes the part of the request proto that caused the error. + /// + public sealed partial class ErrorLocation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ErrorLocation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ErrorsReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorLocation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorLocation(ErrorLocation other) : this() { + fieldPathElements_ = other.fieldPathElements_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorLocation Clone() { + return new ErrorLocation(this); + } + + /// Field number for the "field_path_elements" field. + public const int FieldPathElementsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_fieldPathElements_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation.Types.FieldPathElement.Parser); + private readonly pbc::RepeatedField fieldPathElements_ = new pbc::RepeatedField(); + /// + /// A field path that indicates which field was invalid in the request. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FieldPathElements { + get { return fieldPathElements_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ErrorLocation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ErrorLocation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!fieldPathElements_.Equals(other.fieldPathElements_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= fieldPathElements_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + fieldPathElements_.WriteTo(output, _repeated_fieldPathElements_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += fieldPathElements_.CalculateSize(_repeated_fieldPathElements_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ErrorLocation other) { + if (other == null) { + return; + } + fieldPathElements_.Add(other.fieldPathElements_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + fieldPathElements_.AddEntriesFrom(input, _repeated_fieldPathElements_codec); + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the ErrorLocation message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// A part of a field path. + /// + public sealed partial class FieldPathElement : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FieldPathElement()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ErrorLocation.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldPathElement() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldPathElement(FieldPathElement other) : this() { + fieldName_ = other.fieldName_; + Index = other.Index; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldPathElement Clone() { + return new FieldPathElement(this); + } + + /// Field number for the "field_name" field. + public const int FieldNameFieldNumber = 1; + private string fieldName_ = ""; + /// + /// The name of a field or a oneof + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FieldName { + get { return fieldName_; } + set { + fieldName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "index" field. + public const int IndexFieldNumber = 2; + private static readonly pb::FieldCodec _single_index_codec = pb::FieldCodec.ForStructWrapper(18); + private long? index_; + /// + /// If field_name is a repeated field, this is the element that failed + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Index { + get { return index_; } + set { + index_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FieldPathElement); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FieldPathElement other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (FieldName != other.FieldName) return false; + if (Index != other.Index) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (FieldName.Length != 0) hash ^= FieldName.GetHashCode(); + if (index_ != null) hash ^= Index.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (FieldName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(FieldName); + } + if (index_ != null) { + _single_index_codec.WriteTagAndValue(output, Index); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (FieldName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(FieldName); + } + if (index_ != null) { + size += _single_index_codec.CalculateSizeWithTag(Index); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FieldPathElement other) { + if (other == null) { + return; + } + if (other.FieldName.Length != 0) { + FieldName = other.FieldName; + } + if (other.index_ != null) { + if (index_ == null || other.Index != 0L) { + Index = other.Index; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + FieldName = input.ReadString(); + break; + } + case 18: { + long? value = _single_index_codec.Read(input); + if (index_ == null || value != 0L) { + Index = value; + } + break; + } + } + } + } + + } + + } + #endregion + + } + + /// + /// Additional error details. + /// + public sealed partial class ErrorDetails : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ErrorDetails()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ErrorsReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorDetails() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorDetails(ErrorDetails other) : this() { + unpublishedErrorCode_ = other.unpublishedErrorCode_; + policyViolationDetails_ = other.policyViolationDetails_ != null ? other.policyViolationDetails_.Clone() : null; + policyFindingDetails_ = other.policyFindingDetails_ != null ? other.policyFindingDetails_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ErrorDetails Clone() { + return new ErrorDetails(this); + } + + /// Field number for the "unpublished_error_code" field. + public const int UnpublishedErrorCodeFieldNumber = 1; + private string unpublishedErrorCode_ = ""; + /// + /// The error code that should have been returned, but wasn't. This is used + /// when the error code is InternalError.ERROR_CODE_NOT_PUBLISHED. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string UnpublishedErrorCode { + get { return unpublishedErrorCode_; } + set { + unpublishedErrorCode_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "policy_violation_details" field. + public const int PolicyViolationDetailsFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationDetails policyViolationDetails_; + /// + /// Describes an ad policy violation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationDetails PolicyViolationDetails { + get { return policyViolationDetails_; } + set { + policyViolationDetails_ = value; + } + } + + /// Field number for the "policy_finding_details" field. + public const int PolicyFindingDetailsFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingDetails policyFindingDetails_; + /// + /// Describes policy violation findings. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingDetails PolicyFindingDetails { + get { return policyFindingDetails_; } + set { + policyFindingDetails_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ErrorDetails); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ErrorDetails other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (UnpublishedErrorCode != other.UnpublishedErrorCode) return false; + if (!object.Equals(PolicyViolationDetails, other.PolicyViolationDetails)) return false; + if (!object.Equals(PolicyFindingDetails, other.PolicyFindingDetails)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (UnpublishedErrorCode.Length != 0) hash ^= UnpublishedErrorCode.GetHashCode(); + if (policyViolationDetails_ != null) hash ^= PolicyViolationDetails.GetHashCode(); + if (policyFindingDetails_ != null) hash ^= PolicyFindingDetails.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (UnpublishedErrorCode.Length != 0) { + output.WriteRawTag(10); + output.WriteString(UnpublishedErrorCode); + } + if (policyViolationDetails_ != null) { + output.WriteRawTag(18); + output.WriteMessage(PolicyViolationDetails); + } + if (policyFindingDetails_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PolicyFindingDetails); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (UnpublishedErrorCode.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(UnpublishedErrorCode); + } + if (policyViolationDetails_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PolicyViolationDetails); + } + if (policyFindingDetails_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PolicyFindingDetails); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ErrorDetails other) { + if (other == null) { + return; + } + if (other.UnpublishedErrorCode.Length != 0) { + UnpublishedErrorCode = other.UnpublishedErrorCode; + } + if (other.policyViolationDetails_ != null) { + if (policyViolationDetails_ == null) { + PolicyViolationDetails = new global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationDetails(); + } + PolicyViolationDetails.MergeFrom(other.PolicyViolationDetails); + } + if (other.policyFindingDetails_ != null) { + if (policyFindingDetails_ == null) { + PolicyFindingDetails = new global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingDetails(); + } + PolicyFindingDetails.MergeFrom(other.PolicyFindingDetails); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + UnpublishedErrorCode = input.ReadString(); + break; + } + case 18: { + if (policyViolationDetails_ == null) { + PolicyViolationDetails = new global::Google.Ads.GoogleAds.V3.Errors.PolicyViolationDetails(); + } + input.ReadMessage(PolicyViolationDetails); + break; + } + case 26: { + if (policyFindingDetails_ == null) { + PolicyFindingDetails = new global::Google.Ads.GoogleAds.V3.Errors.PolicyFindingDetails(); + } + input.ReadMessage(PolicyFindingDetails); + break; + } + } + } + } + + } + + /// + /// Error returned as part of a mutate response. + /// This error indicates single policy violation by some text + /// in one of the fields. + /// + public sealed partial class PolicyViolationDetails : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PolicyViolationDetails()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ErrorsReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PolicyViolationDetails() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PolicyViolationDetails(PolicyViolationDetails other) : this() { + externalPolicyDescription_ = other.externalPolicyDescription_; + key_ = other.key_ != null ? other.key_.Clone() : null; + externalPolicyName_ = other.externalPolicyName_; + isExemptible_ = other.isExemptible_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PolicyViolationDetails Clone() { + return new PolicyViolationDetails(this); + } + + /// Field number for the "external_policy_description" field. + public const int ExternalPolicyDescriptionFieldNumber = 2; + private string externalPolicyDescription_ = ""; + /// + /// Human readable description of policy violation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ExternalPolicyDescription { + get { return externalPolicyDescription_; } + set { + externalPolicyDescription_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "key" field. + public const int KeyFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Common.PolicyViolationKey key_; + /// + /// Unique identifier for this violation. + /// If policy is exemptible, this key may be used to request exemption. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PolicyViolationKey Key { + get { return key_; } + set { + key_ = value; + } + } + + /// Field number for the "external_policy_name" field. + public const int ExternalPolicyNameFieldNumber = 5; + private string externalPolicyName_ = ""; + /// + /// Human readable name of the policy. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ExternalPolicyName { + get { return externalPolicyName_; } + set { + externalPolicyName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "is_exemptible" field. + public const int IsExemptibleFieldNumber = 6; + private bool isExemptible_; + /// + /// Whether user can file an exemption request for this violation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool IsExemptible { + get { return isExemptible_; } + set { + isExemptible_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PolicyViolationDetails); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PolicyViolationDetails other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ExternalPolicyDescription != other.ExternalPolicyDescription) return false; + if (!object.Equals(Key, other.Key)) return false; + if (ExternalPolicyName != other.ExternalPolicyName) return false; + if (IsExemptible != other.IsExemptible) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ExternalPolicyDescription.Length != 0) hash ^= ExternalPolicyDescription.GetHashCode(); + if (key_ != null) hash ^= Key.GetHashCode(); + if (ExternalPolicyName.Length != 0) hash ^= ExternalPolicyName.GetHashCode(); + if (IsExemptible != false) hash ^= IsExemptible.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ExternalPolicyDescription.Length != 0) { + output.WriteRawTag(18); + output.WriteString(ExternalPolicyDescription); + } + if (key_ != null) { + output.WriteRawTag(34); + output.WriteMessage(Key); + } + if (ExternalPolicyName.Length != 0) { + output.WriteRawTag(42); + output.WriteString(ExternalPolicyName); + } + if (IsExemptible != false) { + output.WriteRawTag(48); + output.WriteBool(IsExemptible); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ExternalPolicyDescription.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ExternalPolicyDescription); + } + if (key_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Key); + } + if (ExternalPolicyName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ExternalPolicyName); + } + if (IsExemptible != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PolicyViolationDetails other) { + if (other == null) { + return; + } + if (other.ExternalPolicyDescription.Length != 0) { + ExternalPolicyDescription = other.ExternalPolicyDescription; + } + if (other.key_ != null) { + if (key_ == null) { + Key = new global::Google.Ads.GoogleAds.V3.Common.PolicyViolationKey(); + } + Key.MergeFrom(other.Key); + } + if (other.ExternalPolicyName.Length != 0) { + ExternalPolicyName = other.ExternalPolicyName; + } + if (other.IsExemptible != false) { + IsExemptible = other.IsExemptible; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + ExternalPolicyDescription = input.ReadString(); + break; + } + case 34: { + if (key_ == null) { + Key = new global::Google.Ads.GoogleAds.V3.Common.PolicyViolationKey(); + } + input.ReadMessage(Key); + break; + } + case 42: { + ExternalPolicyName = input.ReadString(); + break; + } + case 48: { + IsExemptible = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// Error returned as part of a mutate response. + /// This error indicates one or more policy findings in the fields of a + /// resource. + /// + public sealed partial class PolicyFindingDetails : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PolicyFindingDetails()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ErrorsReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PolicyFindingDetails() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PolicyFindingDetails(PolicyFindingDetails other) : this() { + policyTopicEntries_ = other.policyTopicEntries_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PolicyFindingDetails Clone() { + return new PolicyFindingDetails(this); + } + + /// Field number for the "policy_topic_entries" field. + public const int PolicyTopicEntriesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_policyTopicEntries_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Common.PolicyTopicEntry.Parser); + private readonly pbc::RepeatedField policyTopicEntries_ = new pbc::RepeatedField(); + /// + /// The list of policy topics for the resource. Contains the PROHIBITED or + /// FULLY_LIMITED policy topic entries that prevented the resource from being + /// saved (among any other entries the resource may also have). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PolicyTopicEntries { + get { return policyTopicEntries_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PolicyFindingDetails); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PolicyFindingDetails other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!policyTopicEntries_.Equals(other.policyTopicEntries_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= policyTopicEntries_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + policyTopicEntries_.WriteTo(output, _repeated_policyTopicEntries_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += policyTopicEntries_.CalculateSize(_repeated_policyTopicEntries_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PolicyFindingDetails other) { + if (other == null) { + return; + } + policyTopicEntries_.Add(other.policyTopicEntries_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + policyTopicEntries_.AddEntriesFrom(input, _repeated_policyTopicEntries_codec); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExpandedLandingPageView.cs b/src/V3/Stubs/ExpandedLandingPageView.cs new file mode 100644 index 000000000..c5057c572 --- /dev/null +++ b/src/V3/Stubs/ExpandedLandingPageView.cs @@ -0,0 +1,235 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/expanded_landing_page_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/expanded_landing_page_view.proto + public static partial class ExpandedLandingPageViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/expanded_landing_page_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExpandedLandingPageViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZXhwYW5kZWRf", + "bGFuZGluZ19wYWdlX3ZpZXcucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90", + "bxoZZ29vZ2xlL2FwaS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVm", + "L3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3Rv", + "Iq0CChdFeHBhbmRlZExhbmRpbmdQYWdlVmlldxJPCg1yZXNvdXJjZV9uYW1l", + "GAEgASgJQjjgQQX6QTIKMGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9FeHBh", + "bmRlZExhbmRpbmdQYWdlVmlldxI9ChJleHBhbmRlZF9maW5hbF91cmwYAiAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAzqBAepBfgow", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0V4cGFuZGVkTGFuZGluZ1BhZ2VW", + "aWV3EkpjdXN0b21lcnMve2N1c3RvbWVyfS9leHBhbmRlZExhbmRpbmdQYWdl", + "Vmlld3Mve2V4cGFuZGVkX2xhbmRpbmdfcGFnZV92aWV3fUKJAgolY29tLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IcRXhwYW5kZWRMYW5k", + "aW5nUGFnZVZpZXdQcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90", + "by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291", + "cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNl", + "c8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2ds", + "ZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView), global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView.Parser, new[]{ "ResourceName", "ExpandedFinalUrl" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A landing page view with metrics aggregated at the expanded final URL + /// level. + /// + public sealed partial class ExpandedLandingPageView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExpandedLandingPageView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedLandingPageView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedLandingPageView(ExpandedLandingPageView other) : this() { + resourceName_ = other.resourceName_; + ExpandedFinalUrl = other.ExpandedFinalUrl; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExpandedLandingPageView Clone() { + return new ExpandedLandingPageView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the expanded landing page view. + /// Expanded landing page view resource names have the form: + /// + /// `customers/{customer_id}/expandedLandingPageViews/{expanded_final_url_fingerprint}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "expanded_final_url" field. + public const int ExpandedFinalUrlFieldNumber = 2; + private static readonly pb::FieldCodec _single_expandedFinalUrl_codec = pb::FieldCodec.ForClassWrapper(18); + private string expandedFinalUrl_; + /// + /// Output only. The final URL that clicks are directed to. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ExpandedFinalUrl { + get { return expandedFinalUrl_; } + set { + expandedFinalUrl_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExpandedLandingPageView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExpandedLandingPageView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (ExpandedFinalUrl != other.ExpandedFinalUrl) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (expandedFinalUrl_ != null) hash ^= ExpandedFinalUrl.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (expandedFinalUrl_ != null) { + _single_expandedFinalUrl_codec.WriteTagAndValue(output, ExpandedFinalUrl); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (expandedFinalUrl_ != null) { + size += _single_expandedFinalUrl_codec.CalculateSizeWithTag(ExpandedFinalUrl); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExpandedLandingPageView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.expandedFinalUrl_ != null) { + if (expandedFinalUrl_ == null || other.ExpandedFinalUrl != "") { + ExpandedFinalUrl = other.ExpandedFinalUrl; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_expandedFinalUrl_codec.Read(input); + if (expandedFinalUrl_ == null || value != "") { + ExpandedFinalUrl = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExpandedLandingPageViewService.cs b/src/V3/Stubs/ExpandedLandingPageViewService.cs new file mode 100644 index 000000000..301ab6c43 --- /dev/null +++ b/src/V3/Stubs/ExpandedLandingPageViewService.cs @@ -0,0 +1,198 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/expanded_landing_page_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/expanded_landing_page_view_service.proto + public static partial class ExpandedLandingPageViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/expanded_landing_page_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExpandedLandingPageViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cklnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9leHBhbmRlZF9s", + "YW5kaW5nX3BhZ2Vfdmlld19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcxpCZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "cmVzb3VyY2VzL2V4cGFuZGVkX2xhbmRpbmdfcGFnZV92aWV3LnByb3RvGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVu", + "dC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90byI/CiFH", + "ZXRFeHBhbmRlZExhbmRpbmdQYWdlVmlld1JlcXVlc3QSGgoNcmVzb3VyY2Vf", + "bmFtZRgBIAEoCUID4EECMrECCh5FeHBhbmRlZExhbmRpbmdQYWdlVmlld1Nl", + "cnZpY2US8QEKGkdldEV4cGFuZGVkTGFuZGluZ1BhZ2VWaWV3EkMuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR2V0RXhwYW5kZWRMYW5kaW5n", + "UGFnZVZpZXdSZXF1ZXN0GjouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLkV4cGFuZGVkTGFuZGluZ1BhZ2VWaWV3IlKC0+STAjwSOi92My97", + "cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9leHBhbmRlZExhbmRpbmdQYWdl", + "Vmlld3MvKn3aQQ1yZXNvdXJjZV9uYW1lGhvKQRhnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb21CigIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlc0IjRXhwYW5kZWRMYW5kaW5nUGFnZVZpZXdTZXJ2aWNlUHJvdG9QAVpI", + "Z29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29v", + "Z2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFk", + "cy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFk", + "c1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpT", + "ZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetExpandedLandingPageViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetExpandedLandingPageViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [ExpandedLandingPageViewService.GetExpandedLandingPageView][google.ads.googleads.v3.services.ExpandedLandingPageViewService.GetExpandedLandingPageView]. + /// + public sealed partial class GetExpandedLandingPageViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetExpandedLandingPageViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ExpandedLandingPageViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetExpandedLandingPageViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetExpandedLandingPageViewRequest(GetExpandedLandingPageViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetExpandedLandingPageViewRequest Clone() { + return new GetExpandedLandingPageViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the expanded landing page view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetExpandedLandingPageViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetExpandedLandingPageViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetExpandedLandingPageViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExpandedLandingPageViewServiceClient.cs b/src/V3/Stubs/ExpandedLandingPageViewServiceClient.cs new file mode 100644 index 000000000..1083791ea --- /dev/null +++ b/src/V3/Stubs/ExpandedLandingPageViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class ExpandedLandingPageViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static ExpandedLandingPageViewServiceSettings GetDefault() => new ExpandedLandingPageViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public ExpandedLandingPageViewServiceSettings() { } + + private ExpandedLandingPageViewServiceSettings(ExpandedLandingPageViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetExpandedLandingPageViewSettings = existing.GetExpandedLandingPageViewSettings; + OnCopy(existing); + } + + partial void OnCopy(ExpandedLandingPageViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// ExpandedLandingPageViewServiceClient.GetExpandedLandingPageView and ExpandedLandingPageViewServiceClient.GetExpandedLandingPageViewAsync. + /// + /// + /// The default ExpandedLandingPageViewServiceClient.GetExpandedLandingPageView and + /// ExpandedLandingPageViewServiceClient.GetExpandedLandingPageViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetExpandedLandingPageViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public ExpandedLandingPageViewServiceSettings Clone() => new ExpandedLandingPageViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class ExpandedLandingPageViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public ExpandedLandingPageViewServiceSettings Settings { get; set; } + + /// + public override ExpandedLandingPageViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return ExpandedLandingPageViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return ExpandedLandingPageViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => ExpandedLandingPageViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => ExpandedLandingPageViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => ExpandedLandingPageViewServiceClient.ChannelPool; + } + + /// + /// ExpandedLandingPageViewService client wrapper, for convenient use. + /// + public abstract partial class ExpandedLandingPageViewServiceClient + { + /// + /// The default endpoint for the ExpandedLandingPageViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default ExpandedLandingPageViewService scopes. + /// + /// + /// The default ExpandedLandingPageViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ExpandedLandingPageViewServiceClient client = await ExpandedLandingPageViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ExpandedLandingPageViewServiceClient.DefaultEndpoint.Host, ExpandedLandingPageViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ExpandedLandingPageViewServiceClient client = ExpandedLandingPageViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, ExpandedLandingPageViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ExpandedLandingPageViewServiceClient client = ExpandedLandingPageViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ExpandedLandingPageViewServiceClient.DefaultEndpoint.Host, ExpandedLandingPageViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ExpandedLandingPageViewServiceClient client = ExpandedLandingPageViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static ExpandedLandingPageViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, ExpandedLandingPageViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ExpandedLandingPageViewServiceClient Create(grpccore::Channel channel, ExpandedLandingPageViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ExpandedLandingPageViewServiceClient Create(grpccore::CallInvoker callInvoker, ExpandedLandingPageViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + ExpandedLandingPageViewService.ExpandedLandingPageViewServiceClient grpcClient = new ExpandedLandingPageViewService.ExpandedLandingPageViewServiceClient(callInvoker); + return new ExpandedLandingPageViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC ExpandedLandingPageViewService client. + /// + public virtual ExpandedLandingPageViewService.ExpandedLandingPageViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// + /// Required. The resource name of the expanded landing page view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetExpandedLandingPageViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetExpandedLandingPageViewAsync( + new GetExpandedLandingPageViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// + /// Required. The resource name of the expanded landing page view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetExpandedLandingPageViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetExpandedLandingPageViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// + /// Required. The resource name of the expanded landing page view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ExpandedLandingPageView GetExpandedLandingPageView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetExpandedLandingPageView( + new GetExpandedLandingPageViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetExpandedLandingPageViewAsync( + GetExpandedLandingPageViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetExpandedLandingPageViewAsync( + GetExpandedLandingPageViewRequest request, + st::CancellationToken cancellationToken) => GetExpandedLandingPageViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ExpandedLandingPageView GetExpandedLandingPageView( + GetExpandedLandingPageViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// ExpandedLandingPageViewService client wrapper implementation, for convenient use. + /// + public sealed partial class ExpandedLandingPageViewServiceClientImpl : ExpandedLandingPageViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetExpandedLandingPageView; + + /// + /// Constructs a client wrapper for the ExpandedLandingPageViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public ExpandedLandingPageViewServiceClientImpl(ExpandedLandingPageViewService.ExpandedLandingPageViewServiceClient grpcClient, ExpandedLandingPageViewServiceSettings settings) + { + GrpcClient = grpcClient; + ExpandedLandingPageViewServiceSettings effectiveSettings = settings ?? ExpandedLandingPageViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetExpandedLandingPageView = clientHelper.BuildApiCall( + GrpcClient.GetExpandedLandingPageViewAsync, GrpcClient.GetExpandedLandingPageView, effectiveSettings.GetExpandedLandingPageViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetExpandedLandingPageView); + Modify_GetExpandedLandingPageViewApiCall(ref _callGetExpandedLandingPageView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetExpandedLandingPageViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(ExpandedLandingPageViewService.ExpandedLandingPageViewServiceClient grpcClient, ExpandedLandingPageViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC ExpandedLandingPageViewService client. + /// + public override ExpandedLandingPageViewService.ExpandedLandingPageViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetExpandedLandingPageViewRequest(ref GetExpandedLandingPageViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetExpandedLandingPageViewAsync( + GetExpandedLandingPageViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetExpandedLandingPageViewRequest(ref request, ref callSettings); + return _callGetExpandedLandingPageView.Async(request, callSettings); + } + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::ExpandedLandingPageView GetExpandedLandingPageView( + GetExpandedLandingPageViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetExpandedLandingPageViewRequest(ref request, ref callSettings); + return _callGetExpandedLandingPageView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/ExpandedLandingPageViewServiceGrpc.cs b/src/V3/Stubs/ExpandedLandingPageViewServiceGrpc.cs new file mode 100644 index 000000000..1fb7d5f4c --- /dev/null +++ b/src/V3/Stubs/ExpandedLandingPageViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/expanded_landing_page_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch expanded landing page views. + /// + public static partial class ExpandedLandingPageViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.ExpandedLandingPageViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetExpandedLandingPageViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetExpandedLandingPageViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_ExpandedLandingPageView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetExpandedLandingPageView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetExpandedLandingPageView", + __Marshaller_google_ads_googleads_v3_services_GetExpandedLandingPageViewRequest, + __Marshaller_google_ads_googleads_v3_resources_ExpandedLandingPageView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.ExpandedLandingPageViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of ExpandedLandingPageViewService + public abstract partial class ExpandedLandingPageViewServiceBase + { + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetExpandedLandingPageView(global::Google.Ads.GoogleAds.V3.Services.GetExpandedLandingPageViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for ExpandedLandingPageViewService + public partial class ExpandedLandingPageViewServiceClient : grpc::ClientBase + { + /// Creates a new client for ExpandedLandingPageViewService + /// The channel to use to make remote calls. + public ExpandedLandingPageViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for ExpandedLandingPageViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public ExpandedLandingPageViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected ExpandedLandingPageViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected ExpandedLandingPageViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView GetExpandedLandingPageView(global::Google.Ads.GoogleAds.V3.Services.GetExpandedLandingPageViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetExpandedLandingPageView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView GetExpandedLandingPageView(global::Google.Ads.GoogleAds.V3.Services.GetExpandedLandingPageViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetExpandedLandingPageView, null, options, request); + } + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetExpandedLandingPageViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetExpandedLandingPageViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetExpandedLandingPageViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested expanded landing page view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetExpandedLandingPageViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetExpandedLandingPageViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetExpandedLandingPageView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override ExpandedLandingPageViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new ExpandedLandingPageViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(ExpandedLandingPageViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetExpandedLandingPageView, serviceImpl.GetExpandedLandingPageView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, ExpandedLandingPageViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetExpandedLandingPageView, serviceImpl.GetExpandedLandingPageView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/ExplorerAutoOptimizerSetting.cs b/src/V3/Stubs/ExplorerAutoOptimizerSetting.cs new file mode 100644 index 000000000..d7844f9f2 --- /dev/null +++ b/src/V3/Stubs/ExplorerAutoOptimizerSetting.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/explorer_auto_optimizer_setting.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/explorer_auto_optimizer_setting.proto + public static partial class ExplorerAutoOptimizerSettingReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/explorer_auto_optimizer_setting.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExplorerAutoOptimizerSettingReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZXhwbG9yZXJfYXV0", + "b19vcHRpbWl6ZXJfc2V0dGluZy5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuY29tbW9uGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8a", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iSgocRXhwbG9yZXJBdXRv", + "T3B0aW1pemVyU2V0dGluZxIqCgZvcHRfaW4YASABKAsyGi5nb29nbGUucHJv", + "dG9idWYuQm9vbFZhbHVlQvwBCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuY29tbW9uQiFFeHBsb3JlckF1dG9PcHRpbWl6ZXJTZXR0aW5nUHJvdG9Q", + "AVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMv", + "Z29vZ2xlYWRzL3YzL2NvbW1vbjtjb21tb26iAgNHQUGqAh5Hb29nbGUuQWRz", + "Lkdvb2dsZUFkcy5WMy5Db21tb27KAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xW", + "M1xDb21tb27qAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6Q29tbW9u", + "YgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.ExplorerAutoOptimizerSetting), global::Google.Ads.GoogleAds.V3.Common.ExplorerAutoOptimizerSetting.Parser, new[]{ "OptIn" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Settings for the Display Campaign Optimizer, initially named "Explorer". + /// Learn more about + /// [automatic targeting](https://support.google.com/google-ads/answer/190596). + /// + public sealed partial class ExplorerAutoOptimizerSetting : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExplorerAutoOptimizerSetting()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExplorerAutoOptimizerSettingReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExplorerAutoOptimizerSetting() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExplorerAutoOptimizerSetting(ExplorerAutoOptimizerSetting other) : this() { + OptIn = other.OptIn; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExplorerAutoOptimizerSetting Clone() { + return new ExplorerAutoOptimizerSetting(this); + } + + /// Field number for the "opt_in" field. + public const int OptInFieldNumber = 1; + private static readonly pb::FieldCodec _single_optIn_codec = pb::FieldCodec.ForStructWrapper(10); + private bool? optIn_; + /// + /// Indicates whether the optimizer is turned on. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? OptIn { + get { return optIn_; } + set { + optIn_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExplorerAutoOptimizerSetting); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExplorerAutoOptimizerSetting other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (OptIn != other.OptIn) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (optIn_ != null) hash ^= OptIn.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (optIn_ != null) { + _single_optIn_codec.WriteTagAndValue(output, OptIn); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (optIn_ != null) { + size += _single_optIn_codec.CalculateSizeWithTag(OptIn); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExplorerAutoOptimizerSetting other) { + if (other == null) { + return; + } + if (other.optIn_ != null) { + if (optIn_ == null || other.OptIn != false) { + OptIn = other.OptIn; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + bool? value = _single_optIn_codec.Read(input); + if (optIn_ == null || value != false) { + OptIn = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExtensionFeedItem.cs b/src/V3/Stubs/ExtensionFeedItem.cs new file mode 100644 index 000000000..7ea0fe91e --- /dev/null +++ b/src/V3/Stubs/ExtensionFeedItem.cs @@ -0,0 +1,1136 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/extension_feed_item.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/extension_feed_item.proto + public static partial class ExtensionFeedItemReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/extension_feed_item.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExtensionFeedItemReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZXh0ZW5zaW9u", + "X2ZlZWRfaXRlbS5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzGi1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vY3JpdGVy", + "aWEucHJvdG8aL2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9leHRl", + "bnNpb25zLnByb3RvGjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9l", + "eHRlbnNpb25fdHlwZS5wcm90bxo0Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "ZW51bXMvZmVlZF9pdGVtX3N0YXR1cy5wcm90bxo7Z29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvZW51bXMvZmVlZF9pdGVtX3RhcmdldF9kZXZpY2UucHJvdG8a", + "H2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkv", + "cmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90", + "bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKEEAoRRXh0ZW5zaW9u", + "RmVlZEl0ZW0SSQoNcmVzb3VyY2VfbmFtZRgBIAEoCUIy4EEF+kEsCipnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb20vRXh0ZW5zaW9uRmVlZEl0ZW0SLAoCaWQY", + "GCABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDElsKDmV4", + "dGVuc2lvbl90eXBlGA0gASgOMj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuRXh0ZW5zaW9uVHlwZUVudW0uRXh0ZW5zaW9uVHlwZUID4EEDEjUK", + "D3N0YXJ0X2RhdGVfdGltZRgFIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZRIzCg1lbmRfZGF0ZV90aW1lGAYgASgLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlEkQKDGFkX3NjaGVkdWxlcxgQIAMoCzIuLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZFNjaGVkdWxlSW5mbxJcCgZk", + "ZXZpY2UYESABKA4yTC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5G", + "ZWVkSXRlbVRhcmdldERldmljZUVudW0uRmVlZEl0ZW1UYXJnZXREZXZpY2US", + "cwocdGFyZ2V0ZWRfZ2VvX3RhcmdldF9jb25zdGFudBgUIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIv+kEsCipnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vR2VvVGFyZ2V0Q29uc3RhbnQSRQoQdGFyZ2V0ZWRfa2V5d29y", + "ZBgWIAEoCzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5LZXl3", + "b3JkSW5mbxJVCgZzdGF0dXMYBCABKA4yQC5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtcy5GZWVkSXRlbVN0YXR1c0VudW0uRmVlZEl0ZW1TdGF0dXNC", + "A+BBAxJOChJzaXRlbGlua19mZWVkX2l0ZW0YAiABKAsyMC5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5jb21tb24uU2l0ZWxpbmtGZWVkSXRlbUgAEmEKHHN0", + "cnVjdHVyZWRfc25pcHBldF9mZWVkX2l0ZW0YAyABKAsyOS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5jb21tb24uU3RydWN0dXJlZFNuaXBwZXRGZWVkSXRl", + "bUgAEkQKDWFwcF9mZWVkX2l0ZW0YByABKAsyKy5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5jb21tb24uQXBwRmVlZEl0ZW1IABJGCg5jYWxsX2ZlZWRfaXRl", + "bRgIIAEoCzIsLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5DYWxs", + "RmVlZEl0ZW1IABJMChFjYWxsb3V0X2ZlZWRfaXRlbRgJIAEoCzIvLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5DYWxsb3V0RmVlZEl0ZW1IABJV", + "ChZ0ZXh0X21lc3NhZ2VfZmVlZF9pdGVtGAogASgLMjMuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuY29tbW9uLlRleHRNZXNzYWdlRmVlZEl0ZW1IABJICg9w", + "cmljZV9mZWVkX2l0ZW0YCyABKAsyLS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5jb21tb24uUHJpY2VGZWVkSXRlbUgAElAKE3Byb21vdGlvbl9mZWVkX2l0", + "ZW0YDCABKAsyMS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uUHJv", + "bW90aW9uRmVlZEl0ZW1IABJTChJsb2NhdGlvbl9mZWVkX2l0ZW0YDiABKAsy", + "MC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uTG9jYXRpb25GZWVk", + "SXRlbUID4EEDSAASZgocYWZmaWxpYXRlX2xvY2F0aW9uX2ZlZWRfaXRlbRgP", + "IAEoCzI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZmZpbGlh", + "dGVMb2NhdGlvbkZlZWRJdGVtQgPgQQNIABJXChdob3RlbF9jYWxsb3V0X2Zl", + "ZWRfaXRlbRgXIAEoCzI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1v", + "bi5Ib3RlbENhbGxvdXRGZWVkSXRlbUgAEmEKEXRhcmdldGVkX2NhbXBhaWdu", + "GBIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQib6QSMKIWdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbS9DYW1wYWlnbkgBEmAKEXRhcmdldGVk", + "X2FkX2dyb3VwGBMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVl", + "QiX6QSIKIGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9BZEdyb3VwSAE6bupB", + "awoqZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0V4dGVuc2lvbkZlZWRJdGVt", + "Ej1jdXN0b21lcnMve2N1c3RvbWVyfS9leHRlbnNpb25GZWVkSXRlbXMve2V4", + "dGVuc2lvbl9mZWVkX2l0ZW19QgsKCWV4dGVuc2lvbkIcChpzZXJ2aW5nX3Jl", + "c291cmNlX3RhcmdldGluZ0KDAgolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlc0IWRXh0ZW5zaW9uRmVlZEl0ZW1Qcm90b1ABWkpnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRz", + "XFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpS", + "ZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem), global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem.Parser, new[]{ "ResourceName", "Id", "ExtensionType", "StartDateTime", "EndDateTime", "AdSchedules", "Device", "TargetedGeoTargetConstant", "TargetedKeyword", "Status", "SitelinkFeedItem", "StructuredSnippetFeedItem", "AppFeedItem", "CallFeedItem", "CalloutFeedItem", "TextMessageFeedItem", "PriceFeedItem", "PromotionFeedItem", "LocationFeedItem", "AffiliateLocationFeedItem", "HotelCalloutFeedItem", "TargetedCampaign", "TargetedAdGroup" }, new[]{ "Extension", "ServingResourceTargeting" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// An extension feed item. + /// + public sealed partial class ExtensionFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExtensionFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItemReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItem(ExtensionFeedItem other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + extensionType_ = other.extensionType_; + StartDateTime = other.StartDateTime; + EndDateTime = other.EndDateTime; + adSchedules_ = other.adSchedules_.Clone(); + device_ = other.device_; + TargetedGeoTargetConstant = other.TargetedGeoTargetConstant; + targetedKeyword_ = other.targetedKeyword_ != null ? other.targetedKeyword_.Clone() : null; + status_ = other.status_; + switch (other.ExtensionCase) { + case ExtensionOneofCase.SitelinkFeedItem: + SitelinkFeedItem = other.SitelinkFeedItem.Clone(); + break; + case ExtensionOneofCase.StructuredSnippetFeedItem: + StructuredSnippetFeedItem = other.StructuredSnippetFeedItem.Clone(); + break; + case ExtensionOneofCase.AppFeedItem: + AppFeedItem = other.AppFeedItem.Clone(); + break; + case ExtensionOneofCase.CallFeedItem: + CallFeedItem = other.CallFeedItem.Clone(); + break; + case ExtensionOneofCase.CalloutFeedItem: + CalloutFeedItem = other.CalloutFeedItem.Clone(); + break; + case ExtensionOneofCase.TextMessageFeedItem: + TextMessageFeedItem = other.TextMessageFeedItem.Clone(); + break; + case ExtensionOneofCase.PriceFeedItem: + PriceFeedItem = other.PriceFeedItem.Clone(); + break; + case ExtensionOneofCase.PromotionFeedItem: + PromotionFeedItem = other.PromotionFeedItem.Clone(); + break; + case ExtensionOneofCase.LocationFeedItem: + LocationFeedItem = other.LocationFeedItem.Clone(); + break; + case ExtensionOneofCase.AffiliateLocationFeedItem: + AffiliateLocationFeedItem = other.AffiliateLocationFeedItem.Clone(); + break; + case ExtensionOneofCase.HotelCalloutFeedItem: + HotelCalloutFeedItem = other.HotelCalloutFeedItem.Clone(); + break; + } + + switch (other.ServingResourceTargetingCase) { + case ServingResourceTargetingOneofCase.TargetedCampaign: + TargetedCampaign = other.TargetedCampaign; + break; + case ServingResourceTargetingOneofCase.TargetedAdGroup: + TargetedAdGroup = other.TargetedAdGroup; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItem Clone() { + return new ExtensionFeedItem(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the extension feed item. + /// Extension feed item resource names have the form: + /// + /// `customers/{customer_id}/extensionFeedItems/{feed_item_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 24; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(194); + private long? id_; + /// + /// Output only. The ID of this feed item. Read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "extension_type" field. + public const int ExtensionTypeFieldNumber = 13; + private global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType extensionType_ = 0; + /// + /// Output only. The extension type of the extension feed item. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType ExtensionType { + get { return extensionType_; } + set { + extensionType_ = value; + } + } + + /// Field number for the "start_date_time" field. + public const int StartDateTimeFieldNumber = 5; + private static readonly pb::FieldCodec _single_startDateTime_codec = pb::FieldCodec.ForClassWrapper(42); + private string startDateTime_; + /// + /// Start time in which this feed item is effective and can begin serving. The + /// time is in the customer's time zone. + /// The format is "YYYY-MM-DD HH:MM:SS". + /// Examples: "2018-03-05 09:15:00" or "2018-02-01 14:34:30" + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDateTime { + get { return startDateTime_; } + set { + startDateTime_ = value; + } + } + + + /// Field number for the "end_date_time" field. + public const int EndDateTimeFieldNumber = 6; + private static readonly pb::FieldCodec _single_endDateTime_codec = pb::FieldCodec.ForClassWrapper(50); + private string endDateTime_; + /// + /// End time in which this feed item is no longer effective and will stop + /// serving. The time is in the customer's time zone. + /// The format is "YYYY-MM-DD HH:MM:SS". + /// Examples: "2018-03-05 09:15:00" or "2018-02-01 14:34:30" + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDateTime { + get { return endDateTime_; } + set { + endDateTime_ = value; + } + } + + + /// Field number for the "ad_schedules" field. + public const int AdSchedulesFieldNumber = 16; + private static readonly pb::FieldCodec _repeated_adSchedules_codec + = pb::FieldCodec.ForMessage(130, global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo.Parser); + private readonly pbc::RepeatedField adSchedules_ = new pbc::RepeatedField(); + /// + /// List of non-overlapping schedules specifying all time intervals + /// for which the feed item may serve. There can be a maximum of 6 schedules + /// per day. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField AdSchedules { + get { return adSchedules_; } + } + + /// Field number for the "device" field. + public const int DeviceFieldNumber = 17; + private global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum.Types.FeedItemTargetDevice device_ = 0; + /// + /// The targeted device. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum.Types.FeedItemTargetDevice Device { + get { return device_; } + set { + device_ = value; + } + } + + /// Field number for the "targeted_geo_target_constant" field. + public const int TargetedGeoTargetConstantFieldNumber = 20; + private static readonly pb::FieldCodec _single_targetedGeoTargetConstant_codec = pb::FieldCodec.ForClassWrapper(162); + private string targetedGeoTargetConstant_; + /// + /// The targeted geo target constant. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TargetedGeoTargetConstant { + get { return targetedGeoTargetConstant_; } + set { + targetedGeoTargetConstant_ = value; + } + } + + + /// Field number for the "targeted_keyword" field. + public const int TargetedKeywordFieldNumber = 22; + private global::Google.Ads.GoogleAds.V3.Common.KeywordInfo targetedKeyword_; + /// + /// The targeted keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.KeywordInfo TargetedKeyword { + get { return targetedKeyword_; } + set { + targetedKeyword_ = value; + } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum.Types.FeedItemStatus status_ = 0; + /// + /// Output only. Status of the feed item. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum.Types.FeedItemStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "sitelink_feed_item" field. + public const int SitelinkFeedItemFieldNumber = 2; + /// + /// Sitelink extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.SitelinkFeedItem SitelinkFeedItem { + get { return extensionCase_ == ExtensionOneofCase.SitelinkFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.SitelinkFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.SitelinkFeedItem; + } + } + + /// Field number for the "structured_snippet_feed_item" field. + public const int StructuredSnippetFeedItemFieldNumber = 3; + /// + /// Structured snippet extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.StructuredSnippetFeedItem StructuredSnippetFeedItem { + get { return extensionCase_ == ExtensionOneofCase.StructuredSnippetFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.StructuredSnippetFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.StructuredSnippetFeedItem; + } + } + + /// Field number for the "app_feed_item" field. + public const int AppFeedItemFieldNumber = 7; + /// + /// App extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AppFeedItem AppFeedItem { + get { return extensionCase_ == ExtensionOneofCase.AppFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.AppFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.AppFeedItem; + } + } + + /// Field number for the "call_feed_item" field. + public const int CallFeedItemFieldNumber = 8; + /// + /// Call extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CallFeedItem CallFeedItem { + get { return extensionCase_ == ExtensionOneofCase.CallFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.CallFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.CallFeedItem; + } + } + + /// Field number for the "callout_feed_item" field. + public const int CalloutFeedItemFieldNumber = 9; + /// + /// Callout extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.CalloutFeedItem CalloutFeedItem { + get { return extensionCase_ == ExtensionOneofCase.CalloutFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.CalloutFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.CalloutFeedItem; + } + } + + /// Field number for the "text_message_feed_item" field. + public const int TextMessageFeedItemFieldNumber = 10; + /// + /// Text message extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.TextMessageFeedItem TextMessageFeedItem { + get { return extensionCase_ == ExtensionOneofCase.TextMessageFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.TextMessageFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.TextMessageFeedItem; + } + } + + /// Field number for the "price_feed_item" field. + public const int PriceFeedItemFieldNumber = 11; + /// + /// Price extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PriceFeedItem PriceFeedItem { + get { return extensionCase_ == ExtensionOneofCase.PriceFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.PriceFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.PriceFeedItem; + } + } + + /// Field number for the "promotion_feed_item" field. + public const int PromotionFeedItemFieldNumber = 12; + /// + /// Promotion extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.PromotionFeedItem PromotionFeedItem { + get { return extensionCase_ == ExtensionOneofCase.PromotionFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.PromotionFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.PromotionFeedItem; + } + } + + /// Field number for the "location_feed_item" field. + public const int LocationFeedItemFieldNumber = 14; + /// + /// Output only. Location extension. Locations are synced from a GMB account into a feed. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.LocationFeedItem LocationFeedItem { + get { return extensionCase_ == ExtensionOneofCase.LocationFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.LocationFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.LocationFeedItem; + } + } + + /// Field number for the "affiliate_location_feed_item" field. + public const int AffiliateLocationFeedItemFieldNumber = 15; + /// + /// Output only. Affiliate location extension. Feed locations are populated by Google Ads + /// based on a chain ID. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AffiliateLocationFeedItem AffiliateLocationFeedItem { + get { return extensionCase_ == ExtensionOneofCase.AffiliateLocationFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.AffiliateLocationFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.AffiliateLocationFeedItem; + } + } + + /// Field number for the "hotel_callout_feed_item" field. + public const int HotelCalloutFeedItemFieldNumber = 23; + /// + /// Hotel Callout extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.HotelCalloutFeedItem HotelCalloutFeedItem { + get { return extensionCase_ == ExtensionOneofCase.HotelCalloutFeedItem ? (global::Google.Ads.GoogleAds.V3.Common.HotelCalloutFeedItem) extension_ : null; } + set { + extension_ = value; + extensionCase_ = value == null ? ExtensionOneofCase.None : ExtensionOneofCase.HotelCalloutFeedItem; + } + } + + /// Field number for the "targeted_campaign" field. + public const int TargetedCampaignFieldNumber = 18; + private static readonly pb::FieldCodec _oneof_targetedCampaign_codec = pb::FieldCodec.ForClassWrapper(146); + /// + /// The targeted campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TargetedCampaign { + get { return servingResourceTargetingCase_ == ServingResourceTargetingOneofCase.TargetedCampaign ? (string) servingResourceTargeting_ : (string) null; } + set { + servingResourceTargeting_ = value; + servingResourceTargetingCase_ = value == null ? ServingResourceTargetingOneofCase.None : ServingResourceTargetingOneofCase.TargetedCampaign; + } + } + + /// Field number for the "targeted_ad_group" field. + public const int TargetedAdGroupFieldNumber = 19; + private static readonly pb::FieldCodec _oneof_targetedAdGroup_codec = pb::FieldCodec.ForClassWrapper(154); + /// + /// The targeted ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TargetedAdGroup { + get { return servingResourceTargetingCase_ == ServingResourceTargetingOneofCase.TargetedAdGroup ? (string) servingResourceTargeting_ : (string) null; } + set { + servingResourceTargeting_ = value; + servingResourceTargetingCase_ = value == null ? ServingResourceTargetingOneofCase.None : ServingResourceTargetingOneofCase.TargetedAdGroup; + } + } + + private object extension_; + /// Enum of possible cases for the "extension" oneof. + public enum ExtensionOneofCase { + None = 0, + SitelinkFeedItem = 2, + StructuredSnippetFeedItem = 3, + AppFeedItem = 7, + CallFeedItem = 8, + CalloutFeedItem = 9, + TextMessageFeedItem = 10, + PriceFeedItem = 11, + PromotionFeedItem = 12, + LocationFeedItem = 14, + AffiliateLocationFeedItem = 15, + HotelCalloutFeedItem = 23, + } + private ExtensionOneofCase extensionCase_ = ExtensionOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionOneofCase ExtensionCase { + get { return extensionCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearExtension() { + extensionCase_ = ExtensionOneofCase.None; + extension_ = null; + } + + private object servingResourceTargeting_; + /// Enum of possible cases for the "serving_resource_targeting" oneof. + public enum ServingResourceTargetingOneofCase { + None = 0, + TargetedCampaign = 18, + TargetedAdGroup = 19, + } + private ServingResourceTargetingOneofCase servingResourceTargetingCase_ = ServingResourceTargetingOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ServingResourceTargetingOneofCase ServingResourceTargetingCase { + get { return servingResourceTargetingCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearServingResourceTargeting() { + servingResourceTargetingCase_ = ServingResourceTargetingOneofCase.None; + servingResourceTargeting_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExtensionFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExtensionFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (ExtensionType != other.ExtensionType) return false; + if (StartDateTime != other.StartDateTime) return false; + if (EndDateTime != other.EndDateTime) return false; + if(!adSchedules_.Equals(other.adSchedules_)) return false; + if (Device != other.Device) return false; + if (TargetedGeoTargetConstant != other.TargetedGeoTargetConstant) return false; + if (!object.Equals(TargetedKeyword, other.TargetedKeyword)) return false; + if (Status != other.Status) return false; + if (!object.Equals(SitelinkFeedItem, other.SitelinkFeedItem)) return false; + if (!object.Equals(StructuredSnippetFeedItem, other.StructuredSnippetFeedItem)) return false; + if (!object.Equals(AppFeedItem, other.AppFeedItem)) return false; + if (!object.Equals(CallFeedItem, other.CallFeedItem)) return false; + if (!object.Equals(CalloutFeedItem, other.CalloutFeedItem)) return false; + if (!object.Equals(TextMessageFeedItem, other.TextMessageFeedItem)) return false; + if (!object.Equals(PriceFeedItem, other.PriceFeedItem)) return false; + if (!object.Equals(PromotionFeedItem, other.PromotionFeedItem)) return false; + if (!object.Equals(LocationFeedItem, other.LocationFeedItem)) return false; + if (!object.Equals(AffiliateLocationFeedItem, other.AffiliateLocationFeedItem)) return false; + if (!object.Equals(HotelCalloutFeedItem, other.HotelCalloutFeedItem)) return false; + if (TargetedCampaign != other.TargetedCampaign) return false; + if (TargetedAdGroup != other.TargetedAdGroup) return false; + if (ExtensionCase != other.ExtensionCase) return false; + if (ServingResourceTargetingCase != other.ServingResourceTargetingCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (ExtensionType != 0) hash ^= ExtensionType.GetHashCode(); + if (startDateTime_ != null) hash ^= StartDateTime.GetHashCode(); + if (endDateTime_ != null) hash ^= EndDateTime.GetHashCode(); + hash ^= adSchedules_.GetHashCode(); + if (Device != 0) hash ^= Device.GetHashCode(); + if (targetedGeoTargetConstant_ != null) hash ^= TargetedGeoTargetConstant.GetHashCode(); + if (targetedKeyword_ != null) hash ^= TargetedKeyword.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.SitelinkFeedItem) hash ^= SitelinkFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.StructuredSnippetFeedItem) hash ^= StructuredSnippetFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.AppFeedItem) hash ^= AppFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.CallFeedItem) hash ^= CallFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.CalloutFeedItem) hash ^= CalloutFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.TextMessageFeedItem) hash ^= TextMessageFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.PriceFeedItem) hash ^= PriceFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.PromotionFeedItem) hash ^= PromotionFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.LocationFeedItem) hash ^= LocationFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.AffiliateLocationFeedItem) hash ^= AffiliateLocationFeedItem.GetHashCode(); + if (extensionCase_ == ExtensionOneofCase.HotelCalloutFeedItem) hash ^= HotelCalloutFeedItem.GetHashCode(); + if (servingResourceTargetingCase_ == ServingResourceTargetingOneofCase.TargetedCampaign) hash ^= TargetedCampaign.GetHashCode(); + if (servingResourceTargetingCase_ == ServingResourceTargetingOneofCase.TargetedAdGroup) hash ^= TargetedAdGroup.GetHashCode(); + hash ^= (int) extensionCase_; + hash ^= (int) servingResourceTargetingCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (extensionCase_ == ExtensionOneofCase.SitelinkFeedItem) { + output.WriteRawTag(18); + output.WriteMessage(SitelinkFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.StructuredSnippetFeedItem) { + output.WriteRawTag(26); + output.WriteMessage(StructuredSnippetFeedItem); + } + if (Status != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) Status); + } + if (startDateTime_ != null) { + _single_startDateTime_codec.WriteTagAndValue(output, StartDateTime); + } + if (endDateTime_ != null) { + _single_endDateTime_codec.WriteTagAndValue(output, EndDateTime); + } + if (extensionCase_ == ExtensionOneofCase.AppFeedItem) { + output.WriteRawTag(58); + output.WriteMessage(AppFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.CallFeedItem) { + output.WriteRawTag(66); + output.WriteMessage(CallFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.CalloutFeedItem) { + output.WriteRawTag(74); + output.WriteMessage(CalloutFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.TextMessageFeedItem) { + output.WriteRawTag(82); + output.WriteMessage(TextMessageFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.PriceFeedItem) { + output.WriteRawTag(90); + output.WriteMessage(PriceFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.PromotionFeedItem) { + output.WriteRawTag(98); + output.WriteMessage(PromotionFeedItem); + } + if (ExtensionType != 0) { + output.WriteRawTag(104); + output.WriteEnum((int) ExtensionType); + } + if (extensionCase_ == ExtensionOneofCase.LocationFeedItem) { + output.WriteRawTag(114); + output.WriteMessage(LocationFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.AffiliateLocationFeedItem) { + output.WriteRawTag(122); + output.WriteMessage(AffiliateLocationFeedItem); + } + adSchedules_.WriteTo(output, _repeated_adSchedules_codec); + if (Device != 0) { + output.WriteRawTag(136, 1); + output.WriteEnum((int) Device); + } + if (servingResourceTargetingCase_ == ServingResourceTargetingOneofCase.TargetedCampaign) { + _oneof_targetedCampaign_codec.WriteTagAndValue(output, (string) servingResourceTargeting_); + } + if (servingResourceTargetingCase_ == ServingResourceTargetingOneofCase.TargetedAdGroup) { + _oneof_targetedAdGroup_codec.WriteTagAndValue(output, (string) servingResourceTargeting_); + } + if (targetedGeoTargetConstant_ != null) { + _single_targetedGeoTargetConstant_codec.WriteTagAndValue(output, TargetedGeoTargetConstant); + } + if (targetedKeyword_ != null) { + output.WriteRawTag(178, 1); + output.WriteMessage(TargetedKeyword); + } + if (extensionCase_ == ExtensionOneofCase.HotelCalloutFeedItem) { + output.WriteRawTag(186, 1); + output.WriteMessage(HotelCalloutFeedItem); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (ExtensionType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ExtensionType); + } + if (startDateTime_ != null) { + size += _single_startDateTime_codec.CalculateSizeWithTag(StartDateTime); + } + if (endDateTime_ != null) { + size += _single_endDateTime_codec.CalculateSizeWithTag(EndDateTime); + } + size += adSchedules_.CalculateSize(_repeated_adSchedules_codec); + if (Device != 0) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) Device); + } + if (targetedGeoTargetConstant_ != null) { + size += _single_targetedGeoTargetConstant_codec.CalculateSizeWithTag(TargetedGeoTargetConstant); + } + if (targetedKeyword_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TargetedKeyword); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (extensionCase_ == ExtensionOneofCase.SitelinkFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(SitelinkFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.StructuredSnippetFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(StructuredSnippetFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.AppFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AppFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.CallFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CallFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.CalloutFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CalloutFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.TextMessageFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(TextMessageFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.PriceFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PriceFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.PromotionFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PromotionFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.LocationFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(LocationFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.AffiliateLocationFeedItem) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AffiliateLocationFeedItem); + } + if (extensionCase_ == ExtensionOneofCase.HotelCalloutFeedItem) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(HotelCalloutFeedItem); + } + if (servingResourceTargetingCase_ == ServingResourceTargetingOneofCase.TargetedCampaign) { + size += _oneof_targetedCampaign_codec.CalculateSizeWithTag(TargetedCampaign); + } + if (servingResourceTargetingCase_ == ServingResourceTargetingOneofCase.TargetedAdGroup) { + size += _oneof_targetedAdGroup_codec.CalculateSizeWithTag(TargetedAdGroup); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExtensionFeedItem other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.ExtensionType != 0) { + ExtensionType = other.ExtensionType; + } + if (other.startDateTime_ != null) { + if (startDateTime_ == null || other.StartDateTime != "") { + StartDateTime = other.StartDateTime; + } + } + if (other.endDateTime_ != null) { + if (endDateTime_ == null || other.EndDateTime != "") { + EndDateTime = other.EndDateTime; + } + } + adSchedules_.Add(other.adSchedules_); + if (other.Device != 0) { + Device = other.Device; + } + if (other.targetedGeoTargetConstant_ != null) { + if (targetedGeoTargetConstant_ == null || other.TargetedGeoTargetConstant != "") { + TargetedGeoTargetConstant = other.TargetedGeoTargetConstant; + } + } + if (other.targetedKeyword_ != null) { + if (targetedKeyword_ == null) { + TargetedKeyword = new global::Google.Ads.GoogleAds.V3.Common.KeywordInfo(); + } + TargetedKeyword.MergeFrom(other.TargetedKeyword); + } + if (other.Status != 0) { + Status = other.Status; + } + switch (other.ExtensionCase) { + case ExtensionOneofCase.SitelinkFeedItem: + if (SitelinkFeedItem == null) { + SitelinkFeedItem = new global::Google.Ads.GoogleAds.V3.Common.SitelinkFeedItem(); + } + SitelinkFeedItem.MergeFrom(other.SitelinkFeedItem); + break; + case ExtensionOneofCase.StructuredSnippetFeedItem: + if (StructuredSnippetFeedItem == null) { + StructuredSnippetFeedItem = new global::Google.Ads.GoogleAds.V3.Common.StructuredSnippetFeedItem(); + } + StructuredSnippetFeedItem.MergeFrom(other.StructuredSnippetFeedItem); + break; + case ExtensionOneofCase.AppFeedItem: + if (AppFeedItem == null) { + AppFeedItem = new global::Google.Ads.GoogleAds.V3.Common.AppFeedItem(); + } + AppFeedItem.MergeFrom(other.AppFeedItem); + break; + case ExtensionOneofCase.CallFeedItem: + if (CallFeedItem == null) { + CallFeedItem = new global::Google.Ads.GoogleAds.V3.Common.CallFeedItem(); + } + CallFeedItem.MergeFrom(other.CallFeedItem); + break; + case ExtensionOneofCase.CalloutFeedItem: + if (CalloutFeedItem == null) { + CalloutFeedItem = new global::Google.Ads.GoogleAds.V3.Common.CalloutFeedItem(); + } + CalloutFeedItem.MergeFrom(other.CalloutFeedItem); + break; + case ExtensionOneofCase.TextMessageFeedItem: + if (TextMessageFeedItem == null) { + TextMessageFeedItem = new global::Google.Ads.GoogleAds.V3.Common.TextMessageFeedItem(); + } + TextMessageFeedItem.MergeFrom(other.TextMessageFeedItem); + break; + case ExtensionOneofCase.PriceFeedItem: + if (PriceFeedItem == null) { + PriceFeedItem = new global::Google.Ads.GoogleAds.V3.Common.PriceFeedItem(); + } + PriceFeedItem.MergeFrom(other.PriceFeedItem); + break; + case ExtensionOneofCase.PromotionFeedItem: + if (PromotionFeedItem == null) { + PromotionFeedItem = new global::Google.Ads.GoogleAds.V3.Common.PromotionFeedItem(); + } + PromotionFeedItem.MergeFrom(other.PromotionFeedItem); + break; + case ExtensionOneofCase.LocationFeedItem: + if (LocationFeedItem == null) { + LocationFeedItem = new global::Google.Ads.GoogleAds.V3.Common.LocationFeedItem(); + } + LocationFeedItem.MergeFrom(other.LocationFeedItem); + break; + case ExtensionOneofCase.AffiliateLocationFeedItem: + if (AffiliateLocationFeedItem == null) { + AffiliateLocationFeedItem = new global::Google.Ads.GoogleAds.V3.Common.AffiliateLocationFeedItem(); + } + AffiliateLocationFeedItem.MergeFrom(other.AffiliateLocationFeedItem); + break; + case ExtensionOneofCase.HotelCalloutFeedItem: + if (HotelCalloutFeedItem == null) { + HotelCalloutFeedItem = new global::Google.Ads.GoogleAds.V3.Common.HotelCalloutFeedItem(); + } + HotelCalloutFeedItem.MergeFrom(other.HotelCalloutFeedItem); + break; + } + + switch (other.ServingResourceTargetingCase) { + case ServingResourceTargetingOneofCase.TargetedCampaign: + TargetedCampaign = other.TargetedCampaign; + break; + case ServingResourceTargetingOneofCase.TargetedAdGroup: + TargetedAdGroup = other.TargetedAdGroup; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Common.SitelinkFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.SitelinkFeedItem(); + if (extensionCase_ == ExtensionOneofCase.SitelinkFeedItem) { + subBuilder.MergeFrom(SitelinkFeedItem); + } + input.ReadMessage(subBuilder); + SitelinkFeedItem = subBuilder; + break; + } + case 26: { + global::Google.Ads.GoogleAds.V3.Common.StructuredSnippetFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.StructuredSnippetFeedItem(); + if (extensionCase_ == ExtensionOneofCase.StructuredSnippetFeedItem) { + subBuilder.MergeFrom(StructuredSnippetFeedItem); + } + input.ReadMessage(subBuilder); + StructuredSnippetFeedItem = subBuilder; + break; + } + case 32: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum.Types.FeedItemStatus) input.ReadEnum(); + break; + } + case 42: { + string value = _single_startDateTime_codec.Read(input); + if (startDateTime_ == null || value != "") { + StartDateTime = value; + } + break; + } + case 50: { + string value = _single_endDateTime_codec.Read(input); + if (endDateTime_ == null || value != "") { + EndDateTime = value; + } + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Common.AppFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AppFeedItem(); + if (extensionCase_ == ExtensionOneofCase.AppFeedItem) { + subBuilder.MergeFrom(AppFeedItem); + } + input.ReadMessage(subBuilder); + AppFeedItem = subBuilder; + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Common.CallFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CallFeedItem(); + if (extensionCase_ == ExtensionOneofCase.CallFeedItem) { + subBuilder.MergeFrom(CallFeedItem); + } + input.ReadMessage(subBuilder); + CallFeedItem = subBuilder; + break; + } + case 74: { + global::Google.Ads.GoogleAds.V3.Common.CalloutFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.CalloutFeedItem(); + if (extensionCase_ == ExtensionOneofCase.CalloutFeedItem) { + subBuilder.MergeFrom(CalloutFeedItem); + } + input.ReadMessage(subBuilder); + CalloutFeedItem = subBuilder; + break; + } + case 82: { + global::Google.Ads.GoogleAds.V3.Common.TextMessageFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.TextMessageFeedItem(); + if (extensionCase_ == ExtensionOneofCase.TextMessageFeedItem) { + subBuilder.MergeFrom(TextMessageFeedItem); + } + input.ReadMessage(subBuilder); + TextMessageFeedItem = subBuilder; + break; + } + case 90: { + global::Google.Ads.GoogleAds.V3.Common.PriceFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.PriceFeedItem(); + if (extensionCase_ == ExtensionOneofCase.PriceFeedItem) { + subBuilder.MergeFrom(PriceFeedItem); + } + input.ReadMessage(subBuilder); + PriceFeedItem = subBuilder; + break; + } + case 98: { + global::Google.Ads.GoogleAds.V3.Common.PromotionFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.PromotionFeedItem(); + if (extensionCase_ == ExtensionOneofCase.PromotionFeedItem) { + subBuilder.MergeFrom(PromotionFeedItem); + } + input.ReadMessage(subBuilder); + PromotionFeedItem = subBuilder; + break; + } + case 104: { + ExtensionType = (global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType) input.ReadEnum(); + break; + } + case 114: { + global::Google.Ads.GoogleAds.V3.Common.LocationFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.LocationFeedItem(); + if (extensionCase_ == ExtensionOneofCase.LocationFeedItem) { + subBuilder.MergeFrom(LocationFeedItem); + } + input.ReadMessage(subBuilder); + LocationFeedItem = subBuilder; + break; + } + case 122: { + global::Google.Ads.GoogleAds.V3.Common.AffiliateLocationFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AffiliateLocationFeedItem(); + if (extensionCase_ == ExtensionOneofCase.AffiliateLocationFeedItem) { + subBuilder.MergeFrom(AffiliateLocationFeedItem); + } + input.ReadMessage(subBuilder); + AffiliateLocationFeedItem = subBuilder; + break; + } + case 130: { + adSchedules_.AddEntriesFrom(input, _repeated_adSchedules_codec); + break; + } + case 136: { + Device = (global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum.Types.FeedItemTargetDevice) input.ReadEnum(); + break; + } + case 146: { + TargetedCampaign = _oneof_targetedCampaign_codec.Read(input); + break; + } + case 154: { + TargetedAdGroup = _oneof_targetedAdGroup_codec.Read(input); + break; + } + case 162: { + string value = _single_targetedGeoTargetConstant_codec.Read(input); + if (targetedGeoTargetConstant_ == null || value != "") { + TargetedGeoTargetConstant = value; + } + break; + } + case 178: { + if (targetedKeyword_ == null) { + TargetedKeyword = new global::Google.Ads.GoogleAds.V3.Common.KeywordInfo(); + } + input.ReadMessage(TargetedKeyword); + break; + } + case 186: { + global::Google.Ads.GoogleAds.V3.Common.HotelCalloutFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Common.HotelCalloutFeedItem(); + if (extensionCase_ == ExtensionOneofCase.HotelCalloutFeedItem) { + subBuilder.MergeFrom(HotelCalloutFeedItem); + } + input.ReadMessage(subBuilder); + HotelCalloutFeedItem = subBuilder; + break; + } + case 194: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExtensionFeedItemError.cs b/src/V3/Stubs/ExtensionFeedItemError.cs new file mode 100644 index 000000000..9c6886b28 --- /dev/null +++ b/src/V3/Stubs/ExtensionFeedItemError.cs @@ -0,0 +1,410 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/extension_feed_item_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/extension_feed_item_error.proto + public static partial class ExtensionFeedItemErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/extension_feed_item_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExtensionFeedItemErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZXh0ZW5zaW9uX2Zl", + "ZWRfaXRlbV9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZXJyb3JzGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvUNChpFeHRl", + "bnNpb25GZWVkSXRlbUVycm9yRW51bSLWDQoWRXh0ZW5zaW9uRmVlZEl0ZW1F", + "cnJvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIWChJWQUxVRV9P", + "VVRfT0ZfUkFOR0UQAhIVChFVUkxfTElTVF9UT09fTE9ORxADEjIKLkNBTk5P", + "VF9IQVZFX1JFU1RSSUNUSU9OX09OX0VNUFRZX0dFT19UQVJHRVRJTkcQBBIe", + "ChpDQU5OT1RfU0VUX1dJVEhfRklOQUxfVVJMUxAFEiEKHUNBTk5PVF9TRVRf", + "V0lUSE9VVF9GSU5BTF9VUkxTEAYSGAoUSU5WQUxJRF9QSE9ORV9OVU1CRVIQ", + "BxIqCiZQSE9ORV9OVU1CRVJfTk9UX1NVUFBPUlRFRF9GT1JfQ09VTlRSWRAI", + "Ei0KKUNBUlJJRVJfU1BFQ0lGSUNfU0hPUlRfTlVNQkVSX05PVF9BTExPV0VE", + "EAkSIwofUFJFTUlVTV9SQVRFX05VTUJFUl9OT1RfQUxMT1dFRBAKEhoKFkRJ", + "U0FMTE9XRURfTlVNQkVSX1RZUEUQCxIoCiRJTlZBTElEX0RPTUVTVElDX1BI", + "T05FX05VTUJFUl9GT1JNQVQQDBIjCh9WQU5JVFlfUEhPTkVfTlVNQkVSX05P", + "VF9BTExPV0VEEA0SIgoeSU5WQUxJRF9DQUxMX0NPTlZFUlNJT05fQUNUSU9O", + "EA4SLQopQ1VTVE9NRVJfTk9UX1dISVRFTElTVEVEX0ZPUl9DQUxMVFJBQ0tJ", + "TkcQDxIqCiZDQUxMVFJBQ0tJTkdfTk9UX1NVUFBPUlRFRF9GT1JfQ09VTlRS", + "WRAQEjAKLENVU1RPTUVSX0NPTlNFTlRfRk9SX0NBTExfUkVDT1JESU5HX1JF", + "UVVJUkVEEBESEgoOSU5WQUxJRF9BUFBfSUQQEhImCiJRVU9URVNfSU5fUkVW", + "SUVXX0VYVEVOU0lPTl9TTklQUEVUEBMSJwojSFlQSEVOU19JTl9SRVZJRVdf", + "RVhURU5TSU9OX1NOSVBQRVQQFBImCiJSRVZJRVdfRVhURU5TSU9OX1NPVVJD", + "RV9JTkVMSUdJQkxFEBUSKAokU09VUkNFX05BTUVfSU5fUkVWSUVXX0VYVEVO", + "U0lPTl9URVhUEBYSHwobSU5DT05TSVNURU5UX0NVUlJFTkNZX0NPREVTEBcS", + "KgomUFJJQ0VfRVhURU5TSU9OX0hBU19EVVBMSUNBVEVEX0hFQURFUlMQGBI0", + "CjBQUklDRV9JVEVNX0hBU19EVVBMSUNBVEVEX0hFQURFUl9BTkRfREVTQ1JJ", + "UFRJT04QGRIlCiFQUklDRV9FWFRFTlNJT05fSEFTX1RPT19GRVdfSVRFTVMQ", + "GhImCiJQUklDRV9FWFRFTlNJT05fSEFTX1RPT19NQU5ZX0lURU1TEBsSFQoR", + "VU5TVVBQT1JURURfVkFMVUUQHBIqCiZVTlNVUFBPUlRFRF9WQUxVRV9JTl9T", + "RUxFQ1RFRF9MQU5HVUFHRRAdEh0KGUlOVkFMSURfREVWSUNFX1BSRUZFUkVO", + "Q0UQHhIYChRJTlZBTElEX1NDSEVEVUxFX0VORBAfEioKJkRBVEVfVElNRV9N", + "VVNUX0JFX0lOX0FDQ09VTlRfVElNRV9aT05FECASGwoXSU5WQUxJRF9TTklQ", + "UEVUU19IRUFERVIQIRInCiNDQU5OT1RfT1BFUkFURV9PTl9SRU1PVkVEX0ZF", + "RURfSVRFTRAiEjwKOFBIT05FX05VTUJFUl9OT1RfU1VQUE9SVEVEX1dJVEhf", + "Q0FMTFRSQUNLSU5HX0ZPUl9DT1VOVFJZECMSKAokQ09ORkxJQ1RJTkdfQ0FM", + "TF9DT05WRVJTSU9OX1NFVFRJTkdTECQSGwoXRVhURU5TSU9OX1RZUEVfTUlT", + "TUFUQ0gQJRIeChpFWFRFTlNJT05fU1VCVFlQRV9SRVFVSVJFRBAmEh4KGkVY", + "VEVOU0lPTl9UWVBFX1VOU1VQUE9SVEVEECcSMQotQ0FOTk9UX09QRVJBVEVf", + "T05fRkVFRF9XSVRIX01VTFRJUExFX01BUFBJTkdTECgSLgoqQ0FOTk9UX09Q", + "RVJBVEVfT05fRkVFRF9XSVRIX0tFWV9BVFRSSUJVVEVTECkSGAoUSU5WQUxJ", + "RF9QUklDRV9GT1JNQVQQKhIaChZQUk9NT1RJT05fSU5WQUxJRF9USU1FECsS", + "JQohVE9PX01BTllfREVDSU1BTF9QTEFDRVNfU1BFQ0lGSUVEECwSJAogQ09O", + "Q1JFVEVfRVhURU5TSU9OX1RZUEVfUkVRVUlSRUQQLRIgChxTQ0hFRFVMRV9F", + "TkRfTk9UX0FGVEVSX1NUQVJUEC5C9gEKImNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnNCG0V4dGVuc2lvbkZlZWRJdGVtRXJyb3JQcm90b1AB", + "WkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYz", + "XEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNi", + "BnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ExtensionFeedItemErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.ExtensionFeedItemErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.ExtensionFeedItemErrorEnum.Types.ExtensionFeedItemError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible extension feed item error. + /// + public sealed partial class ExtensionFeedItemErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExtensionFeedItemErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ExtensionFeedItemErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItemErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItemErrorEnum(ExtensionFeedItemErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItemErrorEnum Clone() { + return new ExtensionFeedItemErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExtensionFeedItemErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExtensionFeedItemErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExtensionFeedItemErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ExtensionFeedItemErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible extension feed item errors. + /// + public enum ExtensionFeedItemError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Value is not within the accepted range. + /// + [pbr::OriginalName("VALUE_OUT_OF_RANGE")] ValueOutOfRange = 2, + /// + /// Url list is too long. + /// + [pbr::OriginalName("URL_LIST_TOO_LONG")] UrlListTooLong = 3, + /// + /// Cannot have a geo targeting restriction without having geo targeting. + /// + [pbr::OriginalName("CANNOT_HAVE_RESTRICTION_ON_EMPTY_GEO_TARGETING")] CannotHaveRestrictionOnEmptyGeoTargeting = 4, + /// + /// Cannot simultaneously set sitelink field with final urls. + /// + [pbr::OriginalName("CANNOT_SET_WITH_FINAL_URLS")] CannotSetWithFinalUrls = 5, + /// + /// Must set field with final urls. + /// + [pbr::OriginalName("CANNOT_SET_WITHOUT_FINAL_URLS")] CannotSetWithoutFinalUrls = 6, + /// + /// Phone number for a call extension is invalid. + /// + [pbr::OriginalName("INVALID_PHONE_NUMBER")] InvalidPhoneNumber = 7, + /// + /// Phone number for a call extension is not supported for the given country + /// code. + /// + [pbr::OriginalName("PHONE_NUMBER_NOT_SUPPORTED_FOR_COUNTRY")] PhoneNumberNotSupportedForCountry = 8, + /// + /// A carrier specific number in short format is not allowed for call + /// extensions. + /// + [pbr::OriginalName("CARRIER_SPECIFIC_SHORT_NUMBER_NOT_ALLOWED")] CarrierSpecificShortNumberNotAllowed = 9, + /// + /// Premium rate numbers are not allowed for call extensions. + /// + [pbr::OriginalName("PREMIUM_RATE_NUMBER_NOT_ALLOWED")] PremiumRateNumberNotAllowed = 10, + /// + /// Phone number type for a call extension is not allowed. + /// For example, personal number is not allowed for a call extension in + /// most regions. + /// + [pbr::OriginalName("DISALLOWED_NUMBER_TYPE")] DisallowedNumberType = 11, + /// + /// Phone number for a call extension does not meet domestic format + /// requirements. + /// + [pbr::OriginalName("INVALID_DOMESTIC_PHONE_NUMBER_FORMAT")] InvalidDomesticPhoneNumberFormat = 12, + /// + /// Vanity phone numbers (i.e. those including letters) are not allowed for + /// call extensions. + /// + [pbr::OriginalName("VANITY_PHONE_NUMBER_NOT_ALLOWED")] VanityPhoneNumberNotAllowed = 13, + /// + /// Call conversion action provided for a call extension is invalid. + /// + [pbr::OriginalName("INVALID_CALL_CONVERSION_ACTION")] InvalidCallConversionAction = 14, + /// + /// For a call extension, the customer is not whitelisted for call tracking. + /// + [pbr::OriginalName("CUSTOMER_NOT_WHITELISTED_FOR_CALLTRACKING")] CustomerNotWhitelistedForCalltracking = 15, + /// + /// Call tracking is not supported for the given country for a call + /// extension. + /// + [pbr::OriginalName("CALLTRACKING_NOT_SUPPORTED_FOR_COUNTRY")] CalltrackingNotSupportedForCountry = 16, + /// + /// Customer hasn't consented for call recording, which is required for + /// creating/updating call feed items. Please see + /// https://support.google.com/google-ads/answer/7412639. + /// + [pbr::OriginalName("CUSTOMER_CONSENT_FOR_CALL_RECORDING_REQUIRED")] CustomerConsentForCallRecordingRequired = 17, + /// + /// App id provided for an app extension is invalid. + /// + [pbr::OriginalName("INVALID_APP_ID")] InvalidAppId = 18, + /// + /// Quotation marks present in the review text for a review extension. + /// + [pbr::OriginalName("QUOTES_IN_REVIEW_EXTENSION_SNIPPET")] QuotesInReviewExtensionSnippet = 19, + /// + /// Hyphen character present in the review text for a review extension. + /// + [pbr::OriginalName("HYPHENS_IN_REVIEW_EXTENSION_SNIPPET")] HyphensInReviewExtensionSnippet = 20, + /// + /// A blacklisted review source name or url was provided for a review + /// extension. + /// + [pbr::OriginalName("REVIEW_EXTENSION_SOURCE_INELIGIBLE")] ReviewExtensionSourceIneligible = 21, + /// + /// Review source name should not be found in the review text. + /// + [pbr::OriginalName("SOURCE_NAME_IN_REVIEW_EXTENSION_TEXT")] SourceNameInReviewExtensionText = 22, + /// + /// Inconsistent currency codes. + /// + [pbr::OriginalName("INCONSISTENT_CURRENCY_CODES")] InconsistentCurrencyCodes = 23, + /// + /// Price extension cannot have duplicated headers. + /// + [pbr::OriginalName("PRICE_EXTENSION_HAS_DUPLICATED_HEADERS")] PriceExtensionHasDuplicatedHeaders = 24, + /// + /// Price item cannot have duplicated header and description. + /// + [pbr::OriginalName("PRICE_ITEM_HAS_DUPLICATED_HEADER_AND_DESCRIPTION")] PriceItemHasDuplicatedHeaderAndDescription = 25, + /// + /// Price extension has too few items. + /// + [pbr::OriginalName("PRICE_EXTENSION_HAS_TOO_FEW_ITEMS")] PriceExtensionHasTooFewItems = 26, + /// + /// Price extension has too many items. + /// + [pbr::OriginalName("PRICE_EXTENSION_HAS_TOO_MANY_ITEMS")] PriceExtensionHasTooManyItems = 27, + /// + /// The input value is not currently supported. + /// + [pbr::OriginalName("UNSUPPORTED_VALUE")] UnsupportedValue = 28, + /// + /// The input value is not currently supported in the selected language of an + /// extension. + /// + [pbr::OriginalName("UNSUPPORTED_VALUE_IN_SELECTED_LANGUAGE")] UnsupportedValueInSelectedLanguage = 29, + /// + /// Unknown or unsupported device preference. + /// + [pbr::OriginalName("INVALID_DEVICE_PREFERENCE")] InvalidDevicePreference = 30, + /// + /// Invalid feed item schedule end time (i.e., endHour = 24 and endMinute != + /// 0). + /// + [pbr::OriginalName("INVALID_SCHEDULE_END")] InvalidScheduleEnd = 31, + /// + /// Date time zone does not match the account's time zone. + /// + [pbr::OriginalName("DATE_TIME_MUST_BE_IN_ACCOUNT_TIME_ZONE")] DateTimeMustBeInAccountTimeZone = 32, + /// + /// Invalid structured snippet header. + /// + [pbr::OriginalName("INVALID_SNIPPETS_HEADER")] InvalidSnippetsHeader = 33, + /// + /// Cannot operate on removed feed item. + /// + [pbr::OriginalName("CANNOT_OPERATE_ON_REMOVED_FEED_ITEM")] CannotOperateOnRemovedFeedItem = 34, + /// + /// Phone number not supported when call tracking enabled for country. + /// + [pbr::OriginalName("PHONE_NUMBER_NOT_SUPPORTED_WITH_CALLTRACKING_FOR_COUNTRY")] PhoneNumberNotSupportedWithCalltrackingForCountry = 35, + /// + /// Cannot set call_conversion_action while call_conversion_tracking_enabled + /// is set to true. + /// + [pbr::OriginalName("CONFLICTING_CALL_CONVERSION_SETTINGS")] ConflictingCallConversionSettings = 36, + /// + /// The type of the input extension feed item doesn't match the existing + /// extension feed item. + /// + [pbr::OriginalName("EXTENSION_TYPE_MISMATCH")] ExtensionTypeMismatch = 37, + /// + /// The oneof field extension i.e. subtype of extension feed item is + /// required. + /// + [pbr::OriginalName("EXTENSION_SUBTYPE_REQUIRED")] ExtensionSubtypeRequired = 38, + /// + /// The referenced feed item is not mapped to a supported extension type. + /// + [pbr::OriginalName("EXTENSION_TYPE_UNSUPPORTED")] ExtensionTypeUnsupported = 39, + /// + /// Cannot operate on a Feed with more than one active FeedMapping. + /// + [pbr::OriginalName("CANNOT_OPERATE_ON_FEED_WITH_MULTIPLE_MAPPINGS")] CannotOperateOnFeedWithMultipleMappings = 40, + /// + /// Cannot operate on a Feed that has key attributes. + /// + [pbr::OriginalName("CANNOT_OPERATE_ON_FEED_WITH_KEY_ATTRIBUTES")] CannotOperateOnFeedWithKeyAttributes = 41, + /// + /// Input price is not in a valid format. + /// + [pbr::OriginalName("INVALID_PRICE_FORMAT")] InvalidPriceFormat = 42, + /// + /// The promotion time is invalid. + /// + [pbr::OriginalName("PROMOTION_INVALID_TIME")] PromotionInvalidTime = 43, + /// + /// This field has too many decimal places specified. + /// + [pbr::OriginalName("TOO_MANY_DECIMAL_PLACES_SPECIFIED")] TooManyDecimalPlacesSpecified = 44, + /// + /// Concrete sub type of ExtensionFeedItem is required for this operation. + /// + [pbr::OriginalName("CONCRETE_EXTENSION_TYPE_REQUIRED")] ConcreteExtensionTypeRequired = 45, + /// + /// Feed item schedule end time must be after start time. + /// + [pbr::OriginalName("SCHEDULE_END_NOT_AFTER_START")] ScheduleEndNotAfterStart = 46, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExtensionFeedItemService.cs b/src/V3/Stubs/ExtensionFeedItemService.cs new file mode 100644 index 000000000..0c4811689 --- /dev/null +++ b/src/V3/Stubs/ExtensionFeedItemService.cs @@ -0,0 +1,1038 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/extension_feed_item_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/extension_feed_item_service.proto + public static partial class ExtensionFeedItemServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/extension_feed_item_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExtensionFeedItemServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9leHRlbnNpb25f", + "ZmVlZF9pdGVtX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvZXh0ZW5zaW9uX2ZlZWRfaXRlbS5wcm90bxocZ29vZ2xlL2FwaS9hbm5v", + "dGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2ds", + "ZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aIGdvb2dsZS9wcm90b2J1Zi9m", + "aWVsZF9tYXNrLnByb3RvGhdnb29nbGUvcnBjL3N0YXR1cy5wcm90byI5ChtH", + "ZXRFeHRlbnNpb25GZWVkSXRlbVJlcXVlc3QSGgoNcmVzb3VyY2VfbmFtZRgB", + "IAEoCUID4EECIsIBCh9NdXRhdGVFeHRlbnNpb25GZWVkSXRlbXNSZXF1ZXN0", + "EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPgQQISVQoKb3BlcmF0aW9ucxgCIAMo", + "CzI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkV4dGVuc2lv", + "bkZlZWRJdGVtT3BlcmF0aW9uQgPgQQISFwoPcGFydGlhbF9mYWlsdXJlGAMg", + "ASgIEhUKDXZhbGlkYXRlX29ubHkYBCABKAgi/AEKGkV4dGVuc2lvbkZlZWRJ", + "dGVtT3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAQgASgLMhouZ29vZ2xlLnBy", + "b3RvYnVmLkZpZWxkTWFzaxJGCgZjcmVhdGUYASABKAsyNC5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuRXh0ZW5zaW9uRmVlZEl0ZW1IABJG", + "CgZ1cGRhdGUYAiABKAsyNC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNv", + "dXJjZXMuRXh0ZW5zaW9uRmVlZEl0ZW1IABIQCgZyZW1vdmUYAyABKAlIAEIL", + "CglvcGVyYXRpb24ipwEKIE11dGF0ZUV4dGVuc2lvbkZlZWRJdGVtc1Jlc3Bv", + "bnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJvchgDIAEoCzISLmdvb2dsZS5y", + "cGMuU3RhdHVzElAKB3Jlc3VsdHMYAiADKAsyPy5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVFeHRlbnNpb25GZWVkSXRlbVJlc3Vs", + "dCI2Ch1NdXRhdGVFeHRlbnNpb25GZWVkSXRlbVJlc3VsdBIVCg1yZXNvdXJj", + "ZV9uYW1lGAEgASgJMpQEChhFeHRlbnNpb25GZWVkSXRlbVNlcnZpY2US2QEK", + "FEdldEV4dGVuc2lvbkZlZWRJdGVtEj0uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMuR2V0RXh0ZW5zaW9uRmVlZEl0ZW1SZXF1ZXN0GjQuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkV4dGVuc2lvbkZlZWRJ", + "dGVtIkyC0+STAjYSNC92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9l", + "eHRlbnNpb25GZWVkSXRlbXMvKn3aQQ1yZXNvdXJjZV9uYW1lEv4BChhNdXRh", + "dGVFeHRlbnNpb25GZWVkSXRlbXMSQS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5NdXRhdGVFeHRlbnNpb25GZWVkSXRlbXNSZXF1ZXN0GkIu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlRXh0ZW5z", + "aW9uRmVlZEl0ZW1zUmVzcG9uc2UiW4LT5JMCPCI3L3YzL2N1c3RvbWVycy97", + "Y3VzdG9tZXJfaWQ9Kn0vZXh0ZW5zaW9uRmVlZEl0ZW1zOm11dGF0ZToBKtpB", + "FmN1c3RvbWVyX2lkLG9wZXJhdGlvbnMaG8pBGGdvb2dsZWFkcy5nb29nbGVh", + "cGlzLmNvbUKEAgokY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzQh1FeHRlbnNpb25GZWVkSXRlbVNlcnZpY2VQcm90b1ABWkhnb29nbGUu", + "Z29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMv", + "djMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdvb2ds", + "ZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNl", + "cnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZpY2Vz", + "YgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItemReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetExtensionFeedItemRequest), global::Google.Ads.GoogleAds.V3.Services.GetExtensionFeedItemRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemOperation), global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemResult), global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [ExtensionFeedItemService.GetExtensionFeedItem][google.ads.googleads.v3.services.ExtensionFeedItemService.GetExtensionFeedItem]. + /// + public sealed partial class GetExtensionFeedItemRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetExtensionFeedItemRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetExtensionFeedItemRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetExtensionFeedItemRequest(GetExtensionFeedItemRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetExtensionFeedItemRequest Clone() { + return new GetExtensionFeedItemRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the extension feed item to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetExtensionFeedItemRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetExtensionFeedItemRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetExtensionFeedItemRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [ExtensionFeedItemService.MutateExtensionFeedItems][google.ads.googleads.v3.services.ExtensionFeedItemService.MutateExtensionFeedItems]. + /// + public sealed partial class MutateExtensionFeedItemsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateExtensionFeedItemsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemsRequest(MutateExtensionFeedItemsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemsRequest Clone() { + return new MutateExtensionFeedItemsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose extension feed items are being + /// modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual extension feed items. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateExtensionFeedItemsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateExtensionFeedItemsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateExtensionFeedItemsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on an extension feed item. + /// + public sealed partial class ExtensionFeedItemOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExtensionFeedItemOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItemOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItemOperation(ExtensionFeedItemOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionFeedItemOperation Clone() { + return new ExtensionFeedItemOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new extension + /// feed item. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The extension feed item is expected to have a + /// valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed extension feed item + /// is expected, in this format: + /// + /// `customers/{customer_id}/extensionFeedItems/{feed_item_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExtensionFeedItemOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExtensionFeedItemOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExtensionFeedItemOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for an extension feed item mutate. + /// + public sealed partial class MutateExtensionFeedItemsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateExtensionFeedItemsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemsResponse(MutateExtensionFeedItemsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemsResponse Clone() { + return new MutateExtensionFeedItemsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateExtensionFeedItemsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateExtensionFeedItemsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateExtensionFeedItemsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the extension feed item mutate. + /// + public sealed partial class MutateExtensionFeedItemResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateExtensionFeedItemResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemResult(MutateExtensionFeedItemResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateExtensionFeedItemResult Clone() { + return new MutateExtensionFeedItemResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateExtensionFeedItemResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateExtensionFeedItemResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateExtensionFeedItemResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExtensionFeedItemServiceClient.cs b/src/V3/Stubs/ExtensionFeedItemServiceClient.cs new file mode 100644 index 000000000..7b2fbbb13 --- /dev/null +++ b/src/V3/Stubs/ExtensionFeedItemServiceClient.cs @@ -0,0 +1,904 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class ExtensionFeedItemServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static ExtensionFeedItemServiceSettings GetDefault() => new ExtensionFeedItemServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public ExtensionFeedItemServiceSettings() { } + + private ExtensionFeedItemServiceSettings(ExtensionFeedItemServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetExtensionFeedItemSettings = existing.GetExtensionFeedItemSettings; + MutateExtensionFeedItemsSettings = existing.MutateExtensionFeedItemsSettings; + OnCopy(existing); + } + + partial void OnCopy(ExtensionFeedItemServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// ExtensionFeedItemServiceClient.GetExtensionFeedItem and ExtensionFeedItemServiceClient.GetExtensionFeedItemAsync. + /// + /// + /// The default ExtensionFeedItemServiceClient.GetExtensionFeedItem and + /// ExtensionFeedItemServiceClient.GetExtensionFeedItemAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetExtensionFeedItemSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// ExtensionFeedItemServiceClient.MutateExtensionFeedItems and ExtensionFeedItemServiceClient.MutateExtensionFeedItemsAsync. + /// + /// + /// The default ExtensionFeedItemServiceClient.MutateExtensionFeedItems and + /// ExtensionFeedItemServiceClient.MutateExtensionFeedItemsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateExtensionFeedItemsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public ExtensionFeedItemServiceSettings Clone() => new ExtensionFeedItemServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class ExtensionFeedItemServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public ExtensionFeedItemServiceSettings Settings { get; set; } + + /// + public override ExtensionFeedItemServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return ExtensionFeedItemServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return ExtensionFeedItemServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => ExtensionFeedItemServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => ExtensionFeedItemServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => ExtensionFeedItemServiceClient.ChannelPool; + } + + /// + /// ExtensionFeedItemService client wrapper, for convenient use. + /// + public abstract partial class ExtensionFeedItemServiceClient + { + /// + /// The default endpoint for the ExtensionFeedItemService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default ExtensionFeedItemService scopes. + /// + /// + /// The default ExtensionFeedItemService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ExtensionFeedItemServiceClient client = await ExtensionFeedItemServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ExtensionFeedItemServiceClient.DefaultEndpoint.Host, ExtensionFeedItemServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ExtensionFeedItemServiceClient client = ExtensionFeedItemServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, ExtensionFeedItemServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// ExtensionFeedItemServiceClient client = ExtensionFeedItemServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// ExtensionFeedItemServiceClient.DefaultEndpoint.Host, ExtensionFeedItemServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// ExtensionFeedItemServiceClient client = ExtensionFeedItemServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static ExtensionFeedItemServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, ExtensionFeedItemServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ExtensionFeedItemServiceClient Create(grpccore::Channel channel, ExtensionFeedItemServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static ExtensionFeedItemServiceClient Create(grpccore::CallInvoker callInvoker, ExtensionFeedItemServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + ExtensionFeedItemService.ExtensionFeedItemServiceClient grpcClient = new ExtensionFeedItemService.ExtensionFeedItemServiceClient(callInvoker); + return new ExtensionFeedItemServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC ExtensionFeedItemService client. + /// + public virtual ExtensionFeedItemService.ExtensionFeedItemServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested extension feed item in full detail. + /// + /// + /// Required. The resource name of the extension feed item to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetExtensionFeedItemAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetExtensionFeedItemAsync( + new GetExtensionFeedItemRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested extension feed item in full detail. + /// + /// + /// Required. The resource name of the extension feed item to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetExtensionFeedItemAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetExtensionFeedItemAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested extension feed item in full detail. + /// + /// + /// Required. The resource name of the extension feed item to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ExtensionFeedItem GetExtensionFeedItem( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetExtensionFeedItem( + new GetExtensionFeedItemRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested extension feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetExtensionFeedItemAsync( + GetExtensionFeedItemRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested extension feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetExtensionFeedItemAsync( + GetExtensionFeedItemRequest request, + st::CancellationToken cancellationToken) => GetExtensionFeedItemAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested extension feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::ExtensionFeedItem GetExtensionFeedItem( + GetExtensionFeedItemRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose extension feed items are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual extension feed items. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateExtensionFeedItemsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateExtensionFeedItemsAsync( + new MutateExtensionFeedItemsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose extension feed items are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual extension feed items. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateExtensionFeedItemsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateExtensionFeedItemsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose extension feed items are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual extension feed items. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateExtensionFeedItemsResponse MutateExtensionFeedItems( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateExtensionFeedItems( + new MutateExtensionFeedItemsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose extension feed items are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual extension feed items. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateExtensionFeedItemsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateExtensionFeedItemsAsync( + new MutateExtensionFeedItemsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose extension feed items are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual extension feed items. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateExtensionFeedItemsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateExtensionFeedItemsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose extension feed items are being + /// modified. + /// + /// + /// Required. The list of operations to perform on individual extension feed items. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateExtensionFeedItemsResponse MutateExtensionFeedItems( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateExtensionFeedItems( + new MutateExtensionFeedItemsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateExtensionFeedItemsAsync( + MutateExtensionFeedItemsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateExtensionFeedItemsAsync( + MutateExtensionFeedItemsRequest request, + st::CancellationToken cancellationToken) => MutateExtensionFeedItemsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateExtensionFeedItemsResponse MutateExtensionFeedItems( + MutateExtensionFeedItemsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// ExtensionFeedItemService client wrapper implementation, for convenient use. + /// + public sealed partial class ExtensionFeedItemServiceClientImpl : ExtensionFeedItemServiceClient + { + private readonly gaxgrpc::ApiCall _callGetExtensionFeedItem; + private readonly gaxgrpc::ApiCall _callMutateExtensionFeedItems; + + /// + /// Constructs a client wrapper for the ExtensionFeedItemService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public ExtensionFeedItemServiceClientImpl(ExtensionFeedItemService.ExtensionFeedItemServiceClient grpcClient, ExtensionFeedItemServiceSettings settings) + { + GrpcClient = grpcClient; + ExtensionFeedItemServiceSettings effectiveSettings = settings ?? ExtensionFeedItemServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetExtensionFeedItem = clientHelper.BuildApiCall( + GrpcClient.GetExtensionFeedItemAsync, GrpcClient.GetExtensionFeedItem, effectiveSettings.GetExtensionFeedItemSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateExtensionFeedItems = clientHelper.BuildApiCall( + GrpcClient.MutateExtensionFeedItemsAsync, GrpcClient.MutateExtensionFeedItems, effectiveSettings.MutateExtensionFeedItemsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetExtensionFeedItem); + Modify_GetExtensionFeedItemApiCall(ref _callGetExtensionFeedItem); + Modify_ApiCall(ref _callMutateExtensionFeedItems); + Modify_MutateExtensionFeedItemsApiCall(ref _callMutateExtensionFeedItems); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetExtensionFeedItemApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateExtensionFeedItemsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(ExtensionFeedItemService.ExtensionFeedItemServiceClient grpcClient, ExtensionFeedItemServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC ExtensionFeedItemService client. + /// + public override ExtensionFeedItemService.ExtensionFeedItemServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetExtensionFeedItemRequest(ref GetExtensionFeedItemRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateExtensionFeedItemsRequest(ref MutateExtensionFeedItemsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested extension feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetExtensionFeedItemAsync( + GetExtensionFeedItemRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetExtensionFeedItemRequest(ref request, ref callSettings); + return _callGetExtensionFeedItem.Async(request, callSettings); + } + + /// + /// Returns the requested extension feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::ExtensionFeedItem GetExtensionFeedItem( + GetExtensionFeedItemRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetExtensionFeedItemRequest(ref request, ref callSettings); + return _callGetExtensionFeedItem.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateExtensionFeedItemsAsync( + MutateExtensionFeedItemsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateExtensionFeedItemsRequest(ref request, ref callSettings); + return _callMutateExtensionFeedItems.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateExtensionFeedItemsResponse MutateExtensionFeedItems( + MutateExtensionFeedItemsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateExtensionFeedItemsRequest(ref request, ref callSettings); + return _callMutateExtensionFeedItems.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/ExtensionFeedItemServiceGrpc.cs b/src/V3/Stubs/ExtensionFeedItemServiceGrpc.cs new file mode 100644 index 000000000..22c9fd7ec --- /dev/null +++ b/src/V3/Stubs/ExtensionFeedItemServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/extension_feed_item_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage extension feed items. + /// + public static partial class ExtensionFeedItemService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.ExtensionFeedItemService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetExtensionFeedItemRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetExtensionFeedItemRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_ExtensionFeedItem = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateExtensionFeedItemsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateExtensionFeedItemsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetExtensionFeedItem = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetExtensionFeedItem", + __Marshaller_google_ads_googleads_v3_services_GetExtensionFeedItemRequest, + __Marshaller_google_ads_googleads_v3_resources_ExtensionFeedItem); + + static readonly grpc::Method __Method_MutateExtensionFeedItems = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateExtensionFeedItems", + __Marshaller_google_ads_googleads_v3_services_MutateExtensionFeedItemsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateExtensionFeedItemsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of ExtensionFeedItemService + public abstract partial class ExtensionFeedItemServiceBase + { + /// + /// Returns the requested extension feed item in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetExtensionFeedItem(global::Google.Ads.GoogleAds.V3.Services.GetExtensionFeedItemRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateExtensionFeedItems(global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for ExtensionFeedItemService + public partial class ExtensionFeedItemServiceClient : grpc::ClientBase + { + /// Creates a new client for ExtensionFeedItemService + /// The channel to use to make remote calls. + public ExtensionFeedItemServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for ExtensionFeedItemService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public ExtensionFeedItemServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected ExtensionFeedItemServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected ExtensionFeedItemServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested extension feed item in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem GetExtensionFeedItem(global::Google.Ads.GoogleAds.V3.Services.GetExtensionFeedItemRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetExtensionFeedItem(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested extension feed item in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem GetExtensionFeedItem(global::Google.Ads.GoogleAds.V3.Services.GetExtensionFeedItemRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetExtensionFeedItem, null, options, request); + } + /// + /// Returns the requested extension feed item in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetExtensionFeedItemAsync(global::Google.Ads.GoogleAds.V3.Services.GetExtensionFeedItemRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetExtensionFeedItemAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested extension feed item in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetExtensionFeedItemAsync(global::Google.Ads.GoogleAds.V3.Services.GetExtensionFeedItemRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetExtensionFeedItem, null, options, request); + } + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsResponse MutateExtensionFeedItems(global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateExtensionFeedItems(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsResponse MutateExtensionFeedItems(global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateExtensionFeedItems, null, options, request); + } + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateExtensionFeedItemsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateExtensionFeedItemsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes extension feed items. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateExtensionFeedItemsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateExtensionFeedItems, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override ExtensionFeedItemServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new ExtensionFeedItemServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(ExtensionFeedItemServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetExtensionFeedItem, serviceImpl.GetExtensionFeedItem) + .AddMethod(__Method_MutateExtensionFeedItems, serviceImpl.MutateExtensionFeedItems).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, ExtensionFeedItemServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetExtensionFeedItem, serviceImpl.GetExtensionFeedItem); + serviceBinder.AddMethod(__Method_MutateExtensionFeedItems, serviceImpl.MutateExtensionFeedItems); + } + + } +} +#endregion diff --git a/src/V3/Stubs/ExtensionSettingDevice.cs b/src/V3/Stubs/ExtensionSettingDevice.cs new file mode 100644 index 000000000..967bd7af6 --- /dev/null +++ b/src/V3/Stubs/ExtensionSettingDevice.cs @@ -0,0 +1,187 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/extension_setting_device.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/extension_setting_device.proto + public static partial class ExtensionSettingDeviceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/extension_setting_device.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExtensionSettingDeviceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9leHRlbnNpb25fc2V0", + "dGluZ19kZXZpY2UucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIm0KGkV4dGVuc2lv", + "blNldHRpbmdEZXZpY2VFbnVtIk8KFkV4dGVuc2lvblNldHRpbmdEZXZpY2US", + "DwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESCgoGTU9CSUxFEAISCwoH", + "REVTS1RPUBADQvABCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXNCG0V4dGVuc2lvblNldHRpbmdEZXZpY2VQcm90b1ABWkJnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "ZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5F", + "bnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xl", + "OjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum), global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceEnum.Types.ExtensionSettingDevice) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing extension setting device types. + /// + public sealed partial class ExtensionSettingDeviceEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExtensionSettingDeviceEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ExtensionSettingDeviceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionSettingDeviceEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionSettingDeviceEnum(ExtensionSettingDeviceEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionSettingDeviceEnum Clone() { + return new ExtensionSettingDeviceEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExtensionSettingDeviceEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExtensionSettingDeviceEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExtensionSettingDeviceEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ExtensionSettingDeviceEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possbile device types for an extension setting. + /// + public enum ExtensionSettingDevice { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Mobile. The extensions in the extension setting will only serve on + /// mobile devices. + /// + [pbr::OriginalName("MOBILE")] Mobile = 2, + /// + /// Desktop. The extensions in the extension setting will only serve on + /// desktop devices. + /// + [pbr::OriginalName("DESKTOP")] Desktop = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExtensionSettingError.cs b/src/V3/Stubs/ExtensionSettingError.cs new file mode 100644 index 000000000..7c5e21e48 --- /dev/null +++ b/src/V3/Stubs/ExtensionSettingError.cs @@ -0,0 +1,509 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/extension_setting_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/extension_setting_error.proto + public static partial class ExtensionSettingErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/extension_setting_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExtensionSettingErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZXh0ZW5zaW9uX3Nl", + "dHRpbmdfZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKYFAoZRXh0ZW5z", + "aW9uU2V0dGluZ0Vycm9yRW51bSL6EwoVRXh0ZW5zaW9uU2V0dGluZ0Vycm9y", + "Eg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhcKE0VYVEVOU0lPTlNf", + "UkVRVUlSRUQQAhIlCiFGRUVEX1RZUEVfRVhURU5TSU9OX1RZUEVfTUlTTUFU", + "Q0gQAxIVChFJTlZBTElEX0ZFRURfVFlQRRAEEjQKMElOVkFMSURfRkVFRF9U", + "WVBFX0ZPUl9DVVNUT01FUl9FWFRFTlNJT05fU0VUVElORxAFEiUKIUNBTk5P", + "VF9DSEFOR0VfRkVFRF9JVEVNX09OX0NSRUFURRAGEikKJUNBTk5PVF9VUERB", + "VEVfTkVXTFlfQ1JFQVRFRF9FWFRFTlNJT04QBxIzCi9OT19FWElTVElOR19B", + "RF9HUk9VUF9FWFRFTlNJT05fU0VUVElOR19GT1JfVFlQRRAIEjMKL05PX0VY", + "SVNUSU5HX0NBTVBBSUdOX0VYVEVOU0lPTl9TRVRUSU5HX0ZPUl9UWVBFEAkS", + "MwovTk9fRVhJU1RJTkdfQ1VTVE9NRVJfRVhURU5TSU9OX1NFVFRJTkdfRk9S", + "X1RZUEUQChItCilBRF9HUk9VUF9FWFRFTlNJT05fU0VUVElOR19BTFJFQURZ", + "X0VYSVNUUxALEi0KKUNBTVBBSUdOX0VYVEVOU0lPTl9TRVRUSU5HX0FMUkVB", + "RFlfRVhJU1RTEAwSLQopQ1VTVE9NRVJfRVhURU5TSU9OX1NFVFRJTkdfQUxS", + "RUFEWV9FWElTVFMQDRI1CjFBRF9HUk9VUF9GRUVEX0FMUkVBRFlfRVhJU1RT", + "X0ZPUl9QTEFDRUhPTERFUl9UWVBFEA4SNQoxQ0FNUEFJR05fRkVFRF9BTFJF", + "QURZX0VYSVNUU19GT1JfUExBQ0VIT0xERVJfVFlQRRAPEjUKMUNVU1RPTUVS", + "X0ZFRURfQUxSRUFEWV9FWElTVFNfRk9SX1BMQUNFSE9MREVSX1RZUEUQEBIW", + "ChJWQUxVRV9PVVRfT0ZfUkFOR0UQERIkCiBDQU5OT1RfU0VUX0ZJRUxEX1dJ", + "VEhfRklOQUxfVVJMUxASEhYKEkZJTkFMX1VSTFNfTk9UX1NFVBATEhgKFElO", + "VkFMSURfUEhPTkVfTlVNQkVSEBQSKgomUEhPTkVfTlVNQkVSX05PVF9TVVBQ", + "T1JURURfRk9SX0NPVU5UUlkQFRItCilDQVJSSUVSX1NQRUNJRklDX1NIT1JU", + "X05VTUJFUl9OT1RfQUxMT1dFRBAWEiMKH1BSRU1JVU1fUkFURV9OVU1CRVJf", + "Tk9UX0FMTE9XRUQQFxIaChZESVNBTExPV0VEX05VTUJFUl9UWVBFEBgSKAok", + "SU5WQUxJRF9ET01FU1RJQ19QSE9ORV9OVU1CRVJfRk9STUFUEBkSIwofVkFO", + "SVRZX1BIT05FX05VTUJFUl9OT1RfQUxMT1dFRBAaEhgKFElOVkFMSURfQ09V", + "TlRSWV9DT0RFEBsSIwofSU5WQUxJRF9DQUxMX0NPTlZFUlNJT05fVFlQRV9J", + "RBAcEi0KKUNVU1RPTUVSX05PVF9XSElURUxJU1RFRF9GT1JfQ0FMTFRSQUNL", + "SU5HEB0SKgomQ0FMTFRSQUNLSU5HX05PVF9TVVBQT1JURURfRk9SX0NPVU5U", + "UlkQHhISCg5JTlZBTElEX0FQUF9JRBAfEiYKIlFVT1RFU19JTl9SRVZJRVdf", + "RVhURU5TSU9OX1NOSVBQRVQQIBInCiNIWVBIRU5TX0lOX1JFVklFV19FWFRF", + "TlNJT05fU05JUFBFVBAhEigKJFJFVklFV19FWFRFTlNJT05fU09VUkNFX05P", + "VF9FTElHSUJMRRAiEigKJFNPVVJDRV9OQU1FX0lOX1JFVklFV19FWFRFTlNJ", + "T05fVEVYVBAjEhEKDU1JU1NJTkdfRklFTEQQJBIfChtJTkNPTlNJU1RFTlRf", + "Q1VSUkVOQ1lfQ09ERVMQJRIqCiZQUklDRV9FWFRFTlNJT05fSEFTX0RVUExJ", + "Q0FURURfSEVBREVSUxAmEjQKMFBSSUNFX0lURU1fSEFTX0RVUExJQ0FURURf", + "SEVBREVSX0FORF9ERVNDUklQVElPThAnEiUKIVBSSUNFX0VYVEVOU0lPTl9I", + "QVNfVE9PX0ZFV19JVEVNUxAoEiYKIlBSSUNFX0VYVEVOU0lPTl9IQVNfVE9P", + "X01BTllfSVRFTVMQKRIVChFVTlNVUFBPUlRFRF9WQUxVRRAqEh0KGUlOVkFM", + "SURfREVWSUNFX1BSRUZFUkVOQ0UQKxIYChRJTlZBTElEX1NDSEVEVUxFX0VO", + "RBAtEioKJkRBVEVfVElNRV9NVVNUX0JFX0lOX0FDQ09VTlRfVElNRV9aT05F", + "EC8SJQohT1ZFUkxBUFBJTkdfU0NIRURVTEVTX05PVF9BTExPV0VEEDASIAoc", + "U0NIRURVTEVfRU5EX05PVF9BRlRFUl9TVEFSVBAxEh4KGlRPT19NQU5ZX1ND", + "SEVEVUxFU19QRVJfREFZEDISJgoiRFVQTElDQVRFX0VYVEVOU0lPTl9GRUVE", + "X0lURU1fRURJVBAzEhsKF0lOVkFMSURfU05JUFBFVFNfSEVBREVSEDQSPAo4", + "UEhPTkVfTlVNQkVSX05PVF9TVVBQT1JURURfV0lUSF9DQUxMVFJBQ0tJTkdf", + "Rk9SX0NPVU5UUlkQNRIfChtDQU1QQUlHTl9UQVJHRVRJTkdfTUlTTUFUQ0gQ", + "NhIiCh5DQU5OT1RfT1BFUkFURV9PTl9SRU1PVkVEX0ZFRUQQNxIbChdFWFRF", + "TlNJT05fVFlQRV9SRVFVSVJFRBA4Ei0KKUlOQ09NUEFUSUJMRV9VTkRFUkxZ", + "SU5HX01BVENISU5HX0ZVTkNUSU9OEDkSHQoZU1RBUlRfREFURV9BRlRFUl9F", + "TkRfREFURRA6EhgKFElOVkFMSURfUFJJQ0VfRk9STUFUEDsSGgoWUFJPTU9U", + "SU9OX0lOVkFMSURfVElNRRA8EjwKOFBST01PVElPTl9DQU5OT1RfU0VUX1BF", + "UkNFTlRfRElTQ09VTlRfQU5EX01PTkVZX0RJU0NPVU5UED0SPgo6UFJPTU9U", + "SU9OX0NBTk5PVF9TRVRfUFJPTU9USU9OX0NPREVfQU5EX09SREVSU19PVkVS", + "X0FNT1VOVBA+EiUKIVRPT19NQU5ZX0RFQ0lNQUxfUExBQ0VTX1NQRUNJRklF", + "RBA/EhkKFUlOVkFMSURfTEFOR1VBR0VfQ09ERRBAEhgKFFVOU1VQUE9SVEVE", + "X0xBTkdVQUdFEEESMAosQ1VTVE9NRVJfQ09OU0VOVF9GT1JfQ0FMTF9SRUNP", + "UkRJTkdfUkVRVUlSRUQQQhImCiJFWFRFTlNJT05fU0VUVElOR19VUERBVEVf", + "SVNfQV9OT09QEENC9QEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnNCGkV4dGVuc2lvblNldHRpbmdFcnJvclByb3RvUAFaRGdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9lcnJvcnM7ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMu", + "VjMuRXJyb3JzygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIi", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ExtensionSettingErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.ExtensionSettingErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.ExtensionSettingErrorEnum.Types.ExtensionSettingError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing validation errors of extension settings. + /// + public sealed partial class ExtensionSettingErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExtensionSettingErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ExtensionSettingErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionSettingErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionSettingErrorEnum(ExtensionSettingErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionSettingErrorEnum Clone() { + return new ExtensionSettingErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExtensionSettingErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExtensionSettingErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExtensionSettingErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ExtensionSettingErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible extension setting errors. + /// + public enum ExtensionSettingError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// A platform restriction was provided without input extensions or existing + /// extensions. + /// + [pbr::OriginalName("EXTENSIONS_REQUIRED")] ExtensionsRequired = 2, + /// + /// The provided feed type does not correspond to the provided extensions. + /// + [pbr::OriginalName("FEED_TYPE_EXTENSION_TYPE_MISMATCH")] FeedTypeExtensionTypeMismatch = 3, + /// + /// The provided feed type cannot be used. + /// + [pbr::OriginalName("INVALID_FEED_TYPE")] InvalidFeedType = 4, + /// + /// The provided feed type cannot be used at the customer level. + /// + [pbr::OriginalName("INVALID_FEED_TYPE_FOR_CUSTOMER_EXTENSION_SETTING")] InvalidFeedTypeForCustomerExtensionSetting = 5, + /// + /// Cannot change a feed item field on a CREATE operation. + /// + [pbr::OriginalName("CANNOT_CHANGE_FEED_ITEM_ON_CREATE")] CannotChangeFeedItemOnCreate = 6, + /// + /// Cannot update an extension that is not already in this setting. + /// + [pbr::OriginalName("CANNOT_UPDATE_NEWLY_CREATED_EXTENSION")] CannotUpdateNewlyCreatedExtension = 7, + /// + /// There is no existing AdGroupExtensionSetting for this type. + /// + [pbr::OriginalName("NO_EXISTING_AD_GROUP_EXTENSION_SETTING_FOR_TYPE")] NoExistingAdGroupExtensionSettingForType = 8, + /// + /// There is no existing CampaignExtensionSetting for this type. + /// + [pbr::OriginalName("NO_EXISTING_CAMPAIGN_EXTENSION_SETTING_FOR_TYPE")] NoExistingCampaignExtensionSettingForType = 9, + /// + /// There is no existing CustomerExtensionSetting for this type. + /// + [pbr::OriginalName("NO_EXISTING_CUSTOMER_EXTENSION_SETTING_FOR_TYPE")] NoExistingCustomerExtensionSettingForType = 10, + /// + /// The AdGroupExtensionSetting already exists. UPDATE should be used to + /// modify the existing AdGroupExtensionSetting. + /// + [pbr::OriginalName("AD_GROUP_EXTENSION_SETTING_ALREADY_EXISTS")] AdGroupExtensionSettingAlreadyExists = 11, + /// + /// The CampaignExtensionSetting already exists. UPDATE should be used to + /// modify the existing CampaignExtensionSetting. + /// + [pbr::OriginalName("CAMPAIGN_EXTENSION_SETTING_ALREADY_EXISTS")] CampaignExtensionSettingAlreadyExists = 12, + /// + /// The CustomerExtensionSetting already exists. UPDATE should be used to + /// modify the existing CustomerExtensionSetting. + /// + [pbr::OriginalName("CUSTOMER_EXTENSION_SETTING_ALREADY_EXISTS")] CustomerExtensionSettingAlreadyExists = 13, + /// + /// An active ad group feed already exists for this place holder type. + /// + [pbr::OriginalName("AD_GROUP_FEED_ALREADY_EXISTS_FOR_PLACEHOLDER_TYPE")] AdGroupFeedAlreadyExistsForPlaceholderType = 14, + /// + /// An active campaign feed already exists for this place holder type. + /// + [pbr::OriginalName("CAMPAIGN_FEED_ALREADY_EXISTS_FOR_PLACEHOLDER_TYPE")] CampaignFeedAlreadyExistsForPlaceholderType = 15, + /// + /// An active customer feed already exists for this place holder type. + /// + [pbr::OriginalName("CUSTOMER_FEED_ALREADY_EXISTS_FOR_PLACEHOLDER_TYPE")] CustomerFeedAlreadyExistsForPlaceholderType = 16, + /// + /// Value is not within the accepted range. + /// + [pbr::OriginalName("VALUE_OUT_OF_RANGE")] ValueOutOfRange = 17, + /// + /// Cannot simultaneously set specified field with final urls. + /// + [pbr::OriginalName("CANNOT_SET_FIELD_WITH_FINAL_URLS")] CannotSetFieldWithFinalUrls = 18, + /// + /// Must set field with final urls. + /// + [pbr::OriginalName("FINAL_URLS_NOT_SET")] FinalUrlsNotSet = 19, + /// + /// Phone number for a call extension is invalid. + /// + [pbr::OriginalName("INVALID_PHONE_NUMBER")] InvalidPhoneNumber = 20, + /// + /// Phone number for a call extension is not supported for the given country + /// code. + /// + [pbr::OriginalName("PHONE_NUMBER_NOT_SUPPORTED_FOR_COUNTRY")] PhoneNumberNotSupportedForCountry = 21, + /// + /// A carrier specific number in short format is not allowed for call + /// extensions. + /// + [pbr::OriginalName("CARRIER_SPECIFIC_SHORT_NUMBER_NOT_ALLOWED")] CarrierSpecificShortNumberNotAllowed = 22, + /// + /// Premium rate numbers are not allowed for call extensions. + /// + [pbr::OriginalName("PREMIUM_RATE_NUMBER_NOT_ALLOWED")] PremiumRateNumberNotAllowed = 23, + /// + /// Phone number type for a call extension is not allowed. + /// + [pbr::OriginalName("DISALLOWED_NUMBER_TYPE")] DisallowedNumberType = 24, + /// + /// Phone number for a call extension does not meet domestic format + /// requirements. + /// + [pbr::OriginalName("INVALID_DOMESTIC_PHONE_NUMBER_FORMAT")] InvalidDomesticPhoneNumberFormat = 25, + /// + /// Vanity phone numbers (i.e. those including letters) are not allowed for + /// call extensions. + /// + [pbr::OriginalName("VANITY_PHONE_NUMBER_NOT_ALLOWED")] VanityPhoneNumberNotAllowed = 26, + /// + /// Country code provided for a call extension is invalid. + /// + [pbr::OriginalName("INVALID_COUNTRY_CODE")] InvalidCountryCode = 27, + /// + /// Call conversion type id provided for a call extension is invalid. + /// + [pbr::OriginalName("INVALID_CALL_CONVERSION_TYPE_ID")] InvalidCallConversionTypeId = 28, + /// + /// For a call extension, the customer is not whitelisted for call tracking. + /// + [pbr::OriginalName("CUSTOMER_NOT_WHITELISTED_FOR_CALLTRACKING")] CustomerNotWhitelistedForCalltracking = 29, + /// + /// Call tracking is not supported for the given country for a call + /// extension. + /// + [pbr::OriginalName("CALLTRACKING_NOT_SUPPORTED_FOR_COUNTRY")] CalltrackingNotSupportedForCountry = 30, + /// + /// App id provided for an app extension is invalid. + /// + [pbr::OriginalName("INVALID_APP_ID")] InvalidAppId = 31, + /// + /// Quotation marks present in the review text for a review extension. + /// + [pbr::OriginalName("QUOTES_IN_REVIEW_EXTENSION_SNIPPET")] QuotesInReviewExtensionSnippet = 32, + /// + /// Hyphen character present in the review text for a review extension. + /// + [pbr::OriginalName("HYPHENS_IN_REVIEW_EXTENSION_SNIPPET")] HyphensInReviewExtensionSnippet = 33, + /// + /// A blacklisted review source name or url was provided for a review + /// extension. + /// + [pbr::OriginalName("REVIEW_EXTENSION_SOURCE_NOT_ELIGIBLE")] ReviewExtensionSourceNotEligible = 34, + /// + /// Review source name should not be found in the review text. + /// + [pbr::OriginalName("SOURCE_NAME_IN_REVIEW_EXTENSION_TEXT")] SourceNameInReviewExtensionText = 35, + /// + /// Field must be set. + /// + [pbr::OriginalName("MISSING_FIELD")] MissingField = 36, + /// + /// Inconsistent currency codes. + /// + [pbr::OriginalName("INCONSISTENT_CURRENCY_CODES")] InconsistentCurrencyCodes = 37, + /// + /// Price extension cannot have duplicated headers. + /// + [pbr::OriginalName("PRICE_EXTENSION_HAS_DUPLICATED_HEADERS")] PriceExtensionHasDuplicatedHeaders = 38, + /// + /// Price item cannot have duplicated header and description. + /// + [pbr::OriginalName("PRICE_ITEM_HAS_DUPLICATED_HEADER_AND_DESCRIPTION")] PriceItemHasDuplicatedHeaderAndDescription = 39, + /// + /// Price extension has too few items + /// + [pbr::OriginalName("PRICE_EXTENSION_HAS_TOO_FEW_ITEMS")] PriceExtensionHasTooFewItems = 40, + /// + /// Price extension has too many items + /// + [pbr::OriginalName("PRICE_EXTENSION_HAS_TOO_MANY_ITEMS")] PriceExtensionHasTooManyItems = 41, + /// + /// The input value is not currently supported. + /// + [pbr::OriginalName("UNSUPPORTED_VALUE")] UnsupportedValue = 42, + /// + /// Unknown or unsupported device preference. + /// + [pbr::OriginalName("INVALID_DEVICE_PREFERENCE")] InvalidDevicePreference = 43, + /// + /// Invalid feed item schedule end time (i.e., endHour = 24 and + /// endMinute != 0). + /// + [pbr::OriginalName("INVALID_SCHEDULE_END")] InvalidScheduleEnd = 45, + /// + /// Date time zone does not match the account's time zone. + /// + [pbr::OriginalName("DATE_TIME_MUST_BE_IN_ACCOUNT_TIME_ZONE")] DateTimeMustBeInAccountTimeZone = 47, + /// + /// Overlapping feed item schedule times (e.g., 7-10AM and 8-11AM) are not + /// allowed. + /// + [pbr::OriginalName("OVERLAPPING_SCHEDULES_NOT_ALLOWED")] OverlappingSchedulesNotAllowed = 48, + /// + /// Feed item schedule end time must be after start time. + /// + [pbr::OriginalName("SCHEDULE_END_NOT_AFTER_START")] ScheduleEndNotAfterStart = 49, + /// + /// There are too many feed item schedules per day. + /// + [pbr::OriginalName("TOO_MANY_SCHEDULES_PER_DAY")] TooManySchedulesPerDay = 50, + /// + /// Cannot edit the same extension feed item more than once in the same + /// request. + /// + [pbr::OriginalName("DUPLICATE_EXTENSION_FEED_ITEM_EDIT")] DuplicateExtensionFeedItemEdit = 51, + /// + /// Invalid structured snippet header. + /// + [pbr::OriginalName("INVALID_SNIPPETS_HEADER")] InvalidSnippetsHeader = 52, + /// + /// Phone number with call tracking enabled is not supported for the + /// specified country. + /// + [pbr::OriginalName("PHONE_NUMBER_NOT_SUPPORTED_WITH_CALLTRACKING_FOR_COUNTRY")] PhoneNumberNotSupportedWithCalltrackingForCountry = 53, + /// + /// The targeted adgroup must belong to the targeted campaign. + /// + [pbr::OriginalName("CAMPAIGN_TARGETING_MISMATCH")] CampaignTargetingMismatch = 54, + /// + /// The feed used by the ExtensionSetting is removed and cannot be operated + /// on. Remove the ExtensionSetting to allow a new one to be created using + /// an active feed. + /// + [pbr::OriginalName("CANNOT_OPERATE_ON_REMOVED_FEED")] CannotOperateOnRemovedFeed = 55, + /// + /// The ExtensionFeedItem type is required for this operation. + /// + [pbr::OriginalName("EXTENSION_TYPE_REQUIRED")] ExtensionTypeRequired = 56, + /// + /// The matching function that links the extension feed to the customer, + /// campaign, or ad group is not compatible with the ExtensionSetting + /// services. + /// + [pbr::OriginalName("INCOMPATIBLE_UNDERLYING_MATCHING_FUNCTION")] IncompatibleUnderlyingMatchingFunction = 57, + /// + /// Start date must be before end date. + /// + [pbr::OriginalName("START_DATE_AFTER_END_DATE")] StartDateAfterEndDate = 58, + /// + /// Input price is not in a valid format. + /// + [pbr::OriginalName("INVALID_PRICE_FORMAT")] InvalidPriceFormat = 59, + /// + /// The promotion time is invalid. + /// + [pbr::OriginalName("PROMOTION_INVALID_TIME")] PromotionInvalidTime = 60, + /// + /// Cannot set both percent discount and money discount fields. + /// + [pbr::OriginalName("PROMOTION_CANNOT_SET_PERCENT_DISCOUNT_AND_MONEY_DISCOUNT")] PromotionCannotSetPercentDiscountAndMoneyDiscount = 61, + /// + /// Cannot set both promotion code and orders over amount fields. + /// + [pbr::OriginalName("PROMOTION_CANNOT_SET_PROMOTION_CODE_AND_ORDERS_OVER_AMOUNT")] PromotionCannotSetPromotionCodeAndOrdersOverAmount = 62, + /// + /// This field has too many decimal places specified. + /// + [pbr::OriginalName("TOO_MANY_DECIMAL_PLACES_SPECIFIED")] TooManyDecimalPlacesSpecified = 63, + /// + /// The language code is not valid. + /// + [pbr::OriginalName("INVALID_LANGUAGE_CODE")] InvalidLanguageCode = 64, + /// + /// The language is not supported. + /// + [pbr::OriginalName("UNSUPPORTED_LANGUAGE")] UnsupportedLanguage = 65, + /// + /// Customer hasn't consented for call recording, which is required for + /// adding/updating call extensions. Please see + /// https://support.google.com/google-ads/answer/7412639. + /// + [pbr::OriginalName("CUSTOMER_CONSENT_FOR_CALL_RECORDING_REQUIRED")] CustomerConsentForCallRecordingRequired = 66, + /// + /// The UPDATE operation does not specify any fields other than the resource + /// name in the update mask. + /// + [pbr::OriginalName("EXTENSION_SETTING_UPDATE_IS_A_NOOP")] ExtensionSettingUpdateIsANoop = 67, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExtensionType.cs b/src/V3/Stubs/ExtensionType.cs new file mode 100644 index 000000000..4bd3422bc --- /dev/null +++ b/src/V3/Stubs/ExtensionType.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/extension_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/extension_type.proto + public static partial class ExtensionTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/extension_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExtensionTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9leHRlbnNpb25fdHlw", + "ZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2ds", + "ZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i8wEKEUV4dGVuc2lvblR5cGVFbnVt", + "It0BCg1FeHRlbnNpb25UeXBlEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9X", + "ThABEggKBE5PTkUQAhIHCgNBUFAQAxIICgRDQUxMEAQSCwoHQ0FMTE9VVBAF", + "EgsKB01FU1NBR0UQBhIJCgVQUklDRRAHEg0KCVBST01PVElPThAIEgwKCFNJ", + "VEVMSU5LEAoSFgoSU1RSVUNUVVJFRF9TTklQUEVUEAsSDAoITE9DQVRJT04Q", + "DBIWChJBRkZJTElBVEVfTE9DQVRJT04QDRIRCg1IT1RFTF9DQUxMT1VUEA9C", + "5wEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0ISRXh0ZW5z", + "aW9uVHlwZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoC", + "HUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeEnum.Types.ExtensionType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible data types for an extension in an + /// extension setting. + /// + public sealed partial class ExtensionTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExtensionTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ExtensionTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionTypeEnum(ExtensionTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExtensionTypeEnum Clone() { + return new ExtensionTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExtensionTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExtensionTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExtensionTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ExtensionTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible data types for an extension in an extension setting. + /// + public enum ExtensionType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// None. + /// + [pbr::OriginalName("NONE")] None = 2, + /// + /// App. + /// + [pbr::OriginalName("APP")] App = 3, + /// + /// Call. + /// + [pbr::OriginalName("CALL")] Call = 4, + /// + /// Callout. + /// + [pbr::OriginalName("CALLOUT")] Callout = 5, + /// + /// Message. + /// + [pbr::OriginalName("MESSAGE")] Message = 6, + /// + /// Price. + /// + [pbr::OriginalName("PRICE")] Price = 7, + /// + /// Promotion. + /// + [pbr::OriginalName("PROMOTION")] Promotion = 8, + /// + /// Sitelink. + /// + [pbr::OriginalName("SITELINK")] Sitelink = 10, + /// + /// Structured snippet. + /// + [pbr::OriginalName("STRUCTURED_SNIPPET")] StructuredSnippet = 11, + /// + /// Location. + /// + [pbr::OriginalName("LOCATION")] Location = 12, + /// + /// Affiliate location. + /// + [pbr::OriginalName("AFFILIATE_LOCATION")] AffiliateLocation = 13, + /// + /// Hotel callout + /// + [pbr::OriginalName("HOTEL_CALLOUT")] HotelCallout = 15, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Extensions.cs b/src/V3/Stubs/Extensions.cs new file mode 100644 index 000000000..3d22590de --- /dev/null +++ b/src/V3/Stubs/Extensions.cs @@ -0,0 +1,4152 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/extensions.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/extensions.proto + public static partial class ExtensionsReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/extensions.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExtensionsReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZXh0ZW5zaW9ucy5w", + "cm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uGjVnb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9jb21tb24vY3VzdG9tX3BhcmFtZXRlci5wcm90", + "bxowZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL2ZlZWRfY29tbW9u", + "LnByb3RvGi1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hcHBfc3Rv", + "cmUucHJvdG8aQ2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2NhbGxf", + "Y29udmVyc2lvbl9yZXBvcnRpbmdfc3RhdGUucHJvdG8aQ2dvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2VudW1zL3ByaWNlX2V4dGVuc2lvbl9wcmljZV9xdWFs", + "aWZpZXIucHJvdG8aPmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3By", + "aWNlX2V4dGVuc2lvbl9wcmljZV91bml0LnByb3RvGjhnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcy9wcmljZV9leHRlbnNpb25fdHlwZS5wcm90bxpJ", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvcHJvbW90aW9uX2V4dGVu", + "c2lvbl9kaXNjb3VudF9tb2RpZmllci5wcm90bxpAZ29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvZW51bXMvcHJvbW90aW9uX2V4dGVuc2lvbl9vY2Nhc2lvbi5w", + "cm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUv", + "YXBpL2Fubm90YXRpb25zLnByb3RvIuUDCgtBcHBGZWVkSXRlbRIvCglsaW5r", + "X3RleHQYASABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSLAoG", + "YXBwX2lkGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEkcK", + "CWFwcF9zdG9yZRgDIAEoDjI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zLkFwcFN0b3JlRW51bS5BcHBTdG9yZRIwCgpmaW5hbF91cmxzGAQgAygL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjcKEWZpbmFsX21vYmls", + "ZV91cmxzGAUgAygLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjsK", + "FXRyYWNraW5nX3VybF90ZW1wbGF0ZRgGIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZRJOChV1cmxfY3VzdG9tX3BhcmFtZXRlcnMYByADKAsy", + "Ly5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uQ3VzdG9tUGFyYW1l", + "dGVyEjYKEGZpbmFsX3VybF9zdWZmaXgYCCABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWUivgMKDENhbGxGZWVkSXRlbRIyCgxwaG9uZV9udW1i", + "ZXIYASABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMgoMY291", + "bnRyeV9jb2RlGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVl", + "EjkKFWNhbGxfdHJhY2tpbmdfZW5hYmxlZBgDIAEoCzIaLmdvb2dsZS5wcm90", + "b2J1Zi5Cb29sVmFsdWUSPAoWY2FsbF9jb252ZXJzaW9uX2FjdGlvbhgEIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJFCiFjYWxsX2NvbnZl", + "cnNpb25fdHJhY2tpbmdfZGlzYWJsZWQYBSABKAsyGi5nb29nbGUucHJvdG9i", + "dWYuQm9vbFZhbHVlEoUBCh9jYWxsX2NvbnZlcnNpb25fcmVwb3J0aW5nX3N0", + "YXRlGAYgASgOMlwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQ2Fs", + "bENvbnZlcnNpb25SZXBvcnRpbmdTdGF0ZUVudW0uQ2FsbENvbnZlcnNpb25S", + "ZXBvcnRpbmdTdGF0ZSJFCg9DYWxsb3V0RmVlZEl0ZW0SMgoMY2FsbG91dF90", + "ZXh0GAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlIqoDChBM", + "b2NhdGlvbkZlZWRJdGVtEjMKDWJ1c2luZXNzX25hbWUYASABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWUSNAoOYWRkcmVzc19saW5lXzEYAiAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSNAoOYWRkcmVzc19s", + "aW5lXzIYAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSKgoE", + "Y2l0eRgEIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIuCghw", + "cm92aW5jZRgFIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIx", + "Cgtwb3N0YWxfY29kZRgGIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZRIyCgxjb3VudHJ5X2NvZGUYByABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWUSMgoMcGhvbmVfbnVtYmVyGAggASgLMhwuZ29vZ2xlLnBy", + "b3RvYnVmLlN0cmluZ1ZhbHVlIpQEChlBZmZpbGlhdGVMb2NhdGlvbkZlZWRJ", + "dGVtEjMKDWJ1c2luZXNzX25hbWUYASABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWUSNAoOYWRkcmVzc19saW5lXzEYAiABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWUSNAoOYWRkcmVzc19saW5lXzIYAyABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSKgoEY2l0eRgEIAEoCzIc", + "Lmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIuCghwcm92aW5jZRgFIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIxCgtwb3N0YWxfY29k", + "ZRgGIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIyCgxjb3Vu", + "dHJ5X2NvZGUYByABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUS", + "MgoMcGhvbmVfbnVtYmVyGAggASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmlu", + "Z1ZhbHVlEi0KCGNoYWluX2lkGAkgASgLMhsuZ29vZ2xlLnByb3RvYnVmLklu", + "dDY0VmFsdWUSMAoKY2hhaW5fbmFtZRgKIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZSKUAgoTVGV4dE1lc3NhZ2VGZWVkSXRlbRIzCg1idXNp", + "bmVzc19uYW1lGAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVl", + "EjIKDGNvdW50cnlfY29kZRgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZRIyCgxwaG9uZV9udW1iZXIYAyABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWUSKgoEdGV4dBgEIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZRI0Cg5leHRlbnNpb25fdGV4dBgFIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSLNAwoNUHJpY2VGZWVkSXRlbRJWCgR0", + "eXBlGAEgASgOMkguZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuUHJp", + "Y2VFeHRlbnNpb25UeXBlRW51bS5QcmljZUV4dGVuc2lvblR5cGUSdQoPcHJp", + "Y2VfcXVhbGlmaWVyGAIgASgOMlwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuUHJpY2VFeHRlbnNpb25QcmljZVF1YWxpZmllckVudW0uUHJpY2VF", + "eHRlbnNpb25QcmljZVF1YWxpZmllchI7ChV0cmFja2luZ191cmxfdGVtcGxh", + "dGUYAyABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMwoNbGFu", + "Z3VhZ2VfY29kZRgEIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZRJDCg9wcmljZV9vZmZlcmluZ3MYBSADKAsyKi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5jb21tb24uUHJpY2VPZmZlchI2ChBmaW5hbF91cmxfc3VmZml4", + "GAYgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlIvACCgpQcmlj", + "ZU9mZmVyEiwKBmhlYWRlchgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZRIxCgtkZXNjcmlwdGlvbhgCIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZRI0CgVwcmljZRgDIAEoCzIlLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmNvbW1vbi5Nb25leRJgCgR1bml0GAQgASgOMlIuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXMuUHJpY2VFeHRlbnNpb25QcmljZVVu", + "aXRFbnVtLlByaWNlRXh0ZW5zaW9uUHJpY2VVbml0EjAKCmZpbmFsX3VybHMY", + "BSADKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSNwoRZmluYWxf", + "bW9iaWxlX3VybHMYBiADKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFs", + "dWUisggKEVByb21vdGlvbkZlZWRJdGVtEjYKEHByb21vdGlvbl90YXJnZXQY", + "ASABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSgwEKEWRpc2Nv", + "dW50X21vZGlmaWVyGAIgASgOMmguZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuUHJvbW90aW9uRXh0ZW5zaW9uRGlzY291bnRNb2RpZmllckVudW0u", + "UHJvbW90aW9uRXh0ZW5zaW9uRGlzY291bnRNb2RpZmllchI6ChRwcm9tb3Rp", + "b25fc3RhcnRfZGF0ZRgHIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZRI4ChJwcm9tb3Rpb25fZW5kX2RhdGUYCCABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWUSagoIb2NjYXNpb24YCSABKA4yWC5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtcy5Qcm9tb3Rpb25FeHRlbnNpb25PY2Nh", + "c2lvbkVudW0uUHJvbW90aW9uRXh0ZW5zaW9uT2NjYXNpb24SMAoKZmluYWxf", + "dXJscxgKIAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI3ChFm", + "aW5hbF9tb2JpbGVfdXJscxgLIAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZRI7ChV0cmFja2luZ191cmxfdGVtcGxhdGUYDCABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWUSTgoVdXJsX2N1c3RvbV9wYXJhbWV0", + "ZXJzGA0gAygLMi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkN1", + "c3RvbVBhcmFtZXRlchI2ChBmaW5hbF91cmxfc3VmZml4GA4gASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjMKDWxhbmd1YWdlX2NvZGUYDyAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMgoLcGVyY2VudF9v", + "ZmYYAyABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUgAEkEKEG1v", + "bmV5X2Ftb3VudF9vZmYYBCABKAsyJS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5jb21tb24uTW9uZXlIABI2Cg5wcm9tb3Rpb25fY29kZRgFIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUgBEkMKEm9yZGVyc19vdmVyX2Ft", + "b3VudBgGIAEoCzIlLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5N", + "b25leUgBQg8KDWRpc2NvdW50X3R5cGVCEwoRcHJvbW90aW9uX3RyaWdnZXIi", + "dwoZU3RydWN0dXJlZFNuaXBwZXRGZWVkSXRlbRIsCgZoZWFkZXIYASABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSLAoGdmFsdWVzGAIgAygL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlIs0DChBTaXRlbGlua0Zl", + "ZWRJdGVtEi8KCWxpbmtfdGV4dBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZRIrCgVsaW5lMRgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZRIrCgVsaW5lMhgDIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZRIwCgpmaW5hbF91cmxzGAQgAygLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlEjcKEWZpbmFsX21vYmlsZV91cmxzGAUgAygLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjsKFXRyYWNraW5nX3VybF90", + "ZW1wbGF0ZRgGIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJO", + "ChV1cmxfY3VzdG9tX3BhcmFtZXRlcnMYByADKAsyLy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5jb21tb24uQ3VzdG9tUGFyYW1ldGVyEjYKEGZpbmFsX3Vy", + "bF9zdWZmaXgYCCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUi", + "dwoUSG90ZWxDYWxsb3V0RmVlZEl0ZW0SKgoEdGV4dBgBIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRIzCg1sYW5ndWFnZV9jb2RlGAIgASgL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQuoBCiJjb20uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuY29tbW9uQg9FeHRlbnNpb25zUHJvdG9QAVpE", + "Z29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29v", + "Z2xlYWRzL3YzL2NvbW1vbjtjb21tb26iAgNHQUGqAh5Hb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5Db21tb27KAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xD", + "b21tb27qAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6Q29tbW9uYgZw", + "cm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CustomParameterReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.FeedCommonReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AppStoreReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceQualifierReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceUnitReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PromotionExtensionDiscountModifierReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PromotionExtensionOccasionReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AppFeedItem), global::Google.Ads.GoogleAds.V3.Common.AppFeedItem.Parser, new[]{ "LinkText", "AppId", "AppStore", "FinalUrls", "FinalMobileUrls", "TrackingUrlTemplate", "UrlCustomParameters", "FinalUrlSuffix" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CallFeedItem), global::Google.Ads.GoogleAds.V3.Common.CallFeedItem.Parser, new[]{ "PhoneNumber", "CountryCode", "CallTrackingEnabled", "CallConversionAction", "CallConversionTrackingDisabled", "CallConversionReportingState" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.CalloutFeedItem), global::Google.Ads.GoogleAds.V3.Common.CalloutFeedItem.Parser, new[]{ "CalloutText" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.LocationFeedItem), global::Google.Ads.GoogleAds.V3.Common.LocationFeedItem.Parser, new[]{ "BusinessName", "AddressLine1", "AddressLine2", "City", "Province", "PostalCode", "CountryCode", "PhoneNumber" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.AffiliateLocationFeedItem), global::Google.Ads.GoogleAds.V3.Common.AffiliateLocationFeedItem.Parser, new[]{ "BusinessName", "AddressLine1", "AddressLine2", "City", "Province", "PostalCode", "CountryCode", "PhoneNumber", "ChainId", "ChainName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.TextMessageFeedItem), global::Google.Ads.GoogleAds.V3.Common.TextMessageFeedItem.Parser, new[]{ "BusinessName", "CountryCode", "PhoneNumber", "Text", "ExtensionText" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.PriceFeedItem), global::Google.Ads.GoogleAds.V3.Common.PriceFeedItem.Parser, new[]{ "Type", "PriceQualifier", "TrackingUrlTemplate", "LanguageCode", "PriceOfferings", "FinalUrlSuffix" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.PriceOffer), global::Google.Ads.GoogleAds.V3.Common.PriceOffer.Parser, new[]{ "Header", "Description", "Price", "Unit", "FinalUrls", "FinalMobileUrls" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.PromotionFeedItem), global::Google.Ads.GoogleAds.V3.Common.PromotionFeedItem.Parser, new[]{ "PromotionTarget", "DiscountModifier", "PromotionStartDate", "PromotionEndDate", "Occasion", "FinalUrls", "FinalMobileUrls", "TrackingUrlTemplate", "UrlCustomParameters", "FinalUrlSuffix", "LanguageCode", "PercentOff", "MoneyAmountOff", "PromotionCode", "OrdersOverAmount" }, new[]{ "DiscountType", "PromotionTrigger" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.StructuredSnippetFeedItem), global::Google.Ads.GoogleAds.V3.Common.StructuredSnippetFeedItem.Parser, new[]{ "Header", "Values" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.SitelinkFeedItem), global::Google.Ads.GoogleAds.V3.Common.SitelinkFeedItem.Parser, new[]{ "LinkText", "Line1", "Line2", "FinalUrls", "FinalMobileUrls", "TrackingUrlTemplate", "UrlCustomParameters", "FinalUrlSuffix" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.HotelCalloutFeedItem), global::Google.Ads.GoogleAds.V3.Common.HotelCalloutFeedItem.Parser, new[]{ "Text", "LanguageCode" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents an App extension. + /// + public sealed partial class AppFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AppFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppFeedItem(AppFeedItem other) : this() { + LinkText = other.LinkText; + AppId = other.AppId; + appStore_ = other.appStore_; + finalUrls_ = other.finalUrls_.Clone(); + finalMobileUrls_ = other.finalMobileUrls_.Clone(); + TrackingUrlTemplate = other.TrackingUrlTemplate; + urlCustomParameters_ = other.urlCustomParameters_.Clone(); + FinalUrlSuffix = other.FinalUrlSuffix; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AppFeedItem Clone() { + return new AppFeedItem(this); + } + + /// Field number for the "link_text" field. + public const int LinkTextFieldNumber = 1; + private static readonly pb::FieldCodec _single_linkText_codec = pb::FieldCodec.ForClassWrapper(10); + private string linkText_; + /// + /// The visible text displayed when the link is rendered in an ad. + /// This string must not be empty, and the length of this string should + /// be between 1 and 25, inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LinkText { + get { return linkText_; } + set { + linkText_ = value; + } + } + + + /// Field number for the "app_id" field. + public const int AppIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_appId_codec = pb::FieldCodec.ForClassWrapper(18); + private string appId_; + /// + /// The store-specific ID for the target application. + /// This string must not be empty. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AppId { + get { return appId_; } + set { + appId_ = value; + } + } + + + /// Field number for the "app_store" field. + public const int AppStoreFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.AppStoreEnum.Types.AppStore appStore_ = 0; + /// + /// The application store that the target application belongs to. + /// This field is required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AppStoreEnum.Types.AppStore AppStore { + get { return appStore_; } + set { + appStore_ = value; + } + } + + /// Field number for the "final_urls" field. + public const int FinalUrlsFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_finalUrls_codec + = pb::FieldCodec.ForClassWrapper(34); + private readonly pbc::RepeatedField finalUrls_ = new pbc::RepeatedField(); + /// + /// A list of possible final URLs after all cross domain redirects. + /// This list must not be empty. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalUrls { + get { return finalUrls_; } + } + + /// Field number for the "final_mobile_urls" field. + public const int FinalMobileUrlsFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_finalMobileUrls_codec + = pb::FieldCodec.ForClassWrapper(42); + private readonly pbc::RepeatedField finalMobileUrls_ = new pbc::RepeatedField(); + /// + /// A list of possible final mobile URLs after all cross domain redirects. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalMobileUrls { + get { return finalMobileUrls_; } + } + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 6; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(50); + private string trackingUrlTemplate_; + /// + /// URL template for constructing a tracking URL. Default value is "{lpurl}". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "url_custom_parameters" field. + public const int UrlCustomParametersFieldNumber = 7; + private static readonly pb::FieldCodec _repeated_urlCustomParameters_codec + = pb::FieldCodec.ForMessage(58, global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser); + private readonly pbc::RepeatedField urlCustomParameters_ = new pbc::RepeatedField(); + /// + /// A list of mappings to be used for substituting URL custom parameter tags in + /// the tracking_url_template, final_urls, and/or final_mobile_urls. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCustomParameters { + get { return urlCustomParameters_; } + } + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 8; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(66); + private string finalUrlSuffix_; + /// + /// URL template for appending params to landing page URLs served with parallel + /// tracking. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AppFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AppFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (LinkText != other.LinkText) return false; + if (AppId != other.AppId) return false; + if (AppStore != other.AppStore) return false; + if(!finalUrls_.Equals(other.finalUrls_)) return false; + if(!finalMobileUrls_.Equals(other.finalMobileUrls_)) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if(!urlCustomParameters_.Equals(other.urlCustomParameters_)) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (linkText_ != null) hash ^= LinkText.GetHashCode(); + if (appId_ != null) hash ^= AppId.GetHashCode(); + if (AppStore != 0) hash ^= AppStore.GetHashCode(); + hash ^= finalUrls_.GetHashCode(); + hash ^= finalMobileUrls_.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + hash ^= urlCustomParameters_.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (linkText_ != null) { + _single_linkText_codec.WriteTagAndValue(output, LinkText); + } + if (appId_ != null) { + _single_appId_codec.WriteTagAndValue(output, AppId); + } + if (AppStore != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) AppStore); + } + finalUrls_.WriteTo(output, _repeated_finalUrls_codec); + finalMobileUrls_.WriteTo(output, _repeated_finalMobileUrls_codec); + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + urlCustomParameters_.WriteTo(output, _repeated_urlCustomParameters_codec); + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (linkText_ != null) { + size += _single_linkText_codec.CalculateSizeWithTag(LinkText); + } + if (appId_ != null) { + size += _single_appId_codec.CalculateSizeWithTag(AppId); + } + if (AppStore != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AppStore); + } + size += finalUrls_.CalculateSize(_repeated_finalUrls_codec); + size += finalMobileUrls_.CalculateSize(_repeated_finalMobileUrls_codec); + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + size += urlCustomParameters_.CalculateSize(_repeated_urlCustomParameters_codec); + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AppFeedItem other) { + if (other == null) { + return; + } + if (other.linkText_ != null) { + if (linkText_ == null || other.LinkText != "") { + LinkText = other.LinkText; + } + } + if (other.appId_ != null) { + if (appId_ == null || other.AppId != "") { + AppId = other.AppId; + } + } + if (other.AppStore != 0) { + AppStore = other.AppStore; + } + finalUrls_.Add(other.finalUrls_); + finalMobileUrls_.Add(other.finalMobileUrls_); + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + urlCustomParameters_.Add(other.urlCustomParameters_); + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_linkText_codec.Read(input); + if (linkText_ == null || value != "") { + LinkText = value; + } + break; + } + case 18: { + string value = _single_appId_codec.Read(input); + if (appId_ == null || value != "") { + AppId = value; + } + break; + } + case 24: { + AppStore = (global::Google.Ads.GoogleAds.V3.Enums.AppStoreEnum.Types.AppStore) input.ReadEnum(); + break; + } + case 34: { + finalUrls_.AddEntriesFrom(input, _repeated_finalUrls_codec); + break; + } + case 42: { + finalMobileUrls_.AddEntriesFrom(input, _repeated_finalMobileUrls_codec); + break; + } + case 50: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 58: { + urlCustomParameters_.AddEntriesFrom(input, _repeated_urlCustomParameters_codec); + break; + } + case 66: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + } + } + } + + } + + /// + /// Represents a Call extension. + /// + public sealed partial class CallFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CallFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallFeedItem(CallFeedItem other) : this() { + PhoneNumber = other.PhoneNumber; + CountryCode = other.CountryCode; + CallTrackingEnabled = other.CallTrackingEnabled; + CallConversionAction = other.CallConversionAction; + CallConversionTrackingDisabled = other.CallConversionTrackingDisabled; + callConversionReportingState_ = other.callConversionReportingState_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CallFeedItem Clone() { + return new CallFeedItem(this); + } + + /// Field number for the "phone_number" field. + public const int PhoneNumberFieldNumber = 1; + private static readonly pb::FieldCodec _single_phoneNumber_codec = pb::FieldCodec.ForClassWrapper(10); + private string phoneNumber_; + /// + /// The advertiser's phone number to append to the ad. + /// This string must not be empty. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PhoneNumber { + get { return phoneNumber_; } + set { + phoneNumber_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string countryCode_; + /// + /// Uppercase two-letter country code of the advertiser's phone number. + /// This string must not be empty. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "call_tracking_enabled" field. + public const int CallTrackingEnabledFieldNumber = 3; + private static readonly pb::FieldCodec _single_callTrackingEnabled_codec = pb::FieldCodec.ForStructWrapper(26); + private bool? callTrackingEnabled_; + /// + /// Indicates whether call tracking is enabled. By default, call tracking is + /// not enabled. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? CallTrackingEnabled { + get { return callTrackingEnabled_; } + set { + callTrackingEnabled_ = value; + } + } + + + /// Field number for the "call_conversion_action" field. + public const int CallConversionActionFieldNumber = 4; + private static readonly pb::FieldCodec _single_callConversionAction_codec = pb::FieldCodec.ForClassWrapper(34); + private string callConversionAction_; + /// + /// The conversion action to attribute a call conversion to. If not set a + /// default conversion action is used. This field only has effect if + /// call_tracking_enabled is set to true. Otherwise this field is ignored. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CallConversionAction { + get { return callConversionAction_; } + set { + callConversionAction_ = value; + } + } + + + /// Field number for the "call_conversion_tracking_disabled" field. + public const int CallConversionTrackingDisabledFieldNumber = 5; + private static readonly pb::FieldCodec _single_callConversionTrackingDisabled_codec = pb::FieldCodec.ForStructWrapper(42); + private bool? callConversionTrackingDisabled_; + /// + /// If true, disable call conversion tracking. call_conversion_action should + /// not be set if this is true. Optional. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? CallConversionTrackingDisabled { + get { return callConversionTrackingDisabled_; } + set { + callConversionTrackingDisabled_ = value; + } + } + + + /// Field number for the "call_conversion_reporting_state" field. + public const int CallConversionReportingStateFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum.Types.CallConversionReportingState callConversionReportingState_ = 0; + /// + /// Enum value that indicates whether this call extension uses its own call + /// conversion setting (or just have call conversion disabled), or following + /// the account level setting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum.Types.CallConversionReportingState CallConversionReportingState { + get { return callConversionReportingState_; } + set { + callConversionReportingState_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CallFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CallFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (PhoneNumber != other.PhoneNumber) return false; + if (CountryCode != other.CountryCode) return false; + if (CallTrackingEnabled != other.CallTrackingEnabled) return false; + if (CallConversionAction != other.CallConversionAction) return false; + if (CallConversionTrackingDisabled != other.CallConversionTrackingDisabled) return false; + if (CallConversionReportingState != other.CallConversionReportingState) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (phoneNumber_ != null) hash ^= PhoneNumber.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (callTrackingEnabled_ != null) hash ^= CallTrackingEnabled.GetHashCode(); + if (callConversionAction_ != null) hash ^= CallConversionAction.GetHashCode(); + if (callConversionTrackingDisabled_ != null) hash ^= CallConversionTrackingDisabled.GetHashCode(); + if (CallConversionReportingState != 0) hash ^= CallConversionReportingState.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (phoneNumber_ != null) { + _single_phoneNumber_codec.WriteTagAndValue(output, PhoneNumber); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (callTrackingEnabled_ != null) { + _single_callTrackingEnabled_codec.WriteTagAndValue(output, CallTrackingEnabled); + } + if (callConversionAction_ != null) { + _single_callConversionAction_codec.WriteTagAndValue(output, CallConversionAction); + } + if (callConversionTrackingDisabled_ != null) { + _single_callConversionTrackingDisabled_codec.WriteTagAndValue(output, CallConversionTrackingDisabled); + } + if (CallConversionReportingState != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) CallConversionReportingState); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (phoneNumber_ != null) { + size += _single_phoneNumber_codec.CalculateSizeWithTag(PhoneNumber); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (callTrackingEnabled_ != null) { + size += _single_callTrackingEnabled_codec.CalculateSizeWithTag(CallTrackingEnabled); + } + if (callConversionAction_ != null) { + size += _single_callConversionAction_codec.CalculateSizeWithTag(CallConversionAction); + } + if (callConversionTrackingDisabled_ != null) { + size += _single_callConversionTrackingDisabled_codec.CalculateSizeWithTag(CallConversionTrackingDisabled); + } + if (CallConversionReportingState != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) CallConversionReportingState); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CallFeedItem other) { + if (other == null) { + return; + } + if (other.phoneNumber_ != null) { + if (phoneNumber_ == null || other.PhoneNumber != "") { + PhoneNumber = other.PhoneNumber; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.callTrackingEnabled_ != null) { + if (callTrackingEnabled_ == null || other.CallTrackingEnabled != false) { + CallTrackingEnabled = other.CallTrackingEnabled; + } + } + if (other.callConversionAction_ != null) { + if (callConversionAction_ == null || other.CallConversionAction != "") { + CallConversionAction = other.CallConversionAction; + } + } + if (other.callConversionTrackingDisabled_ != null) { + if (callConversionTrackingDisabled_ == null || other.CallConversionTrackingDisabled != false) { + CallConversionTrackingDisabled = other.CallConversionTrackingDisabled; + } + } + if (other.CallConversionReportingState != 0) { + CallConversionReportingState = other.CallConversionReportingState; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_phoneNumber_codec.Read(input); + if (phoneNumber_ == null || value != "") { + PhoneNumber = value; + } + break; + } + case 18: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 26: { + bool? value = _single_callTrackingEnabled_codec.Read(input); + if (callTrackingEnabled_ == null || value != false) { + CallTrackingEnabled = value; + } + break; + } + case 34: { + string value = _single_callConversionAction_codec.Read(input); + if (callConversionAction_ == null || value != "") { + CallConversionAction = value; + } + break; + } + case 42: { + bool? value = _single_callConversionTrackingDisabled_codec.Read(input); + if (callConversionTrackingDisabled_ == null || value != false) { + CallConversionTrackingDisabled = value; + } + break; + } + case 48: { + CallConversionReportingState = (global::Google.Ads.GoogleAds.V3.Enums.CallConversionReportingStateEnum.Types.CallConversionReportingState) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Represents a callout extension. + /// + public sealed partial class CalloutFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new CalloutFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CalloutFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CalloutFeedItem(CalloutFeedItem other) : this() { + CalloutText = other.CalloutText; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public CalloutFeedItem Clone() { + return new CalloutFeedItem(this); + } + + /// Field number for the "callout_text" field. + public const int CalloutTextFieldNumber = 1; + private static readonly pb::FieldCodec _single_calloutText_codec = pb::FieldCodec.ForClassWrapper(10); + private string calloutText_; + /// + /// The callout text. + /// The length of this string should be between 1 and 25, inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CalloutText { + get { return calloutText_; } + set { + calloutText_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as CalloutFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(CalloutFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CalloutText != other.CalloutText) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (calloutText_ != null) hash ^= CalloutText.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (calloutText_ != null) { + _single_calloutText_codec.WriteTagAndValue(output, CalloutText); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (calloutText_ != null) { + size += _single_calloutText_codec.CalculateSizeWithTag(CalloutText); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(CalloutFeedItem other) { + if (other == null) { + return; + } + if (other.calloutText_ != null) { + if (calloutText_ == null || other.CalloutText != "") { + CalloutText = other.CalloutText; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_calloutText_codec.Read(input); + if (calloutText_ == null || value != "") { + CalloutText = value; + } + break; + } + } + } + } + + } + + /// + /// Represents a location extension. + /// + public sealed partial class LocationFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new LocationFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationFeedItem(LocationFeedItem other) : this() { + BusinessName = other.BusinessName; + AddressLine1 = other.AddressLine1; + AddressLine2 = other.AddressLine2; + City = other.City; + Province = other.Province; + PostalCode = other.PostalCode; + CountryCode = other.CountryCode; + PhoneNumber = other.PhoneNumber; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationFeedItem Clone() { + return new LocationFeedItem(this); + } + + /// Field number for the "business_name" field. + public const int BusinessNameFieldNumber = 1; + private static readonly pb::FieldCodec _single_businessName_codec = pb::FieldCodec.ForClassWrapper(10); + private string businessName_; + /// + /// The name of the business. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessName { + get { return businessName_; } + set { + businessName_ = value; + } + } + + + /// Field number for the "address_line_1" field. + public const int AddressLine1FieldNumber = 2; + private static readonly pb::FieldCodec _single_addressLine1_codec = pb::FieldCodec.ForClassWrapper(18); + private string addressLine1_; + /// + /// Line 1 of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AddressLine1 { + get { return addressLine1_; } + set { + addressLine1_ = value; + } + } + + + /// Field number for the "address_line_2" field. + public const int AddressLine2FieldNumber = 3; + private static readonly pb::FieldCodec _single_addressLine2_codec = pb::FieldCodec.ForClassWrapper(26); + private string addressLine2_; + /// + /// Line 2 of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AddressLine2 { + get { return addressLine2_; } + set { + addressLine2_ = value; + } + } + + + /// Field number for the "city" field. + public const int CityFieldNumber = 4; + private static readonly pb::FieldCodec _single_city_codec = pb::FieldCodec.ForClassWrapper(34); + private string city_; + /// + /// City of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string City { + get { return city_; } + set { + city_ = value; + } + } + + + /// Field number for the "province" field. + public const int ProvinceFieldNumber = 5; + private static readonly pb::FieldCodec _single_province_codec = pb::FieldCodec.ForClassWrapper(42); + private string province_; + /// + /// Province of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Province { + get { return province_; } + set { + province_ = value; + } + } + + + /// Field number for the "postal_code" field. + public const int PostalCodeFieldNumber = 6; + private static readonly pb::FieldCodec _single_postalCode_codec = pb::FieldCodec.ForClassWrapper(50); + private string postalCode_; + /// + /// Postal code of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PostalCode { + get { return postalCode_; } + set { + postalCode_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 7; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(58); + private string countryCode_; + /// + /// Country code of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "phone_number" field. + public const int PhoneNumberFieldNumber = 8; + private static readonly pb::FieldCodec _single_phoneNumber_codec = pb::FieldCodec.ForClassWrapper(66); + private string phoneNumber_; + /// + /// Phone number of the business. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PhoneNumber { + get { return phoneNumber_; } + set { + phoneNumber_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as LocationFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(LocationFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (BusinessName != other.BusinessName) return false; + if (AddressLine1 != other.AddressLine1) return false; + if (AddressLine2 != other.AddressLine2) return false; + if (City != other.City) return false; + if (Province != other.Province) return false; + if (PostalCode != other.PostalCode) return false; + if (CountryCode != other.CountryCode) return false; + if (PhoneNumber != other.PhoneNumber) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (businessName_ != null) hash ^= BusinessName.GetHashCode(); + if (addressLine1_ != null) hash ^= AddressLine1.GetHashCode(); + if (addressLine2_ != null) hash ^= AddressLine2.GetHashCode(); + if (city_ != null) hash ^= City.GetHashCode(); + if (province_ != null) hash ^= Province.GetHashCode(); + if (postalCode_ != null) hash ^= PostalCode.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (phoneNumber_ != null) hash ^= PhoneNumber.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (businessName_ != null) { + _single_businessName_codec.WriteTagAndValue(output, BusinessName); + } + if (addressLine1_ != null) { + _single_addressLine1_codec.WriteTagAndValue(output, AddressLine1); + } + if (addressLine2_ != null) { + _single_addressLine2_codec.WriteTagAndValue(output, AddressLine2); + } + if (city_ != null) { + _single_city_codec.WriteTagAndValue(output, City); + } + if (province_ != null) { + _single_province_codec.WriteTagAndValue(output, Province); + } + if (postalCode_ != null) { + _single_postalCode_codec.WriteTagAndValue(output, PostalCode); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (phoneNumber_ != null) { + _single_phoneNumber_codec.WriteTagAndValue(output, PhoneNumber); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (businessName_ != null) { + size += _single_businessName_codec.CalculateSizeWithTag(BusinessName); + } + if (addressLine1_ != null) { + size += _single_addressLine1_codec.CalculateSizeWithTag(AddressLine1); + } + if (addressLine2_ != null) { + size += _single_addressLine2_codec.CalculateSizeWithTag(AddressLine2); + } + if (city_ != null) { + size += _single_city_codec.CalculateSizeWithTag(City); + } + if (province_ != null) { + size += _single_province_codec.CalculateSizeWithTag(Province); + } + if (postalCode_ != null) { + size += _single_postalCode_codec.CalculateSizeWithTag(PostalCode); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (phoneNumber_ != null) { + size += _single_phoneNumber_codec.CalculateSizeWithTag(PhoneNumber); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(LocationFeedItem other) { + if (other == null) { + return; + } + if (other.businessName_ != null) { + if (businessName_ == null || other.BusinessName != "") { + BusinessName = other.BusinessName; + } + } + if (other.addressLine1_ != null) { + if (addressLine1_ == null || other.AddressLine1 != "") { + AddressLine1 = other.AddressLine1; + } + } + if (other.addressLine2_ != null) { + if (addressLine2_ == null || other.AddressLine2 != "") { + AddressLine2 = other.AddressLine2; + } + } + if (other.city_ != null) { + if (city_ == null || other.City != "") { + City = other.City; + } + } + if (other.province_ != null) { + if (province_ == null || other.Province != "") { + Province = other.Province; + } + } + if (other.postalCode_ != null) { + if (postalCode_ == null || other.PostalCode != "") { + PostalCode = other.PostalCode; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.phoneNumber_ != null) { + if (phoneNumber_ == null || other.PhoneNumber != "") { + PhoneNumber = other.PhoneNumber; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_businessName_codec.Read(input); + if (businessName_ == null || value != "") { + BusinessName = value; + } + break; + } + case 18: { + string value = _single_addressLine1_codec.Read(input); + if (addressLine1_ == null || value != "") { + AddressLine1 = value; + } + break; + } + case 26: { + string value = _single_addressLine2_codec.Read(input); + if (addressLine2_ == null || value != "") { + AddressLine2 = value; + } + break; + } + case 34: { + string value = _single_city_codec.Read(input); + if (city_ == null || value != "") { + City = value; + } + break; + } + case 42: { + string value = _single_province_codec.Read(input); + if (province_ == null || value != "") { + Province = value; + } + break; + } + case 50: { + string value = _single_postalCode_codec.Read(input); + if (postalCode_ == null || value != "") { + PostalCode = value; + } + break; + } + case 58: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 66: { + string value = _single_phoneNumber_codec.Read(input); + if (phoneNumber_ == null || value != "") { + PhoneNumber = value; + } + break; + } + } + } + } + + } + + /// + /// Represents an affiliate location extension. + /// + public sealed partial class AffiliateLocationFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AffiliateLocationFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedItem(AffiliateLocationFeedItem other) : this() { + BusinessName = other.BusinessName; + AddressLine1 = other.AddressLine1; + AddressLine2 = other.AddressLine2; + City = other.City; + Province = other.Province; + PostalCode = other.PostalCode; + CountryCode = other.CountryCode; + PhoneNumber = other.PhoneNumber; + ChainId = other.ChainId; + ChainName = other.ChainName; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedItem Clone() { + return new AffiliateLocationFeedItem(this); + } + + /// Field number for the "business_name" field. + public const int BusinessNameFieldNumber = 1; + private static readonly pb::FieldCodec _single_businessName_codec = pb::FieldCodec.ForClassWrapper(10); + private string businessName_; + /// + /// The name of the business. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessName { + get { return businessName_; } + set { + businessName_ = value; + } + } + + + /// Field number for the "address_line_1" field. + public const int AddressLine1FieldNumber = 2; + private static readonly pb::FieldCodec _single_addressLine1_codec = pb::FieldCodec.ForClassWrapper(18); + private string addressLine1_; + /// + /// Line 1 of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AddressLine1 { + get { return addressLine1_; } + set { + addressLine1_ = value; + } + } + + + /// Field number for the "address_line_2" field. + public const int AddressLine2FieldNumber = 3; + private static readonly pb::FieldCodec _single_addressLine2_codec = pb::FieldCodec.ForClassWrapper(26); + private string addressLine2_; + /// + /// Line 2 of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AddressLine2 { + get { return addressLine2_; } + set { + addressLine2_ = value; + } + } + + + /// Field number for the "city" field. + public const int CityFieldNumber = 4; + private static readonly pb::FieldCodec _single_city_codec = pb::FieldCodec.ForClassWrapper(34); + private string city_; + /// + /// City of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string City { + get { return city_; } + set { + city_ = value; + } + } + + + /// Field number for the "province" field. + public const int ProvinceFieldNumber = 5; + private static readonly pb::FieldCodec _single_province_codec = pb::FieldCodec.ForClassWrapper(42); + private string province_; + /// + /// Province of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Province { + get { return province_; } + set { + province_ = value; + } + } + + + /// Field number for the "postal_code" field. + public const int PostalCodeFieldNumber = 6; + private static readonly pb::FieldCodec _single_postalCode_codec = pb::FieldCodec.ForClassWrapper(50); + private string postalCode_; + /// + /// Postal code of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PostalCode { + get { return postalCode_; } + set { + postalCode_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 7; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(58); + private string countryCode_; + /// + /// Country code of the business address. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "phone_number" field. + public const int PhoneNumberFieldNumber = 8; + private static readonly pb::FieldCodec _single_phoneNumber_codec = pb::FieldCodec.ForClassWrapper(66); + private string phoneNumber_; + /// + /// Phone number of the business. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PhoneNumber { + get { return phoneNumber_; } + set { + phoneNumber_ = value; + } + } + + + /// Field number for the "chain_id" field. + public const int ChainIdFieldNumber = 9; + private static readonly pb::FieldCodec _single_chainId_codec = pb::FieldCodec.ForStructWrapper(74); + private long? chainId_; + /// + /// Id of the retail chain that is advertised as a seller of your product. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? ChainId { + get { return chainId_; } + set { + chainId_ = value; + } + } + + + /// Field number for the "chain_name" field. + public const int ChainNameFieldNumber = 10; + private static readonly pb::FieldCodec _single_chainName_codec = pb::FieldCodec.ForClassWrapper(82); + private string chainName_; + /// + /// Name of chain. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ChainName { + get { return chainName_; } + set { + chainName_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AffiliateLocationFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AffiliateLocationFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (BusinessName != other.BusinessName) return false; + if (AddressLine1 != other.AddressLine1) return false; + if (AddressLine2 != other.AddressLine2) return false; + if (City != other.City) return false; + if (Province != other.Province) return false; + if (PostalCode != other.PostalCode) return false; + if (CountryCode != other.CountryCode) return false; + if (PhoneNumber != other.PhoneNumber) return false; + if (ChainId != other.ChainId) return false; + if (ChainName != other.ChainName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (businessName_ != null) hash ^= BusinessName.GetHashCode(); + if (addressLine1_ != null) hash ^= AddressLine1.GetHashCode(); + if (addressLine2_ != null) hash ^= AddressLine2.GetHashCode(); + if (city_ != null) hash ^= City.GetHashCode(); + if (province_ != null) hash ^= Province.GetHashCode(); + if (postalCode_ != null) hash ^= PostalCode.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (phoneNumber_ != null) hash ^= PhoneNumber.GetHashCode(); + if (chainId_ != null) hash ^= ChainId.GetHashCode(); + if (chainName_ != null) hash ^= ChainName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (businessName_ != null) { + _single_businessName_codec.WriteTagAndValue(output, BusinessName); + } + if (addressLine1_ != null) { + _single_addressLine1_codec.WriteTagAndValue(output, AddressLine1); + } + if (addressLine2_ != null) { + _single_addressLine2_codec.WriteTagAndValue(output, AddressLine2); + } + if (city_ != null) { + _single_city_codec.WriteTagAndValue(output, City); + } + if (province_ != null) { + _single_province_codec.WriteTagAndValue(output, Province); + } + if (postalCode_ != null) { + _single_postalCode_codec.WriteTagAndValue(output, PostalCode); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (phoneNumber_ != null) { + _single_phoneNumber_codec.WriteTagAndValue(output, PhoneNumber); + } + if (chainId_ != null) { + _single_chainId_codec.WriteTagAndValue(output, ChainId); + } + if (chainName_ != null) { + _single_chainName_codec.WriteTagAndValue(output, ChainName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (businessName_ != null) { + size += _single_businessName_codec.CalculateSizeWithTag(BusinessName); + } + if (addressLine1_ != null) { + size += _single_addressLine1_codec.CalculateSizeWithTag(AddressLine1); + } + if (addressLine2_ != null) { + size += _single_addressLine2_codec.CalculateSizeWithTag(AddressLine2); + } + if (city_ != null) { + size += _single_city_codec.CalculateSizeWithTag(City); + } + if (province_ != null) { + size += _single_province_codec.CalculateSizeWithTag(Province); + } + if (postalCode_ != null) { + size += _single_postalCode_codec.CalculateSizeWithTag(PostalCode); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (phoneNumber_ != null) { + size += _single_phoneNumber_codec.CalculateSizeWithTag(PhoneNumber); + } + if (chainId_ != null) { + size += _single_chainId_codec.CalculateSizeWithTag(ChainId); + } + if (chainName_ != null) { + size += _single_chainName_codec.CalculateSizeWithTag(ChainName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AffiliateLocationFeedItem other) { + if (other == null) { + return; + } + if (other.businessName_ != null) { + if (businessName_ == null || other.BusinessName != "") { + BusinessName = other.BusinessName; + } + } + if (other.addressLine1_ != null) { + if (addressLine1_ == null || other.AddressLine1 != "") { + AddressLine1 = other.AddressLine1; + } + } + if (other.addressLine2_ != null) { + if (addressLine2_ == null || other.AddressLine2 != "") { + AddressLine2 = other.AddressLine2; + } + } + if (other.city_ != null) { + if (city_ == null || other.City != "") { + City = other.City; + } + } + if (other.province_ != null) { + if (province_ == null || other.Province != "") { + Province = other.Province; + } + } + if (other.postalCode_ != null) { + if (postalCode_ == null || other.PostalCode != "") { + PostalCode = other.PostalCode; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.phoneNumber_ != null) { + if (phoneNumber_ == null || other.PhoneNumber != "") { + PhoneNumber = other.PhoneNumber; + } + } + if (other.chainId_ != null) { + if (chainId_ == null || other.ChainId != 0L) { + ChainId = other.ChainId; + } + } + if (other.chainName_ != null) { + if (chainName_ == null || other.ChainName != "") { + ChainName = other.ChainName; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_businessName_codec.Read(input); + if (businessName_ == null || value != "") { + BusinessName = value; + } + break; + } + case 18: { + string value = _single_addressLine1_codec.Read(input); + if (addressLine1_ == null || value != "") { + AddressLine1 = value; + } + break; + } + case 26: { + string value = _single_addressLine2_codec.Read(input); + if (addressLine2_ == null || value != "") { + AddressLine2 = value; + } + break; + } + case 34: { + string value = _single_city_codec.Read(input); + if (city_ == null || value != "") { + City = value; + } + break; + } + case 42: { + string value = _single_province_codec.Read(input); + if (province_ == null || value != "") { + Province = value; + } + break; + } + case 50: { + string value = _single_postalCode_codec.Read(input); + if (postalCode_ == null || value != "") { + PostalCode = value; + } + break; + } + case 58: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 66: { + string value = _single_phoneNumber_codec.Read(input); + if (phoneNumber_ == null || value != "") { + PhoneNumber = value; + } + break; + } + case 74: { + long? value = _single_chainId_codec.Read(input); + if (chainId_ == null || value != 0L) { + ChainId = value; + } + break; + } + case 82: { + string value = _single_chainName_codec.Read(input); + if (chainName_ == null || value != "") { + ChainName = value; + } + break; + } + } + } + } + + } + + /// + /// An extension that users can click on to send a text message to the + /// advertiser. + /// + public sealed partial class TextMessageFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new TextMessageFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextMessageFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextMessageFeedItem(TextMessageFeedItem other) : this() { + BusinessName = other.BusinessName; + CountryCode = other.CountryCode; + PhoneNumber = other.PhoneNumber; + Text = other.Text; + ExtensionText = other.ExtensionText; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TextMessageFeedItem Clone() { + return new TextMessageFeedItem(this); + } + + /// Field number for the "business_name" field. + public const int BusinessNameFieldNumber = 1; + private static readonly pb::FieldCodec _single_businessName_codec = pb::FieldCodec.ForClassWrapper(10); + private string businessName_; + /// + /// The business name to prepend to the message text. + /// This field is required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessName { + get { return businessName_; } + set { + businessName_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string countryCode_; + /// + /// Uppercase two-letter country code of the advertiser's phone number. + /// This field is required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "phone_number" field. + public const int PhoneNumberFieldNumber = 3; + private static readonly pb::FieldCodec _single_phoneNumber_codec = pb::FieldCodec.ForClassWrapper(26); + private string phoneNumber_; + /// + /// The advertiser's phone number the message will be sent to. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PhoneNumber { + get { return phoneNumber_; } + set { + phoneNumber_ = value; + } + } + + + /// Field number for the "text" field. + public const int TextFieldNumber = 4; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(34); + private string text_; + /// + /// The text to show in the ad. + /// This field is required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + /// Field number for the "extension_text" field. + public const int ExtensionTextFieldNumber = 5; + private static readonly pb::FieldCodec _single_extensionText_codec = pb::FieldCodec.ForClassWrapper(42); + private string extensionText_; + /// + /// The message text populated in the messaging app. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ExtensionText { + get { return extensionText_; } + set { + extensionText_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TextMessageFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TextMessageFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (BusinessName != other.BusinessName) return false; + if (CountryCode != other.CountryCode) return false; + if (PhoneNumber != other.PhoneNumber) return false; + if (Text != other.Text) return false; + if (ExtensionText != other.ExtensionText) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (businessName_ != null) hash ^= BusinessName.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (phoneNumber_ != null) hash ^= PhoneNumber.GetHashCode(); + if (text_ != null) hash ^= Text.GetHashCode(); + if (extensionText_ != null) hash ^= ExtensionText.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (businessName_ != null) { + _single_businessName_codec.WriteTagAndValue(output, BusinessName); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (phoneNumber_ != null) { + _single_phoneNumber_codec.WriteTagAndValue(output, PhoneNumber); + } + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (extensionText_ != null) { + _single_extensionText_codec.WriteTagAndValue(output, ExtensionText); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (businessName_ != null) { + size += _single_businessName_codec.CalculateSizeWithTag(BusinessName); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (phoneNumber_ != null) { + size += _single_phoneNumber_codec.CalculateSizeWithTag(PhoneNumber); + } + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (extensionText_ != null) { + size += _single_extensionText_codec.CalculateSizeWithTag(ExtensionText); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TextMessageFeedItem other) { + if (other == null) { + return; + } + if (other.businessName_ != null) { + if (businessName_ == null || other.BusinessName != "") { + BusinessName = other.BusinessName; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.phoneNumber_ != null) { + if (phoneNumber_ == null || other.PhoneNumber != "") { + PhoneNumber = other.PhoneNumber; + } + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + if (other.extensionText_ != null) { + if (extensionText_ == null || other.ExtensionText != "") { + ExtensionText = other.ExtensionText; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_businessName_codec.Read(input); + if (businessName_ == null || value != "") { + BusinessName = value; + } + break; + } + case 18: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 26: { + string value = _single_phoneNumber_codec.Read(input); + if (phoneNumber_ == null || value != "") { + PhoneNumber = value; + } + break; + } + case 34: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + case 42: { + string value = _single_extensionText_codec.Read(input); + if (extensionText_ == null || value != "") { + ExtensionText = value; + } + break; + } + } + } + } + + } + + /// + /// Represents a Price extension. + /// + public sealed partial class PriceFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PriceFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PriceFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PriceFeedItem(PriceFeedItem other) : this() { + type_ = other.type_; + priceQualifier_ = other.priceQualifier_; + TrackingUrlTemplate = other.TrackingUrlTemplate; + LanguageCode = other.LanguageCode; + priceOfferings_ = other.priceOfferings_.Clone(); + FinalUrlSuffix = other.FinalUrlSuffix; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PriceFeedItem Clone() { + return new PriceFeedItem(this); + } + + /// Field number for the "type" field. + public const int TypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionTypeEnum.Types.PriceExtensionType type_ = 0; + /// + /// Price extension type of this extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionTypeEnum.Types.PriceExtensionType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "price_qualifier" field. + public const int PriceQualifierFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceQualifierEnum.Types.PriceExtensionPriceQualifier priceQualifier_ = 0; + /// + /// Price qualifier for all offers of this price extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceQualifierEnum.Types.PriceExtensionPriceQualifier PriceQualifier { + get { return priceQualifier_; } + set { + priceQualifier_ = value; + } + } + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 3; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(26); + private string trackingUrlTemplate_; + /// + /// Tracking URL template for all offers of this price extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "language_code" field. + public const int LanguageCodeFieldNumber = 4; + private static readonly pb::FieldCodec _single_languageCode_codec = pb::FieldCodec.ForClassWrapper(34); + private string languageCode_; + /// + /// The code of the language used for this price extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LanguageCode { + get { return languageCode_; } + set { + languageCode_ = value; + } + } + + + /// Field number for the "price_offerings" field. + public const int PriceOfferingsFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_priceOfferings_codec + = pb::FieldCodec.ForMessage(42, global::Google.Ads.GoogleAds.V3.Common.PriceOffer.Parser); + private readonly pbc::RepeatedField priceOfferings_ = new pbc::RepeatedField(); + /// + /// The price offerings in this price extension. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PriceOfferings { + get { return priceOfferings_; } + } + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 6; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(50); + private string finalUrlSuffix_; + /// + /// URL template for appending params to landing page URLs served with parallel + /// tracking. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PriceFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PriceFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Type != other.Type) return false; + if (PriceQualifier != other.PriceQualifier) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if (LanguageCode != other.LanguageCode) return false; + if(!priceOfferings_.Equals(other.priceOfferings_)) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Type != 0) hash ^= Type.GetHashCode(); + if (PriceQualifier != 0) hash ^= PriceQualifier.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + if (languageCode_ != null) hash ^= LanguageCode.GetHashCode(); + hash ^= priceOfferings_.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Type != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Type); + } + if (PriceQualifier != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) PriceQualifier); + } + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + if (languageCode_ != null) { + _single_languageCode_codec.WriteTagAndValue(output, LanguageCode); + } + priceOfferings_.WriteTo(output, _repeated_priceOfferings_codec); + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (PriceQualifier != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PriceQualifier); + } + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + if (languageCode_ != null) { + size += _single_languageCode_codec.CalculateSizeWithTag(LanguageCode); + } + size += priceOfferings_.CalculateSize(_repeated_priceOfferings_codec); + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PriceFeedItem other) { + if (other == null) { + return; + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.PriceQualifier != 0) { + PriceQualifier = other.PriceQualifier; + } + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + if (other.languageCode_ != null) { + if (languageCode_ == null || other.LanguageCode != "") { + LanguageCode = other.LanguageCode; + } + } + priceOfferings_.Add(other.priceOfferings_); + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionTypeEnum.Types.PriceExtensionType) input.ReadEnum(); + break; + } + case 16: { + PriceQualifier = (global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceQualifierEnum.Types.PriceExtensionPriceQualifier) input.ReadEnum(); + break; + } + case 26: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 34: { + string value = _single_languageCode_codec.Read(input); + if (languageCode_ == null || value != "") { + LanguageCode = value; + } + break; + } + case 42: { + priceOfferings_.AddEntriesFrom(input, _repeated_priceOfferings_codec); + break; + } + case 50: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + } + } + } + + } + + /// + /// Represents one price offer in a price extension. + /// + public sealed partial class PriceOffer : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PriceOffer()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PriceOffer() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PriceOffer(PriceOffer other) : this() { + Header = other.Header; + Description = other.Description; + price_ = other.price_ != null ? other.price_.Clone() : null; + unit_ = other.unit_; + finalUrls_ = other.finalUrls_.Clone(); + finalMobileUrls_ = other.finalMobileUrls_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PriceOffer Clone() { + return new PriceOffer(this); + } + + /// Field number for the "header" field. + public const int HeaderFieldNumber = 1; + private static readonly pb::FieldCodec _single_header_codec = pb::FieldCodec.ForClassWrapper(10); + private string header_; + /// + /// Header text of this offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Header { + get { return header_; } + set { + header_ = value; + } + } + + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 2; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(18); + private string description_; + /// + /// Description text of this offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "price" field. + public const int PriceFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Common.Money price_; + /// + /// Price value of this offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.Money Price { + get { return price_; } + set { + price_ = value; + } + } + + /// Field number for the "unit" field. + public const int UnitFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceUnitEnum.Types.PriceExtensionPriceUnit unit_ = 0; + /// + /// Price unit for this offer. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceUnitEnum.Types.PriceExtensionPriceUnit Unit { + get { return unit_; } + set { + unit_ = value; + } + } + + /// Field number for the "final_urls" field. + public const int FinalUrlsFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_finalUrls_codec + = pb::FieldCodec.ForClassWrapper(42); + private readonly pbc::RepeatedField finalUrls_ = new pbc::RepeatedField(); + /// + /// A list of possible final URLs after all cross domain redirects. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalUrls { + get { return finalUrls_; } + } + + /// Field number for the "final_mobile_urls" field. + public const int FinalMobileUrlsFieldNumber = 6; + private static readonly pb::FieldCodec _repeated_finalMobileUrls_codec + = pb::FieldCodec.ForClassWrapper(50); + private readonly pbc::RepeatedField finalMobileUrls_ = new pbc::RepeatedField(); + /// + /// A list of possible final mobile URLs after all cross domain redirects. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalMobileUrls { + get { return finalMobileUrls_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PriceOffer); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PriceOffer other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Header != other.Header) return false; + if (Description != other.Description) return false; + if (!object.Equals(Price, other.Price)) return false; + if (Unit != other.Unit) return false; + if(!finalUrls_.Equals(other.finalUrls_)) return false; + if(!finalMobileUrls_.Equals(other.finalMobileUrls_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (header_ != null) hash ^= Header.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + if (price_ != null) hash ^= Price.GetHashCode(); + if (Unit != 0) hash ^= Unit.GetHashCode(); + hash ^= finalUrls_.GetHashCode(); + hash ^= finalMobileUrls_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (header_ != null) { + _single_header_codec.WriteTagAndValue(output, Header); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + if (price_ != null) { + output.WriteRawTag(26); + output.WriteMessage(Price); + } + if (Unit != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) Unit); + } + finalUrls_.WriteTo(output, _repeated_finalUrls_codec); + finalMobileUrls_.WriteTo(output, _repeated_finalMobileUrls_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (header_ != null) { + size += _single_header_codec.CalculateSizeWithTag(Header); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + if (price_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Price); + } + if (Unit != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Unit); + } + size += finalUrls_.CalculateSize(_repeated_finalUrls_codec); + size += finalMobileUrls_.CalculateSize(_repeated_finalMobileUrls_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PriceOffer other) { + if (other == null) { + return; + } + if (other.header_ != null) { + if (header_ == null || other.Header != "") { + Header = other.Header; + } + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + if (other.price_ != null) { + if (price_ == null) { + Price = new global::Google.Ads.GoogleAds.V3.Common.Money(); + } + Price.MergeFrom(other.Price); + } + if (other.Unit != 0) { + Unit = other.Unit; + } + finalUrls_.Add(other.finalUrls_); + finalMobileUrls_.Add(other.finalMobileUrls_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_header_codec.Read(input); + if (header_ == null || value != "") { + Header = value; + } + break; + } + case 18: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 26: { + if (price_ == null) { + Price = new global::Google.Ads.GoogleAds.V3.Common.Money(); + } + input.ReadMessage(Price); + break; + } + case 32: { + Unit = (global::Google.Ads.GoogleAds.V3.Enums.PriceExtensionPriceUnitEnum.Types.PriceExtensionPriceUnit) input.ReadEnum(); + break; + } + case 42: { + finalUrls_.AddEntriesFrom(input, _repeated_finalUrls_codec); + break; + } + case 50: { + finalMobileUrls_.AddEntriesFrom(input, _repeated_finalMobileUrls_codec); + break; + } + } + } + } + + } + + /// + /// Represents a Promotion extension. + /// + public sealed partial class PromotionFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PromotionFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromotionFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromotionFeedItem(PromotionFeedItem other) : this() { + PromotionTarget = other.PromotionTarget; + discountModifier_ = other.discountModifier_; + PromotionStartDate = other.PromotionStartDate; + PromotionEndDate = other.PromotionEndDate; + occasion_ = other.occasion_; + finalUrls_ = other.finalUrls_.Clone(); + finalMobileUrls_ = other.finalMobileUrls_.Clone(); + TrackingUrlTemplate = other.TrackingUrlTemplate; + urlCustomParameters_ = other.urlCustomParameters_.Clone(); + FinalUrlSuffix = other.FinalUrlSuffix; + LanguageCode = other.LanguageCode; + switch (other.DiscountTypeCase) { + case DiscountTypeOneofCase.PercentOff: + PercentOff = other.PercentOff; + break; + case DiscountTypeOneofCase.MoneyAmountOff: + MoneyAmountOff = other.MoneyAmountOff.Clone(); + break; + } + + switch (other.PromotionTriggerCase) { + case PromotionTriggerOneofCase.PromotionCode: + PromotionCode = other.PromotionCode; + break; + case PromotionTriggerOneofCase.OrdersOverAmount: + OrdersOverAmount = other.OrdersOverAmount.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromotionFeedItem Clone() { + return new PromotionFeedItem(this); + } + + /// Field number for the "promotion_target" field. + public const int PromotionTargetFieldNumber = 1; + private static readonly pb::FieldCodec _single_promotionTarget_codec = pb::FieldCodec.ForClassWrapper(10); + private string promotionTarget_; + /// + /// A freeform description of what the promotion is targeting. + /// This field is required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PromotionTarget { + get { return promotionTarget_; } + set { + promotionTarget_ = value; + } + } + + + /// Field number for the "discount_modifier" field. + public const int DiscountModifierFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.PromotionExtensionDiscountModifierEnum.Types.PromotionExtensionDiscountModifier discountModifier_ = 0; + /// + /// Enum that modifies the qualification of the discount. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PromotionExtensionDiscountModifierEnum.Types.PromotionExtensionDiscountModifier DiscountModifier { + get { return discountModifier_; } + set { + discountModifier_ = value; + } + } + + /// Field number for the "promotion_start_date" field. + public const int PromotionStartDateFieldNumber = 7; + private static readonly pb::FieldCodec _single_promotionStartDate_codec = pb::FieldCodec.ForClassWrapper(58); + private string promotionStartDate_; + /// + /// Start date of when the promotion is eligible to be redeemed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PromotionStartDate { + get { return promotionStartDate_; } + set { + promotionStartDate_ = value; + } + } + + + /// Field number for the "promotion_end_date" field. + public const int PromotionEndDateFieldNumber = 8; + private static readonly pb::FieldCodec _single_promotionEndDate_codec = pb::FieldCodec.ForClassWrapper(66); + private string promotionEndDate_; + /// + /// End date of when the promotion is eligible to be redeemed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PromotionEndDate { + get { return promotionEndDate_; } + set { + promotionEndDate_ = value; + } + } + + + /// Field number for the "occasion" field. + public const int OccasionFieldNumber = 9; + private global::Google.Ads.GoogleAds.V3.Enums.PromotionExtensionOccasionEnum.Types.PromotionExtensionOccasion occasion_ = 0; + /// + /// The occasion the promotion was intended for. + /// If an occasion is set, the redemption window will need to fall within + /// the date range associated with the occasion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PromotionExtensionOccasionEnum.Types.PromotionExtensionOccasion Occasion { + get { return occasion_; } + set { + occasion_ = value; + } + } + + /// Field number for the "final_urls" field. + public const int FinalUrlsFieldNumber = 10; + private static readonly pb::FieldCodec _repeated_finalUrls_codec + = pb::FieldCodec.ForClassWrapper(82); + private readonly pbc::RepeatedField finalUrls_ = new pbc::RepeatedField(); + /// + /// A list of possible final URLs after all cross domain redirects. + /// This field is required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalUrls { + get { return finalUrls_; } + } + + /// Field number for the "final_mobile_urls" field. + public const int FinalMobileUrlsFieldNumber = 11; + private static readonly pb::FieldCodec _repeated_finalMobileUrls_codec + = pb::FieldCodec.ForClassWrapper(90); + private readonly pbc::RepeatedField finalMobileUrls_ = new pbc::RepeatedField(); + /// + /// A list of possible final mobile URLs after all cross domain redirects. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalMobileUrls { + get { return finalMobileUrls_; } + } + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 12; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(98); + private string trackingUrlTemplate_; + /// + /// URL template for constructing a tracking URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "url_custom_parameters" field. + public const int UrlCustomParametersFieldNumber = 13; + private static readonly pb::FieldCodec _repeated_urlCustomParameters_codec + = pb::FieldCodec.ForMessage(106, global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser); + private readonly pbc::RepeatedField urlCustomParameters_ = new pbc::RepeatedField(); + /// + /// A list of mappings to be used for substituting URL custom parameter tags in + /// the tracking_url_template, final_urls, and/or final_mobile_urls. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCustomParameters { + get { return urlCustomParameters_; } + } + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 14; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(114); + private string finalUrlSuffix_; + /// + /// URL template for appending params to landing page URLs served with parallel + /// tracking. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + /// Field number for the "language_code" field. + public const int LanguageCodeFieldNumber = 15; + private static readonly pb::FieldCodec _single_languageCode_codec = pb::FieldCodec.ForClassWrapper(122); + private string languageCode_; + /// + /// The language of the promotion. + /// Represented as BCP 47 language tag. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LanguageCode { + get { return languageCode_; } + set { + languageCode_ = value; + } + } + + + /// Field number for the "percent_off" field. + public const int PercentOffFieldNumber = 3; + private static readonly pb::FieldCodec _oneof_percentOff_codec = pb::FieldCodec.ForStructWrapper(26); + /// + /// Percentage off discount in the promotion in micros. + /// One million is equivalent to one percent. + /// Either this or money_off_amount is required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? PercentOff { + get { return discountTypeCase_ == DiscountTypeOneofCase.PercentOff ? (long?) discountType_ : (long?) null; } + set { + discountType_ = value; + discountTypeCase_ = value == null ? DiscountTypeOneofCase.None : DiscountTypeOneofCase.PercentOff; + } + } + + /// Field number for the "money_amount_off" field. + public const int MoneyAmountOffFieldNumber = 4; + /// + /// Money amount off for discount in the promotion. + /// Either this or percent_off is required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.Money MoneyAmountOff { + get { return discountTypeCase_ == DiscountTypeOneofCase.MoneyAmountOff ? (global::Google.Ads.GoogleAds.V3.Common.Money) discountType_ : null; } + set { + discountType_ = value; + discountTypeCase_ = value == null ? DiscountTypeOneofCase.None : DiscountTypeOneofCase.MoneyAmountOff; + } + } + + /// Field number for the "promotion_code" field. + public const int PromotionCodeFieldNumber = 5; + private static readonly pb::FieldCodec _oneof_promotionCode_codec = pb::FieldCodec.ForClassWrapper(42); + /// + /// A code the user should use in order to be eligible for the promotion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PromotionCode { + get { return promotionTriggerCase_ == PromotionTriggerOneofCase.PromotionCode ? (string) promotionTrigger_ : (string) null; } + set { + promotionTrigger_ = value; + promotionTriggerCase_ = value == null ? PromotionTriggerOneofCase.None : PromotionTriggerOneofCase.PromotionCode; + } + } + + /// Field number for the "orders_over_amount" field. + public const int OrdersOverAmountFieldNumber = 6; + /// + /// The amount the total order needs to be for the user to be eligible for + /// the promotion. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.Money OrdersOverAmount { + get { return promotionTriggerCase_ == PromotionTriggerOneofCase.OrdersOverAmount ? (global::Google.Ads.GoogleAds.V3.Common.Money) promotionTrigger_ : null; } + set { + promotionTrigger_ = value; + promotionTriggerCase_ = value == null ? PromotionTriggerOneofCase.None : PromotionTriggerOneofCase.OrdersOverAmount; + } + } + + private object discountType_; + /// Enum of possible cases for the "discount_type" oneof. + public enum DiscountTypeOneofCase { + None = 0, + PercentOff = 3, + MoneyAmountOff = 4, + } + private DiscountTypeOneofCase discountTypeCase_ = DiscountTypeOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public DiscountTypeOneofCase DiscountTypeCase { + get { return discountTypeCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearDiscountType() { + discountTypeCase_ = DiscountTypeOneofCase.None; + discountType_ = null; + } + + private object promotionTrigger_; + /// Enum of possible cases for the "promotion_trigger" oneof. + public enum PromotionTriggerOneofCase { + None = 0, + PromotionCode = 5, + OrdersOverAmount = 6, + } + private PromotionTriggerOneofCase promotionTriggerCase_ = PromotionTriggerOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PromotionTriggerOneofCase PromotionTriggerCase { + get { return promotionTriggerCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearPromotionTrigger() { + promotionTriggerCase_ = PromotionTriggerOneofCase.None; + promotionTrigger_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PromotionFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PromotionFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (PromotionTarget != other.PromotionTarget) return false; + if (DiscountModifier != other.DiscountModifier) return false; + if (PromotionStartDate != other.PromotionStartDate) return false; + if (PromotionEndDate != other.PromotionEndDate) return false; + if (Occasion != other.Occasion) return false; + if(!finalUrls_.Equals(other.finalUrls_)) return false; + if(!finalMobileUrls_.Equals(other.finalMobileUrls_)) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if(!urlCustomParameters_.Equals(other.urlCustomParameters_)) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + if (LanguageCode != other.LanguageCode) return false; + if (PercentOff != other.PercentOff) return false; + if (!object.Equals(MoneyAmountOff, other.MoneyAmountOff)) return false; + if (PromotionCode != other.PromotionCode) return false; + if (!object.Equals(OrdersOverAmount, other.OrdersOverAmount)) return false; + if (DiscountTypeCase != other.DiscountTypeCase) return false; + if (PromotionTriggerCase != other.PromotionTriggerCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (promotionTarget_ != null) hash ^= PromotionTarget.GetHashCode(); + if (DiscountModifier != 0) hash ^= DiscountModifier.GetHashCode(); + if (promotionStartDate_ != null) hash ^= PromotionStartDate.GetHashCode(); + if (promotionEndDate_ != null) hash ^= PromotionEndDate.GetHashCode(); + if (Occasion != 0) hash ^= Occasion.GetHashCode(); + hash ^= finalUrls_.GetHashCode(); + hash ^= finalMobileUrls_.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + hash ^= urlCustomParameters_.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + if (languageCode_ != null) hash ^= LanguageCode.GetHashCode(); + if (discountTypeCase_ == DiscountTypeOneofCase.PercentOff) hash ^= PercentOff.GetHashCode(); + if (discountTypeCase_ == DiscountTypeOneofCase.MoneyAmountOff) hash ^= MoneyAmountOff.GetHashCode(); + if (promotionTriggerCase_ == PromotionTriggerOneofCase.PromotionCode) hash ^= PromotionCode.GetHashCode(); + if (promotionTriggerCase_ == PromotionTriggerOneofCase.OrdersOverAmount) hash ^= OrdersOverAmount.GetHashCode(); + hash ^= (int) discountTypeCase_; + hash ^= (int) promotionTriggerCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (promotionTarget_ != null) { + _single_promotionTarget_codec.WriteTagAndValue(output, PromotionTarget); + } + if (DiscountModifier != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) DiscountModifier); + } + if (discountTypeCase_ == DiscountTypeOneofCase.PercentOff) { + _oneof_percentOff_codec.WriteTagAndValue(output, (long?) discountType_); + } + if (discountTypeCase_ == DiscountTypeOneofCase.MoneyAmountOff) { + output.WriteRawTag(34); + output.WriteMessage(MoneyAmountOff); + } + if (promotionTriggerCase_ == PromotionTriggerOneofCase.PromotionCode) { + _oneof_promotionCode_codec.WriteTagAndValue(output, (string) promotionTrigger_); + } + if (promotionTriggerCase_ == PromotionTriggerOneofCase.OrdersOverAmount) { + output.WriteRawTag(50); + output.WriteMessage(OrdersOverAmount); + } + if (promotionStartDate_ != null) { + _single_promotionStartDate_codec.WriteTagAndValue(output, PromotionStartDate); + } + if (promotionEndDate_ != null) { + _single_promotionEndDate_codec.WriteTagAndValue(output, PromotionEndDate); + } + if (Occasion != 0) { + output.WriteRawTag(72); + output.WriteEnum((int) Occasion); + } + finalUrls_.WriteTo(output, _repeated_finalUrls_codec); + finalMobileUrls_.WriteTo(output, _repeated_finalMobileUrls_codec); + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + urlCustomParameters_.WriteTo(output, _repeated_urlCustomParameters_codec); + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + if (languageCode_ != null) { + _single_languageCode_codec.WriteTagAndValue(output, LanguageCode); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (promotionTarget_ != null) { + size += _single_promotionTarget_codec.CalculateSizeWithTag(PromotionTarget); + } + if (DiscountModifier != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DiscountModifier); + } + if (promotionStartDate_ != null) { + size += _single_promotionStartDate_codec.CalculateSizeWithTag(PromotionStartDate); + } + if (promotionEndDate_ != null) { + size += _single_promotionEndDate_codec.CalculateSizeWithTag(PromotionEndDate); + } + if (Occasion != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Occasion); + } + size += finalUrls_.CalculateSize(_repeated_finalUrls_codec); + size += finalMobileUrls_.CalculateSize(_repeated_finalMobileUrls_codec); + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + size += urlCustomParameters_.CalculateSize(_repeated_urlCustomParameters_codec); + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + if (languageCode_ != null) { + size += _single_languageCode_codec.CalculateSizeWithTag(LanguageCode); + } + if (discountTypeCase_ == DiscountTypeOneofCase.PercentOff) { + size += _oneof_percentOff_codec.CalculateSizeWithTag(PercentOff); + } + if (discountTypeCase_ == DiscountTypeOneofCase.MoneyAmountOff) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(MoneyAmountOff); + } + if (promotionTriggerCase_ == PromotionTriggerOneofCase.PromotionCode) { + size += _oneof_promotionCode_codec.CalculateSizeWithTag(PromotionCode); + } + if (promotionTriggerCase_ == PromotionTriggerOneofCase.OrdersOverAmount) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(OrdersOverAmount); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PromotionFeedItem other) { + if (other == null) { + return; + } + if (other.promotionTarget_ != null) { + if (promotionTarget_ == null || other.PromotionTarget != "") { + PromotionTarget = other.PromotionTarget; + } + } + if (other.DiscountModifier != 0) { + DiscountModifier = other.DiscountModifier; + } + if (other.promotionStartDate_ != null) { + if (promotionStartDate_ == null || other.PromotionStartDate != "") { + PromotionStartDate = other.PromotionStartDate; + } + } + if (other.promotionEndDate_ != null) { + if (promotionEndDate_ == null || other.PromotionEndDate != "") { + PromotionEndDate = other.PromotionEndDate; + } + } + if (other.Occasion != 0) { + Occasion = other.Occasion; + } + finalUrls_.Add(other.finalUrls_); + finalMobileUrls_.Add(other.finalMobileUrls_); + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + urlCustomParameters_.Add(other.urlCustomParameters_); + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + if (other.languageCode_ != null) { + if (languageCode_ == null || other.LanguageCode != "") { + LanguageCode = other.LanguageCode; + } + } + switch (other.DiscountTypeCase) { + case DiscountTypeOneofCase.PercentOff: + PercentOff = other.PercentOff; + break; + case DiscountTypeOneofCase.MoneyAmountOff: + if (MoneyAmountOff == null) { + MoneyAmountOff = new global::Google.Ads.GoogleAds.V3.Common.Money(); + } + MoneyAmountOff.MergeFrom(other.MoneyAmountOff); + break; + } + + switch (other.PromotionTriggerCase) { + case PromotionTriggerOneofCase.PromotionCode: + PromotionCode = other.PromotionCode; + break; + case PromotionTriggerOneofCase.OrdersOverAmount: + if (OrdersOverAmount == null) { + OrdersOverAmount = new global::Google.Ads.GoogleAds.V3.Common.Money(); + } + OrdersOverAmount.MergeFrom(other.OrdersOverAmount); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_promotionTarget_codec.Read(input); + if (promotionTarget_ == null || value != "") { + PromotionTarget = value; + } + break; + } + case 16: { + DiscountModifier = (global::Google.Ads.GoogleAds.V3.Enums.PromotionExtensionDiscountModifierEnum.Types.PromotionExtensionDiscountModifier) input.ReadEnum(); + break; + } + case 26: { + PercentOff = _oneof_percentOff_codec.Read(input); + break; + } + case 34: { + global::Google.Ads.GoogleAds.V3.Common.Money subBuilder = new global::Google.Ads.GoogleAds.V3.Common.Money(); + if (discountTypeCase_ == DiscountTypeOneofCase.MoneyAmountOff) { + subBuilder.MergeFrom(MoneyAmountOff); + } + input.ReadMessage(subBuilder); + MoneyAmountOff = subBuilder; + break; + } + case 42: { + PromotionCode = _oneof_promotionCode_codec.Read(input); + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Common.Money subBuilder = new global::Google.Ads.GoogleAds.V3.Common.Money(); + if (promotionTriggerCase_ == PromotionTriggerOneofCase.OrdersOverAmount) { + subBuilder.MergeFrom(OrdersOverAmount); + } + input.ReadMessage(subBuilder); + OrdersOverAmount = subBuilder; + break; + } + case 58: { + string value = _single_promotionStartDate_codec.Read(input); + if (promotionStartDate_ == null || value != "") { + PromotionStartDate = value; + } + break; + } + case 66: { + string value = _single_promotionEndDate_codec.Read(input); + if (promotionEndDate_ == null || value != "") { + PromotionEndDate = value; + } + break; + } + case 72: { + Occasion = (global::Google.Ads.GoogleAds.V3.Enums.PromotionExtensionOccasionEnum.Types.PromotionExtensionOccasion) input.ReadEnum(); + break; + } + case 82: { + finalUrls_.AddEntriesFrom(input, _repeated_finalUrls_codec); + break; + } + case 90: { + finalMobileUrls_.AddEntriesFrom(input, _repeated_finalMobileUrls_codec); + break; + } + case 98: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 106: { + urlCustomParameters_.AddEntriesFrom(input, _repeated_urlCustomParameters_codec); + break; + } + case 114: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + case 122: { + string value = _single_languageCode_codec.Read(input); + if (languageCode_ == null || value != "") { + LanguageCode = value; + } + break; + } + } + } + } + + } + + /// + /// Represents a structured snippet extension. + /// + public sealed partial class StructuredSnippetFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new StructuredSnippetFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[9]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public StructuredSnippetFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public StructuredSnippetFeedItem(StructuredSnippetFeedItem other) : this() { + Header = other.Header; + values_ = other.values_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public StructuredSnippetFeedItem Clone() { + return new StructuredSnippetFeedItem(this); + } + + /// Field number for the "header" field. + public const int HeaderFieldNumber = 1; + private static readonly pb::FieldCodec _single_header_codec = pb::FieldCodec.ForClassWrapper(10); + private string header_; + /// + /// The header of the snippet. + /// This string must not be empty. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Header { + get { return header_; } + set { + header_ = value; + } + } + + + /// Field number for the "values" field. + public const int ValuesFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_values_codec + = pb::FieldCodec.ForClassWrapper(18); + private readonly pbc::RepeatedField values_ = new pbc::RepeatedField(); + /// + /// The values in the snippet. + /// The maximum size of this collection is 10. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Values { + get { return values_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as StructuredSnippetFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(StructuredSnippetFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Header != other.Header) return false; + if(!values_.Equals(other.values_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (header_ != null) hash ^= Header.GetHashCode(); + hash ^= values_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (header_ != null) { + _single_header_codec.WriteTagAndValue(output, Header); + } + values_.WriteTo(output, _repeated_values_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (header_ != null) { + size += _single_header_codec.CalculateSizeWithTag(Header); + } + size += values_.CalculateSize(_repeated_values_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(StructuredSnippetFeedItem other) { + if (other == null) { + return; + } + if (other.header_ != null) { + if (header_ == null || other.Header != "") { + Header = other.Header; + } + } + values_.Add(other.values_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_header_codec.Read(input); + if (header_ == null || value != "") { + Header = value; + } + break; + } + case 18: { + values_.AddEntriesFrom(input, _repeated_values_codec); + break; + } + } + } + } + + } + + /// + /// Represents a sitelink extension. + /// + public sealed partial class SitelinkFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SitelinkFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[10]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SitelinkFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SitelinkFeedItem(SitelinkFeedItem other) : this() { + LinkText = other.LinkText; + Line1 = other.Line1; + Line2 = other.Line2; + finalUrls_ = other.finalUrls_.Clone(); + finalMobileUrls_ = other.finalMobileUrls_.Clone(); + TrackingUrlTemplate = other.TrackingUrlTemplate; + urlCustomParameters_ = other.urlCustomParameters_.Clone(); + FinalUrlSuffix = other.FinalUrlSuffix; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SitelinkFeedItem Clone() { + return new SitelinkFeedItem(this); + } + + /// Field number for the "link_text" field. + public const int LinkTextFieldNumber = 1; + private static readonly pb::FieldCodec _single_linkText_codec = pb::FieldCodec.ForClassWrapper(10); + private string linkText_; + /// + /// URL display text for the sitelink. + /// The length of this string should be between 1 and 25, inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LinkText { + get { return linkText_; } + set { + linkText_ = value; + } + } + + + /// Field number for the "line1" field. + public const int Line1FieldNumber = 2; + private static readonly pb::FieldCodec _single_line1_codec = pb::FieldCodec.ForClassWrapper(18); + private string line1_; + /// + /// First line of the description for the sitelink. + /// If this value is set, line2 must also be set. + /// The length of this string should be between 0 and 35, inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Line1 { + get { return line1_; } + set { + line1_ = value; + } + } + + + /// Field number for the "line2" field. + public const int Line2FieldNumber = 3; + private static readonly pb::FieldCodec _single_line2_codec = pb::FieldCodec.ForClassWrapper(26); + private string line2_; + /// + /// Second line of the description for the sitelink. + /// If this value is set, line1 must also be set. + /// The length of this string should be between 0 and 35, inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Line2 { + get { return line2_; } + set { + line2_ = value; + } + } + + + /// Field number for the "final_urls" field. + public const int FinalUrlsFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_finalUrls_codec + = pb::FieldCodec.ForClassWrapper(34); + private readonly pbc::RepeatedField finalUrls_ = new pbc::RepeatedField(); + /// + /// A list of possible final URLs after all cross domain redirects. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalUrls { + get { return finalUrls_; } + } + + /// Field number for the "final_mobile_urls" field. + public const int FinalMobileUrlsFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_finalMobileUrls_codec + = pb::FieldCodec.ForClassWrapper(42); + private readonly pbc::RepeatedField finalMobileUrls_ = new pbc::RepeatedField(); + /// + /// A list of possible final mobile URLs after all cross domain redirects. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FinalMobileUrls { + get { return finalMobileUrls_; } + } + + /// Field number for the "tracking_url_template" field. + public const int TrackingUrlTemplateFieldNumber = 6; + private static readonly pb::FieldCodec _single_trackingUrlTemplate_codec = pb::FieldCodec.ForClassWrapper(50); + private string trackingUrlTemplate_; + /// + /// URL template for constructing a tracking URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TrackingUrlTemplate { + get { return trackingUrlTemplate_; } + set { + trackingUrlTemplate_ = value; + } + } + + + /// Field number for the "url_custom_parameters" field. + public const int UrlCustomParametersFieldNumber = 7; + private static readonly pb::FieldCodec _repeated_urlCustomParameters_codec + = pb::FieldCodec.ForMessage(58, global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser); + private readonly pbc::RepeatedField urlCustomParameters_ = new pbc::RepeatedField(); + /// + /// A list of mappings to be used for substituting URL custom parameter tags in + /// the tracking_url_template, final_urls, and/or final_mobile_urls. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCustomParameters { + get { return urlCustomParameters_; } + } + + /// Field number for the "final_url_suffix" field. + public const int FinalUrlSuffixFieldNumber = 8; + private static readonly pb::FieldCodec _single_finalUrlSuffix_codec = pb::FieldCodec.ForClassWrapper(66); + private string finalUrlSuffix_; + /// + /// Final URL suffix to be appended to landing page URLs served with + /// parallel tracking. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FinalUrlSuffix { + get { return finalUrlSuffix_; } + set { + finalUrlSuffix_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SitelinkFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SitelinkFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (LinkText != other.LinkText) return false; + if (Line1 != other.Line1) return false; + if (Line2 != other.Line2) return false; + if(!finalUrls_.Equals(other.finalUrls_)) return false; + if(!finalMobileUrls_.Equals(other.finalMobileUrls_)) return false; + if (TrackingUrlTemplate != other.TrackingUrlTemplate) return false; + if(!urlCustomParameters_.Equals(other.urlCustomParameters_)) return false; + if (FinalUrlSuffix != other.FinalUrlSuffix) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (linkText_ != null) hash ^= LinkText.GetHashCode(); + if (line1_ != null) hash ^= Line1.GetHashCode(); + if (line2_ != null) hash ^= Line2.GetHashCode(); + hash ^= finalUrls_.GetHashCode(); + hash ^= finalMobileUrls_.GetHashCode(); + if (trackingUrlTemplate_ != null) hash ^= TrackingUrlTemplate.GetHashCode(); + hash ^= urlCustomParameters_.GetHashCode(); + if (finalUrlSuffix_ != null) hash ^= FinalUrlSuffix.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (linkText_ != null) { + _single_linkText_codec.WriteTagAndValue(output, LinkText); + } + if (line1_ != null) { + _single_line1_codec.WriteTagAndValue(output, Line1); + } + if (line2_ != null) { + _single_line2_codec.WriteTagAndValue(output, Line2); + } + finalUrls_.WriteTo(output, _repeated_finalUrls_codec); + finalMobileUrls_.WriteTo(output, _repeated_finalMobileUrls_codec); + if (trackingUrlTemplate_ != null) { + _single_trackingUrlTemplate_codec.WriteTagAndValue(output, TrackingUrlTemplate); + } + urlCustomParameters_.WriteTo(output, _repeated_urlCustomParameters_codec); + if (finalUrlSuffix_ != null) { + _single_finalUrlSuffix_codec.WriteTagAndValue(output, FinalUrlSuffix); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (linkText_ != null) { + size += _single_linkText_codec.CalculateSizeWithTag(LinkText); + } + if (line1_ != null) { + size += _single_line1_codec.CalculateSizeWithTag(Line1); + } + if (line2_ != null) { + size += _single_line2_codec.CalculateSizeWithTag(Line2); + } + size += finalUrls_.CalculateSize(_repeated_finalUrls_codec); + size += finalMobileUrls_.CalculateSize(_repeated_finalMobileUrls_codec); + if (trackingUrlTemplate_ != null) { + size += _single_trackingUrlTemplate_codec.CalculateSizeWithTag(TrackingUrlTemplate); + } + size += urlCustomParameters_.CalculateSize(_repeated_urlCustomParameters_codec); + if (finalUrlSuffix_ != null) { + size += _single_finalUrlSuffix_codec.CalculateSizeWithTag(FinalUrlSuffix); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SitelinkFeedItem other) { + if (other == null) { + return; + } + if (other.linkText_ != null) { + if (linkText_ == null || other.LinkText != "") { + LinkText = other.LinkText; + } + } + if (other.line1_ != null) { + if (line1_ == null || other.Line1 != "") { + Line1 = other.Line1; + } + } + if (other.line2_ != null) { + if (line2_ == null || other.Line2 != "") { + Line2 = other.Line2; + } + } + finalUrls_.Add(other.finalUrls_); + finalMobileUrls_.Add(other.finalMobileUrls_); + if (other.trackingUrlTemplate_ != null) { + if (trackingUrlTemplate_ == null || other.TrackingUrlTemplate != "") { + TrackingUrlTemplate = other.TrackingUrlTemplate; + } + } + urlCustomParameters_.Add(other.urlCustomParameters_); + if (other.finalUrlSuffix_ != null) { + if (finalUrlSuffix_ == null || other.FinalUrlSuffix != "") { + FinalUrlSuffix = other.FinalUrlSuffix; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_linkText_codec.Read(input); + if (linkText_ == null || value != "") { + LinkText = value; + } + break; + } + case 18: { + string value = _single_line1_codec.Read(input); + if (line1_ == null || value != "") { + Line1 = value; + } + break; + } + case 26: { + string value = _single_line2_codec.Read(input); + if (line2_ == null || value != "") { + Line2 = value; + } + break; + } + case 34: { + finalUrls_.AddEntriesFrom(input, _repeated_finalUrls_codec); + break; + } + case 42: { + finalMobileUrls_.AddEntriesFrom(input, _repeated_finalMobileUrls_codec); + break; + } + case 50: { + string value = _single_trackingUrlTemplate_codec.Read(input); + if (trackingUrlTemplate_ == null || value != "") { + TrackingUrlTemplate = value; + } + break; + } + case 58: { + urlCustomParameters_.AddEntriesFrom(input, _repeated_urlCustomParameters_codec); + break; + } + case 66: { + string value = _single_finalUrlSuffix_codec.Read(input); + if (finalUrlSuffix_ == null || value != "") { + FinalUrlSuffix = value; + } + break; + } + } + } + } + + } + + /// + /// Represents a hotel callout extension. + /// + public sealed partial class HotelCalloutFeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelCalloutFeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.ExtensionsReflection.Descriptor.MessageTypes[11]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCalloutFeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCalloutFeedItem(HotelCalloutFeedItem other) : this() { + Text = other.Text; + LanguageCode = other.LanguageCode; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelCalloutFeedItem Clone() { + return new HotelCalloutFeedItem(this); + } + + /// Field number for the "text" field. + public const int TextFieldNumber = 1; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(10); + private string text_; + /// + /// The callout text. + /// The length of this string should be between 1 and 25, inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + /// Field number for the "language_code" field. + public const int LanguageCodeFieldNumber = 2; + private static readonly pb::FieldCodec _single_languageCode_codec = pb::FieldCodec.ForClassWrapper(18); + private string languageCode_; + /// + /// The language of the hotel callout text. + /// IETF BCP 47 compliant language code. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string LanguageCode { + get { return languageCode_; } + set { + languageCode_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelCalloutFeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelCalloutFeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Text != other.Text) return false; + if (LanguageCode != other.LanguageCode) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (text_ != null) hash ^= Text.GetHashCode(); + if (languageCode_ != null) hash ^= LanguageCode.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (languageCode_ != null) { + _single_languageCode_codec.WriteTagAndValue(output, LanguageCode); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (languageCode_ != null) { + size += _single_languageCode_codec.CalculateSizeWithTag(LanguageCode); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelCalloutFeedItem other) { + if (other == null) { + return; + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + if (other.languageCode_ != null) { + if (languageCode_ == null || other.LanguageCode != "") { + LanguageCode = other.LanguageCode; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + case 18: { + string value = _single_languageCode_codec.Read(input); + if (languageCode_ == null || value != "") { + LanguageCode = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ExternalConversionSource.cs b/src/V3/Stubs/ExternalConversionSource.cs new file mode 100644 index 000000000..a220cb73a --- /dev/null +++ b/src/V3/Stubs/ExternalConversionSource.cs @@ -0,0 +1,295 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/external_conversion_source.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/external_conversion_source.proto + public static partial class ExternalConversionSourceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/external_conversion_source.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ExternalConversionSourceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9leHRlcm5hbF9jb252", + "ZXJzaW9uX3NvdXJjZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8igAQKHEV4dGVy", + "bmFsQ29udmVyc2lvblNvdXJjZUVudW0i3wMKGEV4dGVybmFsQ29udmVyc2lv", + "blNvdXJjZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARILCgdXRUJQ", + "QUdFEAISDQoJQU5BTFlUSUNTEAMSCgoGVVBMT0FEEAQSEwoPQURfQ0FMTF9N", + "RVRSSUNTEAUSGAoUV0VCU0lURV9DQUxMX01FVFJJQ1MQBhIQCgxTVE9SRV9W", + "SVNJVFMQBxISCg5BTkRST0lEX0lOX0FQUBAIEg4KCklPU19JTl9BUFAQCRIS", + "Cg5JT1NfRklSU1RfT1BFThAKEhMKD0FQUF9VTlNQRUNJRklFRBALEhYKEkFO", + "RFJPSURfRklSU1RfT1BFThAMEhAKDFVQTE9BRF9DQUxMUxANEgwKCEZJUkVC", + "QVNFEA4SEQoNQ0xJQ0tfVE9fQ0FMTBAPEg4KClNBTEVTRk9SQ0UQEBITCg9T", + "VE9SRV9TQUxFU19DUk0QERIfChtTVE9SRV9TQUxFU19QQVlNRU5UX05FVFdP", + "UksQEhIPCgtHT09HTEVfUExBWRATEh0KGVRISVJEX1BBUlRZX0FQUF9BTkFM", + "WVRJQ1MQFBIWChJHT09HTEVfQVRUUklCVVRJT04QFRIWChJTVE9SRV9TQUxF", + "U19ESVJFQ1QQFkLyAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zQh1FeHRlcm5hbENvbnZlcnNpb25Tb3VyY2VQcm90b1ABWkJnb29nbGUu", + "Z29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMv", + "djMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5W", + "My5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29v", + "Z2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.ExternalConversionSourceEnum), global::Google.Ads.GoogleAds.V3.Enums.ExternalConversionSourceEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.ExternalConversionSourceEnum.Types.ExternalConversionSource) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the external conversion source that is + /// associated with a ConversionAction. + /// + public sealed partial class ExternalConversionSourceEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ExternalConversionSourceEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.ExternalConversionSourceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExternalConversionSourceEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExternalConversionSourceEnum(ExternalConversionSourceEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ExternalConversionSourceEnum Clone() { + return new ExternalConversionSourceEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ExternalConversionSourceEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ExternalConversionSourceEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ExternalConversionSourceEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ExternalConversionSourceEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The external conversion source that is associated with a ConversionAction. + /// + public enum ExternalConversionSource { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Conversion that occurs when a user navigates to a particular webpage + /// after viewing an ad; Displayed in Google Ads UI as 'Website'. + /// + [pbr::OriginalName("WEBPAGE")] Webpage = 2, + /// + /// Conversion that comes from linked Google Analytics goal or transaction; + /// Displayed in Google Ads UI as 'Analytics'. + /// + [pbr::OriginalName("ANALYTICS")] Analytics = 3, + /// + /// Website conversion that is uploaded through ConversionUploadService; + /// Displayed in Google Ads UI as 'Import from clicks'. + /// + [pbr::OriginalName("UPLOAD")] Upload = 4, + /// + /// Conversion that occurs when a user clicks on a call extension directly on + /// an ad; Displayed in Google Ads UI as 'Calls from ads'. + /// + [pbr::OriginalName("AD_CALL_METRICS")] AdCallMetrics = 5, + /// + /// Conversion that occurs when a user calls a dynamically-generated phone + /// number (by installed javascript) from an advertiser's website after + /// clicking on an ad; Displayed in Google Ads UI as 'Calls from website'. + /// + [pbr::OriginalName("WEBSITE_CALL_METRICS")] WebsiteCallMetrics = 6, + /// + /// Conversion that occurs when a user visits an advertiser's retail store + /// after clicking on a Google ad; + /// Displayed in Google Ads UI as 'Store visits'. + /// + [pbr::OriginalName("STORE_VISITS")] StoreVisits = 7, + /// + /// Conversion that occurs when a user takes an in-app action such as a + /// purchase in an Android app; + /// Displayed in Google Ads UI as 'Android in-app action'. + /// + [pbr::OriginalName("ANDROID_IN_APP")] AndroidInApp = 8, + /// + /// Conversion that occurs when a user takes an in-app action such as a + /// purchase in an iOS app; + /// Displayed in Google Ads UI as 'iOS in-app action'. + /// + [pbr::OriginalName("IOS_IN_APP")] IosInApp = 9, + /// + /// Conversion that occurs when a user opens an iOS app for the first time; + /// Displayed in Google Ads UI as 'iOS app install (first open)'. + /// + [pbr::OriginalName("IOS_FIRST_OPEN")] IosFirstOpen = 10, + /// + /// Legacy app conversions that do not have an AppPlatform provided; + /// Displayed in Google Ads UI as 'Mobile app'. + /// + [pbr::OriginalName("APP_UNSPECIFIED")] AppUnspecified = 11, + /// + /// Conversion that occurs when a user opens an Android app for the first + /// time; Displayed in Google Ads UI as 'Android app install (first open)'. + /// + [pbr::OriginalName("ANDROID_FIRST_OPEN")] AndroidFirstOpen = 12, + /// + /// Call conversion that is uploaded through ConversionUploadService; + /// Displayed in Google Ads UI as 'Import from calls'. + /// + [pbr::OriginalName("UPLOAD_CALLS")] UploadCalls = 13, + /// + /// Conversion that comes from a linked Firebase event; + /// Displayed in Google Ads UI as 'Firebase'. + /// + [pbr::OriginalName("FIREBASE")] Firebase = 14, + /// + /// Conversion that occurs when a user clicks on a mobile phone number; + /// Displayed in Google Ads UI as 'Phone number clicks'. + /// + [pbr::OriginalName("CLICK_TO_CALL")] ClickToCall = 15, + /// + /// Conversion that comes from Salesforce; + /// Displayed in Google Ads UI as 'Salesforce.com'. + /// + [pbr::OriginalName("SALESFORCE")] Salesforce = 16, + /// + /// Conversion that comes from in-store purchases recorded by CRM; + /// Displayed in Google Ads UI as 'Store sales (data partner)'. + /// + [pbr::OriginalName("STORE_SALES_CRM")] StoreSalesCrm = 17, + /// + /// Conversion that comes from in-store purchases from payment network; + /// Displayed in Google Ads UI as 'Store sales (payment network)'. + /// + [pbr::OriginalName("STORE_SALES_PAYMENT_NETWORK")] StoreSalesPaymentNetwork = 18, + /// + /// Codeless Google Play conversion; + /// Displayed in Google Ads UI as 'Google Play'. + /// + [pbr::OriginalName("GOOGLE_PLAY")] GooglePlay = 19, + /// + /// Conversion that comes from a linked third-party app analytics event; + /// Displayed in Google Ads UI as 'Third-party app analytics'. + /// + [pbr::OriginalName("THIRD_PARTY_APP_ANALYTICS")] ThirdPartyAppAnalytics = 20, + /// + /// Conversion that is controlled by Google Attribution. + /// + [pbr::OriginalName("GOOGLE_ATTRIBUTION")] GoogleAttribution = 21, + /// + /// Store Sales conversion based on first-party or third-party merchant data + /// uploads. Displayed in Google Ads UI as 'Store sales (direct)'. + /// + [pbr::OriginalName("STORE_SALES_DIRECT")] StoreSalesDirect = 22, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Feed.cs b/src/V3/Stubs/Feed.cs new file mode 100644 index 000000000..769d716e4 --- /dev/null +++ b/src/V3/Stubs/Feed.cs @@ -0,0 +1,1694 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/feed.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/feed.proto + public static partial class FeedReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/feed.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cixnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZmVlZC5wcm90", + "bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzGk1nb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9lbnVtcy9hZmZpbGlhdGVfbG9jYXRpb25fZmVl", + "ZF9yZWxhdGlvbnNoaXBfdHlwZS5wcm90bxo3Z29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvZW51bXMvZmVlZF9hdHRyaWJ1dGVfdHlwZS5wcm90bxovZ29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvZmVlZF9vcmlnaW4ucHJvdG8aL2dv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2ZlZWRfc3RhdHVzLnByb3Rv", + "Gh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29nbGUvYXBp", + "L3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJv", + "dG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iwQwKBEZlZWQSPAoN", + "cmVzb3VyY2VfbmFtZRgBIAEoCUIl4EEF+kEfCh1nb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vRmVlZBIsCgJpZBgCIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5J", + "bnQ2NFZhbHVlQgPgQQMSLwoEbmFtZRgDIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZUID4EEFEkQKCmF0dHJpYnV0ZXMYBCADKAsyMC5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuRmVlZEF0dHJpYnV0ZRJX", + "ChRhdHRyaWJ1dGVfb3BlcmF0aW9ucxgJIAMoCzI5Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5GZWVkQXR0cmlidXRlT3BlcmF0aW9uEk0K", + "Bm9yaWdpbhgFIAEoDjI4Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "LkZlZWRPcmlnaW5FbnVtLkZlZWRPcmlnaW5CA+BBBRJNCgZzdGF0dXMYCCAB", + "KA4yOC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5GZWVkU3RhdHVz", + "RW51bS5GZWVkU3RhdHVzQgPgQQMSYwoZcGxhY2VzX2xvY2F0aW9uX2ZlZWRf", + "ZGF0YRgGIAEoCzI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cy5GZWVkLlBsYWNlc0xvY2F0aW9uRmVlZERhdGFIABJpChxhZmZpbGlhdGVf", + "bG9jYXRpb25fZmVlZF9kYXRhGAcgASgLMkEuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMucmVzb3VyY2VzLkZlZWQuQWZmaWxpYXRlTG9jYXRpb25GZWVkRGF0", + "YUgAGs4EChZQbGFjZXNMb2NhdGlvbkZlZWREYXRhEmEKCm9hdXRoX2luZm8Y", + "ASABKAsySC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuRmVl", + "ZC5QbGFjZXNMb2NhdGlvbkZlZWREYXRhLk9BdXRoSW5mb0ID4EEFEjMKDWVt", + "YWlsX2FkZHJlc3MYAiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFs", + "dWUSOQoTYnVzaW5lc3NfYWNjb3VudF9pZBgKIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZRI6ChRidXNpbmVzc19uYW1lX2ZpbHRlchgEIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI2ChBjYXRlZ29yeV9m", + "aWx0ZXJzGAUgAygLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEjMK", + "DWxhYmVsX2ZpbHRlcnMYBiADKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5n", + "VmFsdWUatwEKCU9BdXRoSW5mbxIxCgtodHRwX21ldGhvZBgBIAEoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRI2ChBodHRwX3JlcXVlc3RfdXJs", + "GAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEj8KGWh0dHBf", + "YXV0aG9yaXphdGlvbl9oZWFkZXIYAyABKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWUa1wEKGUFmZmlsaWF0ZUxvY2F0aW9uRmVlZERhdGESLgoJ", + "Y2hhaW5faWRzGAEgAygLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUS", + "iQEKEXJlbGF0aW9uc2hpcF90eXBlGAIgASgOMm4uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXMuQWZmaWxpYXRlTG9jYXRpb25GZWVkUmVsYXRpb25z", + "aGlwVHlwZUVudW0uQWZmaWxpYXRlTG9jYXRpb25GZWVkUmVsYXRpb25zaGlw", + "VHlwZTpF6kFCCh1nb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRmVlZBIhY3Vz", + "dG9tZXJzL3tjdXN0b21lcn0vZmVlZHMve2ZlZWR9Qh0KG3N5c3RlbV9mZWVk", + "X2dlbmVyYXRpb25fZGF0YSLuAQoNRmVlZEF0dHJpYnV0ZRInCgJpZBgBIAEo", + "CzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlEioKBG5hbWUYAiABKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSVAoEdHlwZRgDIAEoDjJG", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkZlZWRBdHRyaWJ1dGVU", + "eXBlRW51bS5GZWVkQXR0cmlidXRlVHlwZRIyCg5pc19wYXJ0X29mX2tleRgE", + "IAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29sVmFsdWUi7AEKFkZlZWRBdHRy", + "aWJ1dGVPcGVyYXRpb24SWQoIb3BlcmF0b3IYASABKA4yQi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuRmVlZEF0dHJpYnV0ZU9wZXJhdGlv", + "bi5PcGVyYXRvckID4EEDEkQKBXZhbHVlGAIgASgLMjAuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMucmVzb3VyY2VzLkZlZWRBdHRyaWJ1dGVCA+BBAyIxCghP", + "cGVyYXRvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIHCgNBREQQ", + "AkL2AQolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IJ", + "RmVlZFByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogID", + "R0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationFeedRelationshipTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedOriginReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Feed), global::Google.Ads.GoogleAds.V3.Resources.Feed.Parser, new[]{ "ResourceName", "Id", "Name", "Attributes", "AttributeOperations", "Origin", "Status", "PlacesLocationFeedData", "AffiliateLocationFeedData" }, new[]{ "SystemFeedGenerationData" }, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData), global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Parser, new[]{ "OauthInfo", "EmailAddress", "BusinessAccountId", "BusinessNameFilter", "CategoryFilters", "LabelFilters" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Types.OAuthInfo), global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Types.OAuthInfo.Parser, new[]{ "HttpMethod", "HttpRequestUrl", "HttpAuthorizationHeader" }, null, null, null)}), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.AffiliateLocationFeedData), global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.AffiliateLocationFeedData.Parser, new[]{ "ChainIds", "RelationshipType" }, null, null, null)}), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedAttribute), global::Google.Ads.GoogleAds.V3.Resources.FeedAttribute.Parser, new[]{ "Id", "Name", "Type", "IsPartOfKey" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedAttributeOperation), global::Google.Ads.GoogleAds.V3.Resources.FeedAttributeOperation.Parser, new[]{ "Operator", "Value" }, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedAttributeOperation.Types.Operator) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// A feed. + /// + public sealed partial class Feed : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Feed()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Feed() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Feed(Feed other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + attributes_ = other.attributes_.Clone(); + attributeOperations_ = other.attributeOperations_.Clone(); + origin_ = other.origin_; + status_ = other.status_; + switch (other.SystemFeedGenerationDataCase) { + case SystemFeedGenerationDataOneofCase.PlacesLocationFeedData: + PlacesLocationFeedData = other.PlacesLocationFeedData.Clone(); + break; + case SystemFeedGenerationDataOneofCase.AffiliateLocationFeedData: + AffiliateLocationFeedData = other.AffiliateLocationFeedData.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Feed Clone() { + return new Feed(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the feed. + /// Feed resource names have the form: + /// + /// `customers/{customer_id}/feeds/{feed_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the feed. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 3; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(26); + private string name_; + /// + /// Immutable. Name of the feed. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "attributes" field. + public const int AttributesFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_attributes_codec + = pb::FieldCodec.ForMessage(34, global::Google.Ads.GoogleAds.V3.Resources.FeedAttribute.Parser); + private readonly pbc::RepeatedField attributes_ = new pbc::RepeatedField(); + /// + /// The Feed's attributes. Required on CREATE, unless + /// system_feed_generation_data is provided, in which case Google Ads will + /// update the feed with the correct attributes. + /// Disallowed on UPDATE. Use attribute_operations to add new attributes. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Attributes { + get { return attributes_; } + } + + /// Field number for the "attribute_operations" field. + public const int AttributeOperationsFieldNumber = 9; + private static readonly pb::FieldCodec _repeated_attributeOperations_codec + = pb::FieldCodec.ForMessage(74, global::Google.Ads.GoogleAds.V3.Resources.FeedAttributeOperation.Parser); + private readonly pbc::RepeatedField attributeOperations_ = new pbc::RepeatedField(); + /// + /// The list of operations changing the feed attributes. Attributes can only + /// be added, not removed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField AttributeOperations { + get { return attributeOperations_; } + } + + /// Field number for the "origin" field. + public const int OriginFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.FeedOriginEnum.Types.FeedOrigin origin_ = 0; + /// + /// Immutable. Specifies who manages the FeedAttributes for the Feed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedOriginEnum.Types.FeedOrigin Origin { + get { return origin_; } + set { + origin_ = value; + } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 8; + private global::Google.Ads.GoogleAds.V3.Enums.FeedStatusEnum.Types.FeedStatus status_ = 0; + /// + /// Output only. Status of the feed. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedStatusEnum.Types.FeedStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "places_location_feed_data" field. + public const int PlacesLocationFeedDataFieldNumber = 6; + /// + /// Data used to configure a location feed populated from Google My Business + /// Locations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData PlacesLocationFeedData { + get { return systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.PlacesLocationFeedData ? (global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData) systemFeedGenerationData_ : null; } + set { + systemFeedGenerationData_ = value; + systemFeedGenerationDataCase_ = value == null ? SystemFeedGenerationDataOneofCase.None : SystemFeedGenerationDataOneofCase.PlacesLocationFeedData; + } + } + + /// Field number for the "affiliate_location_feed_data" field. + public const int AffiliateLocationFeedDataFieldNumber = 7; + /// + /// Data used to configure an affiliate location feed populated with + /// the specified chains. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.AffiliateLocationFeedData AffiliateLocationFeedData { + get { return systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.AffiliateLocationFeedData ? (global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.AffiliateLocationFeedData) systemFeedGenerationData_ : null; } + set { + systemFeedGenerationData_ = value; + systemFeedGenerationDataCase_ = value == null ? SystemFeedGenerationDataOneofCase.None : SystemFeedGenerationDataOneofCase.AffiliateLocationFeedData; + } + } + + private object systemFeedGenerationData_; + /// Enum of possible cases for the "system_feed_generation_data" oneof. + public enum SystemFeedGenerationDataOneofCase { + None = 0, + PlacesLocationFeedData = 6, + AffiliateLocationFeedData = 7, + } + private SystemFeedGenerationDataOneofCase systemFeedGenerationDataCase_ = SystemFeedGenerationDataOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SystemFeedGenerationDataOneofCase SystemFeedGenerationDataCase { + get { return systemFeedGenerationDataCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearSystemFeedGenerationData() { + systemFeedGenerationDataCase_ = SystemFeedGenerationDataOneofCase.None; + systemFeedGenerationData_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as Feed); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(Feed other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if(!attributes_.Equals(other.attributes_)) return false; + if(!attributeOperations_.Equals(other.attributeOperations_)) return false; + if (Origin != other.Origin) return false; + if (Status != other.Status) return false; + if (!object.Equals(PlacesLocationFeedData, other.PlacesLocationFeedData)) return false; + if (!object.Equals(AffiliateLocationFeedData, other.AffiliateLocationFeedData)) return false; + if (SystemFeedGenerationDataCase != other.SystemFeedGenerationDataCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + hash ^= attributes_.GetHashCode(); + hash ^= attributeOperations_.GetHashCode(); + if (Origin != 0) hash ^= Origin.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.PlacesLocationFeedData) hash ^= PlacesLocationFeedData.GetHashCode(); + if (systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.AffiliateLocationFeedData) hash ^= AffiliateLocationFeedData.GetHashCode(); + hash ^= (int) systemFeedGenerationDataCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + attributes_.WriteTo(output, _repeated_attributes_codec); + if (Origin != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) Origin); + } + if (systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.PlacesLocationFeedData) { + output.WriteRawTag(50); + output.WriteMessage(PlacesLocationFeedData); + } + if (systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.AffiliateLocationFeedData) { + output.WriteRawTag(58); + output.WriteMessage(AffiliateLocationFeedData); + } + if (Status != 0) { + output.WriteRawTag(64); + output.WriteEnum((int) Status); + } + attributeOperations_.WriteTo(output, _repeated_attributeOperations_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + size += attributes_.CalculateSize(_repeated_attributes_codec); + size += attributeOperations_.CalculateSize(_repeated_attributeOperations_codec); + if (Origin != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Origin); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.PlacesLocationFeedData) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PlacesLocationFeedData); + } + if (systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.AffiliateLocationFeedData) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AffiliateLocationFeedData); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(Feed other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + attributes_.Add(other.attributes_); + attributeOperations_.Add(other.attributeOperations_); + if (other.Origin != 0) { + Origin = other.Origin; + } + if (other.Status != 0) { + Status = other.Status; + } + switch (other.SystemFeedGenerationDataCase) { + case SystemFeedGenerationDataOneofCase.PlacesLocationFeedData: + if (PlacesLocationFeedData == null) { + PlacesLocationFeedData = new global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData(); + } + PlacesLocationFeedData.MergeFrom(other.PlacesLocationFeedData); + break; + case SystemFeedGenerationDataOneofCase.AffiliateLocationFeedData: + if (AffiliateLocationFeedData == null) { + AffiliateLocationFeedData = new global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.AffiliateLocationFeedData(); + } + AffiliateLocationFeedData.MergeFrom(other.AffiliateLocationFeedData); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 26: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 34: { + attributes_.AddEntriesFrom(input, _repeated_attributes_codec); + break; + } + case 40: { + Origin = (global::Google.Ads.GoogleAds.V3.Enums.FeedOriginEnum.Types.FeedOrigin) input.ReadEnum(); + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData(); + if (systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.PlacesLocationFeedData) { + subBuilder.MergeFrom(PlacesLocationFeedData); + } + input.ReadMessage(subBuilder); + PlacesLocationFeedData = subBuilder; + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.AffiliateLocationFeedData subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.AffiliateLocationFeedData(); + if (systemFeedGenerationDataCase_ == SystemFeedGenerationDataOneofCase.AffiliateLocationFeedData) { + subBuilder.MergeFrom(AffiliateLocationFeedData); + } + input.ReadMessage(subBuilder); + AffiliateLocationFeedData = subBuilder; + break; + } + case 64: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.FeedStatusEnum.Types.FeedStatus) input.ReadEnum(); + break; + } + case 74: { + attributeOperations_.AddEntriesFrom(input, _repeated_attributeOperations_codec); + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the Feed message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Data used to configure a location feed populated from Google My Business + /// Locations. + /// + public sealed partial class PlacesLocationFeedData : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new PlacesLocationFeedData()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Feed.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PlacesLocationFeedData() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PlacesLocationFeedData(PlacesLocationFeedData other) : this() { + oauthInfo_ = other.oauthInfo_ != null ? other.oauthInfo_.Clone() : null; + EmailAddress = other.EmailAddress; + BusinessAccountId = other.BusinessAccountId; + BusinessNameFilter = other.BusinessNameFilter; + categoryFilters_ = other.categoryFilters_.Clone(); + labelFilters_ = other.labelFilters_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public PlacesLocationFeedData Clone() { + return new PlacesLocationFeedData(this); + } + + /// Field number for the "oauth_info" field. + public const int OauthInfoFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Types.OAuthInfo oauthInfo_; + /// + /// Immutable. Required authentication token (from OAuth API) for the email. + /// This field can only be specified in a create request. All its subfields + /// are not selectable. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Types.OAuthInfo OauthInfo { + get { return oauthInfo_; } + set { + oauthInfo_ = value; + } + } + + /// Field number for the "email_address" field. + public const int EmailAddressFieldNumber = 2; + private static readonly pb::FieldCodec _single_emailAddress_codec = pb::FieldCodec.ForClassWrapper(18); + private string emailAddress_; + /// + /// Email address of a Google My Business account or email address of a + /// manager of the Google My Business account. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EmailAddress { + get { return emailAddress_; } + set { + emailAddress_ = value; + } + } + + + /// Field number for the "business_account_id" field. + public const int BusinessAccountIdFieldNumber = 10; + private static readonly pb::FieldCodec _single_businessAccountId_codec = pb::FieldCodec.ForClassWrapper(82); + private string businessAccountId_; + /// + /// Plus page ID of the managed business whose locations should be used. If + /// this field is not set, then all businesses accessible by the user + /// (specified by email_address) are used. + /// This field is mutate-only and is not selectable. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessAccountId { + get { return businessAccountId_; } + set { + businessAccountId_ = value; + } + } + + + /// Field number for the "business_name_filter" field. + public const int BusinessNameFilterFieldNumber = 4; + private static readonly pb::FieldCodec _single_businessNameFilter_codec = pb::FieldCodec.ForClassWrapper(34); + private string businessNameFilter_; + /// + /// Used to filter Google My Business listings by business name. If + /// business_name_filter is set, only listings with a matching business name + /// are candidates to be sync'd into FeedItems. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BusinessNameFilter { + get { return businessNameFilter_; } + set { + businessNameFilter_ = value; + } + } + + + /// Field number for the "category_filters" field. + public const int CategoryFiltersFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_categoryFilters_codec + = pb::FieldCodec.ForClassWrapper(42); + private readonly pbc::RepeatedField categoryFilters_ = new pbc::RepeatedField(); + /// + /// Used to filter Google My Business listings by categories. If entries + /// exist in category_filters, only listings that belong to any of the + /// categories are candidates to be sync'd into FeedItems. If no entries + /// exist in category_filters, then all listings are candidates for syncing. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField CategoryFilters { + get { return categoryFilters_; } + } + + /// Field number for the "label_filters" field. + public const int LabelFiltersFieldNumber = 6; + private static readonly pb::FieldCodec _repeated_labelFilters_codec + = pb::FieldCodec.ForClassWrapper(50); + private readonly pbc::RepeatedField labelFilters_ = new pbc::RepeatedField(); + /// + /// Used to filter Google My Business listings by labels. If entries exist in + /// label_filters, only listings that has any of the labels set are + /// candidates to be synchronized into FeedItems. If no entries exist in + /// label_filters, then all listings are candidates for syncing. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField LabelFilters { + get { return labelFilters_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as PlacesLocationFeedData); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(PlacesLocationFeedData other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(OauthInfo, other.OauthInfo)) return false; + if (EmailAddress != other.EmailAddress) return false; + if (BusinessAccountId != other.BusinessAccountId) return false; + if (BusinessNameFilter != other.BusinessNameFilter) return false; + if(!categoryFilters_.Equals(other.categoryFilters_)) return false; + if(!labelFilters_.Equals(other.labelFilters_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (oauthInfo_ != null) hash ^= OauthInfo.GetHashCode(); + if (emailAddress_ != null) hash ^= EmailAddress.GetHashCode(); + if (businessAccountId_ != null) hash ^= BusinessAccountId.GetHashCode(); + if (businessNameFilter_ != null) hash ^= BusinessNameFilter.GetHashCode(); + hash ^= categoryFilters_.GetHashCode(); + hash ^= labelFilters_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (oauthInfo_ != null) { + output.WriteRawTag(10); + output.WriteMessage(OauthInfo); + } + if (emailAddress_ != null) { + _single_emailAddress_codec.WriteTagAndValue(output, EmailAddress); + } + if (businessNameFilter_ != null) { + _single_businessNameFilter_codec.WriteTagAndValue(output, BusinessNameFilter); + } + categoryFilters_.WriteTo(output, _repeated_categoryFilters_codec); + labelFilters_.WriteTo(output, _repeated_labelFilters_codec); + if (businessAccountId_ != null) { + _single_businessAccountId_codec.WriteTagAndValue(output, BusinessAccountId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (oauthInfo_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(OauthInfo); + } + if (emailAddress_ != null) { + size += _single_emailAddress_codec.CalculateSizeWithTag(EmailAddress); + } + if (businessAccountId_ != null) { + size += _single_businessAccountId_codec.CalculateSizeWithTag(BusinessAccountId); + } + if (businessNameFilter_ != null) { + size += _single_businessNameFilter_codec.CalculateSizeWithTag(BusinessNameFilter); + } + size += categoryFilters_.CalculateSize(_repeated_categoryFilters_codec); + size += labelFilters_.CalculateSize(_repeated_labelFilters_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(PlacesLocationFeedData other) { + if (other == null) { + return; + } + if (other.oauthInfo_ != null) { + if (oauthInfo_ == null) { + OauthInfo = new global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Types.OAuthInfo(); + } + OauthInfo.MergeFrom(other.OauthInfo); + } + if (other.emailAddress_ != null) { + if (emailAddress_ == null || other.EmailAddress != "") { + EmailAddress = other.EmailAddress; + } + } + if (other.businessAccountId_ != null) { + if (businessAccountId_ == null || other.BusinessAccountId != "") { + BusinessAccountId = other.BusinessAccountId; + } + } + if (other.businessNameFilter_ != null) { + if (businessNameFilter_ == null || other.BusinessNameFilter != "") { + BusinessNameFilter = other.BusinessNameFilter; + } + } + categoryFilters_.Add(other.categoryFilters_); + labelFilters_.Add(other.labelFilters_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (oauthInfo_ == null) { + OauthInfo = new global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Types.OAuthInfo(); + } + input.ReadMessage(OauthInfo); + break; + } + case 18: { + string value = _single_emailAddress_codec.Read(input); + if (emailAddress_ == null || value != "") { + EmailAddress = value; + } + break; + } + case 34: { + string value = _single_businessNameFilter_codec.Read(input); + if (businessNameFilter_ == null || value != "") { + BusinessNameFilter = value; + } + break; + } + case 42: { + categoryFilters_.AddEntriesFrom(input, _repeated_categoryFilters_codec); + break; + } + case 50: { + labelFilters_.AddEntriesFrom(input, _repeated_labelFilters_codec); + break; + } + case 82: { + string value = _single_businessAccountId_codec.Read(input); + if (businessAccountId_ == null || value != "") { + BusinessAccountId = value; + } + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the PlacesLocationFeedData message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Data used for authorization using OAuth. + /// + public sealed partial class OAuthInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new OAuthInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Feed.Types.PlacesLocationFeedData.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OAuthInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OAuthInfo(OAuthInfo other) : this() { + HttpMethod = other.HttpMethod; + HttpRequestUrl = other.HttpRequestUrl; + HttpAuthorizationHeader = other.HttpAuthorizationHeader; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OAuthInfo Clone() { + return new OAuthInfo(this); + } + + /// Field number for the "http_method" field. + public const int HttpMethodFieldNumber = 1; + private static readonly pb::FieldCodec _single_httpMethod_codec = pb::FieldCodec.ForClassWrapper(10); + private string httpMethod_; + /// + /// The HTTP method used to obtain authorization. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string HttpMethod { + get { return httpMethod_; } + set { + httpMethod_ = value; + } + } + + + /// Field number for the "http_request_url" field. + public const int HttpRequestUrlFieldNumber = 2; + private static readonly pb::FieldCodec _single_httpRequestUrl_codec = pb::FieldCodec.ForClassWrapper(18); + private string httpRequestUrl_; + /// + /// The HTTP request URL used to obtain authorization. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string HttpRequestUrl { + get { return httpRequestUrl_; } + set { + httpRequestUrl_ = value; + } + } + + + /// Field number for the "http_authorization_header" field. + public const int HttpAuthorizationHeaderFieldNumber = 3; + private static readonly pb::FieldCodec _single_httpAuthorizationHeader_codec = pb::FieldCodec.ForClassWrapper(26); + private string httpAuthorizationHeader_; + /// + /// The HTTP authorization header used to obtain authorization. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string HttpAuthorizationHeader { + get { return httpAuthorizationHeader_; } + set { + httpAuthorizationHeader_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as OAuthInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(OAuthInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (HttpMethod != other.HttpMethod) return false; + if (HttpRequestUrl != other.HttpRequestUrl) return false; + if (HttpAuthorizationHeader != other.HttpAuthorizationHeader) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (httpMethod_ != null) hash ^= HttpMethod.GetHashCode(); + if (httpRequestUrl_ != null) hash ^= HttpRequestUrl.GetHashCode(); + if (httpAuthorizationHeader_ != null) hash ^= HttpAuthorizationHeader.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (httpMethod_ != null) { + _single_httpMethod_codec.WriteTagAndValue(output, HttpMethod); + } + if (httpRequestUrl_ != null) { + _single_httpRequestUrl_codec.WriteTagAndValue(output, HttpRequestUrl); + } + if (httpAuthorizationHeader_ != null) { + _single_httpAuthorizationHeader_codec.WriteTagAndValue(output, HttpAuthorizationHeader); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (httpMethod_ != null) { + size += _single_httpMethod_codec.CalculateSizeWithTag(HttpMethod); + } + if (httpRequestUrl_ != null) { + size += _single_httpRequestUrl_codec.CalculateSizeWithTag(HttpRequestUrl); + } + if (httpAuthorizationHeader_ != null) { + size += _single_httpAuthorizationHeader_codec.CalculateSizeWithTag(HttpAuthorizationHeader); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(OAuthInfo other) { + if (other == null) { + return; + } + if (other.httpMethod_ != null) { + if (httpMethod_ == null || other.HttpMethod != "") { + HttpMethod = other.HttpMethod; + } + } + if (other.httpRequestUrl_ != null) { + if (httpRequestUrl_ == null || other.HttpRequestUrl != "") { + HttpRequestUrl = other.HttpRequestUrl; + } + } + if (other.httpAuthorizationHeader_ != null) { + if (httpAuthorizationHeader_ == null || other.HttpAuthorizationHeader != "") { + HttpAuthorizationHeader = other.HttpAuthorizationHeader; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_httpMethod_codec.Read(input); + if (httpMethod_ == null || value != "") { + HttpMethod = value; + } + break; + } + case 18: { + string value = _single_httpRequestUrl_codec.Read(input); + if (httpRequestUrl_ == null || value != "") { + HttpRequestUrl = value; + } + break; + } + case 26: { + string value = _single_httpAuthorizationHeader_codec.Read(input); + if (httpAuthorizationHeader_ == null || value != "") { + HttpAuthorizationHeader = value; + } + break; + } + } + } + } + + } + + } + #endregion + + } + + /// + /// Data used to configure an affiliate location feed populated with the + /// specified chains. + /// + public sealed partial class AffiliateLocationFeedData : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AffiliateLocationFeedData()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Feed.Descriptor.NestedTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedData() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedData(AffiliateLocationFeedData other) : this() { + chainIds_ = other.chainIds_.Clone(); + relationshipType_ = other.relationshipType_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AffiliateLocationFeedData Clone() { + return new AffiliateLocationFeedData(this); + } + + /// Field number for the "chain_ids" field. + public const int ChainIdsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_chainIds_codec + = pb::FieldCodec.ForStructWrapper(10); + private readonly pbc::RepeatedField chainIds_ = new pbc::RepeatedField(); + /// + /// The list of chains that the affiliate location feed will sync the + /// locations from. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ChainIds { + get { return chainIds_; } + } + + /// Field number for the "relationship_type" field. + public const int RelationshipTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationFeedRelationshipTypeEnum.Types.AffiliateLocationFeedRelationshipType relationshipType_ = 0; + /// + /// The relationship the chains have with the advertiser. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationFeedRelationshipTypeEnum.Types.AffiliateLocationFeedRelationshipType RelationshipType { + get { return relationshipType_; } + set { + relationshipType_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AffiliateLocationFeedData); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AffiliateLocationFeedData other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!chainIds_.Equals(other.chainIds_)) return false; + if (RelationshipType != other.RelationshipType) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= chainIds_.GetHashCode(); + if (RelationshipType != 0) hash ^= RelationshipType.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + chainIds_.WriteTo(output, _repeated_chainIds_codec); + if (RelationshipType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) RelationshipType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += chainIds_.CalculateSize(_repeated_chainIds_codec); + if (RelationshipType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) RelationshipType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AffiliateLocationFeedData other) { + if (other == null) { + return; + } + chainIds_.Add(other.chainIds_); + if (other.RelationshipType != 0) { + RelationshipType = other.RelationshipType; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + chainIds_.AddEntriesFrom(input, _repeated_chainIds_codec); + break; + } + case 16: { + RelationshipType = (global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationFeedRelationshipTypeEnum.Types.AffiliateLocationFeedRelationshipType) input.ReadEnum(); + break; + } + } + } + } + + } + + } + #endregion + + } + + /// + /// FeedAttributes define the types of data expected to be present in a Feed. A + /// single FeedAttribute specifies the expected type of the FeedItemAttributes + /// with the same FeedAttributeId. Optionally, a FeedAttribute can be marked as + /// being part of a FeedItem's unique key. + /// + public sealed partial class FeedAttribute : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedAttribute()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttribute() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttribute(FeedAttribute other) : this() { + Id = other.Id; + Name = other.Name; + type_ = other.type_; + IsPartOfKey = other.IsPartOfKey; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttribute Clone() { + return new FeedAttribute(this); + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 1; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(10); + private long? id_; + /// + /// ID of the attribute. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 2; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(18); + private string name_; + /// + /// The name of the attribute. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Types.FeedAttributeType type_ = 0; + /// + /// Data type for feed attribute. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Types.FeedAttributeType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "is_part_of_key" field. + public const int IsPartOfKeyFieldNumber = 4; + private static readonly pb::FieldCodec _single_isPartOfKey_codec = pb::FieldCodec.ForStructWrapper(34); + private bool? isPartOfKey_; + /// + /// Indicates that data corresponding to this attribute is part of a + /// FeedItem's unique key. It defaults to false if it is unspecified. Note + /// that a unique key is not required in a Feed's schema, in which case the + /// FeedItems must be referenced by their feed_item_id. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? IsPartOfKey { + get { return isPartOfKey_; } + set { + isPartOfKey_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedAttribute); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedAttribute other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (Type != other.Type) return false; + if (IsPartOfKey != other.IsPartOfKey) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (isPartOfKey_ != null) hash ^= IsPartOfKey.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (Type != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Type); + } + if (isPartOfKey_ != null) { + _single_isPartOfKey_codec.WriteTagAndValue(output, IsPartOfKey); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (isPartOfKey_ != null) { + size += _single_isPartOfKey_codec.CalculateSizeWithTag(IsPartOfKey); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedAttribute other) { + if (other == null) { + return; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.isPartOfKey_ != null) { + if (isPartOfKey_ == null || other.IsPartOfKey != false) { + IsPartOfKey = other.IsPartOfKey; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 18: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 24: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Types.FeedAttributeType) input.ReadEnum(); + break; + } + case 34: { + bool? value = _single_isPartOfKey_codec.Read(input); + if (isPartOfKey_ == null || value != false) { + IsPartOfKey = value; + } + break; + } + } + } + } + + } + + /// + /// Operation to be performed on a feed attribute list in a mutate. + /// + public sealed partial class FeedAttributeOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedAttributeOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeOperation(FeedAttributeOperation other) : this() { + operator_ = other.operator_; + value_ = other.value_ != null ? other.value_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeOperation Clone() { + return new FeedAttributeOperation(this); + } + + /// Field number for the "operator" field. + public const int OperatorFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Resources.FeedAttributeOperation.Types.Operator operator_ = 0; + /// + /// Output only. Type of list operation to perform. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedAttributeOperation.Types.Operator Operator { + get { return operator_; } + set { + operator_ = value; + } + } + + /// Field number for the "value" field. + public const int ValueFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Resources.FeedAttribute value_; + /// + /// Output only. The feed attribute being added to the list. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedAttribute Value { + get { return value_; } + set { + value_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedAttributeOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedAttributeOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Operator != other.Operator) return false; + if (!object.Equals(Value, other.Value)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Operator != 0) hash ^= Operator.GetHashCode(); + if (value_ != null) hash ^= Value.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Operator != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Operator); + } + if (value_ != null) { + output.WriteRawTag(18); + output.WriteMessage(Value); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Operator != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Operator); + } + if (value_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Value); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedAttributeOperation other) { + if (other == null) { + return; + } + if (other.Operator != 0) { + Operator = other.Operator; + } + if (other.value_ != null) { + if (value_ == null) { + Value = new global::Google.Ads.GoogleAds.V3.Resources.FeedAttribute(); + } + Value.MergeFrom(other.Value); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Operator = (global::Google.Ads.GoogleAds.V3.Resources.FeedAttributeOperation.Types.Operator) input.ReadEnum(); + break; + } + case 18: { + if (value_ == null) { + Value = new global::Google.Ads.GoogleAds.V3.Resources.FeedAttribute(); + } + input.ReadMessage(Value); + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedAttributeOperation message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The operator. + /// + public enum Operator { + /// + /// Unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Add the attribute to the existing attributes. + /// + [pbr::OriginalName("ADD")] Add = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedAttributeReferenceError.cs b/src/V3/Stubs/FeedAttributeReferenceError.cs new file mode 100644 index 000000000..154b6a334 --- /dev/null +++ b/src/V3/Stubs/FeedAttributeReferenceError.cs @@ -0,0 +1,191 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/feed_attribute_reference_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/feed_attribute_reference_error.proto + public static partial class FeedAttributeReferenceErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/feed_attribute_reference_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedAttributeReferenceErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZmVlZF9hdHRyaWJ1", + "dGVfcmVmZXJlbmNlX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lcnJvcnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iugEK", + "H0ZlZWRBdHRyaWJ1dGVSZWZlcmVuY2VFcnJvckVudW0ilgEKG0ZlZWRBdHRy", + "aWJ1dGVSZWZlcmVuY2VFcnJvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05P", + "V04QARIhCh1DQU5OT1RfUkVGRVJFTkNFX1JFTU9WRURfRkVFRBACEhUKEUlO", + "VkFMSURfRkVFRF9OQU1FEAMSHwobSU5WQUxJRF9GRUVEX0FUVFJJQlVURV9O", + "QU1FEARC+wEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNC", + "IEZlZWRBdHRyaWJ1dGVSZWZlcmVuY2VFcnJvclByb3RvUAFaRGdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9lcnJvcnM7ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFkcy5Hb29nbGVBZHMu", + "VjMuRXJyb3JzygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRXJyb3Jz6gIi", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVycm9yc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedAttributeReferenceErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FeedAttributeReferenceErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedAttributeReferenceErrorEnum.Types.FeedAttributeReferenceError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible feed attribute reference errors. + /// + public sealed partial class FeedAttributeReferenceErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedAttributeReferenceErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FeedAttributeReferenceErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeReferenceErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeReferenceErrorEnum(FeedAttributeReferenceErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeReferenceErrorEnum Clone() { + return new FeedAttributeReferenceErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedAttributeReferenceErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedAttributeReferenceErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedAttributeReferenceErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedAttributeReferenceErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible feed attribute reference errors. + /// + public enum FeedAttributeReferenceError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// A feed referenced by ID has been removed. + /// + [pbr::OriginalName("CANNOT_REFERENCE_REMOVED_FEED")] CannotReferenceRemovedFeed = 2, + /// + /// There is no enabled feed with the given name. + /// + [pbr::OriginalName("INVALID_FEED_NAME")] InvalidFeedName = 3, + /// + /// There is no feed attribute in an enabled feed with the given name. + /// + [pbr::OriginalName("INVALID_FEED_ATTRIBUTE_NAME")] InvalidFeedAttributeName = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedAttributeType.cs b/src/V3/Stubs/FeedAttributeType.cs new file mode 100644 index 000000000..5ba3f87ed --- /dev/null +++ b/src/V3/Stubs/FeedAttributeType.cs @@ -0,0 +1,232 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_attribute_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_attribute_type.proto + public static partial class FeedAttributeTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_attribute_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedAttributeTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2F0dHJpYnV0", + "ZV90eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxoc", + "Z29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKEAgoVRmVlZEF0dHJpYnV0", + "ZVR5cGVFbnVtIuoBChFGZWVkQXR0cmlidXRlVHlwZRIPCgtVTlNQRUNJRklF", + "RBAAEgsKB1VOS05PV04QARIJCgVJTlQ2NBACEgoKBkRPVUJMRRADEgoKBlNU", + "UklORxAEEgsKB0JPT0xFQU4QBRIHCgNVUkwQBhINCglEQVRFX1RJTUUQBxIO", + "CgpJTlQ2NF9MSVNUEAgSDwoLRE9VQkxFX0xJU1QQCRIPCgtTVFJJTkdfTElT", + "VBAKEhAKDEJPT0xFQU5fTElTVBALEgwKCFVSTF9MSVNUEAwSEgoOREFURV9U", + "SU1FX0xJU1QQDRIJCgVQUklDRRAOQusBCiFjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXNCFkZlZWRBdHRyaWJ1dGVUeXBlUHJvdG9QAVpCZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVB", + "ZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oC", + "IUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeEnum.Types.FeedAttributeType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible data types for a feed attribute. + /// + public sealed partial class FeedAttributeTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedAttributeTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedAttributeTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeTypeEnum(FeedAttributeTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedAttributeTypeEnum Clone() { + return new FeedAttributeTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedAttributeTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedAttributeTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedAttributeTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedAttributeTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible data types for a feed attribute. + /// + public enum FeedAttributeType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Int64. + /// + [pbr::OriginalName("INT64")] Int64 = 2, + /// + /// Double. + /// + [pbr::OriginalName("DOUBLE")] Double = 3, + /// + /// String. + /// + [pbr::OriginalName("STRING")] String = 4, + /// + /// Boolean. + /// + [pbr::OriginalName("BOOLEAN")] Boolean = 5, + /// + /// Url. + /// + [pbr::OriginalName("URL")] Url = 6, + /// + /// Datetime. + /// + [pbr::OriginalName("DATE_TIME")] DateTime = 7, + /// + /// Int64 list. + /// + [pbr::OriginalName("INT64_LIST")] Int64List = 8, + /// + /// Double (8 bytes) list. + /// + [pbr::OriginalName("DOUBLE_LIST")] DoubleList = 9, + /// + /// String list. + /// + [pbr::OriginalName("STRING_LIST")] StringList = 10, + /// + /// Boolean list. + /// + [pbr::OriginalName("BOOLEAN_LIST")] BooleanList = 11, + /// + /// Url list. + /// + [pbr::OriginalName("URL_LIST")] UrlList = 12, + /// + /// Datetime list. + /// + [pbr::OriginalName("DATE_TIME_LIST")] DateTimeList = 13, + /// + /// Price. + /// + [pbr::OriginalName("PRICE")] Price = 14, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedCommon.cs b/src/V3/Stubs/FeedCommon.cs new file mode 100644 index 000000000..c51a3de93 --- /dev/null +++ b/src/V3/Stubs/FeedCommon.cs @@ -0,0 +1,231 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/feed_common.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/feed_common.proto + public static partial class FeedCommonReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/feed_common.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedCommonReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZmVlZF9jb21tb24u", + "cHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbhoeZ29vZ2xl", + "L3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvInAKBU1vbmV5EjMKDWN1cnJlbmN5X2NvZGUYASABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMgoNYW1vdW50X21pY3JvcxgC", + "IAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQuoBCiJjb20uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uQg9GZWVkQ29tbW9uUHJvdG9Q", + "AVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMv", + "Z29vZ2xlYWRzL3YzL2NvbW1vbjtjb21tb26iAgNHQUGqAh5Hb29nbGUuQWRz", + "Lkdvb2dsZUFkcy5WMy5Db21tb27KAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xW", + "M1xDb21tb27qAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6Q29tbW9u", + "YgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.Money), global::Google.Ads.GoogleAds.V3.Common.Money.Parser, new[]{ "CurrencyCode", "AmountMicros" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Represents a price in a particular currency. + /// + public sealed partial class Money : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Money()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.FeedCommonReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Money() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Money(Money other) : this() { + CurrencyCode = other.CurrencyCode; + AmountMicros = other.AmountMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Money Clone() { + return new Money(this); + } + + /// Field number for the "currency_code" field. + public const int CurrencyCodeFieldNumber = 1; + private static readonly pb::FieldCodec _single_currencyCode_codec = pb::FieldCodec.ForClassWrapper(10); + private string currencyCode_; + /// + /// Three-character ISO 4217 currency code. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CurrencyCode { + get { return currencyCode_; } + set { + currencyCode_ = value; + } + } + + + /// Field number for the "amount_micros" field. + public const int AmountMicrosFieldNumber = 2; + private static readonly pb::FieldCodec _single_amountMicros_codec = pb::FieldCodec.ForStructWrapper(18); + private long? amountMicros_; + /// + /// Amount in micros. One million is equivalent to one unit. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AmountMicros { + get { return amountMicros_; } + set { + amountMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as Money); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(Money other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CurrencyCode != other.CurrencyCode) return false; + if (AmountMicros != other.AmountMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (currencyCode_ != null) hash ^= CurrencyCode.GetHashCode(); + if (amountMicros_ != null) hash ^= AmountMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (currencyCode_ != null) { + _single_currencyCode_codec.WriteTagAndValue(output, CurrencyCode); + } + if (amountMicros_ != null) { + _single_amountMicros_codec.WriteTagAndValue(output, AmountMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (currencyCode_ != null) { + size += _single_currencyCode_codec.CalculateSizeWithTag(CurrencyCode); + } + if (amountMicros_ != null) { + size += _single_amountMicros_codec.CalculateSizeWithTag(AmountMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(Money other) { + if (other == null) { + return; + } + if (other.currencyCode_ != null) { + if (currencyCode_ == null || other.CurrencyCode != "") { + CurrencyCode = other.CurrencyCode; + } + } + if (other.amountMicros_ != null) { + if (amountMicros_ == null || other.AmountMicros != 0L) { + AmountMicros = other.AmountMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_currencyCode_codec.Read(input); + if (currencyCode_ == null || value != "") { + CurrencyCode = value; + } + break; + } + case 18: { + long? value = _single_amountMicros_codec.Read(input); + if (amountMicros_ == null || value != 0L) { + AmountMicros = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedError.cs b/src/V3/Stubs/FeedError.cs new file mode 100644 index 000000000..fc9ab55b6 --- /dev/null +++ b/src/V3/Stubs/FeedError.cs @@ -0,0 +1,282 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/feed_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/feed_error.proto + public static partial class FeedErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/feed_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZmVlZF9lcnJvci5w", + "cm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxnb29nbGUv", + "YXBpL2Fubm90YXRpb25zLnByb3RvIsYGCg1GZWVkRXJyb3JFbnVtIrQGCglG", + "ZWVkRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESHgoaQVRU", + "UklCVVRFX05BTUVTX05PVF9VTklRVUUQAhIvCitBVFRSSUJVVEVTX0RPX05P", + "VF9NQVRDSF9FWElTVElOR19BVFRSSUJVVEVTEAMSLgoqQ0FOTk9UX1NQRUNJ", + "RllfVVNFUl9PUklHSU5fRk9SX1NZU1RFTV9GRUVEEAQSNAowQ0FOTk9UX1NQ", + "RUNJRllfR09PR0xFX09SSUdJTl9GT1JfTk9OX1NZU1RFTV9GRUVEEAUSMgou", + "Q0FOTk9UX1NQRUNJRllfRkVFRF9BVFRSSUJVVEVTX0ZPUl9TWVNURU1fRkVF", + "RBAGEjQKMENBTk5PVF9VUERBVEVfRkVFRF9BVFRSSUJVVEVTX1dJVEhfT1JJ", + "R0lOX0dPT0dMRRAHEhAKDEZFRURfUkVNT1ZFRBAIEhgKFElOVkFMSURfT1JJ", + "R0lOX1ZBTFVFEAkSGwoXRkVFRF9PUklHSU5fSVNfTk9UX1VTRVIQChIgChxJ", + "TlZBTElEX0FVVEhfVE9LRU5fRk9SX0VNQUlMEAsSEQoNSU5WQUxJRF9FTUFJ", + "TBAMEhcKE0RVUExJQ0FURV9GRUVEX05BTUUQDRIVChFJTlZBTElEX0ZFRURf", + "TkFNRRAOEhYKEk1JU1NJTkdfT0FVVEhfSU5GTxAPEi4KKk5FV19BVFRSSUJV", + "VEVfQ0FOTk9UX0JFX1BBUlRfT0ZfVU5JUVVFX0tFWRAQEhcKE1RPT19NQU5Z", + "X0FUVFJJQlVURVMQERIcChhJTlZBTElEX0JVU0lORVNTX0FDQ09VTlQQEhIz", + "Ci9CVVNJTkVTU19BQ0NPVU5UX0NBTk5PVF9BQ0NFU1NfTE9DQVRJT05fQUND", + "T1VOVBATEh4KGklOVkFMSURfQUZGSUxJQVRFX0NIQUlOX0lEEBQSGQoVRFVQ", + "TElDQVRFX1NZU1RFTV9GRUVEEBUSFAoQR01CX0FDQ0VTU19FUlJPUhAWEjUK", + "MUNBTk5PVF9IQVZFX0xPQ0FUSU9OX0FORF9BRkZJTElBVEVfTE9DQVRJT05f", + "RkVFRFMQF0LpAQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9y", + "c0IORmVlZEVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOi", + "AgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FeedErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedErrorEnum.Types.FeedError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible feed errors. + /// + public sealed partial class FeedErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FeedErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedErrorEnum(FeedErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedErrorEnum Clone() { + return new FeedErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible feed errors. + /// + public enum FeedError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The names of the FeedAttributes must be unique. + /// + [pbr::OriginalName("ATTRIBUTE_NAMES_NOT_UNIQUE")] AttributeNamesNotUnique = 2, + /// + /// The attribute list must be an exact copy of the existing list if the + /// attribute ID's are present. + /// + [pbr::OriginalName("ATTRIBUTES_DO_NOT_MATCH_EXISTING_ATTRIBUTES")] AttributesDoNotMatchExistingAttributes = 3, + /// + /// Cannot specify USER origin for a system generated feed. + /// + [pbr::OriginalName("CANNOT_SPECIFY_USER_ORIGIN_FOR_SYSTEM_FEED")] CannotSpecifyUserOriginForSystemFeed = 4, + /// + /// Cannot specify GOOGLE origin for a non-system generated feed. + /// + [pbr::OriginalName("CANNOT_SPECIFY_GOOGLE_ORIGIN_FOR_NON_SYSTEM_FEED")] CannotSpecifyGoogleOriginForNonSystemFeed = 5, + /// + /// Cannot specify feed attributes for system feed. + /// + [pbr::OriginalName("CANNOT_SPECIFY_FEED_ATTRIBUTES_FOR_SYSTEM_FEED")] CannotSpecifyFeedAttributesForSystemFeed = 6, + /// + /// Cannot update FeedAttributes on feed with origin GOOGLE. + /// + [pbr::OriginalName("CANNOT_UPDATE_FEED_ATTRIBUTES_WITH_ORIGIN_GOOGLE")] CannotUpdateFeedAttributesWithOriginGoogle = 7, + /// + /// The given ID refers to a removed Feed. Removed Feeds are immutable. + /// + [pbr::OriginalName("FEED_REMOVED")] FeedRemoved = 8, + /// + /// The origin of the feed is not valid for the client. + /// + [pbr::OriginalName("INVALID_ORIGIN_VALUE")] InvalidOriginValue = 9, + /// + /// A user can only create and modify feeds with USER origin. + /// + [pbr::OriginalName("FEED_ORIGIN_IS_NOT_USER")] FeedOriginIsNotUser = 10, + /// + /// Invalid auth token for the given email. + /// + [pbr::OriginalName("INVALID_AUTH_TOKEN_FOR_EMAIL")] InvalidAuthTokenForEmail = 11, + /// + /// Invalid email specified. + /// + [pbr::OriginalName("INVALID_EMAIL")] InvalidEmail = 12, + /// + /// Feed name matches that of another active Feed. + /// + [pbr::OriginalName("DUPLICATE_FEED_NAME")] DuplicateFeedName = 13, + /// + /// Name of feed is not allowed. + /// + [pbr::OriginalName("INVALID_FEED_NAME")] InvalidFeedName = 14, + /// + /// Missing OAuthInfo. + /// + [pbr::OriginalName("MISSING_OAUTH_INFO")] MissingOauthInfo = 15, + /// + /// New FeedAttributes must not affect the unique key. + /// + [pbr::OriginalName("NEW_ATTRIBUTE_CANNOT_BE_PART_OF_UNIQUE_KEY")] NewAttributeCannotBePartOfUniqueKey = 16, + /// + /// Too many FeedAttributes for a Feed. + /// + [pbr::OriginalName("TOO_MANY_ATTRIBUTES")] TooManyAttributes = 17, + /// + /// The business account is not valid. + /// + [pbr::OriginalName("INVALID_BUSINESS_ACCOUNT")] InvalidBusinessAccount = 18, + /// + /// Business account cannot access Google My Business account. + /// + [pbr::OriginalName("BUSINESS_ACCOUNT_CANNOT_ACCESS_LOCATION_ACCOUNT")] BusinessAccountCannotAccessLocationAccount = 19, + /// + /// Invalid chain ID provided for affiliate location feed. + /// + [pbr::OriginalName("INVALID_AFFILIATE_CHAIN_ID")] InvalidAffiliateChainId = 20, + /// + /// There is already a feed with the given system feed generation data. + /// + [pbr::OriginalName("DUPLICATE_SYSTEM_FEED")] DuplicateSystemFeed = 21, + /// + /// An error occurred accessing GMB account. + /// + [pbr::OriginalName("GMB_ACCESS_ERROR")] GmbAccessError = 22, + /// + /// A customer cannot have both LOCATION and AFFILIATE_LOCATION feeds. + /// + [pbr::OriginalName("CANNOT_HAVE_LOCATION_AND_AFFILIATE_LOCATION_FEEDS")] CannotHaveLocationAndAffiliateLocationFeeds = 23, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItem.cs b/src/V3/Stubs/FeedItem.cs new file mode 100644 index 000000000..fb3e558b4 --- /dev/null +++ b/src/V3/Stubs/FeedItem.cs @@ -0,0 +1,1606 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/feed_item.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/feed_item.proto + public static partial class FeedItemReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/feed_item.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZmVlZF9pdGVt", + "LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMaNWdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9jdXN0b21fcGFyYW1ldGVy", + "LnByb3RvGjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZmVlZF9j", + "b21tb24ucHJvdG8aK2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9w", + "b2xpY3kucHJvdG8aRWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2Zl", + "ZWRfaXRlbV9xdWFsaXR5X2FwcHJvdmFsX3N0YXR1cy5wcm90bxpIZ29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvZmVlZF9pdGVtX3F1YWxpdHlfZGlz", + "YXBwcm92YWxfcmVhc29uLnByb3RvGjRnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9mZWVkX2l0ZW1fc3RhdHVzLnByb3RvGj9nb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcy9mZWVkX2l0ZW1fdmFsaWRhdGlvbl9zdGF0dXMu", + "cHJvdG8aPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2dlb190YXJn", + "ZXRpbmdfcmVzdHJpY3Rpb24ucHJvdG8aNGdvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL2VudW1zL3BsYWNlaG9sZGVyX3R5cGUucHJvdG8aOmdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL2VudW1zL3BvbGljeV9hcHByb3ZhbF9zdGF0dXMucHJv", + "dG8aOGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3BvbGljeV9yZXZp", + "ZXdfc3RhdHVzLnByb3RvGj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJv", + "cnMvZmVlZF9pdGVtX3ZhbGlkYXRpb25fZXJyb3IucHJvdG8aH2dvb2dsZS9h", + "cGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2Uu", + "cHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90bxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byLdBgoIRmVlZEl0ZW0SQAoNcmVzb3Vy", + "Y2VfbmFtZRgBIAEoCUIp4EEF+kEjCiFnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b20vRmVlZEl0ZW0SUQoEZmVlZBgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZUIl4EEF+kEfCh1nb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20v", + "RmVlZBIsCgJpZBgDIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVl", + "QgPgQQMSNQoPc3RhcnRfZGF0ZV90aW1lGAQgASgLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlEjMKDWVuZF9kYXRlX3RpbWUYBSABKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWUSUwoQYXR0cmlidXRlX3ZhbHVlcxgG", + "IAMoCzI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5GZWVk", + "SXRlbUF0dHJpYnV0ZVZhbHVlEnUKGWdlb190YXJnZXRpbmdfcmVzdHJpY3Rp", + "b24YByABKA4yUi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5HZW9U", + "YXJnZXRpbmdSZXN0cmljdGlvbkVudW0uR2VvVGFyZ2V0aW5nUmVzdHJpY3Rp", + "b24STgoVdXJsX2N1c3RvbV9wYXJhbWV0ZXJzGAggAygLMi8uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuY29tbW9uLkN1c3RvbVBhcmFtZXRlchJVCgZzdGF0", + "dXMYCSABKA4yQC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5GZWVk", + "SXRlbVN0YXR1c0VudW0uRmVlZEl0ZW1TdGF0dXNCA+BBAxJbCgxwb2xpY3lf", + "aW5mb3MYCiADKAsyQC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMuRmVlZEl0ZW1QbGFjZWhvbGRlclBvbGljeUluZm9CA+BBAzpS6kFPCiFn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRmVlZEl0ZW0SKmN1c3RvbWVycy97", + "Y3VzdG9tZXJ9L2ZlZWRJdGVtcy97ZmVlZF9pdGVtfSKuBAoWRmVlZEl0ZW1B", + "dHRyaWJ1dGVWYWx1ZRI2ChFmZWVkX2F0dHJpYnV0ZV9pZBgBIAEoCzIbLmdv", + "b2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlEjIKDWludGVnZXJfdmFsdWUYAiAB", + "KAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZRIxCg1ib29sZWFuX3Zh", + "bHVlGAMgASgLMhouZ29vZ2xlLnByb3RvYnVmLkJvb2xWYWx1ZRIyCgxzdHJp", + "bmdfdmFsdWUYBCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUS", + "MgoMZG91YmxlX3ZhbHVlGAUgASgLMhwuZ29vZ2xlLnByb3RvYnVmLkRvdWJs", + "ZVZhbHVlEjoKC3ByaWNlX3ZhbHVlGAYgASgLMiUuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLk1vbmV5EjMKDmludGVnZXJfdmFsdWVzGAcgAygL", + "MhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWUSMgoOYm9vbGVhbl92YWx1", + "ZXMYCCADKAsyGi5nb29nbGUucHJvdG9idWYuQm9vbFZhbHVlEjMKDXN0cmlu", + "Z192YWx1ZXMYCSADKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUS", + "MwoNZG91YmxlX3ZhbHVlcxgKIAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5Eb3Vi", + "bGVWYWx1ZSLfBwodRmVlZEl0ZW1QbGFjZWhvbGRlclBvbGljeUluZm8SZgoV", + "cGxhY2Vob2xkZXJfdHlwZV9lbnVtGAogASgOMkIuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXMuUGxhY2Vob2xkZXJUeXBlRW51bS5QbGFjZWhvbGRl", + "clR5cGVCA+BBAxJFChpmZWVkX21hcHBpbmdfcmVzb3VyY2VfbmFtZRgCIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEmQKDXJldmll", + "d19zdGF0dXMYAyABKA4ySC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cy5Qb2xpY3lSZXZpZXdTdGF0dXNFbnVtLlBvbGljeVJldmlld1N0YXR1c0ID", + "4EEDEmoKD2FwcHJvdmFsX3N0YXR1cxgEIAEoDjJMLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVudW1zLlBvbGljeUFwcHJvdmFsU3RhdHVzRW51bS5Qb2xp", + "Y3lBcHByb3ZhbFN0YXR1c0ID4EEDElMKFHBvbGljeV90b3BpY19lbnRyaWVz", + "GAUgAygLMjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLlBvbGlj", + "eVRvcGljRW50cnlCA+BBAxJ0ChF2YWxpZGF0aW9uX3N0YXR1cxgGIAEoDjJU", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkZlZWRJdGVtVmFsaWRh", + "dGlvblN0YXR1c0VudW0uRmVlZEl0ZW1WYWxpZGF0aW9uU3RhdHVzQgPgQQMS", + "WgoRdmFsaWRhdGlvbl9lcnJvcnMYByADKAsyOi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5yZXNvdXJjZXMuRmVlZEl0ZW1WYWxpZGF0aW9uRXJyb3JCA+BB", + "AxKEAQoXcXVhbGl0eV9hcHByb3ZhbF9zdGF0dXMYCCABKA4yXi5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lbnVtcy5GZWVkSXRlbVF1YWxpdHlBcHByb3Zh", + "bFN0YXR1c0VudW0uRmVlZEl0ZW1RdWFsaXR5QXBwcm92YWxTdGF0dXNCA+BB", + "AxKOAQobcXVhbGl0eV9kaXNhcHByb3ZhbF9yZWFzb25zGAkgAygOMmQuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuRmVlZEl0ZW1RdWFsaXR5RGlz", + "YXBwcm92YWxSZWFzb25FbnVtLkZlZWRJdGVtUXVhbGl0eURpc2FwcHJvdmFs", + "UmVhc29uQgPgQQMiugIKF0ZlZWRJdGVtVmFsaWRhdGlvbkVycm9yEnIKEHZh", + "bGlkYXRpb25fZXJyb3IYASABKA4yUy5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lcnJvcnMuRmVlZEl0ZW1WYWxpZGF0aW9uRXJyb3JFbnVtLkZlZWRJdGVt", + "VmFsaWRhdGlvbkVycm9yQgPgQQMSNgoLZGVzY3JpcHRpb24YAiABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxI8ChJmZWVkX2F0dHJp", + "YnV0ZV9pZHMYAyADKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID", + "4EEDEjUKCmV4dHJhX2luZm8YBSABKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWVCA+BBA0L6AQolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlc0INRmVlZEl0ZW1Qcm90b1ABWkpnb29nbGUuZ29sYW5nLm9y", + "Zy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNl", + "c+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CustomParameterReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.FeedCommonReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.PolicyReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityApprovalStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityDisapprovalReasonReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemValidationStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingRestrictionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedItem), global::Google.Ads.GoogleAds.V3.Resources.FeedItem.Parser, new[]{ "ResourceName", "Feed", "Id", "StartDateTime", "EndDateTime", "AttributeValues", "GeoTargetingRestriction", "UrlCustomParameters", "Status", "PolicyInfos" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedItemAttributeValue), global::Google.Ads.GoogleAds.V3.Resources.FeedItemAttributeValue.Parser, new[]{ "FeedAttributeId", "IntegerValue", "BooleanValue", "StringValue", "DoubleValue", "PriceValue", "IntegerValues", "BooleanValues", "StringValues", "DoubleValues" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedItemPlaceholderPolicyInfo), global::Google.Ads.GoogleAds.V3.Resources.FeedItemPlaceholderPolicyInfo.Parser, new[]{ "PlaceholderTypeEnum", "FeedMappingResourceName", "ReviewStatus", "ApprovalStatus", "PolicyTopicEntries", "ValidationStatus", "ValidationErrors", "QualityApprovalStatus", "QualityDisapprovalReasons" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedItemValidationError), global::Google.Ads.GoogleAds.V3.Resources.FeedItemValidationError.Parser, new[]{ "ValidationError", "Description", "FeedAttributeIds", "ExtraInfo" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A feed item. + /// + public sealed partial class FeedItem : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItem()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedItemReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItem() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItem(FeedItem other) : this() { + resourceName_ = other.resourceName_; + Feed = other.Feed; + Id = other.Id; + StartDateTime = other.StartDateTime; + EndDateTime = other.EndDateTime; + attributeValues_ = other.attributeValues_.Clone(); + geoTargetingRestriction_ = other.geoTargetingRestriction_; + urlCustomParameters_ = other.urlCustomParameters_.Clone(); + status_ = other.status_; + policyInfos_ = other.policyInfos_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItem Clone() { + return new FeedItem(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the feed item. + /// Feed item resource names have the form: + /// + /// `customers/{customer_id}/feedItems/{feed_id}~{feed_item_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "feed" field. + public const int FeedFieldNumber = 2; + private static readonly pb::FieldCodec _single_feed_codec = pb::FieldCodec.ForClassWrapper(18); + private string feed_; + /// + /// Immutable. The feed to which this feed item belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Feed { + get { return feed_; } + set { + feed_ = value; + } + } + + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of this feed item. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "start_date_time" field. + public const int StartDateTimeFieldNumber = 4; + private static readonly pb::FieldCodec _single_startDateTime_codec = pb::FieldCodec.ForClassWrapper(34); + private string startDateTime_; + /// + /// Start time in which this feed item is effective and can begin serving. The + /// time is in the customer's time zone. + /// The format is "YYYY-MM-DD HH:MM:SS". + /// Examples: "2018-03-05 09:15:00" or "2018-02-01 14:34:30" + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StartDateTime { + get { return startDateTime_; } + set { + startDateTime_ = value; + } + } + + + /// Field number for the "end_date_time" field. + public const int EndDateTimeFieldNumber = 5; + private static readonly pb::FieldCodec _single_endDateTime_codec = pb::FieldCodec.ForClassWrapper(42); + private string endDateTime_; + /// + /// End time in which this feed item is no longer effective and will stop + /// serving. The time is in the customer's time zone. + /// The format is "YYYY-MM-DD HH:MM:SS". + /// Examples: "2018-03-05 09:15:00" or "2018-02-01 14:34:30" + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string EndDateTime { + get { return endDateTime_; } + set { + endDateTime_ = value; + } + } + + + /// Field number for the "attribute_values" field. + public const int AttributeValuesFieldNumber = 6; + private static readonly pb::FieldCodec _repeated_attributeValues_codec + = pb::FieldCodec.ForMessage(50, global::Google.Ads.GoogleAds.V3.Resources.FeedItemAttributeValue.Parser); + private readonly pbc::RepeatedField attributeValues_ = new pbc::RepeatedField(); + /// + /// The feed item's attribute values. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField AttributeValues { + get { return attributeValues_; } + } + + /// Field number for the "geo_targeting_restriction" field. + public const int GeoTargetingRestrictionFieldNumber = 7; + private global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingRestrictionEnum.Types.GeoTargetingRestriction geoTargetingRestriction_ = 0; + /// + /// Geo targeting restriction specifies the type of location that can be used + /// for targeting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingRestrictionEnum.Types.GeoTargetingRestriction GeoTargetingRestriction { + get { return geoTargetingRestriction_; } + set { + geoTargetingRestriction_ = value; + } + } + + /// Field number for the "url_custom_parameters" field. + public const int UrlCustomParametersFieldNumber = 8; + private static readonly pb::FieldCodec _repeated_urlCustomParameters_codec + = pb::FieldCodec.ForMessage(66, global::Google.Ads.GoogleAds.V3.Common.CustomParameter.Parser); + private readonly pbc::RepeatedField urlCustomParameters_ = new pbc::RepeatedField(); + /// + /// The list of mappings used to substitute custom parameter tags in a + /// `tracking_url_template`, `final_urls`, or `mobile_final_urls`. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField UrlCustomParameters { + get { return urlCustomParameters_; } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 9; + private global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum.Types.FeedItemStatus status_ = 0; + /// + /// Output only. Status of the feed item. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum.Types.FeedItemStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "policy_infos" field. + public const int PolicyInfosFieldNumber = 10; + private static readonly pb::FieldCodec _repeated_policyInfos_codec + = pb::FieldCodec.ForMessage(82, global::Google.Ads.GoogleAds.V3.Resources.FeedItemPlaceholderPolicyInfo.Parser); + private readonly pbc::RepeatedField policyInfos_ = new pbc::RepeatedField(); + /// + /// Output only. List of info about a feed item's validation and approval state for active + /// feed mappings. There will be an entry in the list for each type of feed + /// mapping associated with the feed, e.g. a feed with a sitelink and a call + /// feed mapping would cause every feed item associated with that feed to have + /// an entry in this list for both sitelink and call. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PolicyInfos { + get { return policyInfos_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItem); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItem other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Feed != other.Feed) return false; + if (Id != other.Id) return false; + if (StartDateTime != other.StartDateTime) return false; + if (EndDateTime != other.EndDateTime) return false; + if(!attributeValues_.Equals(other.attributeValues_)) return false; + if (GeoTargetingRestriction != other.GeoTargetingRestriction) return false; + if(!urlCustomParameters_.Equals(other.urlCustomParameters_)) return false; + if (Status != other.Status) return false; + if(!policyInfos_.Equals(other.policyInfos_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (feed_ != null) hash ^= Feed.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (startDateTime_ != null) hash ^= StartDateTime.GetHashCode(); + if (endDateTime_ != null) hash ^= EndDateTime.GetHashCode(); + hash ^= attributeValues_.GetHashCode(); + if (GeoTargetingRestriction != 0) hash ^= GeoTargetingRestriction.GetHashCode(); + hash ^= urlCustomParameters_.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + hash ^= policyInfos_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (feed_ != null) { + _single_feed_codec.WriteTagAndValue(output, Feed); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (startDateTime_ != null) { + _single_startDateTime_codec.WriteTagAndValue(output, StartDateTime); + } + if (endDateTime_ != null) { + _single_endDateTime_codec.WriteTagAndValue(output, EndDateTime); + } + attributeValues_.WriteTo(output, _repeated_attributeValues_codec); + if (GeoTargetingRestriction != 0) { + output.WriteRawTag(56); + output.WriteEnum((int) GeoTargetingRestriction); + } + urlCustomParameters_.WriteTo(output, _repeated_urlCustomParameters_codec); + if (Status != 0) { + output.WriteRawTag(72); + output.WriteEnum((int) Status); + } + policyInfos_.WriteTo(output, _repeated_policyInfos_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (feed_ != null) { + size += _single_feed_codec.CalculateSizeWithTag(Feed); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (startDateTime_ != null) { + size += _single_startDateTime_codec.CalculateSizeWithTag(StartDateTime); + } + if (endDateTime_ != null) { + size += _single_endDateTime_codec.CalculateSizeWithTag(EndDateTime); + } + size += attributeValues_.CalculateSize(_repeated_attributeValues_codec); + if (GeoTargetingRestriction != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) GeoTargetingRestriction); + } + size += urlCustomParameters_.CalculateSize(_repeated_urlCustomParameters_codec); + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + size += policyInfos_.CalculateSize(_repeated_policyInfos_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItem other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.feed_ != null) { + if (feed_ == null || other.Feed != "") { + Feed = other.Feed; + } + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.startDateTime_ != null) { + if (startDateTime_ == null || other.StartDateTime != "") { + StartDateTime = other.StartDateTime; + } + } + if (other.endDateTime_ != null) { + if (endDateTime_ == null || other.EndDateTime != "") { + EndDateTime = other.EndDateTime; + } + } + attributeValues_.Add(other.attributeValues_); + if (other.GeoTargetingRestriction != 0) { + GeoTargetingRestriction = other.GeoTargetingRestriction; + } + urlCustomParameters_.Add(other.urlCustomParameters_); + if (other.Status != 0) { + Status = other.Status; + } + policyInfos_.Add(other.policyInfos_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_feed_codec.Read(input); + if (feed_ == null || value != "") { + Feed = value; + } + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_startDateTime_codec.Read(input); + if (startDateTime_ == null || value != "") { + StartDateTime = value; + } + break; + } + case 42: { + string value = _single_endDateTime_codec.Read(input); + if (endDateTime_ == null || value != "") { + EndDateTime = value; + } + break; + } + case 50: { + attributeValues_.AddEntriesFrom(input, _repeated_attributeValues_codec); + break; + } + case 56: { + GeoTargetingRestriction = (global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingRestrictionEnum.Types.GeoTargetingRestriction) input.ReadEnum(); + break; + } + case 66: { + urlCustomParameters_.AddEntriesFrom(input, _repeated_urlCustomParameters_codec); + break; + } + case 72: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum.Types.FeedItemStatus) input.ReadEnum(); + break; + } + case 82: { + policyInfos_.AddEntriesFrom(input, _repeated_policyInfos_codec); + break; + } + } + } + } + + } + + /// + /// A feed item attribute value. + /// + public sealed partial class FeedItemAttributeValue : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemAttributeValue()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedItemReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemAttributeValue() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemAttributeValue(FeedItemAttributeValue other) : this() { + FeedAttributeId = other.FeedAttributeId; + IntegerValue = other.IntegerValue; + BooleanValue = other.BooleanValue; + StringValue = other.StringValue; + DoubleValue = other.DoubleValue; + priceValue_ = other.priceValue_ != null ? other.priceValue_.Clone() : null; + integerValues_ = other.integerValues_.Clone(); + booleanValues_ = other.booleanValues_.Clone(); + stringValues_ = other.stringValues_.Clone(); + doubleValues_ = other.doubleValues_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemAttributeValue Clone() { + return new FeedItemAttributeValue(this); + } + + /// Field number for the "feed_attribute_id" field. + public const int FeedAttributeIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_feedAttributeId_codec = pb::FieldCodec.ForStructWrapper(10); + private long? feedAttributeId_; + /// + /// Id of the feed attribute for which the value is associated with. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? FeedAttributeId { + get { return feedAttributeId_; } + set { + feedAttributeId_ = value; + } + } + + + /// Field number for the "integer_value" field. + public const int IntegerValueFieldNumber = 2; + private static readonly pb::FieldCodec _single_integerValue_codec = pb::FieldCodec.ForStructWrapper(18); + private long? integerValue_; + /// + /// Int64 value. Should be set if feed_attribute_id refers to a feed attribute + /// of type INT64. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? IntegerValue { + get { return integerValue_; } + set { + integerValue_ = value; + } + } + + + /// Field number for the "boolean_value" field. + public const int BooleanValueFieldNumber = 3; + private static readonly pb::FieldCodec _single_booleanValue_codec = pb::FieldCodec.ForStructWrapper(26); + private bool? booleanValue_; + /// + /// Bool value. Should be set if feed_attribute_id refers to a feed attribute + /// of type BOOLEAN. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? BooleanValue { + get { return booleanValue_; } + set { + booleanValue_ = value; + } + } + + + /// Field number for the "string_value" field. + public const int StringValueFieldNumber = 4; + private static readonly pb::FieldCodec _single_stringValue_codec = pb::FieldCodec.ForClassWrapper(34); + private string stringValue_; + /// + /// String value. Should be set if feed_attribute_id refers to a feed attribute + /// of type STRING, URL or DATE_TIME. + /// For STRING the maximum length is 1500 characters. For URL the maximum + /// length is 2076 characters. For DATE_TIME the string must be in the format + /// "YYYYMMDD HHMMSS". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string StringValue { + get { return stringValue_; } + set { + stringValue_ = value; + } + } + + + /// Field number for the "double_value" field. + public const int DoubleValueFieldNumber = 5; + private static readonly pb::FieldCodec _single_doubleValue_codec = pb::FieldCodec.ForStructWrapper(42); + private double? doubleValue_; + /// + /// Double value. Should be set if feed_attribute_id refers to a feed attribute + /// of type DOUBLE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? DoubleValue { + get { return doubleValue_; } + set { + doubleValue_ = value; + } + } + + + /// Field number for the "price_value" field. + public const int PriceValueFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Common.Money priceValue_; + /// + /// Price value. Should be set if feed_attribute_id refers to a feed attribute + /// of type PRICE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.Money PriceValue { + get { return priceValue_; } + set { + priceValue_ = value; + } + } + + /// Field number for the "integer_values" field. + public const int IntegerValuesFieldNumber = 7; + private static readonly pb::FieldCodec _repeated_integerValues_codec + = pb::FieldCodec.ForStructWrapper(58); + private readonly pbc::RepeatedField integerValues_ = new pbc::RepeatedField(); + /// + /// Repeated int64 value. Should be set if feed_attribute_id refers to a feed + /// attribute of type INT64_LIST. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField IntegerValues { + get { return integerValues_; } + } + + /// Field number for the "boolean_values" field. + public const int BooleanValuesFieldNumber = 8; + private static readonly pb::FieldCodec _repeated_booleanValues_codec + = pb::FieldCodec.ForStructWrapper(66); + private readonly pbc::RepeatedField booleanValues_ = new pbc::RepeatedField(); + /// + /// Repeated bool value. Should be set if feed_attribute_id refers to a feed + /// attribute of type BOOLEAN_LIST. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField BooleanValues { + get { return booleanValues_; } + } + + /// Field number for the "string_values" field. + public const int StringValuesFieldNumber = 9; + private static readonly pb::FieldCodec _repeated_stringValues_codec + = pb::FieldCodec.ForClassWrapper(74); + private readonly pbc::RepeatedField stringValues_ = new pbc::RepeatedField(); + /// + /// Repeated string value. Should be set if feed_attribute_id refers to a feed + /// attribute of type STRING_LIST, URL_LIST or DATE_TIME_LIST. + /// For STRING_LIST and URL_LIST the total size of the list in bytes may not + /// exceed 3000. For DATE_TIME_LIST the number of elements may not exceed 200. + /// + /// For STRING_LIST the maximum length of each string element is 1500 + /// characters. For URL_LIST the maximum length is 2076 characters. For + /// DATE_TIME the format of the string must be the same as start and end time + /// for the feed item. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField StringValues { + get { return stringValues_; } + } + + /// Field number for the "double_values" field. + public const int DoubleValuesFieldNumber = 10; + private static readonly pb::FieldCodec _repeated_doubleValues_codec + = pb::FieldCodec.ForStructWrapper(82); + private readonly pbc::RepeatedField doubleValues_ = new pbc::RepeatedField(); + /// + /// Repeated double value. Should be set if feed_attribute_id refers to a feed + /// attribute of type DOUBLE_LIST. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField DoubleValues { + get { return doubleValues_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemAttributeValue); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemAttributeValue other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (FeedAttributeId != other.FeedAttributeId) return false; + if (IntegerValue != other.IntegerValue) return false; + if (BooleanValue != other.BooleanValue) return false; + if (StringValue != other.StringValue) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(DoubleValue, other.DoubleValue)) return false; + if (!object.Equals(PriceValue, other.PriceValue)) return false; + if(!integerValues_.Equals(other.integerValues_)) return false; + if(!booleanValues_.Equals(other.booleanValues_)) return false; + if(!stringValues_.Equals(other.stringValues_)) return false; + if(!doubleValues_.Equals(other.doubleValues_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (feedAttributeId_ != null) hash ^= FeedAttributeId.GetHashCode(); + if (integerValue_ != null) hash ^= IntegerValue.GetHashCode(); + if (booleanValue_ != null) hash ^= BooleanValue.GetHashCode(); + if (stringValue_ != null) hash ^= StringValue.GetHashCode(); + if (doubleValue_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(DoubleValue); + if (priceValue_ != null) hash ^= PriceValue.GetHashCode(); + hash ^= integerValues_.GetHashCode(); + hash ^= booleanValues_.GetHashCode(); + hash ^= stringValues_.GetHashCode(); + hash ^= doubleValues_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (feedAttributeId_ != null) { + _single_feedAttributeId_codec.WriteTagAndValue(output, FeedAttributeId); + } + if (integerValue_ != null) { + _single_integerValue_codec.WriteTagAndValue(output, IntegerValue); + } + if (booleanValue_ != null) { + _single_booleanValue_codec.WriteTagAndValue(output, BooleanValue); + } + if (stringValue_ != null) { + _single_stringValue_codec.WriteTagAndValue(output, StringValue); + } + if (doubleValue_ != null) { + _single_doubleValue_codec.WriteTagAndValue(output, DoubleValue); + } + if (priceValue_ != null) { + output.WriteRawTag(50); + output.WriteMessage(PriceValue); + } + integerValues_.WriteTo(output, _repeated_integerValues_codec); + booleanValues_.WriteTo(output, _repeated_booleanValues_codec); + stringValues_.WriteTo(output, _repeated_stringValues_codec); + doubleValues_.WriteTo(output, _repeated_doubleValues_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (feedAttributeId_ != null) { + size += _single_feedAttributeId_codec.CalculateSizeWithTag(FeedAttributeId); + } + if (integerValue_ != null) { + size += _single_integerValue_codec.CalculateSizeWithTag(IntegerValue); + } + if (booleanValue_ != null) { + size += _single_booleanValue_codec.CalculateSizeWithTag(BooleanValue); + } + if (stringValue_ != null) { + size += _single_stringValue_codec.CalculateSizeWithTag(StringValue); + } + if (doubleValue_ != null) { + size += _single_doubleValue_codec.CalculateSizeWithTag(DoubleValue); + } + if (priceValue_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PriceValue); + } + size += integerValues_.CalculateSize(_repeated_integerValues_codec); + size += booleanValues_.CalculateSize(_repeated_booleanValues_codec); + size += stringValues_.CalculateSize(_repeated_stringValues_codec); + size += doubleValues_.CalculateSize(_repeated_doubleValues_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemAttributeValue other) { + if (other == null) { + return; + } + if (other.feedAttributeId_ != null) { + if (feedAttributeId_ == null || other.FeedAttributeId != 0L) { + FeedAttributeId = other.FeedAttributeId; + } + } + if (other.integerValue_ != null) { + if (integerValue_ == null || other.IntegerValue != 0L) { + IntegerValue = other.IntegerValue; + } + } + if (other.booleanValue_ != null) { + if (booleanValue_ == null || other.BooleanValue != false) { + BooleanValue = other.BooleanValue; + } + } + if (other.stringValue_ != null) { + if (stringValue_ == null || other.StringValue != "") { + StringValue = other.StringValue; + } + } + if (other.doubleValue_ != null) { + if (doubleValue_ == null || other.DoubleValue != 0D) { + DoubleValue = other.DoubleValue; + } + } + if (other.priceValue_ != null) { + if (priceValue_ == null) { + PriceValue = new global::Google.Ads.GoogleAds.V3.Common.Money(); + } + PriceValue.MergeFrom(other.PriceValue); + } + integerValues_.Add(other.integerValues_); + booleanValues_.Add(other.booleanValues_); + stringValues_.Add(other.stringValues_); + doubleValues_.Add(other.doubleValues_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_feedAttributeId_codec.Read(input); + if (feedAttributeId_ == null || value != 0L) { + FeedAttributeId = value; + } + break; + } + case 18: { + long? value = _single_integerValue_codec.Read(input); + if (integerValue_ == null || value != 0L) { + IntegerValue = value; + } + break; + } + case 26: { + bool? value = _single_booleanValue_codec.Read(input); + if (booleanValue_ == null || value != false) { + BooleanValue = value; + } + break; + } + case 34: { + string value = _single_stringValue_codec.Read(input); + if (stringValue_ == null || value != "") { + StringValue = value; + } + break; + } + case 42: { + double? value = _single_doubleValue_codec.Read(input); + if (doubleValue_ == null || value != 0D) { + DoubleValue = value; + } + break; + } + case 50: { + if (priceValue_ == null) { + PriceValue = new global::Google.Ads.GoogleAds.V3.Common.Money(); + } + input.ReadMessage(PriceValue); + break; + } + case 58: { + integerValues_.AddEntriesFrom(input, _repeated_integerValues_codec); + break; + } + case 66: { + booleanValues_.AddEntriesFrom(input, _repeated_booleanValues_codec); + break; + } + case 74: { + stringValues_.AddEntriesFrom(input, _repeated_stringValues_codec); + break; + } + case 82: { + doubleValues_.AddEntriesFrom(input, _repeated_doubleValues_codec); + break; + } + } + } + } + + } + + /// + /// Policy, validation, and quality approval info for a feed item for the + /// specified placeholder type. + /// + public sealed partial class FeedItemPlaceholderPolicyInfo : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemPlaceholderPolicyInfo()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedItemReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemPlaceholderPolicyInfo() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemPlaceholderPolicyInfo(FeedItemPlaceholderPolicyInfo other) : this() { + placeholderTypeEnum_ = other.placeholderTypeEnum_; + FeedMappingResourceName = other.FeedMappingResourceName; + reviewStatus_ = other.reviewStatus_; + approvalStatus_ = other.approvalStatus_; + policyTopicEntries_ = other.policyTopicEntries_.Clone(); + validationStatus_ = other.validationStatus_; + validationErrors_ = other.validationErrors_.Clone(); + qualityApprovalStatus_ = other.qualityApprovalStatus_; + qualityDisapprovalReasons_ = other.qualityDisapprovalReasons_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemPlaceholderPolicyInfo Clone() { + return new FeedItemPlaceholderPolicyInfo(this); + } + + /// Field number for the "placeholder_type_enum" field. + public const int PlaceholderTypeEnumFieldNumber = 10; + private global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType placeholderTypeEnum_ = 0; + /// + /// Output only. The placeholder type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType PlaceholderTypeEnum { + get { return placeholderTypeEnum_; } + set { + placeholderTypeEnum_ = value; + } + } + + /// Field number for the "feed_mapping_resource_name" field. + public const int FeedMappingResourceNameFieldNumber = 2; + private static readonly pb::FieldCodec _single_feedMappingResourceName_codec = pb::FieldCodec.ForClassWrapper(18); + private string feedMappingResourceName_; + /// + /// Output only. The FeedMapping that contains the placeholder type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FeedMappingResourceName { + get { return feedMappingResourceName_; } + set { + feedMappingResourceName_ = value; + } + } + + + /// Field number for the "review_status" field. + public const int ReviewStatusFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus reviewStatus_ = 0; + /// + /// Output only. Where the placeholder type is in the review process. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus ReviewStatus { + get { return reviewStatus_; } + set { + reviewStatus_ = value; + } + } + + /// Field number for the "approval_status" field. + public const int ApprovalStatusFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus approvalStatus_ = 0; + /// + /// Output only. The overall approval status of the placeholder type, calculated based on + /// the status of its individual policy topic entries. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus ApprovalStatus { + get { return approvalStatus_; } + set { + approvalStatus_ = value; + } + } + + /// Field number for the "policy_topic_entries" field. + public const int PolicyTopicEntriesFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_policyTopicEntries_codec + = pb::FieldCodec.ForMessage(42, global::Google.Ads.GoogleAds.V3.Common.PolicyTopicEntry.Parser); + private readonly pbc::RepeatedField policyTopicEntries_ = new pbc::RepeatedField(); + /// + /// Output only. The list of policy findings for the placeholder type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField PolicyTopicEntries { + get { return policyTopicEntries_; } + } + + /// Field number for the "validation_status" field. + public const int ValidationStatusFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.FeedItemValidationStatusEnum.Types.FeedItemValidationStatus validationStatus_ = 0; + /// + /// Output only. The validation status of the palceholder type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedItemValidationStatusEnum.Types.FeedItemValidationStatus ValidationStatus { + get { return validationStatus_; } + set { + validationStatus_ = value; + } + } + + /// Field number for the "validation_errors" field. + public const int ValidationErrorsFieldNumber = 7; + private static readonly pb::FieldCodec _repeated_validationErrors_codec + = pb::FieldCodec.ForMessage(58, global::Google.Ads.GoogleAds.V3.Resources.FeedItemValidationError.Parser); + private readonly pbc::RepeatedField validationErrors_ = new pbc::RepeatedField(); + /// + /// Output only. List of placeholder type validation errors. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ValidationErrors { + get { return validationErrors_; } + } + + /// Field number for the "quality_approval_status" field. + public const int QualityApprovalStatusFieldNumber = 8; + private global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityApprovalStatusEnum.Types.FeedItemQualityApprovalStatus qualityApprovalStatus_ = 0; + /// + /// Output only. Placeholder type quality evaluation approval status. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityApprovalStatusEnum.Types.FeedItemQualityApprovalStatus QualityApprovalStatus { + get { return qualityApprovalStatus_; } + set { + qualityApprovalStatus_ = value; + } + } + + /// Field number for the "quality_disapproval_reasons" field. + public const int QualityDisapprovalReasonsFieldNumber = 9; + private static readonly pb::FieldCodec _repeated_qualityDisapprovalReasons_codec + = pb::FieldCodec.ForEnum(74, x => (int) x, x => (global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityDisapprovalReasonEnum.Types.FeedItemQualityDisapprovalReason) x); + private readonly pbc::RepeatedField qualityDisapprovalReasons_ = new pbc::RepeatedField(); + /// + /// Output only. List of placeholder type quality evaluation disapproval reasons. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField QualityDisapprovalReasons { + get { return qualityDisapprovalReasons_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemPlaceholderPolicyInfo); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemPlaceholderPolicyInfo other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (PlaceholderTypeEnum != other.PlaceholderTypeEnum) return false; + if (FeedMappingResourceName != other.FeedMappingResourceName) return false; + if (ReviewStatus != other.ReviewStatus) return false; + if (ApprovalStatus != other.ApprovalStatus) return false; + if(!policyTopicEntries_.Equals(other.policyTopicEntries_)) return false; + if (ValidationStatus != other.ValidationStatus) return false; + if(!validationErrors_.Equals(other.validationErrors_)) return false; + if (QualityApprovalStatus != other.QualityApprovalStatus) return false; + if(!qualityDisapprovalReasons_.Equals(other.qualityDisapprovalReasons_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (PlaceholderTypeEnum != 0) hash ^= PlaceholderTypeEnum.GetHashCode(); + if (feedMappingResourceName_ != null) hash ^= FeedMappingResourceName.GetHashCode(); + if (ReviewStatus != 0) hash ^= ReviewStatus.GetHashCode(); + if (ApprovalStatus != 0) hash ^= ApprovalStatus.GetHashCode(); + hash ^= policyTopicEntries_.GetHashCode(); + if (ValidationStatus != 0) hash ^= ValidationStatus.GetHashCode(); + hash ^= validationErrors_.GetHashCode(); + if (QualityApprovalStatus != 0) hash ^= QualityApprovalStatus.GetHashCode(); + hash ^= qualityDisapprovalReasons_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (feedMappingResourceName_ != null) { + _single_feedMappingResourceName_codec.WriteTagAndValue(output, FeedMappingResourceName); + } + if (ReviewStatus != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) ReviewStatus); + } + if (ApprovalStatus != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) ApprovalStatus); + } + policyTopicEntries_.WriteTo(output, _repeated_policyTopicEntries_codec); + if (ValidationStatus != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) ValidationStatus); + } + validationErrors_.WriteTo(output, _repeated_validationErrors_codec); + if (QualityApprovalStatus != 0) { + output.WriteRawTag(64); + output.WriteEnum((int) QualityApprovalStatus); + } + qualityDisapprovalReasons_.WriteTo(output, _repeated_qualityDisapprovalReasons_codec); + if (PlaceholderTypeEnum != 0) { + output.WriteRawTag(80); + output.WriteEnum((int) PlaceholderTypeEnum); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (PlaceholderTypeEnum != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PlaceholderTypeEnum); + } + if (feedMappingResourceName_ != null) { + size += _single_feedMappingResourceName_codec.CalculateSizeWithTag(FeedMappingResourceName); + } + if (ReviewStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ReviewStatus); + } + if (ApprovalStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ApprovalStatus); + } + size += policyTopicEntries_.CalculateSize(_repeated_policyTopicEntries_codec); + if (ValidationStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ValidationStatus); + } + size += validationErrors_.CalculateSize(_repeated_validationErrors_codec); + if (QualityApprovalStatus != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) QualityApprovalStatus); + } + size += qualityDisapprovalReasons_.CalculateSize(_repeated_qualityDisapprovalReasons_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemPlaceholderPolicyInfo other) { + if (other == null) { + return; + } + if (other.PlaceholderTypeEnum != 0) { + PlaceholderTypeEnum = other.PlaceholderTypeEnum; + } + if (other.feedMappingResourceName_ != null) { + if (feedMappingResourceName_ == null || other.FeedMappingResourceName != "") { + FeedMappingResourceName = other.FeedMappingResourceName; + } + } + if (other.ReviewStatus != 0) { + ReviewStatus = other.ReviewStatus; + } + if (other.ApprovalStatus != 0) { + ApprovalStatus = other.ApprovalStatus; + } + policyTopicEntries_.Add(other.policyTopicEntries_); + if (other.ValidationStatus != 0) { + ValidationStatus = other.ValidationStatus; + } + validationErrors_.Add(other.validationErrors_); + if (other.QualityApprovalStatus != 0) { + QualityApprovalStatus = other.QualityApprovalStatus; + } + qualityDisapprovalReasons_.Add(other.qualityDisapprovalReasons_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + string value = _single_feedMappingResourceName_codec.Read(input); + if (feedMappingResourceName_ == null || value != "") { + FeedMappingResourceName = value; + } + break; + } + case 24: { + ReviewStatus = (global::Google.Ads.GoogleAds.V3.Enums.PolicyReviewStatusEnum.Types.PolicyReviewStatus) input.ReadEnum(); + break; + } + case 32: { + ApprovalStatus = (global::Google.Ads.GoogleAds.V3.Enums.PolicyApprovalStatusEnum.Types.PolicyApprovalStatus) input.ReadEnum(); + break; + } + case 42: { + policyTopicEntries_.AddEntriesFrom(input, _repeated_policyTopicEntries_codec); + break; + } + case 48: { + ValidationStatus = (global::Google.Ads.GoogleAds.V3.Enums.FeedItemValidationStatusEnum.Types.FeedItemValidationStatus) input.ReadEnum(); + break; + } + case 58: { + validationErrors_.AddEntriesFrom(input, _repeated_validationErrors_codec); + break; + } + case 64: { + QualityApprovalStatus = (global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityApprovalStatusEnum.Types.FeedItemQualityApprovalStatus) input.ReadEnum(); + break; + } + case 74: + case 72: { + qualityDisapprovalReasons_.AddEntriesFrom(input, _repeated_qualityDisapprovalReasons_codec); + break; + } + case 80: { + PlaceholderTypeEnum = (global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Stores a validation error and the set of offending feed attributes which + /// together are responsible for causing a feed item validation error. + /// + public sealed partial class FeedItemValidationError : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemValidationError()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedItemReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationError() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationError(FeedItemValidationError other) : this() { + validationError_ = other.validationError_; + Description = other.Description; + feedAttributeIds_ = other.feedAttributeIds_.Clone(); + ExtraInfo = other.ExtraInfo; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationError Clone() { + return new FeedItemValidationError(this); + } + + /// Field number for the "validation_error" field. + public const int ValidationErrorFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorEnum.Types.FeedItemValidationError validationError_ = 0; + /// + /// Output only. Error code indicating what validation error was triggered. The description + /// of the error can be found in the 'description' field. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorEnum.Types.FeedItemValidationError ValidationError { + get { return validationError_; } + set { + validationError_ = value; + } + } + + /// Field number for the "description" field. + public const int DescriptionFieldNumber = 2; + private static readonly pb::FieldCodec _single_description_codec = pb::FieldCodec.ForClassWrapper(18); + private string description_; + /// + /// Output only. The description of the validation error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Description { + get { return description_; } + set { + description_ = value; + } + } + + + /// Field number for the "feed_attribute_ids" field. + public const int FeedAttributeIdsFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_feedAttributeIds_codec + = pb::FieldCodec.ForStructWrapper(26); + private readonly pbc::RepeatedField feedAttributeIds_ = new pbc::RepeatedField(); + /// + /// Output only. Set of feed attributes in the feed item flagged during validation. If + /// empty, no specific feed attributes can be associated with the error + /// (e.g. error across the entire feed item). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField FeedAttributeIds { + get { return feedAttributeIds_; } + } + + /// Field number for the "extra_info" field. + public const int ExtraInfoFieldNumber = 5; + private static readonly pb::FieldCodec _single_extraInfo_codec = pb::FieldCodec.ForClassWrapper(42); + private string extraInfo_; + /// + /// Output only. Any extra information related to this error which is not captured by + /// validation_error and feed_attribute_id (e.g. placeholder field IDs when + /// feed_attribute_id is not mapped). Note that extra_info is not localized. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ExtraInfo { + get { return extraInfo_; } + set { + extraInfo_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemValidationError); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemValidationError other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ValidationError != other.ValidationError) return false; + if (Description != other.Description) return false; + if(!feedAttributeIds_.Equals(other.feedAttributeIds_)) return false; + if (ExtraInfo != other.ExtraInfo) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ValidationError != 0) hash ^= ValidationError.GetHashCode(); + if (description_ != null) hash ^= Description.GetHashCode(); + hash ^= feedAttributeIds_.GetHashCode(); + if (extraInfo_ != null) hash ^= ExtraInfo.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ValidationError != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) ValidationError); + } + if (description_ != null) { + _single_description_codec.WriteTagAndValue(output, Description); + } + feedAttributeIds_.WriteTo(output, _repeated_feedAttributeIds_codec); + if (extraInfo_ != null) { + _single_extraInfo_codec.WriteTagAndValue(output, ExtraInfo); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ValidationError != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) ValidationError); + } + if (description_ != null) { + size += _single_description_codec.CalculateSizeWithTag(Description); + } + size += feedAttributeIds_.CalculateSize(_repeated_feedAttributeIds_codec); + if (extraInfo_ != null) { + size += _single_extraInfo_codec.CalculateSizeWithTag(ExtraInfo); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemValidationError other) { + if (other == null) { + return; + } + if (other.ValidationError != 0) { + ValidationError = other.ValidationError; + } + if (other.description_ != null) { + if (description_ == null || other.Description != "") { + Description = other.Description; + } + } + feedAttributeIds_.Add(other.feedAttributeIds_); + if (other.extraInfo_ != null) { + if (extraInfo_ == null || other.ExtraInfo != "") { + ExtraInfo = other.ExtraInfo; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + ValidationError = (global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorEnum.Types.FeedItemValidationError) input.ReadEnum(); + break; + } + case 18: { + string value = _single_description_codec.Read(input); + if (description_ == null || value != "") { + Description = value; + } + break; + } + case 26: { + feedAttributeIds_.AddEntriesFrom(input, _repeated_feedAttributeIds_codec); + break; + } + case 42: { + string value = _single_extraInfo_codec.Read(input); + if (extraInfo_ == null || value != "") { + ExtraInfo = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemError.cs b/src/V3/Stubs/FeedItemError.cs new file mode 100644 index 000000000..be2f21e6c --- /dev/null +++ b/src/V3/Stubs/FeedItemError.cs @@ -0,0 +1,219 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/feed_item_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/feed_item_error.proto + public static partial class FeedItemErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/feed_item_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZmVlZF9pdGVtX2Vy", + "cm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMaHGdv", + "b2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ihwMKEUZlZWRJdGVtRXJyb3JF", + "bnVtIvECCg1GZWVkSXRlbUVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5L", + "Tk9XThABEi4KKkNBTk5PVF9DT05WRVJUX0FUVFJJQlVURV9WQUxVRV9GUk9N", + "X1NUUklORxACEicKI0NBTk5PVF9PUEVSQVRFX09OX1JFTU9WRURfRkVFRF9J", + "VEVNEAMSKgomREFURV9USU1FX01VU1RfQkVfSU5fQUNDT1VOVF9USU1FX1pP", + "TkUQBBIcChhLRVlfQVRUUklCVVRFU19OT1RfRk9VTkQQBRIPCgtJTlZBTElE", + "X1VSTBAGEhoKFk1JU1NJTkdfS0VZX0FUVFJJQlVURVMQBxIdChlLRVlfQVRU", + "UklCVVRFU19OT1RfVU5JUVVFEAgSJQohQ0FOTk9UX01PRElGWV9LRVlfQVRU", + "UklCVVRFX1ZBTFVFEAkSLAooU0laRV9UT09fTEFSR0VfRk9SX01VTFRJX1ZB", + "TFVFX0FUVFJJQlVURRAKQu0BCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZXJyb3JzQhJGZWVkSXRlbUVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFu", + "Zy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vy", + "cm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5F", + "cnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedItemErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FeedItemErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedItemErrorEnum.Types.FeedItemError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible feed item errors. + /// + public sealed partial class FeedItemErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FeedItemErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemErrorEnum(FeedItemErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemErrorEnum Clone() { + return new FeedItemErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible feed item errors. + /// + public enum FeedItemError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Cannot convert the feed attribute value from string to its real type. + /// + [pbr::OriginalName("CANNOT_CONVERT_ATTRIBUTE_VALUE_FROM_STRING")] CannotConvertAttributeValueFromString = 2, + /// + /// Cannot operate on removed feed item. + /// + [pbr::OriginalName("CANNOT_OPERATE_ON_REMOVED_FEED_ITEM")] CannotOperateOnRemovedFeedItem = 3, + /// + /// Date time zone does not match the account's time zone. + /// + [pbr::OriginalName("DATE_TIME_MUST_BE_IN_ACCOUNT_TIME_ZONE")] DateTimeMustBeInAccountTimeZone = 4, + /// + /// Feed item with the key attributes could not be found. + /// + [pbr::OriginalName("KEY_ATTRIBUTES_NOT_FOUND")] KeyAttributesNotFound = 5, + /// + /// Url feed attribute value is not valid. + /// + [pbr::OriginalName("INVALID_URL")] InvalidUrl = 6, + /// + /// Some key attributes are missing. + /// + [pbr::OriginalName("MISSING_KEY_ATTRIBUTES")] MissingKeyAttributes = 7, + /// + /// Feed item has same key attributes as another feed item. + /// + [pbr::OriginalName("KEY_ATTRIBUTES_NOT_UNIQUE")] KeyAttributesNotUnique = 8, + /// + /// Cannot modify key attributes on an existing feed item. + /// + [pbr::OriginalName("CANNOT_MODIFY_KEY_ATTRIBUTE_VALUE")] CannotModifyKeyAttributeValue = 9, + /// + /// The feed attribute value is too large. + /// + [pbr::OriginalName("SIZE_TOO_LARGE_FOR_MULTI_VALUE_ATTRIBUTE")] SizeTooLargeForMultiValueAttribute = 10, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemQualityApprovalStatus.cs b/src/V3/Stubs/FeedItemQualityApprovalStatus.cs new file mode 100644 index 000000000..d363678e1 --- /dev/null +++ b/src/V3/Stubs/FeedItemQualityApprovalStatus.cs @@ -0,0 +1,188 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_item_quality_approval_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_item_quality_approval_status.proto + public static partial class FeedItemQualityApprovalStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_item_quality_approval_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemQualityApprovalStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2l0ZW1fcXVh", + "bGl0eV9hcHByb3ZhbF9zdGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIoEB", + "CiFGZWVkSXRlbVF1YWxpdHlBcHByb3ZhbFN0YXR1c0VudW0iXAodRmVlZEl0", + "ZW1RdWFsaXR5QXBwcm92YWxTdGF0dXMSDwoLVU5TUEVDSUZJRUQQABILCgdV", + "TktOT1dOEAESDAoIQVBQUk9WRUQQAhIPCgtESVNBUFBST1ZFRBADQvcBCiFj", + "b20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCIkZlZWRJdGVtUXVh", + "bGl0eUFwcHJvdmFsU3RhdHVzUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2Vu", + "dW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1H", + "b29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityApprovalStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityApprovalStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityApprovalStatusEnum.Types.FeedItemQualityApprovalStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible quality evaluation approval statuses + /// of a feed item. + /// + public sealed partial class FeedItemQualityApprovalStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemQualityApprovalStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityApprovalStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemQualityApprovalStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemQualityApprovalStatusEnum(FeedItemQualityApprovalStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemQualityApprovalStatusEnum Clone() { + return new FeedItemQualityApprovalStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemQualityApprovalStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemQualityApprovalStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemQualityApprovalStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemQualityApprovalStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible quality evaluation approval statuses of a feed item. + /// + public enum FeedItemQualityApprovalStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Meets all quality expectations. + /// + [pbr::OriginalName("APPROVED")] Approved = 2, + /// + /// Does not meet some quality expectations. The specific reason is found in + /// the quality_disapproval_reasons field. + /// + [pbr::OriginalName("DISAPPROVED")] Disapproved = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemQualityDisapprovalReason.cs b/src/V3/Stubs/FeedItemQualityDisapprovalReason.cs new file mode 100644 index 000000000..b9eede3a4 --- /dev/null +++ b/src/V3/Stubs/FeedItemQualityDisapprovalReason.cs @@ -0,0 +1,268 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_item_quality_disapproval_reason.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_item_quality_disapproval_reason.proto + public static partial class FeedItemQualityDisapprovalReasonReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_item_quality_disapproval_reason.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemQualityDisapprovalReasonReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2l0ZW1fcXVh", + "bGl0eV9kaXNhcHByb3ZhbF9yZWFzb24ucHJvdG8SHWdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3Rv", + "IuAGCiRGZWVkSXRlbVF1YWxpdHlEaXNhcHByb3ZhbFJlYXNvbkVudW0itwYK", + "IEZlZWRJdGVtUXVhbGl0eURpc2FwcHJvdmFsUmVhc29uEg8KC1VOU1BFQ0lG", + "SUVEEAASCwoHVU5LTk9XThABEiIKHlBSSUNFX1RBQkxFX1JFUEVUSVRJVkVf", + "SEVBREVSUxACEiYKIlBSSUNFX1RBQkxFX1JFUEVUSVRJVkVfREVTQ1JJUFRJ", + "T04QAxIhCh1QUklDRV9UQUJMRV9JTkNPTlNJU1RFTlRfUk9XUxAEEioKJlBS", + "SUNFX0RFU0NSSVBUSU9OX0hBU19QUklDRV9RVUFMSUZJRVJTEAUSHgoaUFJJ", + "Q0VfVU5TVVBQT1JURURfTEFOR1VBR0UQBhIuCipQUklDRV9UQUJMRV9ST1df", + "SEVBREVSX1RBQkxFX1RZUEVfTUlTTUFUQ0gQBxIvCitQUklDRV9UQUJMRV9S", + "T1dfSEVBREVSX0hBU19QUk9NT1RJT05BTF9URVhUEAgSLAooUFJJQ0VfVEFC", + "TEVfUk9XX0RFU0NSSVBUSU9OX05PVF9SRUxFVkFOVBAJEjQKMFBSSUNFX1RB", + "QkxFX1JPV19ERVNDUklQVElPTl9IQVNfUFJPTU9USU9OQUxfVEVYVBAKEjEK", + "LVBSSUNFX1RBQkxFX1JPV19IRUFERVJfREVTQ1JJUFRJT05fUkVQRVRJVElW", + "RRALEh4KGlBSSUNFX1RBQkxFX1JPV19VTlJBVEVBQkxFEAwSIQodUFJJQ0Vf", + "VEFCTEVfUk9XX1BSSUNFX0lOVkFMSUQQDRIfChtQUklDRV9UQUJMRV9ST1df", + "VVJMX0lOVkFMSUQQDhIpCiVQUklDRV9IRUFERVJfT1JfREVTQ1JJUFRJT05f", + "SEFTX1BSSUNFEA8SLgoqU1RSVUNUVVJFRF9TTklQUEVUU19IRUFERVJfUE9M", + "SUNZX1ZJT0xBVEVEEBASJwojU1RSVUNUVVJFRF9TTklQUEVUU19SRVBFQVRF", + "RF9WQUxVRVMQERIsCihTVFJVQ1RVUkVEX1NOSVBQRVRTX0VESVRPUklBTF9H", + "VUlERUxJTkVTEBISLAooU1RSVUNUVVJFRF9TTklQUEVUU19IQVNfUFJPTU9U", + "SU9OQUxfVEVYVBATQvoBCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXNCJUZlZWRJdGVtUXVhbGl0eURpc2FwcHJvdmFsUmVhc29uUHJvdG9Q", + "AVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMv", + "Z29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5H", + "b29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xF", + "bnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJv", + "dG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityDisapprovalReasonEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityDisapprovalReasonEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityDisapprovalReasonEnum.Types.FeedItemQualityDisapprovalReason) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible quality evaluation disapproval reasons + /// of a feed item. + /// + public sealed partial class FeedItemQualityDisapprovalReasonEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemQualityDisapprovalReasonEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedItemQualityDisapprovalReasonReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemQualityDisapprovalReasonEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemQualityDisapprovalReasonEnum(FeedItemQualityDisapprovalReasonEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemQualityDisapprovalReasonEnum Clone() { + return new FeedItemQualityDisapprovalReasonEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemQualityDisapprovalReasonEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemQualityDisapprovalReasonEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemQualityDisapprovalReasonEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemQualityDisapprovalReasonEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible quality evaluation disapproval reasons of a feed item. + /// + public enum FeedItemQualityDisapprovalReason { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Price contains repetitive headers. + /// + [pbr::OriginalName("PRICE_TABLE_REPETITIVE_HEADERS")] PriceTableRepetitiveHeaders = 2, + /// + /// Price contains repetitive description. + /// + [pbr::OriginalName("PRICE_TABLE_REPETITIVE_DESCRIPTION")] PriceTableRepetitiveDescription = 3, + /// + /// Price contains inconsistent items. + /// + [pbr::OriginalName("PRICE_TABLE_INCONSISTENT_ROWS")] PriceTableInconsistentRows = 4, + /// + /// Price contains qualifiers in description. + /// + [pbr::OriginalName("PRICE_DESCRIPTION_HAS_PRICE_QUALIFIERS")] PriceDescriptionHasPriceQualifiers = 5, + /// + /// Price contains an unsupported language. + /// + [pbr::OriginalName("PRICE_UNSUPPORTED_LANGUAGE")] PriceUnsupportedLanguage = 6, + /// + /// Price item header is not relevant to the price type. + /// + [pbr::OriginalName("PRICE_TABLE_ROW_HEADER_TABLE_TYPE_MISMATCH")] PriceTableRowHeaderTableTypeMismatch = 7, + /// + /// Price item header has promotional text. + /// + [pbr::OriginalName("PRICE_TABLE_ROW_HEADER_HAS_PROMOTIONAL_TEXT")] PriceTableRowHeaderHasPromotionalText = 8, + /// + /// Price item description is not relevant to the item header. + /// + [pbr::OriginalName("PRICE_TABLE_ROW_DESCRIPTION_NOT_RELEVANT")] PriceTableRowDescriptionNotRelevant = 9, + /// + /// Price item description contains promotional text. + /// + [pbr::OriginalName("PRICE_TABLE_ROW_DESCRIPTION_HAS_PROMOTIONAL_TEXT")] PriceTableRowDescriptionHasPromotionalText = 10, + /// + /// Price item header and description are repetitive. + /// + [pbr::OriginalName("PRICE_TABLE_ROW_HEADER_DESCRIPTION_REPETITIVE")] PriceTableRowHeaderDescriptionRepetitive = 11, + /// + /// Price item is in a foreign language, nonsense, or can't be rated. + /// + [pbr::OriginalName("PRICE_TABLE_ROW_UNRATEABLE")] PriceTableRowUnrateable = 12, + /// + /// Price item price is invalid or inaccurate. + /// + [pbr::OriginalName("PRICE_TABLE_ROW_PRICE_INVALID")] PriceTableRowPriceInvalid = 13, + /// + /// Price item URL is invalid or irrelevant. + /// + [pbr::OriginalName("PRICE_TABLE_ROW_URL_INVALID")] PriceTableRowUrlInvalid = 14, + /// + /// Price item header or description has price. + /// + [pbr::OriginalName("PRICE_HEADER_OR_DESCRIPTION_HAS_PRICE")] PriceHeaderOrDescriptionHasPrice = 15, + /// + /// Structured snippet values do not match the header. + /// + [pbr::OriginalName("STRUCTURED_SNIPPETS_HEADER_POLICY_VIOLATED")] StructuredSnippetsHeaderPolicyViolated = 16, + /// + /// Structured snippet values are repeated. + /// + [pbr::OriginalName("STRUCTURED_SNIPPETS_REPEATED_VALUES")] StructuredSnippetsRepeatedValues = 17, + /// + /// Structured snippet values violate editorial guidelines like punctuation. + /// + [pbr::OriginalName("STRUCTURED_SNIPPETS_EDITORIAL_GUIDELINES")] StructuredSnippetsEditorialGuidelines = 18, + /// + /// Structured snippet contain promotional text. + /// + [pbr::OriginalName("STRUCTURED_SNIPPETS_HAS_PROMOTIONAL_TEXT")] StructuredSnippetsHasPromotionalText = 19, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemService.cs b/src/V3/Stubs/FeedItemService.cs new file mode 100644 index 000000000..2ae8b2507 --- /dev/null +++ b/src/V3/Stubs/FeedItemService.cs @@ -0,0 +1,1031 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_item_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/feed_item_service.proto + public static partial class FeedItemServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/feed_item_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9mZWVkX2l0ZW1f", + "c2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMaMWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9mZWVkX2l0", + "ZW0ucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8aF2dvb2ds", + "ZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9y", + "LnByb3RvGiBnb29nbGUvcHJvdG9idWYvZmllbGRfbWFzay5wcm90bxoXZ29v", + "Z2xlL3JwYy9zdGF0dXMucHJvdG8iMAoSR2V0RmVlZEl0ZW1SZXF1ZXN0EhoK", + "DXJlc291cmNlX25hbWUYASABKAlCA+BBAiKwAQoWTXV0YXRlRmVlZEl0ZW1z", + "UmVxdWVzdBIYCgtjdXN0b21lcl9pZBgBIAEoCUID4EECEkwKCm9wZXJhdGlv", + "bnMYAiADKAsyMy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5G", + "ZWVkSXRlbU9wZXJhdGlvbkID4EECEhcKD3BhcnRpYWxfZmFpbHVyZRgDIAEo", + "CBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIuEBChFGZWVkSXRlbU9wZXJhdGlv", + "bhIvCgt1cGRhdGVfbWFzaxgEIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5GaWVs", + "ZE1hc2sSPQoGY3JlYXRlGAEgASgLMisuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzLkZlZWRJdGVtSAASPQoGdXBkYXRlGAIgASgLMisuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkZlZWRJdGVtSAASEAoG", + "cmVtb3ZlGAMgASgJSABCCwoJb3BlcmF0aW9uIpUBChdNdXRhdGVGZWVkSXRl", + "bXNSZXNwb25zZRIxChVwYXJ0aWFsX2ZhaWx1cmVfZXJyb3IYAyABKAsyEi5n", + "b29nbGUucnBjLlN0YXR1cxJHCgdyZXN1bHRzGAIgAygLMjYuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlRmVlZEl0ZW1SZXN1bHQi", + "LQoUTXV0YXRlRmVlZEl0ZW1SZXN1bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEo", + "CTLDAwoPRmVlZEl0ZW1TZXJ2aWNlErUBCgtHZXRGZWVkSXRlbRI0Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEZlZWRJdGVtUmVxdWVz", + "dBorLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5GZWVkSXRl", + "bSJDgtPkkwItEisvdjMve3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovZmVl", + "ZEl0ZW1zLyp92kENcmVzb3VyY2VfbmFtZRLaAQoPTXV0YXRlRmVlZEl0ZW1z", + "EjguZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlRmVl", + "ZEl0ZW1zUmVxdWVzdBo5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzLk11dGF0ZUZlZWRJdGVtc1Jlc3BvbnNlIlKC0+STAjMiLi92My9jdXN0", + "b21lcnMve2N1c3RvbWVyX2lkPSp9L2ZlZWRJdGVtczptdXRhdGU6ASraQRZj", + "dXN0b21lcl9pZCxvcGVyYXRpb25zGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBp", + "cy5jb21C+wEKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "c0IURmVlZEl0ZW1TZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2Vz", + "O3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2Vy", + "dmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.FeedItemReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemRequest), global::Google.Ads.GoogleAds.V3.Services.GetFeedItemRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.FeedItemOperation), global::Google.Ads.GoogleAds.V3.Services.FeedItemOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemResult), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [FeedItemService.GetFeedItem][google.ads.googleads.v3.services.FeedItemService.GetFeedItem]. + /// + public sealed partial class GetFeedItemRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetFeedItemRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedItemRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedItemRequest(GetFeedItemRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedItemRequest Clone() { + return new GetFeedItemRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the feed item to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetFeedItemRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetFeedItemRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetFeedItemRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [FeedItemService.MutateFeedItems][google.ads.googleads.v3.services.FeedItemService.MutateFeedItems]. + /// + public sealed partial class MutateFeedItemsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedItemsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemsRequest(MutateFeedItemsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemsRequest Clone() { + return new MutateFeedItemsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose feed items are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.FeedItemOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual feed items. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedItemsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedItemsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedItemsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on an feed item. + /// + public sealed partial class FeedItemOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemOperation(FeedItemOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemOperation Clone() { + return new FeedItemOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new feed item. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedItem Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.FeedItem) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The feed item is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedItem Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.FeedItem) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed feed item is + /// expected, in this format: + /// + /// `customers/{customer_id}/feedItems/{feed_id}~{feed_item_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.FeedItem(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.FeedItem(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.FeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.FeedItem(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.FeedItem subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.FeedItem(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for an feed item mutate. + /// + public sealed partial class MutateFeedItemsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedItemsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemsResponse(MutateFeedItemsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemsResponse Clone() { + return new MutateFeedItemsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedItemsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedItemsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedItemsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the feed item mutate. + /// + public sealed partial class MutateFeedItemResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedItemResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemResult(MutateFeedItemResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemResult Clone() { + return new MutateFeedItemResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedItemResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedItemResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedItemResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemServiceClient.cs b/src/V3/Stubs/FeedItemServiceClient.cs new file mode 100644 index 000000000..ac6ee0db9 --- /dev/null +++ b/src/V3/Stubs/FeedItemServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class FeedItemServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static FeedItemServiceSettings GetDefault() => new FeedItemServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public FeedItemServiceSettings() { } + + private FeedItemServiceSettings(FeedItemServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetFeedItemSettings = existing.GetFeedItemSettings; + MutateFeedItemsSettings = existing.MutateFeedItemsSettings; + OnCopy(existing); + } + + partial void OnCopy(FeedItemServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// FeedItemServiceClient.GetFeedItem and FeedItemServiceClient.GetFeedItemAsync. + /// + /// + /// The default FeedItemServiceClient.GetFeedItem and + /// FeedItemServiceClient.GetFeedItemAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetFeedItemSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// FeedItemServiceClient.MutateFeedItems and FeedItemServiceClient.MutateFeedItemsAsync. + /// + /// + /// The default FeedItemServiceClient.MutateFeedItems and + /// FeedItemServiceClient.MutateFeedItemsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateFeedItemsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public FeedItemServiceSettings Clone() => new FeedItemServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class FeedItemServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public FeedItemServiceSettings Settings { get; set; } + + /// + public override FeedItemServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return FeedItemServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return FeedItemServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => FeedItemServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => FeedItemServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => FeedItemServiceClient.ChannelPool; + } + + /// + /// FeedItemService client wrapper, for convenient use. + /// + public abstract partial class FeedItemServiceClient + { + /// + /// The default endpoint for the FeedItemService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default FeedItemService scopes. + /// + /// + /// The default FeedItemService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedItemServiceClient client = await FeedItemServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedItemServiceClient.DefaultEndpoint.Host, FeedItemServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedItemServiceClient client = FeedItemServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, FeedItemServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedItemServiceClient client = FeedItemServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedItemServiceClient.DefaultEndpoint.Host, FeedItemServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedItemServiceClient client = FeedItemServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static FeedItemServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, FeedItemServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedItemServiceClient Create(grpccore::Channel channel, FeedItemServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedItemServiceClient Create(grpccore::CallInvoker callInvoker, FeedItemServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + FeedItemService.FeedItemServiceClient grpcClient = new FeedItemService.FeedItemServiceClient(callInvoker); + return new FeedItemServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC FeedItemService client. + /// + public virtual FeedItemService.FeedItemServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested feed item in full detail. + /// + /// + /// Required. The resource name of the feed item to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedItemAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedItemAsync( + new GetFeedItemRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed item in full detail. + /// + /// + /// Required. The resource name of the feed item to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedItemAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetFeedItemAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed item in full detail. + /// + /// + /// Required. The resource name of the feed item to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::FeedItem GetFeedItem( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedItem( + new GetFeedItemRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedItemAsync( + GetFeedItemRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedItemAsync( + GetFeedItemRequest request, + st::CancellationToken cancellationToken) => GetFeedItemAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::FeedItem GetFeedItem( + GetFeedItemRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed items are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed items. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateFeedItemsAsync( + new MutateFeedItemsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed items are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed items. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateFeedItemsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed items are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed items. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedItemsResponse MutateFeedItems( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateFeedItems( + new MutateFeedItemsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed items are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed items. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateFeedItemsAsync( + new MutateFeedItemsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed items are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed items. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateFeedItemsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed items are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed items. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedItemsResponse MutateFeedItems( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateFeedItems( + new MutateFeedItemsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemsAsync( + MutateFeedItemsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemsAsync( + MutateFeedItemsRequest request, + st::CancellationToken cancellationToken) => MutateFeedItemsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedItemsResponse MutateFeedItems( + MutateFeedItemsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// FeedItemService client wrapper implementation, for convenient use. + /// + public sealed partial class FeedItemServiceClientImpl : FeedItemServiceClient + { + private readonly gaxgrpc::ApiCall _callGetFeedItem; + private readonly gaxgrpc::ApiCall _callMutateFeedItems; + + /// + /// Constructs a client wrapper for the FeedItemService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public FeedItemServiceClientImpl(FeedItemService.FeedItemServiceClient grpcClient, FeedItemServiceSettings settings) + { + GrpcClient = grpcClient; + FeedItemServiceSettings effectiveSettings = settings ?? FeedItemServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetFeedItem = clientHelper.BuildApiCall( + GrpcClient.GetFeedItemAsync, GrpcClient.GetFeedItem, effectiveSettings.GetFeedItemSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateFeedItems = clientHelper.BuildApiCall( + GrpcClient.MutateFeedItemsAsync, GrpcClient.MutateFeedItems, effectiveSettings.MutateFeedItemsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetFeedItem); + Modify_GetFeedItemApiCall(ref _callGetFeedItem); + Modify_ApiCall(ref _callMutateFeedItems); + Modify_MutateFeedItemsApiCall(ref _callMutateFeedItems); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetFeedItemApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateFeedItemsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(FeedItemService.FeedItemServiceClient grpcClient, FeedItemServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC FeedItemService client. + /// + public override FeedItemService.FeedItemServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetFeedItemRequest(ref GetFeedItemRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateFeedItemsRequest(ref MutateFeedItemsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetFeedItemAsync( + GetFeedItemRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedItemRequest(ref request, ref callSettings); + return _callGetFeedItem.Async(request, callSettings); + } + + /// + /// Returns the requested feed item in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::FeedItem GetFeedItem( + GetFeedItemRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedItemRequest(ref request, ref callSettings); + return _callGetFeedItem.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateFeedItemsAsync( + MutateFeedItemsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateFeedItemsRequest(ref request, ref callSettings); + return _callMutateFeedItems.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateFeedItemsResponse MutateFeedItems( + MutateFeedItemsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateFeedItemsRequest(ref request, ref callSettings); + return _callMutateFeedItems.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/FeedItemServiceGrpc.cs b/src/V3/Stubs/FeedItemServiceGrpc.cs new file mode 100644 index 000000000..1dc3c30d9 --- /dev/null +++ b/src/V3/Stubs/FeedItemServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_item_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage feed items. + /// + public static partial class FeedItemService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.FeedItemService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetFeedItemRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetFeedItemRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_FeedItem = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.FeedItem.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateFeedItemsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateFeedItemsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetFeedItem = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetFeedItem", + __Marshaller_google_ads_googleads_v3_services_GetFeedItemRequest, + __Marshaller_google_ads_googleads_v3_resources_FeedItem); + + static readonly grpc::Method __Method_MutateFeedItems = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateFeedItems", + __Marshaller_google_ads_googleads_v3_services_MutateFeedItemsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateFeedItemsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of FeedItemService + public abstract partial class FeedItemServiceBase + { + /// + /// Returns the requested feed item in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetFeedItem(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateFeedItems(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for FeedItemService + public partial class FeedItemServiceClient : grpc::ClientBase + { + /// Creates a new client for FeedItemService + /// The channel to use to make remote calls. + public FeedItemServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for FeedItemService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public FeedItemServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected FeedItemServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected FeedItemServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested feed item in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.FeedItem GetFeedItem(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedItem(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed item in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.FeedItem GetFeedItem(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetFeedItem, null, options, request); + } + /// + /// Returns the requested feed item in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedItemAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedItemAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed item in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedItemAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetFeedItem, null, options, request); + } + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsResponse MutateFeedItems(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateFeedItems(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsResponse MutateFeedItems(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateFeedItems, null, options, request); + } + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateFeedItemsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateFeedItemsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes feed items. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateFeedItemsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateFeedItems, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override FeedItemServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new FeedItemServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(FeedItemServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetFeedItem, serviceImpl.GetFeedItem) + .AddMethod(__Method_MutateFeedItems, serviceImpl.MutateFeedItems).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, FeedItemServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetFeedItem, serviceImpl.GetFeedItem); + serviceBinder.AddMethod(__Method_MutateFeedItems, serviceImpl.MutateFeedItems); + } + + } +} +#endregion diff --git a/src/V3/Stubs/FeedItemStatus.cs b/src/V3/Stubs/FeedItemStatus.cs new file mode 100644 index 000000000..1a1c4c790 --- /dev/null +++ b/src/V3/Stubs/FeedItemStatus.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_item_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_item_status.proto + public static partial class FeedItemStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_item_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2l0ZW1fc3Rh", + "dHVzLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJeChJGZWVkSXRlbVN0YXR1c0Vu", + "dW0iSAoORmVlZEl0ZW1TdGF0dXMSDwoLVU5TUEVDSUZJRUQQABILCgdVTktO", + "T1dOEAESCwoHRU5BQkxFRBACEgsKB1JFTU9WRUQQA0LoAQohY29tLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhNGZWVkSXRlbVN0YXR1c1Byb3Rv", + "UAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "RW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusEnum.Types.FeedItemStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of a feed item. + /// + public sealed partial class FeedItemStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedItemStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemStatusEnum(FeedItemStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemStatusEnum Clone() { + return new FeedItemStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a feed item. + /// + public enum FeedItemStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Feed item is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Feed item has been removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemTarget.cs b/src/V3/Stubs/FeedItemTarget.cs new file mode 100644 index 000000000..d520e1ce9 --- /dev/null +++ b/src/V3/Stubs/FeedItemTarget.cs @@ -0,0 +1,602 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/feed_item_target.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/feed_item_target.proto + public static partial class FeedItemTargetReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/feed_item_target.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemTargetReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZmVlZF9pdGVt", + "X3RhcmdldC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzGi1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vY3JpdGVyaWEu", + "cHJvdG8aO2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2ZlZWRfaXRl", + "bV90YXJnZXRfZGV2aWNlLnByb3RvGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9mZWVkX2l0ZW1fdGFyZ2V0X3N0YXR1cy5wcm90bxo5Z29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvZmVlZF9pdGVtX3RhcmdldF90eXBl", + "LnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29n", + "bGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBl", + "cnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i1QgKDkZl", + "ZWRJdGVtVGFyZ2V0EkYKDXJlc291cmNlX25hbWUYASABKAlCL+BBBfpBKQon", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0ZlZWRJdGVtVGFyZ2V0EloKCWZl", + "ZWRfaXRlbRgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIp", + "4EEF+kEjCiFnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRmVlZEl0ZW0SbAoV", + "ZmVlZF9pdGVtX3RhcmdldF90eXBlGAMgASgOMkguZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZW51bXMuRmVlZEl0ZW1UYXJnZXRUeXBlRW51bS5GZWVkSXRl", + "bVRhcmdldFR5cGVCA+BBAxI9ChNmZWVkX2l0ZW1fdGFyZ2V0X2lkGAYgASgL", + "MhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWVCA+BBAxJhCgZzdGF0dXMY", + "CyABKA4yTC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5GZWVkSXRl", + "bVRhcmdldFN0YXR1c0VudW0uRmVlZEl0ZW1UYXJnZXRTdGF0dXNCA+BBAxJb", + "CghjYW1wYWlnbhgEIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZUIp4EEF+kEjCiFnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQ2FtcGFpZ25I", + "ABJaCghhZF9ncm91cBgFIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZUIo4EEF+kEiCiBnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vQWRHcm91", + "cEgAEkMKB2tleXdvcmQYByABKAsyKy5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5jb21tb24uS2V5d29yZEluZm9CA+BBBUgAEm8KE2dlb190YXJnZXRfY29u", + "c3RhbnQYCCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCMuBB", + "BfpBLAoqZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0dlb1RhcmdldENvbnN0", + "YW50SAASYwoGZGV2aWNlGAkgASgOMkwuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZW51bXMuRmVlZEl0ZW1UYXJnZXREZXZpY2VFbnVtLkZlZWRJdGVtVGFy", + "Z2V0RGV2aWNlQgPgQQVIABJKCgthZF9zY2hlZHVsZRgKIAEoCzIuLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5BZFNjaGVkdWxlSW5mb0ID4EEF", + "SAA6ZepBYgonZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0ZlZWRJdGVtVGFy", + "Z2V0EjdjdXN0b21lcnMve2N1c3RvbWVyfS9mZWVkSXRlbVRhcmdldHMve2Zl", + "ZWRfaXRlbV90YXJnZXR9QggKBnRhcmdldEKAAgolY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnJlc291cmNlc0ITRmVlZEl0ZW1UYXJnZXRQcm90b1AB", + "Wkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2ds", + "ZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.CriteriaReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget), global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget.Parser, new[]{ "ResourceName", "FeedItem", "FeedItemTargetType", "FeedItemTargetId", "Status", "Campaign", "AdGroup", "Keyword", "GeoTargetConstant", "Device", "AdSchedule" }, new[]{ "Target" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A feed item target. + /// + public sealed partial class FeedItemTarget : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemTarget()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedItemTargetReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTarget() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTarget(FeedItemTarget other) : this() { + resourceName_ = other.resourceName_; + FeedItem = other.FeedItem; + feedItemTargetType_ = other.feedItemTargetType_; + FeedItemTargetId = other.FeedItemTargetId; + status_ = other.status_; + switch (other.TargetCase) { + case TargetOneofCase.Campaign: + Campaign = other.Campaign; + break; + case TargetOneofCase.AdGroup: + AdGroup = other.AdGroup; + break; + case TargetOneofCase.Keyword: + Keyword = other.Keyword.Clone(); + break; + case TargetOneofCase.GeoTargetConstant: + GeoTargetConstant = other.GeoTargetConstant; + break; + case TargetOneofCase.Device: + Device = other.Device; + break; + case TargetOneofCase.AdSchedule: + AdSchedule = other.AdSchedule.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTarget Clone() { + return new FeedItemTarget(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the feed item target. + /// Feed item target resource names have the form: + /// `customers/{customer_id}/feedItemTargets/{feed_id}~{feed_item_id}~{feed_item_target_type}~{feed_item_target_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "feed_item" field. + public const int FeedItemFieldNumber = 2; + private static readonly pb::FieldCodec _single_feedItem_codec = pb::FieldCodec.ForClassWrapper(18); + private string feedItem_; + /// + /// Immutable. The feed item to which this feed item target belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string FeedItem { + get { return feedItem_; } + set { + feedItem_ = value; + } + } + + + /// Field number for the "feed_item_target_type" field. + public const int FeedItemTargetTypeFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeEnum.Types.FeedItemTargetType feedItemTargetType_ = 0; + /// + /// Output only. The target type of this feed item target. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeEnum.Types.FeedItemTargetType FeedItemTargetType { + get { return feedItemTargetType_; } + set { + feedItemTargetType_ = value; + } + } + + /// Field number for the "feed_item_target_id" field. + public const int FeedItemTargetIdFieldNumber = 6; + private static readonly pb::FieldCodec _single_feedItemTargetId_codec = pb::FieldCodec.ForStructWrapper(50); + private long? feedItemTargetId_; + /// + /// Output only. The ID of the targeted resource. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? FeedItemTargetId { + get { return feedItemTargetId_; } + set { + feedItemTargetId_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 11; + private global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetStatusEnum.Types.FeedItemTargetStatus status_ = 0; + /// + /// Output only. Status of the feed item target. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetStatusEnum.Types.FeedItemTargetStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 4; + private static readonly pb::FieldCodec _oneof_campaign_codec = pb::FieldCodec.ForClassWrapper(34); + /// + /// Immutable. The targeted campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Campaign { + get { return targetCase_ == TargetOneofCase.Campaign ? (string) target_ : (string) null; } + set { + target_ = value; + targetCase_ = value == null ? TargetOneofCase.None : TargetOneofCase.Campaign; + } + } + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 5; + private static readonly pb::FieldCodec _oneof_adGroup_codec = pb::FieldCodec.ForClassWrapper(42); + /// + /// Immutable. The targeted ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AdGroup { + get { return targetCase_ == TargetOneofCase.AdGroup ? (string) target_ : (string) null; } + set { + target_ = value; + targetCase_ = value == null ? TargetOneofCase.None : TargetOneofCase.AdGroup; + } + } + + /// Field number for the "keyword" field. + public const int KeywordFieldNumber = 7; + /// + /// Immutable. The targeted keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.KeywordInfo Keyword { + get { return targetCase_ == TargetOneofCase.Keyword ? (global::Google.Ads.GoogleAds.V3.Common.KeywordInfo) target_ : null; } + set { + target_ = value; + targetCase_ = value == null ? TargetOneofCase.None : TargetOneofCase.Keyword; + } + } + + /// Field number for the "geo_target_constant" field. + public const int GeoTargetConstantFieldNumber = 8; + private static readonly pb::FieldCodec _oneof_geoTargetConstant_codec = pb::FieldCodec.ForClassWrapper(66); + /// + /// Immutable. The targeted geo target constant resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string GeoTargetConstant { + get { return targetCase_ == TargetOneofCase.GeoTargetConstant ? (string) target_ : (string) null; } + set { + target_ = value; + targetCase_ = value == null ? TargetOneofCase.None : TargetOneofCase.GeoTargetConstant; + } + } + + /// Field number for the "device" field. + public const int DeviceFieldNumber = 9; + /// + /// Immutable. The targeted device. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum.Types.FeedItemTargetDevice Device { + get { return targetCase_ == TargetOneofCase.Device ? (global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum.Types.FeedItemTargetDevice) target_ : 0; } + set { + target_ = value; + targetCase_ = TargetOneofCase.Device; + } + } + + /// Field number for the "ad_schedule" field. + public const int AdScheduleFieldNumber = 10; + /// + /// Immutable. The targeted schedule. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo AdSchedule { + get { return targetCase_ == TargetOneofCase.AdSchedule ? (global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo) target_ : null; } + set { + target_ = value; + targetCase_ = value == null ? TargetOneofCase.None : TargetOneofCase.AdSchedule; + } + } + + private object target_; + /// Enum of possible cases for the "target" oneof. + public enum TargetOneofCase { + None = 0, + Campaign = 4, + AdGroup = 5, + Keyword = 7, + GeoTargetConstant = 8, + Device = 9, + AdSchedule = 10, + } + private TargetOneofCase targetCase_ = TargetOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetOneofCase TargetCase { + get { return targetCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearTarget() { + targetCase_ = TargetOneofCase.None; + target_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemTarget); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemTarget other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (FeedItem != other.FeedItem) return false; + if (FeedItemTargetType != other.FeedItemTargetType) return false; + if (FeedItemTargetId != other.FeedItemTargetId) return false; + if (Status != other.Status) return false; + if (Campaign != other.Campaign) return false; + if (AdGroup != other.AdGroup) return false; + if (!object.Equals(Keyword, other.Keyword)) return false; + if (GeoTargetConstant != other.GeoTargetConstant) return false; + if (Device != other.Device) return false; + if (!object.Equals(AdSchedule, other.AdSchedule)) return false; + if (TargetCase != other.TargetCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (feedItem_ != null) hash ^= FeedItem.GetHashCode(); + if (FeedItemTargetType != 0) hash ^= FeedItemTargetType.GetHashCode(); + if (feedItemTargetId_ != null) hash ^= FeedItemTargetId.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (targetCase_ == TargetOneofCase.Campaign) hash ^= Campaign.GetHashCode(); + if (targetCase_ == TargetOneofCase.AdGroup) hash ^= AdGroup.GetHashCode(); + if (targetCase_ == TargetOneofCase.Keyword) hash ^= Keyword.GetHashCode(); + if (targetCase_ == TargetOneofCase.GeoTargetConstant) hash ^= GeoTargetConstant.GetHashCode(); + if (targetCase_ == TargetOneofCase.Device) hash ^= Device.GetHashCode(); + if (targetCase_ == TargetOneofCase.AdSchedule) hash ^= AdSchedule.GetHashCode(); + hash ^= (int) targetCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (feedItem_ != null) { + _single_feedItem_codec.WriteTagAndValue(output, FeedItem); + } + if (FeedItemTargetType != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) FeedItemTargetType); + } + if (targetCase_ == TargetOneofCase.Campaign) { + _oneof_campaign_codec.WriteTagAndValue(output, (string) target_); + } + if (targetCase_ == TargetOneofCase.AdGroup) { + _oneof_adGroup_codec.WriteTagAndValue(output, (string) target_); + } + if (feedItemTargetId_ != null) { + _single_feedItemTargetId_codec.WriteTagAndValue(output, FeedItemTargetId); + } + if (targetCase_ == TargetOneofCase.Keyword) { + output.WriteRawTag(58); + output.WriteMessage(Keyword); + } + if (targetCase_ == TargetOneofCase.GeoTargetConstant) { + _oneof_geoTargetConstant_codec.WriteTagAndValue(output, (string) target_); + } + if (targetCase_ == TargetOneofCase.Device) { + output.WriteRawTag(72); + output.WriteEnum((int) Device); + } + if (targetCase_ == TargetOneofCase.AdSchedule) { + output.WriteRawTag(82); + output.WriteMessage(AdSchedule); + } + if (Status != 0) { + output.WriteRawTag(88); + output.WriteEnum((int) Status); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (feedItem_ != null) { + size += _single_feedItem_codec.CalculateSizeWithTag(FeedItem); + } + if (FeedItemTargetType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) FeedItemTargetType); + } + if (feedItemTargetId_ != null) { + size += _single_feedItemTargetId_codec.CalculateSizeWithTag(FeedItemTargetId); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (targetCase_ == TargetOneofCase.Campaign) { + size += _oneof_campaign_codec.CalculateSizeWithTag(Campaign); + } + if (targetCase_ == TargetOneofCase.AdGroup) { + size += _oneof_adGroup_codec.CalculateSizeWithTag(AdGroup); + } + if (targetCase_ == TargetOneofCase.Keyword) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Keyword); + } + if (targetCase_ == TargetOneofCase.GeoTargetConstant) { + size += _oneof_geoTargetConstant_codec.CalculateSizeWithTag(GeoTargetConstant); + } + if (targetCase_ == TargetOneofCase.Device) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Device); + } + if (targetCase_ == TargetOneofCase.AdSchedule) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdSchedule); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemTarget other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.feedItem_ != null) { + if (feedItem_ == null || other.FeedItem != "") { + FeedItem = other.FeedItem; + } + } + if (other.FeedItemTargetType != 0) { + FeedItemTargetType = other.FeedItemTargetType; + } + if (other.feedItemTargetId_ != null) { + if (feedItemTargetId_ == null || other.FeedItemTargetId != 0L) { + FeedItemTargetId = other.FeedItemTargetId; + } + } + if (other.Status != 0) { + Status = other.Status; + } + switch (other.TargetCase) { + case TargetOneofCase.Campaign: + Campaign = other.Campaign; + break; + case TargetOneofCase.AdGroup: + AdGroup = other.AdGroup; + break; + case TargetOneofCase.Keyword: + if (Keyword == null) { + Keyword = new global::Google.Ads.GoogleAds.V3.Common.KeywordInfo(); + } + Keyword.MergeFrom(other.Keyword); + break; + case TargetOneofCase.GeoTargetConstant: + GeoTargetConstant = other.GeoTargetConstant; + break; + case TargetOneofCase.Device: + Device = other.Device; + break; + case TargetOneofCase.AdSchedule: + if (AdSchedule == null) { + AdSchedule = new global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo(); + } + AdSchedule.MergeFrom(other.AdSchedule); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_feedItem_codec.Read(input); + if (feedItem_ == null || value != "") { + FeedItem = value; + } + break; + } + case 24: { + FeedItemTargetType = (global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeEnum.Types.FeedItemTargetType) input.ReadEnum(); + break; + } + case 34: { + Campaign = _oneof_campaign_codec.Read(input); + break; + } + case 42: { + AdGroup = _oneof_adGroup_codec.Read(input); + break; + } + case 50: { + long? value = _single_feedItemTargetId_codec.Read(input); + if (feedItemTargetId_ == null || value != 0L) { + FeedItemTargetId = value; + } + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Common.KeywordInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.KeywordInfo(); + if (targetCase_ == TargetOneofCase.Keyword) { + subBuilder.MergeFrom(Keyword); + } + input.ReadMessage(subBuilder); + Keyword = subBuilder; + break; + } + case 66: { + GeoTargetConstant = _oneof_geoTargetConstant_codec.Read(input); + break; + } + case 72: { + target_ = input.ReadEnum(); + targetCase_ = TargetOneofCase.Device; + break; + } + case 82: { + global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo subBuilder = new global::Google.Ads.GoogleAds.V3.Common.AdScheduleInfo(); + if (targetCase_ == TargetOneofCase.AdSchedule) { + subBuilder.MergeFrom(AdSchedule); + } + input.ReadMessage(subBuilder); + AdSchedule = subBuilder; + break; + } + case 88: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetStatusEnum.Types.FeedItemTargetStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemTargetDevice.cs b/src/V3/Stubs/FeedItemTargetDevice.cs new file mode 100644 index 000000000..3c686ed2f --- /dev/null +++ b/src/V3/Stubs/FeedItemTargetDevice.cs @@ -0,0 +1,182 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_item_target_device.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_item_target_device.proto + public static partial class FeedItemTargetDeviceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_item_target_device.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemTargetDeviceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2l0ZW1fdGFy", + "Z2V0X2RldmljZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iXAoYRmVlZEl0ZW1U", + "YXJnZXREZXZpY2VFbnVtIkAKFEZlZWRJdGVtVGFyZ2V0RGV2aWNlEg8KC1VO", + "U1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgoKBk1PQklMRRACQu4BCiFjb20u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCGUZlZWRJdGVtVGFyZ2V0", + "RGV2aWNlUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29v", + "Z2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgId", + "R29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYz", + "OjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceEnum.Types.FeedItemTargetDevice) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible data types for a feed item target + /// device. + /// + public sealed partial class FeedItemTargetDeviceEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemTargetDeviceEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetDeviceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetDeviceEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetDeviceEnum(FeedItemTargetDeviceEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetDeviceEnum Clone() { + return new FeedItemTargetDeviceEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemTargetDeviceEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemTargetDeviceEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemTargetDeviceEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemTargetDeviceEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible data types for a feed item target device. + /// + public enum FeedItemTargetDevice { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Mobile. + /// + [pbr::OriginalName("MOBILE")] Mobile = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemTargetError.cs b/src/V3/Stubs/FeedItemTargetError.cs new file mode 100644 index 000000000..48df713bf --- /dev/null +++ b/src/V3/Stubs/FeedItemTargetError.cs @@ -0,0 +1,217 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/feed_item_target_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/feed_item_target_error.proto + public static partial class FeedItemTargetErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/feed_item_target_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemTargetErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZmVlZF9pdGVtX3Rh", + "cmdldF9lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJy", + "b3JzGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvwCChdGZWVkSXRl", + "bVRhcmdldEVycm9yRW51bSLgAgoTRmVlZEl0ZW1UYXJnZXRFcnJvchIPCgtV", + "TlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIjCh9NVVNUX1NFVF9UQVJHRVRf", + "T05FT0ZfT05fQ1JFQVRFEAISIwofRkVFRF9JVEVNX1RBUkdFVF9BTFJFQURZ", + "X0VYSVNUUxADEiYKIkZFRURfSVRFTV9TQ0hFRFVMRVNfQ0FOTk9UX09WRVJM", + "QVAQBBIoCiRUQVJHRVRfTElNSVRfRVhDRUVERURfRk9SX0dJVkVOX1RZUEUQ", + "BRIeChpUT09fTUFOWV9TQ0hFRFVMRVNfUEVSX0RBWRAGEj0KOUNBTk5PVF9I", + "QVZFX0VOQUJMRURfQ0FNUEFJR05fQU5EX0VOQUJMRURfQURfR1JPVVBfVEFS", + "R0VUUxAHEhkKFURVUExJQ0FURV9BRF9TQ0hFRFVMRRAIEhUKEURVUExJQ0FU", + "RV9LRVlXT1JEEAlC8wEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnNCGEZlZWRJdGVtVGFyZ2V0RXJyb3JQcm90b1ABWkRnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "ZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedItemTargetErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FeedItemTargetErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedItemTargetErrorEnum.Types.FeedItemTargetError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible feed item target errors. + /// + public sealed partial class FeedItemTargetErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemTargetErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FeedItemTargetErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetErrorEnum(FeedItemTargetErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetErrorEnum Clone() { + return new FeedItemTargetErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemTargetErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemTargetErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemTargetErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemTargetErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible feed item target errors. + /// + public enum FeedItemTargetError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// On CREATE, the FeedItemTarget must have a populated field in the oneof + /// target. + /// + [pbr::OriginalName("MUST_SET_TARGET_ONEOF_ON_CREATE")] MustSetTargetOneofOnCreate = 2, + /// + /// The specified feed item target already exists, so it cannot be added. + /// + [pbr::OriginalName("FEED_ITEM_TARGET_ALREADY_EXISTS")] FeedItemTargetAlreadyExists = 3, + /// + /// The schedules for a given feed item cannot overlap. + /// + [pbr::OriginalName("FEED_ITEM_SCHEDULES_CANNOT_OVERLAP")] FeedItemSchedulesCannotOverlap = 4, + /// + /// Too many targets of a given type were added for a single feed item. + /// + [pbr::OriginalName("TARGET_LIMIT_EXCEEDED_FOR_GIVEN_TYPE")] TargetLimitExceededForGivenType = 5, + /// + /// Too many AdSchedules are enabled for the feed item for the given day. + /// + [pbr::OriginalName("TOO_MANY_SCHEDULES_PER_DAY")] TooManySchedulesPerDay = 6, + /// + /// A feed item may either have an enabled campaign target or an enabled ad + /// group target. + /// + [pbr::OriginalName("CANNOT_HAVE_ENABLED_CAMPAIGN_AND_ENABLED_AD_GROUP_TARGETS")] CannotHaveEnabledCampaignAndEnabledAdGroupTargets = 7, + /// + /// Duplicate ad schedules aren't allowed. + /// + [pbr::OriginalName("DUPLICATE_AD_SCHEDULE")] DuplicateAdSchedule = 8, + /// + /// Duplicate keywords aren't allowed. + /// + [pbr::OriginalName("DUPLICATE_KEYWORD")] DuplicateKeyword = 9, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemTargetService.cs b/src/V3/Stubs/FeedItemTargetService.cs new file mode 100644 index 000000000..f9025ae2b --- /dev/null +++ b/src/V3/Stubs/FeedItemTargetService.cs @@ -0,0 +1,843 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_item_target_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/feed_item_target_service.proto + public static partial class FeedItemTargetServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/feed_item_target_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemTargetServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9mZWVkX2l0ZW1f", + "dGFyZ2V0X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "ZmVlZF9pdGVtX3RhcmdldC5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkv", + "ZmllbGRfYmVoYXZpb3IucHJvdG8iNgoYR2V0RmVlZEl0ZW1UYXJnZXRSZXF1", + "ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiKMAQocTXV0YXRlRmVl", + "ZEl0ZW1UYXJnZXRzUmVxdWVzdBIYCgtjdXN0b21lcl9pZBgBIAEoCUID4EEC", + "ElIKCm9wZXJhdGlvbnMYAiADKAsyOS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5GZWVkSXRlbVRhcmdldE9wZXJhdGlvbkID4EECIn0KF0Zl", + "ZWRJdGVtVGFyZ2V0T3BlcmF0aW9uEkMKBmNyZWF0ZRgBIAEoCzIxLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5GZWVkSXRlbVRhcmdldEgA", + "EhAKBnJlbW92ZRgCIAEoCUgAQgsKCW9wZXJhdGlvbiJuCh1NdXRhdGVGZWVk", + "SXRlbVRhcmdldHNSZXNwb25zZRJNCgdyZXN1bHRzGAIgAygLMjwuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlRmVlZEl0ZW1UYXJn", + "ZXRSZXN1bHQiMwoaTXV0YXRlRmVlZEl0ZW1UYXJnZXRSZXN1bHQSFQoNcmVz", + "b3VyY2VfbmFtZRgBIAEoCTL5AwoVRmVlZEl0ZW1UYXJnZXRTZXJ2aWNlEs0B", + "ChFHZXRGZWVkSXRlbVRhcmdldBI6Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLkdldEZlZWRJdGVtVGFyZ2V0UmVxdWVzdBoxLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5GZWVkSXRlbVRhcmdldCJJgtPk", + "kwIzEjEvdjMve3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovZmVlZEl0ZW1U", + "YXJnZXRzLyp92kENcmVzb3VyY2VfbmFtZRLyAQoVTXV0YXRlRmVlZEl0ZW1U", + "YXJnZXRzEj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0", + "YXRlRmVlZEl0ZW1UYXJnZXRzUmVxdWVzdBo/Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzLk11dGF0ZUZlZWRJdGVtVGFyZ2V0c1Jlc3BvbnNl", + "IliC0+STAjkiNC92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2ZlZWRJ", + "dGVtVGFyZ2V0czptdXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVyYXRpb25z", + "GhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21CgQIKJGNvbS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0IaRmVlZEl0ZW1UYXJnZXRTZXJ2", + "aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FB", + "qgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVc", + "QWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29n", + "bGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.FeedItemTargetReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemTargetRequest), global::Google.Ads.GoogleAds.V3.Services.GetFeedItemTargetRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsRequest.Parser, new[]{ "CustomerId", "Operations" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetOperation), global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsResponse.Parser, new[]{ "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetResult), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [FeedItemTargetService.GetFeedItemTarget][google.ads.googleads.v3.services.FeedItemTargetService.GetFeedItemTarget]. + /// + public sealed partial class GetFeedItemTargetRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetFeedItemTargetRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedItemTargetRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedItemTargetRequest(GetFeedItemTargetRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedItemTargetRequest Clone() { + return new GetFeedItemTargetRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the feed item targets to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetFeedItemTargetRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetFeedItemTargetRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetFeedItemTargetRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [FeedItemTargetService.MutateFeedItemTargets][google.ads.googleads.v3.services.FeedItemTargetService.MutateFeedItemTargets]. + /// + public sealed partial class MutateFeedItemTargetsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedItemTargetsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetsRequest(MutateFeedItemTargetsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetsRequest Clone() { + return new MutateFeedItemTargetsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose feed item targets are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual feed item targets. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedItemTargetsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedItemTargetsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedItemTargetsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove) on an feed item target. + /// + public sealed partial class FeedItemTargetOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemTargetOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetOperation(FeedItemTargetOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetOperation Clone() { + return new FeedItemTargetOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new feed item + /// target. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 2; + /// + /// Remove operation: A resource name for the removed feed item target is + /// expected, in this format: + /// + /// `customers/{customer_id}/feedItemTargets/{feed_id}~{feed_item_id}~{feed_item_target_type}~{feed_item_target_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 2, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemTargetOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemTargetOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(18); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemTargetOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for an feed item target mutate. + /// + public sealed partial class MutateFeedItemTargetsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedItemTargetsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetsResponse(MutateFeedItemTargetsResponse other) : this() { + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetsResponse Clone() { + return new MutateFeedItemTargetsResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedItemTargetsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedItemTargetsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedItemTargetsResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// The result for the feed item target mutate. + /// + public sealed partial class MutateFeedItemTargetResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedItemTargetResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetResult(MutateFeedItemTargetResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedItemTargetResult Clone() { + return new MutateFeedItemTargetResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedItemTargetResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedItemTargetResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedItemTargetResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemTargetServiceClient.cs b/src/V3/Stubs/FeedItemTargetServiceClient.cs new file mode 100644 index 000000000..8dc741584 --- /dev/null +++ b/src/V3/Stubs/FeedItemTargetServiceClient.cs @@ -0,0 +1,770 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class FeedItemTargetServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static FeedItemTargetServiceSettings GetDefault() => new FeedItemTargetServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public FeedItemTargetServiceSettings() { } + + private FeedItemTargetServiceSettings(FeedItemTargetServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetFeedItemTargetSettings = existing.GetFeedItemTargetSettings; + MutateFeedItemTargetsSettings = existing.MutateFeedItemTargetsSettings; + OnCopy(existing); + } + + partial void OnCopy(FeedItemTargetServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// FeedItemTargetServiceClient.GetFeedItemTarget and FeedItemTargetServiceClient.GetFeedItemTargetAsync. + /// + /// + /// The default FeedItemTargetServiceClient.GetFeedItemTarget and + /// FeedItemTargetServiceClient.GetFeedItemTargetAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetFeedItemTargetSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// FeedItemTargetServiceClient.MutateFeedItemTargets and FeedItemTargetServiceClient.MutateFeedItemTargetsAsync. + /// + /// + /// The default FeedItemTargetServiceClient.MutateFeedItemTargets and + /// FeedItemTargetServiceClient.MutateFeedItemTargetsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateFeedItemTargetsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public FeedItemTargetServiceSettings Clone() => new FeedItemTargetServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class FeedItemTargetServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public FeedItemTargetServiceSettings Settings { get; set; } + + /// + public override FeedItemTargetServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return FeedItemTargetServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return FeedItemTargetServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => FeedItemTargetServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => FeedItemTargetServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => FeedItemTargetServiceClient.ChannelPool; + } + + /// + /// FeedItemTargetService client wrapper, for convenient use. + /// + public abstract partial class FeedItemTargetServiceClient + { + /// + /// The default endpoint for the FeedItemTargetService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default FeedItemTargetService scopes. + /// + /// + /// The default FeedItemTargetService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedItemTargetServiceClient client = await FeedItemTargetServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedItemTargetServiceClient.DefaultEndpoint.Host, FeedItemTargetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedItemTargetServiceClient client = FeedItemTargetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, FeedItemTargetServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedItemTargetServiceClient client = FeedItemTargetServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedItemTargetServiceClient.DefaultEndpoint.Host, FeedItemTargetServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedItemTargetServiceClient client = FeedItemTargetServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static FeedItemTargetServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, FeedItemTargetServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedItemTargetServiceClient Create(grpccore::Channel channel, FeedItemTargetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedItemTargetServiceClient Create(grpccore::CallInvoker callInvoker, FeedItemTargetServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + FeedItemTargetService.FeedItemTargetServiceClient grpcClient = new FeedItemTargetService.FeedItemTargetServiceClient(callInvoker); + return new FeedItemTargetServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC FeedItemTargetService client. + /// + public virtual FeedItemTargetService.FeedItemTargetServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested feed item targets in full detail. + /// + /// + /// Required. The resource name of the feed item targets to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedItemTargetAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedItemTargetAsync( + new GetFeedItemTargetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed item targets in full detail. + /// + /// + /// Required. The resource name of the feed item targets to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedItemTargetAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetFeedItemTargetAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed item targets in full detail. + /// + /// + /// Required. The resource name of the feed item targets to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::FeedItemTarget GetFeedItemTarget( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedItemTarget( + new GetFeedItemTargetRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed item targets in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedItemTargetAsync( + GetFeedItemTargetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested feed item targets in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedItemTargetAsync( + GetFeedItemTargetRequest request, + st::CancellationToken cancellationToken) => GetFeedItemTargetAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed item targets in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::FeedItemTarget GetFeedItemTarget( + GetFeedItemTargetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose feed item targets are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed item targets. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemTargetsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateFeedItemTargetsAsync( + new MutateFeedItemTargetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose feed item targets are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed item targets. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemTargetsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateFeedItemTargetsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// + /// Required. The ID of the customer whose feed item targets are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed item targets. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedItemTargetsResponse MutateFeedItemTargets( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateFeedItemTargets( + new MutateFeedItemTargetsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemTargetsAsync( + MutateFeedItemTargetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedItemTargetsAsync( + MutateFeedItemTargetsRequest request, + st::CancellationToken cancellationToken) => MutateFeedItemTargetsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedItemTargetsResponse MutateFeedItemTargets( + MutateFeedItemTargetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// FeedItemTargetService client wrapper implementation, for convenient use. + /// + public sealed partial class FeedItemTargetServiceClientImpl : FeedItemTargetServiceClient + { + private readonly gaxgrpc::ApiCall _callGetFeedItemTarget; + private readonly gaxgrpc::ApiCall _callMutateFeedItemTargets; + + /// + /// Constructs a client wrapper for the FeedItemTargetService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public FeedItemTargetServiceClientImpl(FeedItemTargetService.FeedItemTargetServiceClient grpcClient, FeedItemTargetServiceSettings settings) + { + GrpcClient = grpcClient; + FeedItemTargetServiceSettings effectiveSettings = settings ?? FeedItemTargetServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetFeedItemTarget = clientHelper.BuildApiCall( + GrpcClient.GetFeedItemTargetAsync, GrpcClient.GetFeedItemTarget, effectiveSettings.GetFeedItemTargetSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateFeedItemTargets = clientHelper.BuildApiCall( + GrpcClient.MutateFeedItemTargetsAsync, GrpcClient.MutateFeedItemTargets, effectiveSettings.MutateFeedItemTargetsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetFeedItemTarget); + Modify_GetFeedItemTargetApiCall(ref _callGetFeedItemTarget); + Modify_ApiCall(ref _callMutateFeedItemTargets); + Modify_MutateFeedItemTargetsApiCall(ref _callMutateFeedItemTargets); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetFeedItemTargetApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateFeedItemTargetsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(FeedItemTargetService.FeedItemTargetServiceClient grpcClient, FeedItemTargetServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC FeedItemTargetService client. + /// + public override FeedItemTargetService.FeedItemTargetServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetFeedItemTargetRequest(ref GetFeedItemTargetRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateFeedItemTargetsRequest(ref MutateFeedItemTargetsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested feed item targets in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetFeedItemTargetAsync( + GetFeedItemTargetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedItemTargetRequest(ref request, ref callSettings); + return _callGetFeedItemTarget.Async(request, callSettings); + } + + /// + /// Returns the requested feed item targets in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::FeedItemTarget GetFeedItemTarget( + GetFeedItemTargetRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedItemTargetRequest(ref request, ref callSettings); + return _callGetFeedItemTarget.Sync(request, callSettings); + } + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateFeedItemTargetsAsync( + MutateFeedItemTargetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateFeedItemTargetsRequest(ref request, ref callSettings); + return _callMutateFeedItemTargets.Async(request, callSettings); + } + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateFeedItemTargetsResponse MutateFeedItemTargets( + MutateFeedItemTargetsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateFeedItemTargetsRequest(ref request, ref callSettings); + return _callMutateFeedItemTargets.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/FeedItemTargetServiceGrpc.cs b/src/V3/Stubs/FeedItemTargetServiceGrpc.cs new file mode 100644 index 000000000..44dd13d51 --- /dev/null +++ b/src/V3/Stubs/FeedItemTargetServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_item_target_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage feed item targets. + /// + public static partial class FeedItemTargetService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.FeedItemTargetService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetFeedItemTargetRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetFeedItemTargetRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_FeedItemTarget = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateFeedItemTargetsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateFeedItemTargetsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetFeedItemTarget = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetFeedItemTarget", + __Marshaller_google_ads_googleads_v3_services_GetFeedItemTargetRequest, + __Marshaller_google_ads_googleads_v3_resources_FeedItemTarget); + + static readonly grpc::Method __Method_MutateFeedItemTargets = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateFeedItemTargets", + __Marshaller_google_ads_googleads_v3_services_MutateFeedItemTargetsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateFeedItemTargetsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of FeedItemTargetService + public abstract partial class FeedItemTargetServiceBase + { + /// + /// Returns the requested feed item targets in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetFeedItemTarget(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemTargetRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateFeedItemTargets(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for FeedItemTargetService + public partial class FeedItemTargetServiceClient : grpc::ClientBase + { + /// Creates a new client for FeedItemTargetService + /// The channel to use to make remote calls. + public FeedItemTargetServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for FeedItemTargetService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public FeedItemTargetServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected FeedItemTargetServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected FeedItemTargetServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested feed item targets in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget GetFeedItemTarget(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemTargetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedItemTarget(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed item targets in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget GetFeedItemTarget(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemTargetRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetFeedItemTarget, null, options, request); + } + /// + /// Returns the requested feed item targets in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedItemTargetAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemTargetRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedItemTargetAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed item targets in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedItemTargetAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedItemTargetRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetFeedItemTarget, null, options, request); + } + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsResponse MutateFeedItemTargets(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateFeedItemTargets(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsResponse MutateFeedItemTargets(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateFeedItemTargets, null, options, request); + } + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateFeedItemTargetsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateFeedItemTargetsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or removes feed item targets. Operation statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateFeedItemTargetsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateFeedItemTargets, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override FeedItemTargetServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new FeedItemTargetServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(FeedItemTargetServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetFeedItemTarget, serviceImpl.GetFeedItemTarget) + .AddMethod(__Method_MutateFeedItemTargets, serviceImpl.MutateFeedItemTargets).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, FeedItemTargetServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetFeedItemTarget, serviceImpl.GetFeedItemTarget); + serviceBinder.AddMethod(__Method_MutateFeedItemTargets, serviceImpl.MutateFeedItemTargets); + } + + } +} +#endregion diff --git a/src/V3/Stubs/FeedItemTargetStatus.cs b/src/V3/Stubs/FeedItemTargetStatus.cs new file mode 100644 index 000000000..876ea5e39 --- /dev/null +++ b/src/V3/Stubs/FeedItemTargetStatus.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_item_target_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_item_target_status.proto + public static partial class FeedItemTargetStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_item_target_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemTargetStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2l0ZW1fdGFy", + "Z2V0X3N0YXR1cy5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iagoYRmVlZEl0ZW1U", + "YXJnZXRTdGF0dXNFbnVtIk4KFEZlZWRJdGVtVGFyZ2V0U3RhdHVzEg8KC1VO", + "U1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB0VOQUJMRUQQAhILCgdSRU1P", + "VkVEEANC7gEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IZ", + "RmVlZEl0ZW1UYXJnZXRTdGF0dXNQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9y", + "Zy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7", + "ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oC", + "HUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetStatusEnum.Types.FeedItemTargetStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of a feed item target. + /// + public sealed partial class FeedItemTargetStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemTargetStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetStatusEnum(FeedItemTargetStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetStatusEnum Clone() { + return new FeedItemTargetStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemTargetStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemTargetStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemTargetStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemTargetStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a feed item target. + /// + public enum FeedItemTargetStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Feed item target is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Feed item target has been removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemTargetType.cs b/src/V3/Stubs/FeedItemTargetType.cs new file mode 100644 index 000000000..58736978c --- /dev/null +++ b/src/V3/Stubs/FeedItemTargetType.cs @@ -0,0 +1,189 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_item_target_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_item_target_type.proto + public static partial class FeedItemTargetTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_item_target_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemTargetTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2l0ZW1fdGFy", + "Z2V0X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIncKFkZlZWRJdGVtVGFy", + "Z2V0VHlwZUVudW0iXQoSRmVlZEl0ZW1UYXJnZXRUeXBlEg8KC1VOU1BFQ0lG", + "SUVEEAASCwoHVU5LTk9XThABEgwKCENBTVBBSUdOEAISDAoIQURfR1JPVVAQ", + "AxINCglDUklURVJJT04QBELsAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zQhdGZWVkSXRlbVRhcmdldFR5cGVQcm90b1ABWkJnb29nbGUu", + "Z29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMv", + "djMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5W", + "My5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29v", + "Z2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeEnum.Types.FeedItemTargetType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible types of a feed item target. + /// + public sealed partial class FeedItemTargetTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemTargetTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedItemTargetTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetTypeEnum(FeedItemTargetTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemTargetTypeEnum Clone() { + return new FeedItemTargetTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemTargetTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemTargetTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemTargetTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemTargetTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible type of a feed item target. + /// + public enum FeedItemTargetType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Feed item targets a campaign. + /// + [pbr::OriginalName("CAMPAIGN")] Campaign = 2, + /// + /// Feed item targets an ad group. + /// + [pbr::OriginalName("AD_GROUP")] AdGroup = 3, + /// + /// Feed item targets a criterion. + /// + [pbr::OriginalName("CRITERION")] Criterion = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemValidationError.cs b/src/V3/Stubs/FeedItemValidationError.cs new file mode 100644 index 000000000..58bfed5f5 --- /dev/null +++ b/src/V3/Stubs/FeedItemValidationError.cs @@ -0,0 +1,655 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/feed_item_validation_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/feed_item_validation_error.proto + public static partial class FeedItemValidationErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/feed_item_validation_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemValidationErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZmVlZF9pdGVtX3Zh", + "bGlkYXRpb25fZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLnGQobRmVl", + "ZEl0ZW1WYWxpZGF0aW9uRXJyb3JFbnVtIscZChdGZWVkSXRlbVZhbGlkYXRp", + "b25FcnJvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIUChBTVFJJ", + "TkdfVE9PX1NIT1JUEAISEwoPU1RSSU5HX1RPT19MT05HEAMSFwoTVkFMVUVf", + "Tk9UX1NQRUNJRklFRBAEEigKJElOVkFMSURfRE9NRVNUSUNfUEhPTkVfTlVN", + "QkVSX0ZPUk1BVBAFEhgKFElOVkFMSURfUEhPTkVfTlVNQkVSEAYSKgomUEhP", + "TkVfTlVNQkVSX05PVF9TVVBQT1JURURfRk9SX0NPVU5UUlkQBxIjCh9QUkVN", + "SVVNX1JBVEVfTlVNQkVSX05PVF9BTExPV0VEEAgSGgoWRElTQUxMT1dFRF9O", + "VU1CRVJfVFlQRRAJEhYKElZBTFVFX09VVF9PRl9SQU5HRRAKEioKJkNBTExU", + "UkFDS0lOR19OT1RfU1VQUE9SVEVEX0ZPUl9DT1VOVFJZEAsSLQopQ1VTVE9N", + "RVJfTk9UX1dISVRFTElTVEVEX0ZPUl9DQUxMVFJBQ0tJTkcQDBIYChRJTlZB", + "TElEX0NPVU5UUllfQ09ERRANEhIKDklOVkFMSURfQVBQX0lEEA4SIQodTUlT", + "U0lOR19BVFRSSUJVVEVTX0ZPUl9GSUVMRFMQDxITCg9JTlZBTElEX1RZUEVf", + "SUQQEBIZChVJTlZBTElEX0VNQUlMX0FERFJFU1MQERIVChFJTlZBTElEX0hU", + "VFBTX1VSTBASEhwKGE1JU1NJTkdfREVMSVZFUllfQUREUkVTUxATEh0KGVNU", + "QVJUX0RBVEVfQUZURVJfRU5EX0RBVEUQFBIgChxNSVNTSU5HX0ZFRURfSVRF", + "TV9TVEFSVF9USU1FEBUSHgoaTUlTU0lOR19GRUVEX0lURU1fRU5EX1RJTUUQ", + "FhIYChRNSVNTSU5HX0ZFRURfSVRFTV9JRBAXEiMKH1ZBTklUWV9QSE9ORV9O", + "VU1CRVJfTk9UX0FMTE9XRUQQGBIkCiBJTlZBTElEX1JFVklFV19FWFRFTlNJ", + "T05fU05JUFBFVBAZEhkKFUlOVkFMSURfTlVNQkVSX0ZPUk1BVBAaEhcKE0lO", + "VkFMSURfREFURV9GT1JNQVQQGxIYChRJTlZBTElEX1BSSUNFX0ZPUk1BVBAc", + "Eh0KGVVOS05PV05fUExBQ0VIT0xERVJfRklFTEQQHRIuCipNSVNTSU5HX0VO", + "SEFOQ0VEX1NJVEVMSU5LX0RFU0NSSVBUSU9OX0xJTkUQHhImCiJSRVZJRVdf", + "RVhURU5TSU9OX1NPVVJDRV9JTkVMSUdJQkxFEB8SJwojSFlQSEVOU19JTl9S", + "RVZJRVdfRVhURU5TSU9OX1NOSVBQRVQQIBItCilET1VCTEVfUVVPVEVTX0lO", + "X1JFVklFV19FWFRFTlNJT05fU05JUFBFVBAhEiYKIlFVT1RFU19JTl9SRVZJ", + "RVdfRVhURU5TSU9OX1NOSVBQRVQQIhIfChtJTlZBTElEX0ZPUk1fRU5DT0RF", + "RF9QQVJBTVMQIxIeChpJTlZBTElEX1VSTF9QQVJBTUVURVJfTkFNRRAkEhcK", + "E05PX0dFT0NPRElOR19SRVNVTFQQJRIoCiRTT1VSQ0VfTkFNRV9JTl9SRVZJ", + "RVdfRVhURU5TSU9OX1RFWFQQJhItCilDQVJSSUVSX1NQRUNJRklDX1NIT1JU", + "X05VTUJFUl9OT1RfQUxMT1dFRBAnEiAKHElOVkFMSURfUExBQ0VIT0xERVJf", + "RklFTERfSUQQKBITCg9JTlZBTElEX1VSTF9UQUcQKRIRCg1MSVNUX1RPT19M", + "T05HECoSIgoeSU5WQUxJRF9BVFRSSUJVVEVTX0NPTUJJTkFUSU9OECsSFAoQ", + "RFVQTElDQVRFX1ZBTFVFUxAsEiUKIUlOVkFMSURfQ0FMTF9DT05WRVJTSU9O", + "X0FDVElPTl9JRBAtEiEKHUNBTk5PVF9TRVRfV0lUSE9VVF9GSU5BTF9VUkxT", + "EC4SJAogQVBQX0lEX0RPRVNOVF9FWElTVF9JTl9BUFBfU1RPUkUQLxIVChFJ", + "TlZBTElEX0ZJTkFMX1VSTBAwEhgKFElOVkFMSURfVFJBQ0tJTkdfVVJMEDES", + "KgomSU5WQUxJRF9GSU5BTF9VUkxfRk9SX0FQUF9ET1dOTE9BRF9VUkwQMhIS", + "Cg5MSVNUX1RPT19TSE9SVBAzEhcKE0lOVkFMSURfVVNFUl9BQ1RJT04QNBIV", + "ChFJTlZBTElEX1RZUEVfTkFNRRA1Eh8KG0lOVkFMSURfRVZFTlRfQ0hBTkdF", + "X1NUQVRVUxA2EhsKF0lOVkFMSURfU05JUFBFVFNfSEVBREVSEDcSHAoYSU5W", + "QUxJRF9BTkRST0lEX0FQUF9MSU5LEDgSOwo3TlVNQkVSX1RZUEVfV0lUSF9D", + "QUxMVFJBQ0tJTkdfTk9UX1NVUFBPUlRFRF9GT1JfQ09VTlRSWRA5EhoKFlJF", + "U0VSVkVEX0tFWVdPUkRfT1RIRVIQOhIbChdEVVBMSUNBVEVfT1BUSU9OX0xB", + "QkVMUxA7Eh0KGURVUExJQ0FURV9PUFRJT05fUFJFRklMTFMQPBIYChRVTkVR", + "VUFMX0xJU1RfTEVOR1RIUxA9Eh8KG0lOQ09OU0lTVEVOVF9DVVJSRU5DWV9D", + "T0RFUxA+EioKJlBSSUNFX0VYVEVOU0lPTl9IQVNfRFVQTElDQVRFRF9IRUFE", + "RVJTED8SLgoqSVRFTV9IQVNfRFVQTElDQVRFRF9IRUFERVJfQU5EX0RFU0NS", + "SVBUSU9OEEASJQohUFJJQ0VfRVhURU5TSU9OX0hBU19UT09fRkVXX0lURU1T", + "EEESFQoRVU5TVVBQT1JURURfVkFMVUUQQhIcChhJTlZBTElEX0ZJTkFMX01P", + "QklMRV9VUkwQQxIlCiFJTlZBTElEX0tFWVdPUkRMRVNTX0FEX1JVTEVfTEFC", + "RUwQRBInCiNWQUxVRV9UUkFDS19QQVJBTUVURVJfTk9UX1NVUFBPUlRFRBBF", + "EioKJlVOU1VQUE9SVEVEX1ZBTFVFX0lOX1NFTEVDVEVEX0xBTkdVQUdFEEYS", + "GAoUSU5WQUxJRF9JT1NfQVBQX0xJTksQRxIsCihNSVNTSU5HX0lPU19BUFBf", + "TElOS19PUl9JT1NfQVBQX1NUT1JFX0lEEEgSGgoWUFJPTU9USU9OX0lOVkFM", + "SURfVElNRRBJEjkKNVBST01PVElPTl9DQU5OT1RfU0VUX1BFUkNFTlRfT0ZG", + "X0FORF9NT05FWV9BTU9VTlRfT0ZGEEoSPgo6UFJPTU9USU9OX0NBTk5PVF9T", + "RVRfUFJPTU9USU9OX0NPREVfQU5EX09SREVSU19PVkVSX0FNT1VOVBBLEiUK", + "IVRPT19NQU5ZX0RFQ0lNQUxfUExBQ0VTX1NQRUNJRklFRBBMEh4KGkFEX0NV", + "U1RPTUlaRVJTX05PVF9BTExPV0VEEE0SGQoVSU5WQUxJRF9MQU5HVUFHRV9D", + "T0RFEE4SGAoUVU5TVVBQT1JURURfTEFOR1VBR0UQTxIbChdJRl9GVU5DVElP", + "Tl9OT1RfQUxMT1dFRBBQEhwKGElOVkFMSURfRklOQUxfVVJMX1NVRkZJWBBR", + "EiMKH0lOVkFMSURfVEFHX0lOX0ZJTkFMX1VSTF9TVUZGSVgQUhIjCh9JTlZB", + "TElEX0ZJTkFMX1VSTF9TVUZGSVhfRk9STUFUEFMSMAosQ1VTVE9NRVJfQ09O", + "U0VOVF9GT1JfQ0FMTF9SRUNPUkRJTkdfUkVRVUlSRUQQVBInCiNPTkxZX09O", + "RV9ERUxJVkVSWV9PUFRJT05fSVNfQUxMT1dFRBBVEh0KGU5PX0RFTElWRVJZ", + "X09QVElPTl9JU19TRVQQVhImCiJJTlZBTElEX0NPTlZFUlNJT05fUkVQT1JU", + "SU5HX1NUQVRFEFcSFAoQSU1BR0VfU0laRV9XUk9ORxBYEisKJ0VNQUlMX0RF", + "TElWRVJZX05PVF9BVkFJTEFCTEVfSU5fQ09VTlRSWRBZEicKI0FVVE9fUkVQ", + "TFlfTk9UX0FWQUlMQUJMRV9JTl9DT1VOVFJZEFoSGgoWSU5WQUxJRF9MQVRJ", + "VFVERV9WQUxVRRBbEhsKF0lOVkFMSURfTE9OR0lUVURFX1ZBTFVFEFwSEwoP", + "VE9PX01BTllfTEFCRUxTEF0SFQoRSU5WQUxJRF9JTUFHRV9VUkwQXhIaChZN", + "SVNTSU5HX0xBVElUVURFX1ZBTFVFEF8SGwoXTUlTU0lOR19MT05HSVRVREVf", + "VkFMVUUQYBIVChFBRERSRVNTX05PVF9GT1VORBBhEhoKFkFERFJFU1NfTk9U", + "X1RBUkdFVEFCTEUQYkL3AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9yc0IcRmVlZEl0ZW1WYWxpZGF0aW9uRXJyb3JQcm90b1ABWkRnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xl", + "QWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9y", + "c+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3Rv", + "Mw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorEnum.Types.FeedItemValidationError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible validation errors of a feed item. + /// + public sealed partial class FeedItemValidationErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemValidationErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FeedItemValidationErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationErrorEnum(FeedItemValidationErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationErrorEnum Clone() { + return new FeedItemValidationErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemValidationErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemValidationErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemValidationErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemValidationErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible validation errors of a feed item. + /// + public enum FeedItemValidationError { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// String is too short. + /// + [pbr::OriginalName("STRING_TOO_SHORT")] StringTooShort = 2, + /// + /// String is too long. + /// + [pbr::OriginalName("STRING_TOO_LONG")] StringTooLong = 3, + /// + /// Value is not provided. + /// + [pbr::OriginalName("VALUE_NOT_SPECIFIED")] ValueNotSpecified = 4, + /// + /// Phone number format is invalid for region. + /// + [pbr::OriginalName("INVALID_DOMESTIC_PHONE_NUMBER_FORMAT")] InvalidDomesticPhoneNumberFormat = 5, + /// + /// String does not represent a phone number. + /// + [pbr::OriginalName("INVALID_PHONE_NUMBER")] InvalidPhoneNumber = 6, + /// + /// Phone number format is not compatible with country code. + /// + [pbr::OriginalName("PHONE_NUMBER_NOT_SUPPORTED_FOR_COUNTRY")] PhoneNumberNotSupportedForCountry = 7, + /// + /// Premium rate number is not allowed. + /// + [pbr::OriginalName("PREMIUM_RATE_NUMBER_NOT_ALLOWED")] PremiumRateNumberNotAllowed = 8, + /// + /// Phone number type is not allowed. + /// + [pbr::OriginalName("DISALLOWED_NUMBER_TYPE")] DisallowedNumberType = 9, + /// + /// Specified value is outside of the valid range. + /// + [pbr::OriginalName("VALUE_OUT_OF_RANGE")] ValueOutOfRange = 10, + /// + /// Call tracking is not supported in the selected country. + /// + [pbr::OriginalName("CALLTRACKING_NOT_SUPPORTED_FOR_COUNTRY")] CalltrackingNotSupportedForCountry = 11, + /// + /// Customer is not whitelisted for call tracking. + /// + [pbr::OriginalName("CUSTOMER_NOT_WHITELISTED_FOR_CALLTRACKING")] CustomerNotWhitelistedForCalltracking = 12, + /// + /// Country code is invalid. + /// + [pbr::OriginalName("INVALID_COUNTRY_CODE")] InvalidCountryCode = 13, + /// + /// The specified mobile app id is invalid. + /// + [pbr::OriginalName("INVALID_APP_ID")] InvalidAppId = 14, + /// + /// Some required field attributes are missing. + /// + [pbr::OriginalName("MISSING_ATTRIBUTES_FOR_FIELDS")] MissingAttributesForFields = 15, + /// + /// Invalid email button type for email extension. + /// + [pbr::OriginalName("INVALID_TYPE_ID")] InvalidTypeId = 16, + /// + /// Email address is invalid. + /// + [pbr::OriginalName("INVALID_EMAIL_ADDRESS")] InvalidEmailAddress = 17, + /// + /// The HTTPS URL in email extension is invalid. + /// + [pbr::OriginalName("INVALID_HTTPS_URL")] InvalidHttpsUrl = 18, + /// + /// Delivery address is missing from email extension. + /// + [pbr::OriginalName("MISSING_DELIVERY_ADDRESS")] MissingDeliveryAddress = 19, + /// + /// FeedItem scheduling start date comes after end date. + /// + [pbr::OriginalName("START_DATE_AFTER_END_DATE")] StartDateAfterEndDate = 20, + /// + /// FeedItem scheduling start time is missing. + /// + [pbr::OriginalName("MISSING_FEED_ITEM_START_TIME")] MissingFeedItemStartTime = 21, + /// + /// FeedItem scheduling end time is missing. + /// + [pbr::OriginalName("MISSING_FEED_ITEM_END_TIME")] MissingFeedItemEndTime = 22, + /// + /// Cannot compute system attributes on a FeedItem that has no FeedItemId. + /// + [pbr::OriginalName("MISSING_FEED_ITEM_ID")] MissingFeedItemId = 23, + /// + /// Call extension vanity phone numbers are not supported. + /// + [pbr::OriginalName("VANITY_PHONE_NUMBER_NOT_ALLOWED")] VanityPhoneNumberNotAllowed = 24, + /// + /// Invalid review text. + /// + [pbr::OriginalName("INVALID_REVIEW_EXTENSION_SNIPPET")] InvalidReviewExtensionSnippet = 25, + /// + /// Invalid format for numeric value in ad parameter. + /// + [pbr::OriginalName("INVALID_NUMBER_FORMAT")] InvalidNumberFormat = 26, + /// + /// Invalid format for date value in ad parameter. + /// + [pbr::OriginalName("INVALID_DATE_FORMAT")] InvalidDateFormat = 27, + /// + /// Invalid format for price value in ad parameter. + /// + [pbr::OriginalName("INVALID_PRICE_FORMAT")] InvalidPriceFormat = 28, + /// + /// Unrecognized type given for value in ad parameter. + /// + [pbr::OriginalName("UNKNOWN_PLACEHOLDER_FIELD")] UnknownPlaceholderField = 29, + /// + /// Enhanced sitelinks must have both description lines specified. + /// + [pbr::OriginalName("MISSING_ENHANCED_SITELINK_DESCRIPTION_LINE")] MissingEnhancedSitelinkDescriptionLine = 30, + /// + /// Review source is ineligible. + /// + [pbr::OriginalName("REVIEW_EXTENSION_SOURCE_INELIGIBLE")] ReviewExtensionSourceIneligible = 31, + /// + /// Review text cannot contain hyphens or dashes. + /// + [pbr::OriginalName("HYPHENS_IN_REVIEW_EXTENSION_SNIPPET")] HyphensInReviewExtensionSnippet = 32, + /// + /// Review text cannot contain double quote characters. + /// + [pbr::OriginalName("DOUBLE_QUOTES_IN_REVIEW_EXTENSION_SNIPPET")] DoubleQuotesInReviewExtensionSnippet = 33, + /// + /// Review text cannot contain quote characters. + /// + [pbr::OriginalName("QUOTES_IN_REVIEW_EXTENSION_SNIPPET")] QuotesInReviewExtensionSnippet = 34, + /// + /// Parameters are encoded in the wrong format. + /// + [pbr::OriginalName("INVALID_FORM_ENCODED_PARAMS")] InvalidFormEncodedParams = 35, + /// + /// URL parameter name must contain only letters, numbers, underscores, and + /// dashes. + /// + [pbr::OriginalName("INVALID_URL_PARAMETER_NAME")] InvalidUrlParameterName = 36, + /// + /// Cannot find address location. + /// + [pbr::OriginalName("NO_GEOCODING_RESULT")] NoGeocodingResult = 37, + /// + /// Review extension text has source name. + /// + [pbr::OriginalName("SOURCE_NAME_IN_REVIEW_EXTENSION_TEXT")] SourceNameInReviewExtensionText = 38, + /// + /// Some phone numbers can be shorter than usual. Some of these short numbers + /// are carrier-specific, and we disallow those in ad extensions because they + /// will not be available to all users. + /// + [pbr::OriginalName("CARRIER_SPECIFIC_SHORT_NUMBER_NOT_ALLOWED")] CarrierSpecificShortNumberNotAllowed = 39, + /// + /// Triggered when a request references a placeholder field id that does not + /// exist. + /// + [pbr::OriginalName("INVALID_PLACEHOLDER_FIELD_ID")] InvalidPlaceholderFieldId = 40, + /// + /// URL contains invalid ValueTrack tags or format. + /// + [pbr::OriginalName("INVALID_URL_TAG")] InvalidUrlTag = 41, + /// + /// Provided list exceeds acceptable size. + /// + [pbr::OriginalName("LIST_TOO_LONG")] ListTooLong = 42, + /// + /// Certain combinations of attributes aren't allowed to be specified in the + /// same feed item. + /// + [pbr::OriginalName("INVALID_ATTRIBUTES_COMBINATION")] InvalidAttributesCombination = 43, + /// + /// An attribute has the same value repeatedly. + /// + [pbr::OriginalName("DUPLICATE_VALUES")] DuplicateValues = 44, + /// + /// Advertisers can link a conversion action with a phone number to indicate + /// that sufficiently long calls forwarded to that phone number should be + /// counted as conversions of the specified type. This is an error message + /// indicating that the conversion action specified is invalid (e.g., the + /// conversion action does not exist within the appropriate Google Ads + /// account, or it is a type of conversion not appropriate to phone call + /// conversions). + /// + [pbr::OriginalName("INVALID_CALL_CONVERSION_ACTION_ID")] InvalidCallConversionActionId = 45, + /// + /// Tracking template requires final url to be set. + /// + [pbr::OriginalName("CANNOT_SET_WITHOUT_FINAL_URLS")] CannotSetWithoutFinalUrls = 46, + /// + /// An app id was provided that doesn't exist in the given app store. + /// + [pbr::OriginalName("APP_ID_DOESNT_EXIST_IN_APP_STORE")] AppIdDoesntExistInAppStore = 47, + /// + /// Invalid U2 final url. + /// + [pbr::OriginalName("INVALID_FINAL_URL")] InvalidFinalUrl = 48, + /// + /// Invalid U2 tracking url. + /// + [pbr::OriginalName("INVALID_TRACKING_URL")] InvalidTrackingUrl = 49, + /// + /// Final URL should start from App download URL. + /// + [pbr::OriginalName("INVALID_FINAL_URL_FOR_APP_DOWNLOAD_URL")] InvalidFinalUrlForAppDownloadUrl = 50, + /// + /// List provided is too short. + /// + [pbr::OriginalName("LIST_TOO_SHORT")] ListTooShort = 51, + /// + /// User Action field has invalid value. + /// + [pbr::OriginalName("INVALID_USER_ACTION")] InvalidUserAction = 52, + /// + /// Type field has invalid value. + /// + [pbr::OriginalName("INVALID_TYPE_NAME")] InvalidTypeName = 53, + /// + /// Change status for event is invalid. + /// + [pbr::OriginalName("INVALID_EVENT_CHANGE_STATUS")] InvalidEventChangeStatus = 54, + /// + /// The header of a structured snippets extension is not one of the valid + /// headers. + /// + [pbr::OriginalName("INVALID_SNIPPETS_HEADER")] InvalidSnippetsHeader = 55, + /// + /// Android app link is not formatted correctly + /// + [pbr::OriginalName("INVALID_ANDROID_APP_LINK")] InvalidAndroidAppLink = 56, + /// + /// Phone number incompatible with call tracking for country. + /// + [pbr::OriginalName("NUMBER_TYPE_WITH_CALLTRACKING_NOT_SUPPORTED_FOR_COUNTRY")] NumberTypeWithCalltrackingNotSupportedForCountry = 57, + /// + /// The input is identical to a reserved keyword + /// + [pbr::OriginalName("RESERVED_KEYWORD_OTHER")] ReservedKeywordOther = 58, + /// + /// Each option label in the message extension must be unique. + /// + [pbr::OriginalName("DUPLICATE_OPTION_LABELS")] DuplicateOptionLabels = 59, + /// + /// Each option prefill in the message extension must be unique. + /// + [pbr::OriginalName("DUPLICATE_OPTION_PREFILLS")] DuplicateOptionPrefills = 60, + /// + /// In message extensions, the number of optional labels and optional + /// prefills must be the same. + /// + [pbr::OriginalName("UNEQUAL_LIST_LENGTHS")] UnequalListLengths = 61, + /// + /// All currency codes in an ad extension must be the same. + /// + [pbr::OriginalName("INCONSISTENT_CURRENCY_CODES")] InconsistentCurrencyCodes = 62, + /// + /// Headers in price extension are not unique. + /// + [pbr::OriginalName("PRICE_EXTENSION_HAS_DUPLICATED_HEADERS")] PriceExtensionHasDuplicatedHeaders = 63, + /// + /// Header and description in an item are the same. + /// + [pbr::OriginalName("ITEM_HAS_DUPLICATED_HEADER_AND_DESCRIPTION")] ItemHasDuplicatedHeaderAndDescription = 64, + /// + /// Price extension has too few items. + /// + [pbr::OriginalName("PRICE_EXTENSION_HAS_TOO_FEW_ITEMS")] PriceExtensionHasTooFewItems = 65, + /// + /// The given value is not supported. + /// + [pbr::OriginalName("UNSUPPORTED_VALUE")] UnsupportedValue = 66, + /// + /// Invalid final mobile url. + /// + [pbr::OriginalName("INVALID_FINAL_MOBILE_URL")] InvalidFinalMobileUrl = 67, + /// + /// The given string value of Label contains invalid characters + /// + [pbr::OriginalName("INVALID_KEYWORDLESS_AD_RULE_LABEL")] InvalidKeywordlessAdRuleLabel = 68, + /// + /// The given URL contains value track parameters. + /// + [pbr::OriginalName("VALUE_TRACK_PARAMETER_NOT_SUPPORTED")] ValueTrackParameterNotSupported = 69, + /// + /// The given value is not supported in the selected language of an + /// extension. + /// + [pbr::OriginalName("UNSUPPORTED_VALUE_IN_SELECTED_LANGUAGE")] UnsupportedValueInSelectedLanguage = 70, + /// + /// The iOS app link is not formatted correctly. + /// + [pbr::OriginalName("INVALID_IOS_APP_LINK")] InvalidIosAppLink = 71, + /// + /// iOS app link or iOS app store id is missing. + /// + [pbr::OriginalName("MISSING_IOS_APP_LINK_OR_IOS_APP_STORE_ID")] MissingIosAppLinkOrIosAppStoreId = 72, + /// + /// Promotion time is invalid. + /// + [pbr::OriginalName("PROMOTION_INVALID_TIME")] PromotionInvalidTime = 73, + /// + /// Both the percent off and money amount off fields are set. + /// + [pbr::OriginalName("PROMOTION_CANNOT_SET_PERCENT_OFF_AND_MONEY_AMOUNT_OFF")] PromotionCannotSetPercentOffAndMoneyAmountOff = 74, + /// + /// Both the promotion code and orders over amount fields are set. + /// + [pbr::OriginalName("PROMOTION_CANNOT_SET_PROMOTION_CODE_AND_ORDERS_OVER_AMOUNT")] PromotionCannotSetPromotionCodeAndOrdersOverAmount = 75, + /// + /// Too many decimal places are specified. + /// + [pbr::OriginalName("TOO_MANY_DECIMAL_PLACES_SPECIFIED")] TooManyDecimalPlacesSpecified = 76, + /// + /// Ad Customizers are present and not allowed. + /// + [pbr::OriginalName("AD_CUSTOMIZERS_NOT_ALLOWED")] AdCustomizersNotAllowed = 77, + /// + /// Language code is not valid. + /// + [pbr::OriginalName("INVALID_LANGUAGE_CODE")] InvalidLanguageCode = 78, + /// + /// Language is not supported. + /// + [pbr::OriginalName("UNSUPPORTED_LANGUAGE")] UnsupportedLanguage = 79, + /// + /// IF Function is present and not allowed. + /// + [pbr::OriginalName("IF_FUNCTION_NOT_ALLOWED")] IfFunctionNotAllowed = 80, + /// + /// Final url suffix is not valid. + /// + [pbr::OriginalName("INVALID_FINAL_URL_SUFFIX")] InvalidFinalUrlSuffix = 81, + /// + /// Final url suffix contains an invalid tag. + /// + [pbr::OriginalName("INVALID_TAG_IN_FINAL_URL_SUFFIX")] InvalidTagInFinalUrlSuffix = 82, + /// + /// Final url suffix is formatted incorrectly. + /// + [pbr::OriginalName("INVALID_FINAL_URL_SUFFIX_FORMAT")] InvalidFinalUrlSuffixFormat = 83, + /// + /// Consent for call recording, which is required for the use of call + /// extensions, was not provided by the advertiser. Please see + /// https://support.google.com/google-ads/answer/7412639. + /// + [pbr::OriginalName("CUSTOMER_CONSENT_FOR_CALL_RECORDING_REQUIRED")] CustomerConsentForCallRecordingRequired = 84, + /// + /// Multiple message delivery options are set. + /// + [pbr::OriginalName("ONLY_ONE_DELIVERY_OPTION_IS_ALLOWED")] OnlyOneDeliveryOptionIsAllowed = 85, + /// + /// No message delivery option is set. + /// + [pbr::OriginalName("NO_DELIVERY_OPTION_IS_SET")] NoDeliveryOptionIsSet = 86, + /// + /// String value of conversion reporting state field is not valid. + /// + [pbr::OriginalName("INVALID_CONVERSION_REPORTING_STATE")] InvalidConversionReportingState = 87, + /// + /// Image size is not right. + /// + [pbr::OriginalName("IMAGE_SIZE_WRONG")] ImageSizeWrong = 88, + /// + /// Email delivery is not supported in the country specified in the country + /// code field. + /// + [pbr::OriginalName("EMAIL_DELIVERY_NOT_AVAILABLE_IN_COUNTRY")] EmailDeliveryNotAvailableInCountry = 89, + /// + /// Auto reply is not supported in the country specified in the country code + /// field. + /// + [pbr::OriginalName("AUTO_REPLY_NOT_AVAILABLE_IN_COUNTRY")] AutoReplyNotAvailableInCountry = 90, + /// + /// Invalid value specified for latitude. + /// + [pbr::OriginalName("INVALID_LATITUDE_VALUE")] InvalidLatitudeValue = 91, + /// + /// Invalid value specified for longitude. + /// + [pbr::OriginalName("INVALID_LONGITUDE_VALUE")] InvalidLongitudeValue = 92, + /// + /// Too many label fields provided. + /// + [pbr::OriginalName("TOO_MANY_LABELS")] TooManyLabels = 93, + /// + /// Invalid image url. + /// + [pbr::OriginalName("INVALID_IMAGE_URL")] InvalidImageUrl = 94, + /// + /// Latitude value is missing. + /// + [pbr::OriginalName("MISSING_LATITUDE_VALUE")] MissingLatitudeValue = 95, + /// + /// Longitude value is missing. + /// + [pbr::OriginalName("MISSING_LONGITUDE_VALUE")] MissingLongitudeValue = 96, + /// + /// Unable to find address. + /// + [pbr::OriginalName("ADDRESS_NOT_FOUND")] AddressNotFound = 97, + /// + /// Cannot target provided address. + /// + [pbr::OriginalName("ADDRESS_NOT_TARGETABLE")] AddressNotTargetable = 98, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedItemValidationStatus.cs b/src/V3/Stubs/FeedItemValidationStatus.cs new file mode 100644 index 000000000..45765cd57 --- /dev/null +++ b/src/V3/Stubs/FeedItemValidationStatus.cs @@ -0,0 +1,190 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_item_validation_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_item_validation_status.proto + public static partial class FeedItemValidationStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_item_validation_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedItemValidationStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2l0ZW1fdmFs", + "aWRhdGlvbl9zdGF0dXMucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIn0KHEZlZWRJ", + "dGVtVmFsaWRhdGlvblN0YXR1c0VudW0iXQoYRmVlZEl0ZW1WYWxpZGF0aW9u", + "U3RhdHVzEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB1BFTkRJ", + "TkcQAhILCgdJTlZBTElEEAMSCQoFVkFMSUQQBELyAQohY29tLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVudW1zQh1GZWVkSXRlbVZhbGlkYXRpb25TdGF0", + "dXNQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xl", + "QWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVu", + "dW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemValidationStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedItemValidationStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedItemValidationStatusEnum.Types.FeedItemValidationStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible validation statuses of a feed item. + /// + public sealed partial class FeedItemValidationStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedItemValidationStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedItemValidationStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationStatusEnum(FeedItemValidationStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedItemValidationStatusEnum Clone() { + return new FeedItemValidationStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedItemValidationStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedItemValidationStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedItemValidationStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedItemValidationStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible validation statuses of a feed item. + /// + public enum FeedItemValidationStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Validation pending. + /// + [pbr::OriginalName("PENDING")] Pending = 2, + /// + /// An error was found. + /// + [pbr::OriginalName("INVALID")] Invalid = 3, + /// + /// Feed item is semantically well-formed. + /// + [pbr::OriginalName("VALID")] Valid = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedLinkStatus.cs b/src/V3/Stubs/FeedLinkStatus.cs new file mode 100644 index 000000000..bfc5cbd4e --- /dev/null +++ b/src/V3/Stubs/FeedLinkStatus.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_link_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_link_status.proto + public static partial class FeedLinkStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_link_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedLinkStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX2xpbmtfc3Rh", + "dHVzLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJeChJGZWVkTGlua1N0YXR1c0Vu", + "dW0iSAoORmVlZExpbmtTdGF0dXMSDwoLVU5TUEVDSUZJRUQQABILCgdVTktO", + "T1dOEAESCwoHRU5BQkxFRBACEgsKB1JFTU9WRUQQA0LoAQohY29tLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhNGZWVkTGlua1N0YXR1c1Byb3Rv", + "UAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "RW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusEnum.Types.FeedLinkStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for an enum describing possible statuses of a feed link. + /// + public sealed partial class FeedLinkStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedLinkStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedLinkStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedLinkStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedLinkStatusEnum(FeedLinkStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedLinkStatusEnum Clone() { + return new FeedLinkStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedLinkStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedLinkStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedLinkStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedLinkStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a feed link. + /// + public enum FeedLinkStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Feed link is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Feed link has been removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedMapping.cs b/src/V3/Stubs/FeedMapping.cs new file mode 100644 index 000000000..7c10ba945 --- /dev/null +++ b/src/V3/Stubs/FeedMapping.cs @@ -0,0 +1,1433 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/feed_mapping.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/feed_mapping.proto + public static partial class FeedMappingReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/feed_mapping.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedMappingReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZmVlZF9tYXBw", + "aW5nLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMa", + "Q2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2FkX2N1c3RvbWl6ZXJf", + "cGxhY2Vob2xkZXJfZmllbGQucHJvdG8aSGdvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL2VudW1zL2FmZmlsaWF0ZV9sb2NhdGlvbl9wbGFjZWhvbGRlcl9maWVs", + "ZC5wcm90bxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvYXBwX3Bs", + "YWNlaG9sZGVyX2ZpZWxkLnByb3RvGjpnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9jYWxsX3BsYWNlaG9sZGVyX2ZpZWxkLnByb3RvGj1nb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9lbnVtcy9jYWxsb3V0X3BsYWNlaG9sZGVyX2Zp", + "ZWxkLnByb3RvGjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9jdXN0", + "b21fcGxhY2Vob2xkZXJfZmllbGQucHJvdG8aQWdvb2dsZS9hZHMvZ29vZ2xl", + "YWRzL3YzL2VudW1zL2RzYV9wYWdlX2ZlZWRfY3JpdGVyaW9uX2ZpZWxkLnBy", + "b3RvGj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9lZHVjYXRpb25f", + "cGxhY2Vob2xkZXJfZmllbGQucHJvdG8aP2dvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL2VudW1zL2ZlZWRfbWFwcGluZ19jcml0ZXJpb25fdHlwZS5wcm90bxo3", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvZmVlZF9tYXBwaW5nX3N0", + "YXR1cy5wcm90bxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvZmxp", + "Z2h0X3BsYWNlaG9sZGVyX2ZpZWxkLnByb3RvGjtnb29nbGUvYWRzL2dvb2ds", + "ZWFkcy92My9lbnVtcy9ob3RlbF9wbGFjZWhvbGRlcl9maWVsZC5wcm90bxo5", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvam9iX3BsYWNlaG9sZGVy", + "X2ZpZWxkLnByb3RvGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9s", + "b2NhbF9wbGFjZWhvbGRlcl9maWVsZC5wcm90bxpQZ29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvZW51bXMvbG9jYXRpb25fZXh0ZW5zaW9uX3RhcmdldGluZ19j", + "cml0ZXJpb25fZmllbGQucHJvdG8aPmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zL2xvY2F0aW9uX3BsYWNlaG9sZGVyX2ZpZWxkLnByb3RvGj1nb29n", + "bGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9tZXNzYWdlX3BsYWNlaG9sZGVy", + "X2ZpZWxkLnByb3RvGjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9w", + "bGFjZWhvbGRlcl90eXBlLnByb3RvGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9wcmljZV9wbGFjZWhvbGRlcl9maWVsZC5wcm90bxo/Z29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvcHJvbW90aW9uX3BsYWNlaG9sZGVy", + "X2ZpZWxkLnByb3RvGkFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9y", + "ZWFsX2VzdGF0ZV9wbGFjZWhvbGRlcl9maWVsZC5wcm90bxo+Z29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvZW51bXMvc2l0ZWxpbmtfcGxhY2Vob2xkZXJfZmll", + "bGQucHJvdG8aSGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3N0cnVj", + "dHVyZWRfc25pcHBldF9wbGFjZWhvbGRlcl9maWVsZC5wcm90bxo8Z29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvdHJhdmVsX3BsYWNlaG9sZGVyX2Zp", + "ZWxkLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhln", + "b29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3Jh", + "cHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ipAUK", + "C0ZlZWRNYXBwaW5nEkMKDXJlc291cmNlX25hbWUYASABKAlCLOBBBfpBJgok", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0ZlZWRNYXBwaW5nElEKBGZlZWQY", + "AiABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCJeBBBfpBHwod", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0ZlZWQSXwoYYXR0cmlidXRlX2Zp", + "ZWxkX21hcHBpbmdzGAUgAygLMjguZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzLkF0dHJpYnV0ZUZpZWxkTWFwcGluZ0ID4EEFElsKBnN0YXR1", + "cxgGIAEoDjJGLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkZlZWRN", + "YXBwaW5nU3RhdHVzRW51bS5GZWVkTWFwcGluZ1N0YXR1c0ID4EEDEmMKEHBs", + "YWNlaG9sZGVyX3R5cGUYAyABKA4yQi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtcy5QbGFjZWhvbGRlclR5cGVFbnVtLlBsYWNlaG9sZGVyVHlwZUID", + "4EEFSAAScwoOY3JpdGVyaW9uX3R5cGUYBCABKA4yVC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtcy5GZWVkTWFwcGluZ0NyaXRlcmlvblR5cGVFbnVt", + "LkZlZWRNYXBwaW5nQ3JpdGVyaW9uVHlwZUID4EEFSAA6W+pBWAokZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tL0ZlZWRNYXBwaW5nEjBjdXN0b21lcnMve2N1", + "c3RvbWVyfS9mZWVkTWFwcGluZ3Mve2ZlZWRfbWFwcGluZ31CCAoGdGFyZ2V0", + "It4UChVBdHRyaWJ1dGVGaWVsZE1hcHBpbmcSOwoRZmVlZF9hdHRyaWJ1dGVf", + "aWQYASABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEFEjIK", + "CGZpZWxkX2lkGAIgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWVC", + "A+BBAxJzCg5zaXRlbGlua19maWVsZBgDIAEoDjJULmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVudW1zLlNpdGVsaW5rUGxhY2Vob2xkZXJGaWVsZEVudW0u", + "U2l0ZWxpbmtQbGFjZWhvbGRlckZpZWxkQgPgQQVIABJnCgpjYWxsX2ZpZWxk", + "GAQgASgOMkwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuQ2FsbFBs", + "YWNlaG9sZGVyRmllbGRFbnVtLkNhbGxQbGFjZWhvbGRlckZpZWxkQgPgQQVI", + "ABJkCglhcHBfZmllbGQYBSABKA4ySi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtcy5BcHBQbGFjZWhvbGRlckZpZWxkRW51bS5BcHBQbGFjZWhvbGRl", + "ckZpZWxkQgPgQQVIABJzCg5sb2NhdGlvbl9maWVsZBgGIAEoDjJULmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkxvY2F0aW9uUGxhY2Vob2xkZXJG", + "aWVsZEVudW0uTG9jYXRpb25QbGFjZWhvbGRlckZpZWxkQgPgQQNIABKPAQoY", + "YWZmaWxpYXRlX2xvY2F0aW9uX2ZpZWxkGAcgASgOMmYuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuZW51bXMuQWZmaWxpYXRlTG9jYXRpb25QbGFjZWhvbGRl", + "ckZpZWxkRW51bS5BZmZpbGlhdGVMb2NhdGlvblBsYWNlaG9sZGVyRmllbGRC", + "A+BBA0gAEnAKDWNhbGxvdXRfZmllbGQYCCABKA4yUi5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtcy5DYWxsb3V0UGxhY2Vob2xkZXJGaWVsZEVudW0u", + "Q2FsbG91dFBsYWNlaG9sZGVyRmllbGRCA+BBBUgAEo8BChhzdHJ1Y3R1cmVk", + "X3NuaXBwZXRfZmllbGQYCSABKA4yZi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtcy5TdHJ1Y3R1cmVkU25pcHBldFBsYWNlaG9sZGVyRmllbGRFbnVt", + "LlN0cnVjdHVyZWRTbmlwcGV0UGxhY2Vob2xkZXJGaWVsZEID4EEFSAAScAoN", + "bWVzc2FnZV9maWVsZBgKIAEoDjJSLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zLk1lc3NhZ2VQbGFjZWhvbGRlckZpZWxkRW51bS5NZXNzYWdlUGxh", + "Y2Vob2xkZXJGaWVsZEID4EEFSAASagoLcHJpY2VfZmllbGQYCyABKA4yTi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5QcmljZVBsYWNlaG9sZGVy", + "RmllbGRFbnVtLlByaWNlUGxhY2Vob2xkZXJGaWVsZEID4EEFSAASdgoPcHJv", + "bW90aW9uX2ZpZWxkGAwgASgOMlYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuUHJvbW90aW9uUGxhY2Vob2xkZXJGaWVsZEVudW0uUHJvbW90aW9u", + "UGxhY2Vob2xkZXJGaWVsZEID4EEFSAASgAEKE2FkX2N1c3RvbWl6ZXJfZmll", + "bGQYDSABKA4yXC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5BZEN1", + "c3RvbWl6ZXJQbGFjZWhvbGRlckZpZWxkRW51bS5BZEN1c3RvbWl6ZXJQbGFj", + "ZWhvbGRlckZpZWxkQgPgQQVIABJ6ChNkc2FfcGFnZV9mZWVkX2ZpZWxkGA4g", + "ASgOMlYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuRHNhUGFnZUZl", + "ZWRDcml0ZXJpb25GaWVsZEVudW0uRHNhUGFnZUZlZWRDcml0ZXJpb25GaWVs", + "ZEID4EEFSAASpwEKImxvY2F0aW9uX2V4dGVuc2lvbl90YXJnZXRpbmdfZmll", + "bGQYDyABKA4ydC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5Mb2Nh", + "dGlvbkV4dGVuc2lvblRhcmdldGluZ0NyaXRlcmlvbkZpZWxkRW51bS5Mb2Nh", + "dGlvbkV4dGVuc2lvblRhcmdldGluZ0NyaXRlcmlvbkZpZWxkQgPgQQVIABJ2", + "Cg9lZHVjYXRpb25fZmllbGQYECABKA4yVi5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lbnVtcy5FZHVjYXRpb25QbGFjZWhvbGRlckZpZWxkRW51bS5FZHVj", + "YXRpb25QbGFjZWhvbGRlckZpZWxkQgPgQQVIABJtCgxmbGlnaHRfZmllbGQY", + "ESABKA4yUC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5GbGlnaHRQ", + "bGFjZWhvbGRlckZpZWxkRW51bS5GbGlnaHRQbGFjZWhvbGRlckZpZWxkQgPg", + "QQVIABJtCgxjdXN0b21fZmllbGQYEiABKA4yUC5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lbnVtcy5DdXN0b21QbGFjZWhvbGRlckZpZWxkRW51bS5DdXN0", + "b21QbGFjZWhvbGRlckZpZWxkQgPgQQVIABJqCgtob3RlbF9maWVsZBgTIAEo", + "DjJOLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLkhvdGVsUGxhY2Vo", + "b2xkZXJGaWVsZEVudW0uSG90ZWxQbGFjZWhvbGRlckZpZWxkQgPgQQVIABJ6", + "ChFyZWFsX2VzdGF0ZV9maWVsZBgUIAEoDjJYLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zLlJlYWxFc3RhdGVQbGFjZWhvbGRlckZpZWxkRW51bS5S", + "ZWFsRXN0YXRlUGxhY2Vob2xkZXJGaWVsZEID4EEFSAASbQoMdHJhdmVsX2Zp", + "ZWxkGBUgASgOMlAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuVHJh", + "dmVsUGxhY2Vob2xkZXJGaWVsZEVudW0uVHJhdmVsUGxhY2Vob2xkZXJGaWVs", + "ZEID4EEFSAASagoLbG9jYWxfZmllbGQYFiABKA4yTi5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtcy5Mb2NhbFBsYWNlaG9sZGVyRmllbGRFbnVtLkxv", + "Y2FsUGxhY2Vob2xkZXJGaWVsZEID4EEFSAASZAoJam9iX2ZpZWxkGBcgASgO", + "MkouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuSm9iUGxhY2Vob2xk", + "ZXJGaWVsZEVudW0uSm9iUGxhY2Vob2xkZXJGaWVsZEID4EEFSABCBwoFZmll", + "bGRC/QEKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNC", + "EEZlZWRNYXBwaW5nUHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNv", + "dXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJj", + "ZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.AdCustomizerPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.AppPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CallPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CalloutPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.CustomPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.DsaPageFeedCriterionFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.EducationPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedMappingCriterionTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FeedMappingStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.HotelPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.JobPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.LocalPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.LocationExtensionTargetingCriterionFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.LocationPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.MessagePlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PricePlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.PromotionPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.RealEstatePlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SitelinkPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.StructuredSnippetPlaceholderFieldReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.TravelPlaceholderFieldReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedMapping), global::Google.Ads.GoogleAds.V3.Resources.FeedMapping.Parser, new[]{ "ResourceName", "Feed", "AttributeFieldMappings", "Status", "PlaceholderType", "CriterionType" }, new[]{ "Target" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.AttributeFieldMapping), global::Google.Ads.GoogleAds.V3.Resources.AttributeFieldMapping.Parser, new[]{ "FeedAttributeId", "FieldId", "SitelinkField", "CallField", "AppField", "LocationField", "AffiliateLocationField", "CalloutField", "StructuredSnippetField", "MessageField", "PriceField", "PromotionField", "AdCustomizerField", "DsaPageFeedField", "LocationExtensionTargetingField", "EducationField", "FlightField", "CustomField", "HotelField", "RealEstateField", "TravelField", "LocalField", "JobField" }, new[]{ "Field" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A feed mapping. + /// + public sealed partial class FeedMapping : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedMapping()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedMappingReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMapping() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMapping(FeedMapping other) : this() { + resourceName_ = other.resourceName_; + Feed = other.Feed; + attributeFieldMappings_ = other.attributeFieldMappings_.Clone(); + status_ = other.status_; + switch (other.TargetCase) { + case TargetOneofCase.PlaceholderType: + PlaceholderType = other.PlaceholderType; + break; + case TargetOneofCase.CriterionType: + CriterionType = other.CriterionType; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMapping Clone() { + return new FeedMapping(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the feed mapping. + /// Feed mapping resource names have the form: + /// + /// `customers/{customer_id}/feedMappings/{feed_id}~{feed_mapping_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "feed" field. + public const int FeedFieldNumber = 2; + private static readonly pb::FieldCodec _single_feed_codec = pb::FieldCodec.ForClassWrapper(18); + private string feed_; + /// + /// Immutable. The feed of this feed mapping. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Feed { + get { return feed_; } + set { + feed_ = value; + } + } + + + /// Field number for the "attribute_field_mappings" field. + public const int AttributeFieldMappingsFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_attributeFieldMappings_codec + = pb::FieldCodec.ForMessage(42, global::Google.Ads.GoogleAds.V3.Resources.AttributeFieldMapping.Parser); + private readonly pbc::RepeatedField attributeFieldMappings_ = new pbc::RepeatedField(); + /// + /// Immutable. Feed attributes to field mappings. These mappings are a one-to-many + /// relationship meaning that 1 feed attribute can be used to populate + /// multiple placeholder fields, but 1 placeholder field can only draw + /// data from 1 feed attribute. Ad Customizer is an exception, 1 placeholder + /// field can be mapped to multiple feed attributes. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField AttributeFieldMappings { + get { return attributeFieldMappings_; } + } + + /// Field number for the "status" field. + public const int StatusFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.FeedMappingStatusEnum.Types.FeedMappingStatus status_ = 0; + /// + /// Output only. Status of the feed mapping. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedMappingStatusEnum.Types.FeedMappingStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "placeholder_type" field. + public const int PlaceholderTypeFieldNumber = 3; + /// + /// Immutable. The placeholder type of this mapping (i.e., if the mapping maps feed + /// attributes to placeholder fields). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType PlaceholderType { + get { return targetCase_ == TargetOneofCase.PlaceholderType ? (global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType) target_ : 0; } + set { + target_ = value; + targetCase_ = TargetOneofCase.PlaceholderType; + } + } + + /// Field number for the "criterion_type" field. + public const int CriterionTypeFieldNumber = 4; + /// + /// Immutable. The criterion type of this mapping (i.e., if the mapping maps feed + /// attributes to criterion fields). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FeedMappingCriterionTypeEnum.Types.FeedMappingCriterionType CriterionType { + get { return targetCase_ == TargetOneofCase.CriterionType ? (global::Google.Ads.GoogleAds.V3.Enums.FeedMappingCriterionTypeEnum.Types.FeedMappingCriterionType) target_ : 0; } + set { + target_ = value; + targetCase_ = TargetOneofCase.CriterionType; + } + } + + private object target_; + /// Enum of possible cases for the "target" oneof. + public enum TargetOneofCase { + None = 0, + PlaceholderType = 3, + CriterionType = 4, + } + private TargetOneofCase targetCase_ = TargetOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TargetOneofCase TargetCase { + get { return targetCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearTarget() { + targetCase_ = TargetOneofCase.None; + target_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedMapping); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedMapping other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Feed != other.Feed) return false; + if(!attributeFieldMappings_.Equals(other.attributeFieldMappings_)) return false; + if (Status != other.Status) return false; + if (PlaceholderType != other.PlaceholderType) return false; + if (CriterionType != other.CriterionType) return false; + if (TargetCase != other.TargetCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (feed_ != null) hash ^= Feed.GetHashCode(); + hash ^= attributeFieldMappings_.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (targetCase_ == TargetOneofCase.PlaceholderType) hash ^= PlaceholderType.GetHashCode(); + if (targetCase_ == TargetOneofCase.CriterionType) hash ^= CriterionType.GetHashCode(); + hash ^= (int) targetCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (feed_ != null) { + _single_feed_codec.WriteTagAndValue(output, Feed); + } + if (targetCase_ == TargetOneofCase.PlaceholderType) { + output.WriteRawTag(24); + output.WriteEnum((int) PlaceholderType); + } + if (targetCase_ == TargetOneofCase.CriterionType) { + output.WriteRawTag(32); + output.WriteEnum((int) CriterionType); + } + attributeFieldMappings_.WriteTo(output, _repeated_attributeFieldMappings_codec); + if (Status != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) Status); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (feed_ != null) { + size += _single_feed_codec.CalculateSizeWithTag(Feed); + } + size += attributeFieldMappings_.CalculateSize(_repeated_attributeFieldMappings_codec); + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (targetCase_ == TargetOneofCase.PlaceholderType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PlaceholderType); + } + if (targetCase_ == TargetOneofCase.CriterionType) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) CriterionType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedMapping other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.feed_ != null) { + if (feed_ == null || other.Feed != "") { + Feed = other.Feed; + } + } + attributeFieldMappings_.Add(other.attributeFieldMappings_); + if (other.Status != 0) { + Status = other.Status; + } + switch (other.TargetCase) { + case TargetOneofCase.PlaceholderType: + PlaceholderType = other.PlaceholderType; + break; + case TargetOneofCase.CriterionType: + CriterionType = other.CriterionType; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_feed_codec.Read(input); + if (feed_ == null || value != "") { + Feed = value; + } + break; + } + case 24: { + target_ = input.ReadEnum(); + targetCase_ = TargetOneofCase.PlaceholderType; + break; + } + case 32: { + target_ = input.ReadEnum(); + targetCase_ = TargetOneofCase.CriterionType; + break; + } + case 42: { + attributeFieldMappings_.AddEntriesFrom(input, _repeated_attributeFieldMappings_codec); + break; + } + case 48: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.FeedMappingStatusEnum.Types.FeedMappingStatus) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Maps from feed attribute id to a placeholder or criterion field id. + /// + public sealed partial class AttributeFieldMapping : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AttributeFieldMapping()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedMappingReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributeFieldMapping() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributeFieldMapping(AttributeFieldMapping other) : this() { + FeedAttributeId = other.FeedAttributeId; + FieldId = other.FieldId; + switch (other.FieldCase) { + case FieldOneofCase.SitelinkField: + SitelinkField = other.SitelinkField; + break; + case FieldOneofCase.CallField: + CallField = other.CallField; + break; + case FieldOneofCase.AppField: + AppField = other.AppField; + break; + case FieldOneofCase.LocationField: + LocationField = other.LocationField; + break; + case FieldOneofCase.AffiliateLocationField: + AffiliateLocationField = other.AffiliateLocationField; + break; + case FieldOneofCase.CalloutField: + CalloutField = other.CalloutField; + break; + case FieldOneofCase.StructuredSnippetField: + StructuredSnippetField = other.StructuredSnippetField; + break; + case FieldOneofCase.MessageField: + MessageField = other.MessageField; + break; + case FieldOneofCase.PriceField: + PriceField = other.PriceField; + break; + case FieldOneofCase.PromotionField: + PromotionField = other.PromotionField; + break; + case FieldOneofCase.AdCustomizerField: + AdCustomizerField = other.AdCustomizerField; + break; + case FieldOneofCase.DsaPageFeedField: + DsaPageFeedField = other.DsaPageFeedField; + break; + case FieldOneofCase.LocationExtensionTargetingField: + LocationExtensionTargetingField = other.LocationExtensionTargetingField; + break; + case FieldOneofCase.EducationField: + EducationField = other.EducationField; + break; + case FieldOneofCase.FlightField: + FlightField = other.FlightField; + break; + case FieldOneofCase.CustomField: + CustomField = other.CustomField; + break; + case FieldOneofCase.HotelField: + HotelField = other.HotelField; + break; + case FieldOneofCase.RealEstateField: + RealEstateField = other.RealEstateField; + break; + case FieldOneofCase.TravelField: + TravelField = other.TravelField; + break; + case FieldOneofCase.LocalField: + LocalField = other.LocalField; + break; + case FieldOneofCase.JobField: + JobField = other.JobField; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AttributeFieldMapping Clone() { + return new AttributeFieldMapping(this); + } + + /// Field number for the "feed_attribute_id" field. + public const int FeedAttributeIdFieldNumber = 1; + private static readonly pb::FieldCodec _single_feedAttributeId_codec = pb::FieldCodec.ForStructWrapper(10); + private long? feedAttributeId_; + /// + /// Immutable. Feed attribute from which to map. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? FeedAttributeId { + get { return feedAttributeId_; } + set { + feedAttributeId_ = value; + } + } + + + /// Field number for the "field_id" field. + public const int FieldIdFieldNumber = 2; + private static readonly pb::FieldCodec _single_fieldId_codec = pb::FieldCodec.ForStructWrapper(18); + private long? fieldId_; + /// + /// Output only. The placeholder field ID. If a placeholder field enum is not published in + /// the current API version, then this field will be populated and the field + /// oneof will be empty. + /// This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? FieldId { + get { return fieldId_; } + set { + fieldId_ = value; + } + } + + + /// Field number for the "sitelink_field" field. + public const int SitelinkFieldFieldNumber = 3; + /// + /// Immutable. Sitelink Placeholder Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SitelinkPlaceholderFieldEnum.Types.SitelinkPlaceholderField SitelinkField { + get { return fieldCase_ == FieldOneofCase.SitelinkField ? (global::Google.Ads.GoogleAds.V3.Enums.SitelinkPlaceholderFieldEnum.Types.SitelinkPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.SitelinkField; + } + } + + /// Field number for the "call_field" field. + public const int CallFieldFieldNumber = 4; + /// + /// Immutable. Call Placeholder Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CallPlaceholderFieldEnum.Types.CallPlaceholderField CallField { + get { return fieldCase_ == FieldOneofCase.CallField ? (global::Google.Ads.GoogleAds.V3.Enums.CallPlaceholderFieldEnum.Types.CallPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.CallField; + } + } + + /// Field number for the "app_field" field. + public const int AppFieldFieldNumber = 5; + /// + /// Immutable. App Placeholder Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AppPlaceholderFieldEnum.Types.AppPlaceholderField AppField { + get { return fieldCase_ == FieldOneofCase.AppField ? (global::Google.Ads.GoogleAds.V3.Enums.AppPlaceholderFieldEnum.Types.AppPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.AppField; + } + } + + /// Field number for the "location_field" field. + public const int LocationFieldFieldNumber = 6; + /// + /// Output only. Location Placeholder Fields. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.LocationPlaceholderFieldEnum.Types.LocationPlaceholderField LocationField { + get { return fieldCase_ == FieldOneofCase.LocationField ? (global::Google.Ads.GoogleAds.V3.Enums.LocationPlaceholderFieldEnum.Types.LocationPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.LocationField; + } + } + + /// Field number for the "affiliate_location_field" field. + public const int AffiliateLocationFieldFieldNumber = 7; + /// + /// Output only. Affiliate Location Placeholder Fields. This field is read-only. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationPlaceholderFieldEnum.Types.AffiliateLocationPlaceholderField AffiliateLocationField { + get { return fieldCase_ == FieldOneofCase.AffiliateLocationField ? (global::Google.Ads.GoogleAds.V3.Enums.AffiliateLocationPlaceholderFieldEnum.Types.AffiliateLocationPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.AffiliateLocationField; + } + } + + /// Field number for the "callout_field" field. + public const int CalloutFieldFieldNumber = 8; + /// + /// Immutable. Callout Placeholder Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CalloutPlaceholderFieldEnum.Types.CalloutPlaceholderField CalloutField { + get { return fieldCase_ == FieldOneofCase.CalloutField ? (global::Google.Ads.GoogleAds.V3.Enums.CalloutPlaceholderFieldEnum.Types.CalloutPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.CalloutField; + } + } + + /// Field number for the "structured_snippet_field" field. + public const int StructuredSnippetFieldFieldNumber = 9; + /// + /// Immutable. Structured Snippet Placeholder Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.StructuredSnippetPlaceholderFieldEnum.Types.StructuredSnippetPlaceholderField StructuredSnippetField { + get { return fieldCase_ == FieldOneofCase.StructuredSnippetField ? (global::Google.Ads.GoogleAds.V3.Enums.StructuredSnippetPlaceholderFieldEnum.Types.StructuredSnippetPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.StructuredSnippetField; + } + } + + /// Field number for the "message_field" field. + public const int MessageFieldFieldNumber = 10; + /// + /// Immutable. Message Placeholder Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.MessagePlaceholderFieldEnum.Types.MessagePlaceholderField MessageField { + get { return fieldCase_ == FieldOneofCase.MessageField ? (global::Google.Ads.GoogleAds.V3.Enums.MessagePlaceholderFieldEnum.Types.MessagePlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.MessageField; + } + } + + /// Field number for the "price_field" field. + public const int PriceFieldFieldNumber = 11; + /// + /// Immutable. Price Placeholder Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PricePlaceholderFieldEnum.Types.PricePlaceholderField PriceField { + get { return fieldCase_ == FieldOneofCase.PriceField ? (global::Google.Ads.GoogleAds.V3.Enums.PricePlaceholderFieldEnum.Types.PricePlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.PriceField; + } + } + + /// Field number for the "promotion_field" field. + public const int PromotionFieldFieldNumber = 12; + /// + /// Immutable. Promotion Placeholder Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PromotionPlaceholderFieldEnum.Types.PromotionPlaceholderField PromotionField { + get { return fieldCase_ == FieldOneofCase.PromotionField ? (global::Google.Ads.GoogleAds.V3.Enums.PromotionPlaceholderFieldEnum.Types.PromotionPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.PromotionField; + } + } + + /// Field number for the "ad_customizer_field" field. + public const int AdCustomizerFieldFieldNumber = 13; + /// + /// Immutable. Ad Customizer Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AdCustomizerPlaceholderFieldEnum.Types.AdCustomizerPlaceholderField AdCustomizerField { + get { return fieldCase_ == FieldOneofCase.AdCustomizerField ? (global::Google.Ads.GoogleAds.V3.Enums.AdCustomizerPlaceholderFieldEnum.Types.AdCustomizerPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.AdCustomizerField; + } + } + + /// Field number for the "dsa_page_feed_field" field. + public const int DsaPageFeedFieldFieldNumber = 14; + /// + /// Immutable. Dynamic Search Ad Page Feed Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.DsaPageFeedCriterionFieldEnum.Types.DsaPageFeedCriterionField DsaPageFeedField { + get { return fieldCase_ == FieldOneofCase.DsaPageFeedField ? (global::Google.Ads.GoogleAds.V3.Enums.DsaPageFeedCriterionFieldEnum.Types.DsaPageFeedCriterionField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.DsaPageFeedField; + } + } + + /// Field number for the "location_extension_targeting_field" field. + public const int LocationExtensionTargetingFieldFieldNumber = 15; + /// + /// Immutable. Location Target Fields. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.LocationExtensionTargetingCriterionFieldEnum.Types.LocationExtensionTargetingCriterionField LocationExtensionTargetingField { + get { return fieldCase_ == FieldOneofCase.LocationExtensionTargetingField ? (global::Google.Ads.GoogleAds.V3.Enums.LocationExtensionTargetingCriterionFieldEnum.Types.LocationExtensionTargetingCriterionField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.LocationExtensionTargetingField; + } + } + + /// Field number for the "education_field" field. + public const int EducationFieldFieldNumber = 16; + /// + /// Immutable. Education Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.EducationPlaceholderFieldEnum.Types.EducationPlaceholderField EducationField { + get { return fieldCase_ == FieldOneofCase.EducationField ? (global::Google.Ads.GoogleAds.V3.Enums.EducationPlaceholderFieldEnum.Types.EducationPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.EducationField; + } + } + + /// Field number for the "flight_field" field. + public const int FlightFieldFieldNumber = 17; + /// + /// Immutable. Flight Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldEnum.Types.FlightPlaceholderField FlightField { + get { return fieldCase_ == FieldOneofCase.FlightField ? (global::Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldEnum.Types.FlightPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.FlightField; + } + } + + /// Field number for the "custom_field" field. + public const int CustomFieldFieldNumber = 18; + /// + /// Immutable. Custom Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.CustomPlaceholderFieldEnum.Types.CustomPlaceholderField CustomField { + get { return fieldCase_ == FieldOneofCase.CustomField ? (global::Google.Ads.GoogleAds.V3.Enums.CustomPlaceholderFieldEnum.Types.CustomPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.CustomField; + } + } + + /// Field number for the "hotel_field" field. + public const int HotelFieldFieldNumber = 19; + /// + /// Immutable. Hotel Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.HotelPlaceholderFieldEnum.Types.HotelPlaceholderField HotelField { + get { return fieldCase_ == FieldOneofCase.HotelField ? (global::Google.Ads.GoogleAds.V3.Enums.HotelPlaceholderFieldEnum.Types.HotelPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.HotelField; + } + } + + /// Field number for the "real_estate_field" field. + public const int RealEstateFieldFieldNumber = 20; + /// + /// Immutable. Real Estate Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.RealEstatePlaceholderFieldEnum.Types.RealEstatePlaceholderField RealEstateField { + get { return fieldCase_ == FieldOneofCase.RealEstateField ? (global::Google.Ads.GoogleAds.V3.Enums.RealEstatePlaceholderFieldEnum.Types.RealEstatePlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.RealEstateField; + } + } + + /// Field number for the "travel_field" field. + public const int TravelFieldFieldNumber = 21; + /// + /// Immutable. Travel Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.TravelPlaceholderFieldEnum.Types.TravelPlaceholderField TravelField { + get { return fieldCase_ == FieldOneofCase.TravelField ? (global::Google.Ads.GoogleAds.V3.Enums.TravelPlaceholderFieldEnum.Types.TravelPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.TravelField; + } + } + + /// Field number for the "local_field" field. + public const int LocalFieldFieldNumber = 22; + /// + /// Immutable. Local Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.LocalPlaceholderFieldEnum.Types.LocalPlaceholderField LocalField { + get { return fieldCase_ == FieldOneofCase.LocalField ? (global::Google.Ads.GoogleAds.V3.Enums.LocalPlaceholderFieldEnum.Types.LocalPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.LocalField; + } + } + + /// Field number for the "job_field" field. + public const int JobFieldFieldNumber = 23; + /// + /// Immutable. Job Placeholder Fields + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.JobPlaceholderFieldEnum.Types.JobPlaceholderField JobField { + get { return fieldCase_ == FieldOneofCase.JobField ? (global::Google.Ads.GoogleAds.V3.Enums.JobPlaceholderFieldEnum.Types.JobPlaceholderField) field_ : 0; } + set { + field_ = value; + fieldCase_ = FieldOneofCase.JobField; + } + } + + private object field_; + /// Enum of possible cases for the "field" oneof. + public enum FieldOneofCase { + None = 0, + SitelinkField = 3, + CallField = 4, + AppField = 5, + LocationField = 6, + AffiliateLocationField = 7, + CalloutField = 8, + StructuredSnippetField = 9, + MessageField = 10, + PriceField = 11, + PromotionField = 12, + AdCustomizerField = 13, + DsaPageFeedField = 14, + LocationExtensionTargetingField = 15, + EducationField = 16, + FlightField = 17, + CustomField = 18, + HotelField = 19, + RealEstateField = 20, + TravelField = 21, + LocalField = 22, + JobField = 23, + } + private FieldOneofCase fieldCase_ = FieldOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldOneofCase FieldCase { + get { return fieldCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearField() { + fieldCase_ = FieldOneofCase.None; + field_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AttributeFieldMapping); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AttributeFieldMapping other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (FeedAttributeId != other.FeedAttributeId) return false; + if (FieldId != other.FieldId) return false; + if (SitelinkField != other.SitelinkField) return false; + if (CallField != other.CallField) return false; + if (AppField != other.AppField) return false; + if (LocationField != other.LocationField) return false; + if (AffiliateLocationField != other.AffiliateLocationField) return false; + if (CalloutField != other.CalloutField) return false; + if (StructuredSnippetField != other.StructuredSnippetField) return false; + if (MessageField != other.MessageField) return false; + if (PriceField != other.PriceField) return false; + if (PromotionField != other.PromotionField) return false; + if (AdCustomizerField != other.AdCustomizerField) return false; + if (DsaPageFeedField != other.DsaPageFeedField) return false; + if (LocationExtensionTargetingField != other.LocationExtensionTargetingField) return false; + if (EducationField != other.EducationField) return false; + if (FlightField != other.FlightField) return false; + if (CustomField != other.CustomField) return false; + if (HotelField != other.HotelField) return false; + if (RealEstateField != other.RealEstateField) return false; + if (TravelField != other.TravelField) return false; + if (LocalField != other.LocalField) return false; + if (JobField != other.JobField) return false; + if (FieldCase != other.FieldCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (feedAttributeId_ != null) hash ^= FeedAttributeId.GetHashCode(); + if (fieldId_ != null) hash ^= FieldId.GetHashCode(); + if (fieldCase_ == FieldOneofCase.SitelinkField) hash ^= SitelinkField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.CallField) hash ^= CallField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.AppField) hash ^= AppField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.LocationField) hash ^= LocationField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.AffiliateLocationField) hash ^= AffiliateLocationField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.CalloutField) hash ^= CalloutField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.StructuredSnippetField) hash ^= StructuredSnippetField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.MessageField) hash ^= MessageField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.PriceField) hash ^= PriceField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.PromotionField) hash ^= PromotionField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.AdCustomizerField) hash ^= AdCustomizerField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.DsaPageFeedField) hash ^= DsaPageFeedField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.LocationExtensionTargetingField) hash ^= LocationExtensionTargetingField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.EducationField) hash ^= EducationField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.FlightField) hash ^= FlightField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.CustomField) hash ^= CustomField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.HotelField) hash ^= HotelField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.RealEstateField) hash ^= RealEstateField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.TravelField) hash ^= TravelField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.LocalField) hash ^= LocalField.GetHashCode(); + if (fieldCase_ == FieldOneofCase.JobField) hash ^= JobField.GetHashCode(); + hash ^= (int) fieldCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (feedAttributeId_ != null) { + _single_feedAttributeId_codec.WriteTagAndValue(output, FeedAttributeId); + } + if (fieldId_ != null) { + _single_fieldId_codec.WriteTagAndValue(output, FieldId); + } + if (fieldCase_ == FieldOneofCase.SitelinkField) { + output.WriteRawTag(24); + output.WriteEnum((int) SitelinkField); + } + if (fieldCase_ == FieldOneofCase.CallField) { + output.WriteRawTag(32); + output.WriteEnum((int) CallField); + } + if (fieldCase_ == FieldOneofCase.AppField) { + output.WriteRawTag(40); + output.WriteEnum((int) AppField); + } + if (fieldCase_ == FieldOneofCase.LocationField) { + output.WriteRawTag(48); + output.WriteEnum((int) LocationField); + } + if (fieldCase_ == FieldOneofCase.AffiliateLocationField) { + output.WriteRawTag(56); + output.WriteEnum((int) AffiliateLocationField); + } + if (fieldCase_ == FieldOneofCase.CalloutField) { + output.WriteRawTag(64); + output.WriteEnum((int) CalloutField); + } + if (fieldCase_ == FieldOneofCase.StructuredSnippetField) { + output.WriteRawTag(72); + output.WriteEnum((int) StructuredSnippetField); + } + if (fieldCase_ == FieldOneofCase.MessageField) { + output.WriteRawTag(80); + output.WriteEnum((int) MessageField); + } + if (fieldCase_ == FieldOneofCase.PriceField) { + output.WriteRawTag(88); + output.WriteEnum((int) PriceField); + } + if (fieldCase_ == FieldOneofCase.PromotionField) { + output.WriteRawTag(96); + output.WriteEnum((int) PromotionField); + } + if (fieldCase_ == FieldOneofCase.AdCustomizerField) { + output.WriteRawTag(104); + output.WriteEnum((int) AdCustomizerField); + } + if (fieldCase_ == FieldOneofCase.DsaPageFeedField) { + output.WriteRawTag(112); + output.WriteEnum((int) DsaPageFeedField); + } + if (fieldCase_ == FieldOneofCase.LocationExtensionTargetingField) { + output.WriteRawTag(120); + output.WriteEnum((int) LocationExtensionTargetingField); + } + if (fieldCase_ == FieldOneofCase.EducationField) { + output.WriteRawTag(128, 1); + output.WriteEnum((int) EducationField); + } + if (fieldCase_ == FieldOneofCase.FlightField) { + output.WriteRawTag(136, 1); + output.WriteEnum((int) FlightField); + } + if (fieldCase_ == FieldOneofCase.CustomField) { + output.WriteRawTag(144, 1); + output.WriteEnum((int) CustomField); + } + if (fieldCase_ == FieldOneofCase.HotelField) { + output.WriteRawTag(152, 1); + output.WriteEnum((int) HotelField); + } + if (fieldCase_ == FieldOneofCase.RealEstateField) { + output.WriteRawTag(160, 1); + output.WriteEnum((int) RealEstateField); + } + if (fieldCase_ == FieldOneofCase.TravelField) { + output.WriteRawTag(168, 1); + output.WriteEnum((int) TravelField); + } + if (fieldCase_ == FieldOneofCase.LocalField) { + output.WriteRawTag(176, 1); + output.WriteEnum((int) LocalField); + } + if (fieldCase_ == FieldOneofCase.JobField) { + output.WriteRawTag(184, 1); + output.WriteEnum((int) JobField); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (feedAttributeId_ != null) { + size += _single_feedAttributeId_codec.CalculateSizeWithTag(FeedAttributeId); + } + if (fieldId_ != null) { + size += _single_fieldId_codec.CalculateSizeWithTag(FieldId); + } + if (fieldCase_ == FieldOneofCase.SitelinkField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) SitelinkField); + } + if (fieldCase_ == FieldOneofCase.CallField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) CallField); + } + if (fieldCase_ == FieldOneofCase.AppField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AppField); + } + if (fieldCase_ == FieldOneofCase.LocationField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) LocationField); + } + if (fieldCase_ == FieldOneofCase.AffiliateLocationField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AffiliateLocationField); + } + if (fieldCase_ == FieldOneofCase.CalloutField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) CalloutField); + } + if (fieldCase_ == FieldOneofCase.StructuredSnippetField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) StructuredSnippetField); + } + if (fieldCase_ == FieldOneofCase.MessageField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MessageField); + } + if (fieldCase_ == FieldOneofCase.PriceField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PriceField); + } + if (fieldCase_ == FieldOneofCase.PromotionField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PromotionField); + } + if (fieldCase_ == FieldOneofCase.AdCustomizerField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) AdCustomizerField); + } + if (fieldCase_ == FieldOneofCase.DsaPageFeedField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DsaPageFeedField); + } + if (fieldCase_ == FieldOneofCase.LocationExtensionTargetingField) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) LocationExtensionTargetingField); + } + if (fieldCase_ == FieldOneofCase.EducationField) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EducationField); + } + if (fieldCase_ == FieldOneofCase.FlightField) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) FlightField); + } + if (fieldCase_ == FieldOneofCase.CustomField) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) CustomField); + } + if (fieldCase_ == FieldOneofCase.HotelField) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) HotelField); + } + if (fieldCase_ == FieldOneofCase.RealEstateField) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) RealEstateField); + } + if (fieldCase_ == FieldOneofCase.TravelField) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) TravelField); + } + if (fieldCase_ == FieldOneofCase.LocalField) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) LocalField); + } + if (fieldCase_ == FieldOneofCase.JobField) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) JobField); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AttributeFieldMapping other) { + if (other == null) { + return; + } + if (other.feedAttributeId_ != null) { + if (feedAttributeId_ == null || other.FeedAttributeId != 0L) { + FeedAttributeId = other.FeedAttributeId; + } + } + if (other.fieldId_ != null) { + if (fieldId_ == null || other.FieldId != 0L) { + FieldId = other.FieldId; + } + } + switch (other.FieldCase) { + case FieldOneofCase.SitelinkField: + SitelinkField = other.SitelinkField; + break; + case FieldOneofCase.CallField: + CallField = other.CallField; + break; + case FieldOneofCase.AppField: + AppField = other.AppField; + break; + case FieldOneofCase.LocationField: + LocationField = other.LocationField; + break; + case FieldOneofCase.AffiliateLocationField: + AffiliateLocationField = other.AffiliateLocationField; + break; + case FieldOneofCase.CalloutField: + CalloutField = other.CalloutField; + break; + case FieldOneofCase.StructuredSnippetField: + StructuredSnippetField = other.StructuredSnippetField; + break; + case FieldOneofCase.MessageField: + MessageField = other.MessageField; + break; + case FieldOneofCase.PriceField: + PriceField = other.PriceField; + break; + case FieldOneofCase.PromotionField: + PromotionField = other.PromotionField; + break; + case FieldOneofCase.AdCustomizerField: + AdCustomizerField = other.AdCustomizerField; + break; + case FieldOneofCase.DsaPageFeedField: + DsaPageFeedField = other.DsaPageFeedField; + break; + case FieldOneofCase.LocationExtensionTargetingField: + LocationExtensionTargetingField = other.LocationExtensionTargetingField; + break; + case FieldOneofCase.EducationField: + EducationField = other.EducationField; + break; + case FieldOneofCase.FlightField: + FlightField = other.FlightField; + break; + case FieldOneofCase.CustomField: + CustomField = other.CustomField; + break; + case FieldOneofCase.HotelField: + HotelField = other.HotelField; + break; + case FieldOneofCase.RealEstateField: + RealEstateField = other.RealEstateField; + break; + case FieldOneofCase.TravelField: + TravelField = other.TravelField; + break; + case FieldOneofCase.LocalField: + LocalField = other.LocalField; + break; + case FieldOneofCase.JobField: + JobField = other.JobField; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_feedAttributeId_codec.Read(input); + if (feedAttributeId_ == null || value != 0L) { + FeedAttributeId = value; + } + break; + } + case 18: { + long? value = _single_fieldId_codec.Read(input); + if (fieldId_ == null || value != 0L) { + FieldId = value; + } + break; + } + case 24: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.SitelinkField; + break; + } + case 32: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.CallField; + break; + } + case 40: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.AppField; + break; + } + case 48: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.LocationField; + break; + } + case 56: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.AffiliateLocationField; + break; + } + case 64: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.CalloutField; + break; + } + case 72: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.StructuredSnippetField; + break; + } + case 80: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.MessageField; + break; + } + case 88: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.PriceField; + break; + } + case 96: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.PromotionField; + break; + } + case 104: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.AdCustomizerField; + break; + } + case 112: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.DsaPageFeedField; + break; + } + case 120: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.LocationExtensionTargetingField; + break; + } + case 128: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.EducationField; + break; + } + case 136: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.FlightField; + break; + } + case 144: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.CustomField; + break; + } + case 152: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.HotelField; + break; + } + case 160: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.RealEstateField; + break; + } + case 168: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.TravelField; + break; + } + case 176: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.LocalField; + break; + } + case 184: { + field_ = input.ReadEnum(); + fieldCase_ = FieldOneofCase.JobField; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedMappingCriterionType.cs b/src/V3/Stubs/FeedMappingCriterionType.cs new file mode 100644 index 000000000..5cf76d61c --- /dev/null +++ b/src/V3/Stubs/FeedMappingCriterionType.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_mapping_criterion_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_mapping_criterion_type.proto + public static partial class FeedMappingCriterionTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_mapping_criterion_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedMappingCriterionTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX21hcHBpbmdf", + "Y3JpdGVyaW9uX3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIo0BChxGZWVk", + "TWFwcGluZ0NyaXRlcmlvblR5cGVFbnVtIm0KGEZlZWRNYXBwaW5nQ3JpdGVy", + "aW9uVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIgChxMT0NB", + "VElPTl9FWFRFTlNJT05fVEFSR0VUSU5HEAQSEQoNRFNBX1BBR0VfRkVFRBAD", + "QvIBCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCHUZlZWRN", + "YXBwaW5nQ3JpdGVyaW9uVHlwZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztl", + "bnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygId", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedMappingCriterionTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedMappingCriterionTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedMappingCriterionTypeEnum.Types.FeedMappingCriterionType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible criterion types for a feed mapping. + /// + public sealed partial class FeedMappingCriterionTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedMappingCriterionTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedMappingCriterionTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingCriterionTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingCriterionTypeEnum(FeedMappingCriterionTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingCriterionTypeEnum Clone() { + return new FeedMappingCriterionTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedMappingCriterionTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedMappingCriterionTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedMappingCriterionTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedMappingCriterionTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible placeholder types for a feed mapping. + /// + public enum FeedMappingCriterionType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Allows campaign targeting at locations within a location feed. + /// + [pbr::OriginalName("LOCATION_EXTENSION_TARGETING")] LocationExtensionTargeting = 4, + /// + /// Allows url targeting for your dynamic search ads within a page feed. + /// + [pbr::OriginalName("DSA_PAGE_FEED")] DsaPageFeed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedMappingError.cs b/src/V3/Stubs/FeedMappingError.cs new file mode 100644 index 000000000..7747ea6bc --- /dev/null +++ b/src/V3/Stubs/FeedMappingError.cs @@ -0,0 +1,265 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/feed_mapping_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/feed_mapping_error.proto + public static partial class FeedMappingErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/feed_mapping_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedMappingErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZmVlZF9tYXBwaW5n", + "X2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMa", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ikgYKFEZlZWRNYXBwaW5n", + "RXJyb3JFbnVtIvkFChBGZWVkTWFwcGluZ0Vycm9yEg8KC1VOU1BFQ0lGSUVE", + "EAASCwoHVU5LTk9XThABEh0KGUlOVkFMSURfUExBQ0VIT0xERVJfRklFTEQQ", + "AhIbChdJTlZBTElEX0NSSVRFUklPTl9GSUVMRBADEhwKGElOVkFMSURfUExB", + "Q0VIT0xERVJfVFlQRRAEEhoKFklOVkFMSURfQ1JJVEVSSU9OX1RZUEUQBRIf", + "ChtOT19BVFRSSUJVVEVfRklFTERfTUFQUElOR1MQBxIgChxGRUVEX0FUVFJJ", + "QlVURV9UWVBFX01JU01BVENIEAgSOAo0Q0FOTk9UX09QRVJBVEVfT05fTUFQ", + "UElOR1NfRk9SX1NZU1RFTV9HRU5FUkFURURfRkVFRBAJEioKJk1VTFRJUExF", + "X01BUFBJTkdTX0ZPUl9QTEFDRUhPTERFUl9UWVBFEAoSKAokTVVMVElQTEVf", + "TUFQUElOR1NfRk9SX0NSSVRFUklPTl9UWVBFEAsSKwonTVVMVElQTEVfTUFQ", + "UElOR1NfRk9SX1BMQUNFSE9MREVSX0ZJRUxEEAwSKQolTVVMVElQTEVfTUFQ", + "UElOR1NfRk9SX0NSSVRFUklPTl9GSUVMRBANEicKI1VORVhQRUNURURfQVRU", + "UklCVVRFX0ZJRUxEX01BUFBJTkdTEA4SLgoqTE9DQVRJT05fUExBQ0VIT0xE", + "RVJfT05MWV9GT1JfUExBQ0VTX0ZFRURTEA8SKQolQ0FOTk9UX01PRElGWV9N", + "QVBQSU5HU19GT1JfVFlQRURfRkVFRBAQEjoKNklOVkFMSURfUExBQ0VIT0xE", + "RVJfVFlQRV9GT1JfTk9OX1NZU1RFTV9HRU5FUkFURURfRkVFRBAREjsKN0lO", + "VkFMSURfUExBQ0VIT0xERVJfVFlQRV9GT1JfU1lTVEVNX0dFTkVSQVRFRF9G", + "RUVEX1RZUEUQEhIpCiVBVFRSSUJVVEVfRklFTERfTUFQUElOR19NSVNTSU5H", + "X0ZJRUxEEBNC8AEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJv", + "cnNCFUZlZWRNYXBwaW5nRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9y", + "Zy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3Jz", + "O2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9y", + "c8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedMappingErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FeedMappingErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FeedMappingErrorEnum.Types.FeedMappingError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible feed item errors. + /// + public sealed partial class FeedMappingErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedMappingErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FeedMappingErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingErrorEnum(FeedMappingErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingErrorEnum Clone() { + return new FeedMappingErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedMappingErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedMappingErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedMappingErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedMappingErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible feed item errors. + /// + public enum FeedMappingError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The given placeholder field does not exist. + /// + [pbr::OriginalName("INVALID_PLACEHOLDER_FIELD")] InvalidPlaceholderField = 2, + /// + /// The given criterion field does not exist. + /// + [pbr::OriginalName("INVALID_CRITERION_FIELD")] InvalidCriterionField = 3, + /// + /// The given placeholder type does not exist. + /// + [pbr::OriginalName("INVALID_PLACEHOLDER_TYPE")] InvalidPlaceholderType = 4, + /// + /// The given criterion type does not exist. + /// + [pbr::OriginalName("INVALID_CRITERION_TYPE")] InvalidCriterionType = 5, + /// + /// A feed mapping must contain at least one attribute field mapping. + /// + [pbr::OriginalName("NO_ATTRIBUTE_FIELD_MAPPINGS")] NoAttributeFieldMappings = 7, + /// + /// The type of the feed attribute referenced in the attribute field mapping + /// must match the type of the placeholder field. + /// + [pbr::OriginalName("FEED_ATTRIBUTE_TYPE_MISMATCH")] FeedAttributeTypeMismatch = 8, + /// + /// A feed mapping for a system generated feed cannot be operated on. + /// + [pbr::OriginalName("CANNOT_OPERATE_ON_MAPPINGS_FOR_SYSTEM_GENERATED_FEED")] CannotOperateOnMappingsForSystemGeneratedFeed = 9, + /// + /// Only one feed mapping for a placeholder type is allowed per feed or + /// customer (depending on the placeholder type). + /// + [pbr::OriginalName("MULTIPLE_MAPPINGS_FOR_PLACEHOLDER_TYPE")] MultipleMappingsForPlaceholderType = 10, + /// + /// Only one feed mapping for a criterion type is allowed per customer. + /// + [pbr::OriginalName("MULTIPLE_MAPPINGS_FOR_CRITERION_TYPE")] MultipleMappingsForCriterionType = 11, + /// + /// Only one feed attribute mapping for a placeholder field is allowed + /// (depending on the placeholder type). + /// + [pbr::OriginalName("MULTIPLE_MAPPINGS_FOR_PLACEHOLDER_FIELD")] MultipleMappingsForPlaceholderField = 12, + /// + /// Only one feed attribute mapping for a criterion field is allowed + /// (depending on the criterion type). + /// + [pbr::OriginalName("MULTIPLE_MAPPINGS_FOR_CRITERION_FIELD")] MultipleMappingsForCriterionField = 13, + /// + /// This feed mapping may not contain any explicit attribute field mappings. + /// + [pbr::OriginalName("UNEXPECTED_ATTRIBUTE_FIELD_MAPPINGS")] UnexpectedAttributeFieldMappings = 14, + /// + /// Location placeholder feed mappings can only be created for Places feeds. + /// + [pbr::OriginalName("LOCATION_PLACEHOLDER_ONLY_FOR_PLACES_FEEDS")] LocationPlaceholderOnlyForPlacesFeeds = 15, + /// + /// Mappings for typed feeds cannot be modified. + /// + [pbr::OriginalName("CANNOT_MODIFY_MAPPINGS_FOR_TYPED_FEED")] CannotModifyMappingsForTypedFeed = 16, + /// + /// The given placeholder type can only be mapped to system generated feeds. + /// + [pbr::OriginalName("INVALID_PLACEHOLDER_TYPE_FOR_NON_SYSTEM_GENERATED_FEED")] InvalidPlaceholderTypeForNonSystemGeneratedFeed = 17, + /// + /// The given placeholder type cannot be mapped to a system generated feed + /// with the given type. + /// + [pbr::OriginalName("INVALID_PLACEHOLDER_TYPE_FOR_SYSTEM_GENERATED_FEED_TYPE")] InvalidPlaceholderTypeForSystemGeneratedFeedType = 18, + /// + /// The "field" oneof was not set in an AttributeFieldMapping. + /// + [pbr::OriginalName("ATTRIBUTE_FIELD_MAPPING_MISSING_FIELD")] AttributeFieldMappingMissingField = 19, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedMappingService.cs b/src/V3/Stubs/FeedMappingService.cs new file mode 100644 index 000000000..a90ac6bc2 --- /dev/null +++ b/src/V3/Stubs/FeedMappingService.cs @@ -0,0 +1,949 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_mapping_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/feed_mapping_service.proto + public static partial class FeedMappingServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/feed_mapping_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedMappingServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9mZWVkX21hcHBp", + "bmdfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMaNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9mZWVk", + "X21hcHBpbmcucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8a", + "F2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2Jl", + "aGF2aW9yLnByb3RvGhdnb29nbGUvcnBjL3N0YXR1cy5wcm90byIzChVHZXRG", + "ZWVkTWFwcGluZ1JlcXVlc3QSGgoNcmVzb3VyY2VfbmFtZRgBIAEoCUID4EEC", + "IrYBChlNdXRhdGVGZWVkTWFwcGluZ3NSZXF1ZXN0EhgKC2N1c3RvbWVyX2lk", + "GAEgASgJQgPgQQISTwoKb3BlcmF0aW9ucxgCIAMoCzI2Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLkZlZWRNYXBwaW5nT3BlcmF0aW9uQgPg", + "QQISFwoPcGFydGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlkYXRlX29ubHkY", + "BCABKAgidwoURmVlZE1hcHBpbmdPcGVyYXRpb24SQAoGY3JlYXRlGAEgASgL", + "Mi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkZlZWRNYXBw", + "aW5nSAASEAoGcmVtb3ZlGAMgASgJSABCCwoJb3BlcmF0aW9uIpsBChpNdXRh", + "dGVGZWVkTWFwcGluZ3NSZXNwb25zZRIxChVwYXJ0aWFsX2ZhaWx1cmVfZXJy", + "b3IYAyABKAsyEi5nb29nbGUucnBjLlN0YXR1cxJKCgdyZXN1bHRzGAIgAygL", + "MjkuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlRmVl", + "ZE1hcHBpbmdSZXN1bHQiMAoXTXV0YXRlRmVlZE1hcHBpbmdSZXN1bHQSFQoN", + "cmVzb3VyY2VfbmFtZRgBIAEoCTLeAwoSRmVlZE1hcHBpbmdTZXJ2aWNlEsEB", + "Cg5HZXRGZWVkTWFwcGluZxI3Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzLkdldEZlZWRNYXBwaW5nUmVxdWVzdBouLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5GZWVkTWFwcGluZyJGgtPkkwIwEi4vdjMv", + "e3Jlc291cmNlX25hbWU9Y3VzdG9tZXJzLyovZmVlZE1hcHBpbmdzLyp92kEN", + "cmVzb3VyY2VfbmFtZRLmAQoSTXV0YXRlRmVlZE1hcHBpbmdzEjsuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlRmVlZE1hcHBpbmdz", + "UmVxdWVzdBo8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11", + "dGF0ZUZlZWRNYXBwaW5nc1Jlc3BvbnNlIlWC0+STAjYiMS92My9jdXN0b21l", + "cnMve2N1c3RvbWVyX2lkPSp9L2ZlZWRNYXBwaW5nczptdXRhdGU6ASraQRZj", + "dXN0b21lcl9pZCxvcGVyYXRpb25zGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBp", + "cy5jb21C/gEKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "c0IXRmVlZE1hcHBpbmdTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xlLmdvbGFuZy5v", + "cmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZp", + "Y2VzO3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMu", + "U2VydmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xTZXJ2aWNlc+oC", + "JEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.FeedMappingReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetFeedMappingRequest), global::Google.Ads.GoogleAds.V3.Services.GetFeedMappingRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.FeedMappingOperation), global::Google.Ads.GoogleAds.V3.Services.FeedMappingOperation.Parser, new[]{ "Create", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingResult), global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [FeedMappingService.GetFeedMapping][google.ads.googleads.v3.services.FeedMappingService.GetFeedMapping]. + /// + public sealed partial class GetFeedMappingRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetFeedMappingRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedMappingServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedMappingRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedMappingRequest(GetFeedMappingRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedMappingRequest Clone() { + return new GetFeedMappingRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the feed mapping to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetFeedMappingRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetFeedMappingRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetFeedMappingRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [FeedMappingService.MutateFeedMappings][google.ads.googleads.v3.services.FeedMappingService.MutateFeedMappings]. + /// + public sealed partial class MutateFeedMappingsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedMappingsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedMappingServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingsRequest(MutateFeedMappingsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingsRequest Clone() { + return new MutateFeedMappingsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose feed mappings are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.FeedMappingOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual feed mappings. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedMappingsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedMappingsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedMappingsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, remove) on a feed mapping. + /// + public sealed partial class FeedMappingOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedMappingOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedMappingServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingOperation(FeedMappingOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingOperation Clone() { + return new FeedMappingOperation(this); + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new feed mapping. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedMapping Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.FeedMapping) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed feed mapping is + /// expected, in this format: + /// + /// `customers/{customer_id}/feedMappings/{feed_id}~{feed_mapping_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedMappingOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedMappingOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Create, other.Create)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedMappingOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.FeedMapping(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.FeedMapping subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.FeedMapping(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for a feed mapping mutate. + /// + public sealed partial class MutateFeedMappingsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedMappingsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedMappingServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingsResponse(MutateFeedMappingsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingsResponse Clone() { + return new MutateFeedMappingsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedMappingsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedMappingsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedMappingsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the feed mapping mutate. + /// + public sealed partial class MutateFeedMappingResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedMappingResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedMappingServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingResult(MutateFeedMappingResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedMappingResult Clone() { + return new MutateFeedMappingResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedMappingResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedMappingResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedMappingResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedMappingServiceClient.cs b/src/V3/Stubs/FeedMappingServiceClient.cs new file mode 100644 index 000000000..63a3a7f63 --- /dev/null +++ b/src/V3/Stubs/FeedMappingServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class FeedMappingServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static FeedMappingServiceSettings GetDefault() => new FeedMappingServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public FeedMappingServiceSettings() { } + + private FeedMappingServiceSettings(FeedMappingServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetFeedMappingSettings = existing.GetFeedMappingSettings; + MutateFeedMappingsSettings = existing.MutateFeedMappingsSettings; + OnCopy(existing); + } + + partial void OnCopy(FeedMappingServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// FeedMappingServiceClient.GetFeedMapping and FeedMappingServiceClient.GetFeedMappingAsync. + /// + /// + /// The default FeedMappingServiceClient.GetFeedMapping and + /// FeedMappingServiceClient.GetFeedMappingAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetFeedMappingSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// FeedMappingServiceClient.MutateFeedMappings and FeedMappingServiceClient.MutateFeedMappingsAsync. + /// + /// + /// The default FeedMappingServiceClient.MutateFeedMappings and + /// FeedMappingServiceClient.MutateFeedMappingsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateFeedMappingsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public FeedMappingServiceSettings Clone() => new FeedMappingServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class FeedMappingServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public FeedMappingServiceSettings Settings { get; set; } + + /// + public override FeedMappingServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return FeedMappingServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return FeedMappingServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => FeedMappingServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => FeedMappingServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => FeedMappingServiceClient.ChannelPool; + } + + /// + /// FeedMappingService client wrapper, for convenient use. + /// + public abstract partial class FeedMappingServiceClient + { + /// + /// The default endpoint for the FeedMappingService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default FeedMappingService scopes. + /// + /// + /// The default FeedMappingService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedMappingServiceClient client = await FeedMappingServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedMappingServiceClient.DefaultEndpoint.Host, FeedMappingServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedMappingServiceClient client = FeedMappingServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, FeedMappingServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedMappingServiceClient client = FeedMappingServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedMappingServiceClient.DefaultEndpoint.Host, FeedMappingServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedMappingServiceClient client = FeedMappingServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static FeedMappingServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, FeedMappingServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedMappingServiceClient Create(grpccore::Channel channel, FeedMappingServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedMappingServiceClient Create(grpccore::CallInvoker callInvoker, FeedMappingServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + FeedMappingService.FeedMappingServiceClient grpcClient = new FeedMappingService.FeedMappingServiceClient(callInvoker); + return new FeedMappingServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC FeedMappingService client. + /// + public virtual FeedMappingService.FeedMappingServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested feed mapping in full detail. + /// + /// + /// Required. The resource name of the feed mapping to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedMappingAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedMappingAsync( + new GetFeedMappingRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed mapping in full detail. + /// + /// + /// Required. The resource name of the feed mapping to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedMappingAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetFeedMappingAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed mapping in full detail. + /// + /// + /// Required. The resource name of the feed mapping to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::FeedMapping GetFeedMapping( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedMapping( + new GetFeedMappingRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed mapping in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedMappingAsync( + GetFeedMappingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested feed mapping in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedMappingAsync( + GetFeedMappingRequest request, + st::CancellationToken cancellationToken) => GetFeedMappingAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed mapping in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::FeedMapping GetFeedMapping( + GetFeedMappingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed mappings are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed mappings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedMappingsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateFeedMappingsAsync( + new MutateFeedMappingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed mappings are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed mappings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedMappingsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateFeedMappingsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed mappings are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed mappings. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedMappingsResponse MutateFeedMappings( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateFeedMappings( + new MutateFeedMappingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed mappings are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed mappings. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedMappingsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateFeedMappingsAsync( + new MutateFeedMappingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed mappings are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed mappings. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedMappingsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateFeedMappingsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feed mappings are being modified. + /// + /// + /// Required. The list of operations to perform on individual feed mappings. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedMappingsResponse MutateFeedMappings( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateFeedMappings( + new MutateFeedMappingsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedMappingsAsync( + MutateFeedMappingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedMappingsAsync( + MutateFeedMappingsRequest request, + st::CancellationToken cancellationToken) => MutateFeedMappingsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedMappingsResponse MutateFeedMappings( + MutateFeedMappingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// FeedMappingService client wrapper implementation, for convenient use. + /// + public sealed partial class FeedMappingServiceClientImpl : FeedMappingServiceClient + { + private readonly gaxgrpc::ApiCall _callGetFeedMapping; + private readonly gaxgrpc::ApiCall _callMutateFeedMappings; + + /// + /// Constructs a client wrapper for the FeedMappingService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public FeedMappingServiceClientImpl(FeedMappingService.FeedMappingServiceClient grpcClient, FeedMappingServiceSettings settings) + { + GrpcClient = grpcClient; + FeedMappingServiceSettings effectiveSettings = settings ?? FeedMappingServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetFeedMapping = clientHelper.BuildApiCall( + GrpcClient.GetFeedMappingAsync, GrpcClient.GetFeedMapping, effectiveSettings.GetFeedMappingSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateFeedMappings = clientHelper.BuildApiCall( + GrpcClient.MutateFeedMappingsAsync, GrpcClient.MutateFeedMappings, effectiveSettings.MutateFeedMappingsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetFeedMapping); + Modify_GetFeedMappingApiCall(ref _callGetFeedMapping); + Modify_ApiCall(ref _callMutateFeedMappings); + Modify_MutateFeedMappingsApiCall(ref _callMutateFeedMappings); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetFeedMappingApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateFeedMappingsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(FeedMappingService.FeedMappingServiceClient grpcClient, FeedMappingServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC FeedMappingService client. + /// + public override FeedMappingService.FeedMappingServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetFeedMappingRequest(ref GetFeedMappingRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateFeedMappingsRequest(ref MutateFeedMappingsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested feed mapping in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetFeedMappingAsync( + GetFeedMappingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedMappingRequest(ref request, ref callSettings); + return _callGetFeedMapping.Async(request, callSettings); + } + + /// + /// Returns the requested feed mapping in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::FeedMapping GetFeedMapping( + GetFeedMappingRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedMappingRequest(ref request, ref callSettings); + return _callGetFeedMapping.Sync(request, callSettings); + } + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateFeedMappingsAsync( + MutateFeedMappingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateFeedMappingsRequest(ref request, ref callSettings); + return _callMutateFeedMappings.Async(request, callSettings); + } + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateFeedMappingsResponse MutateFeedMappings( + MutateFeedMappingsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateFeedMappingsRequest(ref request, ref callSettings); + return _callMutateFeedMappings.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/FeedMappingServiceGrpc.cs b/src/V3/Stubs/FeedMappingServiceGrpc.cs new file mode 100644 index 000000000..1e6f24165 --- /dev/null +++ b/src/V3/Stubs/FeedMappingServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_mapping_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage feed mappings. + /// + public static partial class FeedMappingService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.FeedMappingService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetFeedMappingRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetFeedMappingRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_FeedMapping = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.FeedMapping.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateFeedMappingsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateFeedMappingsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetFeedMapping = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetFeedMapping", + __Marshaller_google_ads_googleads_v3_services_GetFeedMappingRequest, + __Marshaller_google_ads_googleads_v3_resources_FeedMapping); + + static readonly grpc::Method __Method_MutateFeedMappings = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateFeedMappings", + __Marshaller_google_ads_googleads_v3_services_MutateFeedMappingsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateFeedMappingsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedMappingServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of FeedMappingService + public abstract partial class FeedMappingServiceBase + { + /// + /// Returns the requested feed mapping in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetFeedMapping(global::Google.Ads.GoogleAds.V3.Services.GetFeedMappingRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateFeedMappings(global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for FeedMappingService + public partial class FeedMappingServiceClient : grpc::ClientBase + { + /// Creates a new client for FeedMappingService + /// The channel to use to make remote calls. + public FeedMappingServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for FeedMappingService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public FeedMappingServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected FeedMappingServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected FeedMappingServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested feed mapping in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.FeedMapping GetFeedMapping(global::Google.Ads.GoogleAds.V3.Services.GetFeedMappingRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedMapping(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed mapping in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.FeedMapping GetFeedMapping(global::Google.Ads.GoogleAds.V3.Services.GetFeedMappingRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetFeedMapping, null, options, request); + } + /// + /// Returns the requested feed mapping in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedMappingAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedMappingRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedMappingAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed mapping in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedMappingAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedMappingRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetFeedMapping, null, options, request); + } + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsResponse MutateFeedMappings(global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateFeedMappings(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsResponse MutateFeedMappings(global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateFeedMappings, null, options, request); + } + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateFeedMappingsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateFeedMappingsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates or removes feed mappings. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateFeedMappingsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateFeedMappings, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override FeedMappingServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new FeedMappingServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(FeedMappingServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetFeedMapping, serviceImpl.GetFeedMapping) + .AddMethod(__Method_MutateFeedMappings, serviceImpl.MutateFeedMappings).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, FeedMappingServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetFeedMapping, serviceImpl.GetFeedMapping); + serviceBinder.AddMethod(__Method_MutateFeedMappings, serviceImpl.MutateFeedMappings); + } + + } +} +#endregion diff --git a/src/V3/Stubs/FeedMappingStatus.cs b/src/V3/Stubs/FeedMappingStatus.cs new file mode 100644 index 000000000..5856891be --- /dev/null +++ b/src/V3/Stubs/FeedMappingStatus.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_mapping_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_mapping_status.proto + public static partial class FeedMappingStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_mapping_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedMappingStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX21hcHBpbmdf", + "c3RhdHVzLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxoc", + "Z29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJkChVGZWVkTWFwcGluZ1N0", + "YXR1c0VudW0iSwoRRmVlZE1hcHBpbmdTdGF0dXMSDwoLVU5TUEVDSUZJRUQQ", + "ABILCgdVTktOT1dOEAESCwoHRU5BQkxFRBACEgsKB1JFTU9WRUQQA0LrAQoh", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhZGZWVkTWFwcGlu", + "Z1N0YXR1c1Byb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoC", + "HUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedMappingStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedMappingStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedMappingStatusEnum.Types.FeedMappingStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of a feed mapping. + /// + public sealed partial class FeedMappingStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedMappingStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedMappingStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingStatusEnum(FeedMappingStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedMappingStatusEnum Clone() { + return new FeedMappingStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedMappingStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedMappingStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedMappingStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedMappingStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a feed mapping. + /// + public enum FeedMappingStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Feed mapping is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Feed mapping has been removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedOrigin.cs b/src/V3/Stubs/FeedOrigin.cs new file mode 100644 index 000000000..4c2631bfe --- /dev/null +++ b/src/V3/Stubs/FeedOrigin.cs @@ -0,0 +1,187 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_origin.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_origin.proto + public static partial class FeedOriginReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_origin.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedOriginReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX29yaWdpbi5w", + "cm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8iUgoORmVlZE9yaWdpbkVudW0iQAoKRmVl", + "ZE9yaWdpbhIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIICgRVU0VS", + "EAISCgoGR09PR0xFEANC5AEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtc0IPRmVlZE9yaWdpblByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztl", + "bnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygId", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedOriginEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedOriginEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedOriginEnum.Types.FeedOrigin) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible values for a feed origin. + /// + public sealed partial class FeedOriginEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedOriginEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedOriginReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedOriginEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedOriginEnum(FeedOriginEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedOriginEnum Clone() { + return new FeedOriginEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedOriginEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedOriginEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedOriginEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedOriginEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for a feed origin. + /// + public enum FeedOrigin { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The FeedAttributes for this Feed are managed by the + /// user. Users can add FeedAttributes to this Feed. + /// + [pbr::OriginalName("USER")] User = 2, + /// + /// The FeedAttributes for an GOOGLE Feed are created by Google. A feed of + /// this type is maintained by Google and will have the correct attributes + /// for the placeholder type of the feed. + /// + [pbr::OriginalName("GOOGLE")] Google = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedPlaceholderView.cs b/src/V3/Stubs/FeedPlaceholderView.cs new file mode 100644 index 000000000..2e5760fe2 --- /dev/null +++ b/src/V3/Stubs/FeedPlaceholderView.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/feed_placeholder_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/feed_placeholder_view.proto + public static partial class FeedPlaceholderViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/feed_placeholder_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedPlaceholderViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZmVlZF9wbGFj", + "ZWhvbGRlcl92aWV3LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMaNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL3BsYWNl", + "aG9sZGVyX3R5cGUucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3Iu", + "cHJvdG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHGdvb2dsZS9hcGkv", + "YW5ub3RhdGlvbnMucHJvdG8iuwIKE0ZlZWRQbGFjZWhvbGRlclZpZXcSSwoN", + "cmVzb3VyY2VfbmFtZRgBIAEoCUI04EEF+kEuCixnb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vRmVlZFBsYWNlaG9sZGVyVmlldxJhChBwbGFjZWhvbGRlcl90", + "eXBlGAIgASgOMkIuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuUGxh", + "Y2Vob2xkZXJUeXBlRW51bS5QbGFjZWhvbGRlclR5cGVCA+BBAzp06kFxCixn", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vRmVlZFBsYWNlaG9sZGVyVmlldxJB", + "Y3VzdG9tZXJzL3tjdXN0b21lcn0vZmVlZFBsYWNlaG9sZGVyVmlld3Mve2Zl", + "ZWRfcGxhY2Vob2xkZXJfdmlld31ChQIKJWNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5yZXNvdXJjZXNCGEZlZWRQbGFjZWhvbGRlclZpZXdQcm90b1AB", + "Wkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2ds", + "ZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView), global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView.Parser, new[]{ "ResourceName", "PlaceholderType" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A feed placeholder view. + /// + public sealed partial class FeedPlaceholderView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedPlaceholderView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedPlaceholderView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedPlaceholderView(FeedPlaceholderView other) : this() { + resourceName_ = other.resourceName_; + placeholderType_ = other.placeholderType_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedPlaceholderView Clone() { + return new FeedPlaceholderView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the feed placeholder view. + /// Feed placeholder view resource names have the form: + /// + /// `customers/{customer_id}/feedPlaceholderViews/{placeholder_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "placeholder_type" field. + public const int PlaceholderTypeFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType placeholderType_ = 0; + /// + /// Output only. The placeholder type of the feed placeholder view. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType PlaceholderType { + get { return placeholderType_; } + set { + placeholderType_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedPlaceholderView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedPlaceholderView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (PlaceholderType != other.PlaceholderType) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (PlaceholderType != 0) hash ^= PlaceholderType.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (PlaceholderType != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) PlaceholderType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (PlaceholderType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PlaceholderType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedPlaceholderView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.PlaceholderType != 0) { + PlaceholderType = other.PlaceholderType; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 16: { + PlaceholderType = (global::Google.Ads.GoogleAds.V3.Enums.PlaceholderTypeEnum.Types.PlaceholderType) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedPlaceholderViewService.cs b/src/V3/Stubs/FeedPlaceholderViewService.cs new file mode 100644 index 000000000..334d54f7b --- /dev/null +++ b/src/V3/Stubs/FeedPlaceholderViewService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_placeholder_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/feed_placeholder_view_service.proto + public static partial class FeedPlaceholderViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/feed_placeholder_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedPlaceholderViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9mZWVkX3BsYWNl", + "aG9sZGVyX3ZpZXdfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMaPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcy9mZWVkX3BsYWNlaG9sZGVyX3ZpZXcucHJvdG8aHGdvb2dsZS9hcGkv", + "YW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9n", + "b29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvIjsKHUdldEZlZWRQbGFj", + "ZWhvbGRlclZpZXdSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BB", + "AjKdAgoaRmVlZFBsYWNlaG9sZGVyVmlld1NlcnZpY2US4QEKFkdldEZlZWRQ", + "bGFjZWhvbGRlclZpZXcSPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5HZXRGZWVkUGxhY2Vob2xkZXJWaWV3UmVxdWVzdBo2Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5GZWVkUGxhY2Vob2xkZXJWaWV3", + "Ik6C0+STAjgSNi92My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9mZWVk", + "UGxhY2Vob2xkZXJWaWV3cy8qfdpBDXJlc291cmNlX25hbWUaG8pBGGdvb2ds", + "ZWFkcy5nb29nbGVhcGlzLmNvbUKGAgokY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzQh9GZWVkUGxhY2Vob2xkZXJWaWV3U2VydmljZVBy", + "b3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetFeedPlaceholderViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetFeedPlaceholderViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [FeedPlaceholderViewService.GetFeedPlaceholderView][google.ads.googleads.v3.services.FeedPlaceholderViewService.GetFeedPlaceholderView]. + /// + public sealed partial class GetFeedPlaceholderViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetFeedPlaceholderViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedPlaceholderViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedPlaceholderViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedPlaceholderViewRequest(GetFeedPlaceholderViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedPlaceholderViewRequest Clone() { + return new GetFeedPlaceholderViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the feed placeholder view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetFeedPlaceholderViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetFeedPlaceholderViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetFeedPlaceholderViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedPlaceholderViewServiceClient.cs b/src/V3/Stubs/FeedPlaceholderViewServiceClient.cs new file mode 100644 index 000000000..a59fac2e9 --- /dev/null +++ b/src/V3/Stubs/FeedPlaceholderViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class FeedPlaceholderViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static FeedPlaceholderViewServiceSettings GetDefault() => new FeedPlaceholderViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public FeedPlaceholderViewServiceSettings() { } + + private FeedPlaceholderViewServiceSettings(FeedPlaceholderViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetFeedPlaceholderViewSettings = existing.GetFeedPlaceholderViewSettings; + OnCopy(existing); + } + + partial void OnCopy(FeedPlaceholderViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// FeedPlaceholderViewServiceClient.GetFeedPlaceholderView and FeedPlaceholderViewServiceClient.GetFeedPlaceholderViewAsync. + /// + /// + /// The default FeedPlaceholderViewServiceClient.GetFeedPlaceholderView and + /// FeedPlaceholderViewServiceClient.GetFeedPlaceholderViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetFeedPlaceholderViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public FeedPlaceholderViewServiceSettings Clone() => new FeedPlaceholderViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class FeedPlaceholderViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public FeedPlaceholderViewServiceSettings Settings { get; set; } + + /// + public override FeedPlaceholderViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return FeedPlaceholderViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return FeedPlaceholderViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => FeedPlaceholderViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => FeedPlaceholderViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => FeedPlaceholderViewServiceClient.ChannelPool; + } + + /// + /// FeedPlaceholderViewService client wrapper, for convenient use. + /// + public abstract partial class FeedPlaceholderViewServiceClient + { + /// + /// The default endpoint for the FeedPlaceholderViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default FeedPlaceholderViewService scopes. + /// + /// + /// The default FeedPlaceholderViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedPlaceholderViewServiceClient client = await FeedPlaceholderViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedPlaceholderViewServiceClient.DefaultEndpoint.Host, FeedPlaceholderViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedPlaceholderViewServiceClient client = FeedPlaceholderViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, FeedPlaceholderViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedPlaceholderViewServiceClient client = FeedPlaceholderViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedPlaceholderViewServiceClient.DefaultEndpoint.Host, FeedPlaceholderViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedPlaceholderViewServiceClient client = FeedPlaceholderViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static FeedPlaceholderViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, FeedPlaceholderViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedPlaceholderViewServiceClient Create(grpccore::Channel channel, FeedPlaceholderViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedPlaceholderViewServiceClient Create(grpccore::CallInvoker callInvoker, FeedPlaceholderViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + FeedPlaceholderViewService.FeedPlaceholderViewServiceClient grpcClient = new FeedPlaceholderViewService.FeedPlaceholderViewServiceClient(callInvoker); + return new FeedPlaceholderViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC FeedPlaceholderViewService client. + /// + public virtual FeedPlaceholderViewService.FeedPlaceholderViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// + /// Required. The resource name of the feed placeholder view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedPlaceholderViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedPlaceholderViewAsync( + new GetFeedPlaceholderViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// + /// Required. The resource name of the feed placeholder view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedPlaceholderViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetFeedPlaceholderViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// + /// Required. The resource name of the feed placeholder view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::FeedPlaceholderView GetFeedPlaceholderView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedPlaceholderView( + new GetFeedPlaceholderViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedPlaceholderViewAsync( + GetFeedPlaceholderViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedPlaceholderViewAsync( + GetFeedPlaceholderViewRequest request, + st::CancellationToken cancellationToken) => GetFeedPlaceholderViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::FeedPlaceholderView GetFeedPlaceholderView( + GetFeedPlaceholderViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// FeedPlaceholderViewService client wrapper implementation, for convenient use. + /// + public sealed partial class FeedPlaceholderViewServiceClientImpl : FeedPlaceholderViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetFeedPlaceholderView; + + /// + /// Constructs a client wrapper for the FeedPlaceholderViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public FeedPlaceholderViewServiceClientImpl(FeedPlaceholderViewService.FeedPlaceholderViewServiceClient grpcClient, FeedPlaceholderViewServiceSettings settings) + { + GrpcClient = grpcClient; + FeedPlaceholderViewServiceSettings effectiveSettings = settings ?? FeedPlaceholderViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetFeedPlaceholderView = clientHelper.BuildApiCall( + GrpcClient.GetFeedPlaceholderViewAsync, GrpcClient.GetFeedPlaceholderView, effectiveSettings.GetFeedPlaceholderViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetFeedPlaceholderView); + Modify_GetFeedPlaceholderViewApiCall(ref _callGetFeedPlaceholderView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetFeedPlaceholderViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(FeedPlaceholderViewService.FeedPlaceholderViewServiceClient grpcClient, FeedPlaceholderViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC FeedPlaceholderViewService client. + /// + public override FeedPlaceholderViewService.FeedPlaceholderViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetFeedPlaceholderViewRequest(ref GetFeedPlaceholderViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetFeedPlaceholderViewAsync( + GetFeedPlaceholderViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedPlaceholderViewRequest(ref request, ref callSettings); + return _callGetFeedPlaceholderView.Async(request, callSettings); + } + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::FeedPlaceholderView GetFeedPlaceholderView( + GetFeedPlaceholderViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedPlaceholderViewRequest(ref request, ref callSettings); + return _callGetFeedPlaceholderView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/FeedPlaceholderViewServiceGrpc.cs b/src/V3/Stubs/FeedPlaceholderViewServiceGrpc.cs new file mode 100644 index 000000000..478db340c --- /dev/null +++ b/src/V3/Stubs/FeedPlaceholderViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_placeholder_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch feed placeholder views. + /// + public static partial class FeedPlaceholderViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.FeedPlaceholderViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetFeedPlaceholderViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetFeedPlaceholderViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_FeedPlaceholderView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetFeedPlaceholderView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetFeedPlaceholderView", + __Marshaller_google_ads_googleads_v3_services_GetFeedPlaceholderViewRequest, + __Marshaller_google_ads_googleads_v3_resources_FeedPlaceholderView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedPlaceholderViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of FeedPlaceholderViewService + public abstract partial class FeedPlaceholderViewServiceBase + { + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetFeedPlaceholderView(global::Google.Ads.GoogleAds.V3.Services.GetFeedPlaceholderViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for FeedPlaceholderViewService + public partial class FeedPlaceholderViewServiceClient : grpc::ClientBase + { + /// Creates a new client for FeedPlaceholderViewService + /// The channel to use to make remote calls. + public FeedPlaceholderViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for FeedPlaceholderViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public FeedPlaceholderViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected FeedPlaceholderViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected FeedPlaceholderViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView GetFeedPlaceholderView(global::Google.Ads.GoogleAds.V3.Services.GetFeedPlaceholderViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedPlaceholderView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView GetFeedPlaceholderView(global::Google.Ads.GoogleAds.V3.Services.GetFeedPlaceholderViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetFeedPlaceholderView, null, options, request); + } + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedPlaceholderViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedPlaceholderViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedPlaceholderViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed placeholder view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedPlaceholderViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedPlaceholderViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetFeedPlaceholderView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override FeedPlaceholderViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new FeedPlaceholderViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(FeedPlaceholderViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetFeedPlaceholderView, serviceImpl.GetFeedPlaceholderView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, FeedPlaceholderViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetFeedPlaceholderView, serviceImpl.GetFeedPlaceholderView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/FeedService.cs b/src/V3/Stubs/FeedService.cs new file mode 100644 index 000000000..781432a0f --- /dev/null +++ b/src/V3/Stubs/FeedService.cs @@ -0,0 +1,1030 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/feed_service.proto + public static partial class FeedServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/feed_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9mZWVkX3NlcnZp", + "Y2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzGixn", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZmVlZC5wcm90bxoc", + "Z29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGll", + "bnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aIGdv", + "b2dsZS9wcm90b2J1Zi9maWVsZF9tYXNrLnByb3RvGhdnb29nbGUvcnBjL3N0", + "YXR1cy5wcm90byIsCg5HZXRGZWVkUmVxdWVzdBIaCg1yZXNvdXJjZV9uYW1l", + "GAEgASgJQgPgQQIiqAEKEk11dGF0ZUZlZWRzUmVxdWVzdBIYCgtjdXN0b21l", + "cl9pZBgBIAEoCUID4EECEkgKCm9wZXJhdGlvbnMYAiADKAsyLy5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5GZWVkT3BlcmF0aW9uQgPgQQIS", + "FwoPcGFydGlhbF9mYWlsdXJlGAMgASgIEhUKDXZhbGlkYXRlX29ubHkYBCAB", + "KAgi1QEKDUZlZWRPcGVyYXRpb24SLwoLdXBkYXRlX21hc2sYBCABKAsyGi5n", + "b29nbGUucHJvdG9idWYuRmllbGRNYXNrEjkKBmNyZWF0ZRgBIAEoCzInLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5GZWVkSAASOQoGdXBk", + "YXRlGAIgASgLMicuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "LkZlZWRIABIQCgZyZW1vdmUYAyABKAlIAEILCglvcGVyYXRpb24ijQEKE011", + "dGF0ZUZlZWRzUmVzcG9uc2USMQoVcGFydGlhbF9mYWlsdXJlX2Vycm9yGAMg", + "ASgLMhIuZ29vZ2xlLnJwYy5TdGF0dXMSQwoHcmVzdWx0cxgCIAMoCzIyLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUZlZWRSZXN1", + "bHQiKQoQTXV0YXRlRmVlZFJlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJ", + "Mp8DCgtGZWVkU2VydmljZRKlAQoHR2V0RmVlZBIwLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLkdldEZlZWRSZXF1ZXN0GicuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkZlZWQiP4LT5JMCKRInL3YzL3ty", + "ZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2ZlZWRzLyp92kENcmVzb3VyY2Vf", + "bmFtZRLKAQoLTXV0YXRlRmVlZHMSNC5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5NdXRhdGVGZWVkc1JlcXVlc3QaNS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVGZWVkc1Jlc3BvbnNlIk6C0+ST", + "Ai8iKi92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2ZlZWRzOm11dGF0", + "ZToBKtpBFmN1c3RvbWVyX2lkLG9wZXJhdGlvbnMaG8pBGGdvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbUL3AQokY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzQhBGZWVkU2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcu", + "b3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2", + "aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPq", + "AiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3Rv", + "Mw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.FeedReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetFeedRequest), global::Google.Ads.GoogleAds.V3.Services.GetFeedRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateFeedsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.FeedOperation), global::Google.Ads.GoogleAds.V3.Services.FeedOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateFeedsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateFeedResult), global::Google.Ads.GoogleAds.V3.Services.MutateFeedResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [FeedService.GetFeed][google.ads.googleads.v3.services.FeedService.GetFeed]. + /// + public sealed partial class GetFeedRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetFeedRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedRequest(GetFeedRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetFeedRequest Clone() { + return new GetFeedRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the feed to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetFeedRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetFeedRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetFeedRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [FeedService.MutateFeeds][google.ads.googleads.v3.services.FeedService.MutateFeeds]. + /// + public sealed partial class MutateFeedsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedsRequest(MutateFeedsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedsRequest Clone() { + return new MutateFeedsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose feeds are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.FeedOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual feeds. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on an feed. + /// + public sealed partial class FeedOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedOperation(FeedOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedOperation Clone() { + return new FeedOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// FieldMask that determines which resource fields are modified in an update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new feed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Feed Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.Feed) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The feed is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Feed Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.Feed) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed feed is + /// expected, in this format: + /// + /// `customers/{customer_id}/feeds/{feed_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.Feed(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.Feed(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.Feed subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.Feed(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.Feed subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.Feed(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for an feed mutate. + /// + public sealed partial class MutateFeedsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedsResponse(MutateFeedsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedsResponse Clone() { + return new MutateFeedsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateFeedResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the feed mutate. + /// + public sealed partial class MutateFeedResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateFeedResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedResult(MutateFeedResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateFeedResult Clone() { + return new MutateFeedResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateFeedResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateFeedResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateFeedResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FeedServiceClient.cs b/src/V3/Stubs/FeedServiceClient.cs new file mode 100644 index 000000000..ebe0490b4 --- /dev/null +++ b/src/V3/Stubs/FeedServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class FeedServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static FeedServiceSettings GetDefault() => new FeedServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public FeedServiceSettings() { } + + private FeedServiceSettings(FeedServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetFeedSettings = existing.GetFeedSettings; + MutateFeedsSettings = existing.MutateFeedsSettings; + OnCopy(existing); + } + + partial void OnCopy(FeedServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// FeedServiceClient.GetFeed and FeedServiceClient.GetFeedAsync. + /// + /// + /// The default FeedServiceClient.GetFeed and + /// FeedServiceClient.GetFeedAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetFeedSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// FeedServiceClient.MutateFeeds and FeedServiceClient.MutateFeedsAsync. + /// + /// + /// The default FeedServiceClient.MutateFeeds and + /// FeedServiceClient.MutateFeedsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateFeedsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public FeedServiceSettings Clone() => new FeedServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class FeedServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public FeedServiceSettings Settings { get; set; } + + /// + public override FeedServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return FeedServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return FeedServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => FeedServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => FeedServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => FeedServiceClient.ChannelPool; + } + + /// + /// FeedService client wrapper, for convenient use. + /// + public abstract partial class FeedServiceClient + { + /// + /// The default endpoint for the FeedService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default FeedService scopes. + /// + /// + /// The default FeedService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedServiceClient client = await FeedServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedServiceClient.DefaultEndpoint.Host, FeedServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedServiceClient client = FeedServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, FeedServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// FeedServiceClient client = FeedServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// FeedServiceClient.DefaultEndpoint.Host, FeedServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// FeedServiceClient client = FeedServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static FeedServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, FeedServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedServiceClient Create(grpccore::Channel channel, FeedServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static FeedServiceClient Create(grpccore::CallInvoker callInvoker, FeedServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + FeedService.FeedServiceClient grpcClient = new FeedService.FeedServiceClient(callInvoker); + return new FeedServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC FeedService client. + /// + public virtual FeedService.FeedServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested feed in full detail. + /// + /// + /// Required. The resource name of the feed to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeedAsync( + new GetFeedRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed in full detail. + /// + /// + /// Required. The resource name of the feed to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetFeedAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed in full detail. + /// + /// + /// Required. The resource name of the feed to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Feed GetFeed( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetFeed( + new GetFeedRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedAsync( + GetFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetFeedAsync( + GetFeedRequest request, + st::CancellationToken cancellationToken) => GetFeedAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::Feed GetFeed( + GetFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateFeedsAsync( + new MutateFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateFeedsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual feeds. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedsResponse MutateFeeds( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateFeeds( + new MutateFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual feeds. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateFeedsAsync( + new MutateFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual feeds. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateFeedsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose feeds are being modified. + /// + /// + /// Required. The list of operations to perform on individual feeds. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedsResponse MutateFeeds( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateFeeds( + new MutateFeedsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedsAsync( + MutateFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateFeedsAsync( + MutateFeedsRequest request, + st::CancellationToken cancellationToken) => MutateFeedsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateFeedsResponse MutateFeeds( + MutateFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// FeedService client wrapper implementation, for convenient use. + /// + public sealed partial class FeedServiceClientImpl : FeedServiceClient + { + private readonly gaxgrpc::ApiCall _callGetFeed; + private readonly gaxgrpc::ApiCall _callMutateFeeds; + + /// + /// Constructs a client wrapper for the FeedService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public FeedServiceClientImpl(FeedService.FeedServiceClient grpcClient, FeedServiceSettings settings) + { + GrpcClient = grpcClient; + FeedServiceSettings effectiveSettings = settings ?? FeedServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetFeed = clientHelper.BuildApiCall( + GrpcClient.GetFeedAsync, GrpcClient.GetFeed, effectiveSettings.GetFeedSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateFeeds = clientHelper.BuildApiCall( + GrpcClient.MutateFeedsAsync, GrpcClient.MutateFeeds, effectiveSettings.MutateFeedsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetFeed); + Modify_GetFeedApiCall(ref _callGetFeed); + Modify_ApiCall(ref _callMutateFeeds); + Modify_MutateFeedsApiCall(ref _callMutateFeeds); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetFeedApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateFeedsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(FeedService.FeedServiceClient grpcClient, FeedServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC FeedService client. + /// + public override FeedService.FeedServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetFeedRequest(ref GetFeedRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateFeedsRequest(ref MutateFeedsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetFeedAsync( + GetFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedRequest(ref request, ref callSettings); + return _callGetFeed.Async(request, callSettings); + } + + /// + /// Returns the requested feed in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::Feed GetFeed( + GetFeedRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetFeedRequest(ref request, ref callSettings); + return _callGetFeed.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateFeedsAsync( + MutateFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateFeedsRequest(ref request, ref callSettings); + return _callMutateFeeds.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateFeedsResponse MutateFeeds( + MutateFeedsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateFeedsRequest(ref request, ref callSettings); + return _callMutateFeeds.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/FeedServiceGrpc.cs b/src/V3/Stubs/FeedServiceGrpc.cs new file mode 100644 index 000000000..50c92d0dd --- /dev/null +++ b/src/V3/Stubs/FeedServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/feed_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage feeds. + /// + public static partial class FeedService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.FeedService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetFeedRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetFeedRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_Feed = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.Feed.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateFeedsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateFeedsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateFeedsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateFeedsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetFeed = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetFeed", + __Marshaller_google_ads_googleads_v3_services_GetFeedRequest, + __Marshaller_google_ads_googleads_v3_resources_Feed); + + static readonly grpc::Method __Method_MutateFeeds = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateFeeds", + __Marshaller_google_ads_googleads_v3_services_MutateFeedsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateFeedsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.FeedServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of FeedService + public abstract partial class FeedServiceBase + { + /// + /// Returns the requested feed in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetFeed(global::Google.Ads.GoogleAds.V3.Services.GetFeedRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateFeedsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for FeedService + public partial class FeedServiceClient : grpc::ClientBase + { + /// Creates a new client for FeedService + /// The channel to use to make remote calls. + public FeedServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for FeedService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public FeedServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected FeedServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected FeedServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested feed in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Feed GetFeed(global::Google.Ads.GoogleAds.V3.Services.GetFeedRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeed(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.Feed GetFeed(global::Google.Ads.GoogleAds.V3.Services.GetFeedRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetFeed, null, options, request); + } + /// + /// Returns the requested feed in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetFeedAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested feed in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetFeedAsync(global::Google.Ads.GoogleAds.V3.Services.GetFeedRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetFeed, null, options, request); + } + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateFeedsResponse MutateFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateFeedsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateFeeds(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateFeedsResponse MutateFeeds(global::Google.Ads.GoogleAds.V3.Services.MutateFeedsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateFeeds, null, options, request); + } + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateFeedsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateFeedsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateFeedsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes feeds. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateFeedsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateFeedsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateFeeds, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override FeedServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new FeedServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(FeedServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetFeed, serviceImpl.GetFeed) + .AddMethod(__Method_MutateFeeds, serviceImpl.MutateFeeds).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, FeedServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetFeed, serviceImpl.GetFeed); + serviceBinder.AddMethod(__Method_MutateFeeds, serviceImpl.MutateFeeds); + } + + } +} +#endregion diff --git a/src/V3/Stubs/FeedStatus.cs b/src/V3/Stubs/FeedStatus.cs new file mode 100644 index 000000000..02614daeb --- /dev/null +++ b/src/V3/Stubs/FeedStatus.cs @@ -0,0 +1,184 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/feed_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/feed_status.proto + public static partial class FeedStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/feed_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FeedStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mZWVkX3N0YXR1cy5w", + "cm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8iVgoORmVlZFN0YXR1c0VudW0iRAoKRmVl", + "ZFN0YXR1cxIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARILCgdFTkFC", + "TEVEEAISCwoHUkVNT1ZFRBADQuQBCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZW51bXNCD0ZlZWRTdGF0dXNQcm90b1ABWkJnb29nbGUuZ29sYW5n", + "Lm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVt", + "c8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.FeedStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FeedStatusEnum.Types.FeedStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible statuses of a feed. + /// + public sealed partial class FeedStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FeedStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FeedStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedStatusEnum(FeedStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FeedStatusEnum Clone() { + return new FeedStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FeedStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FeedStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FeedStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FeedStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible statuses of a feed. + /// + public enum FeedStatus { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Feed is enabled. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// Feed has been removed. + /// + [pbr::OriginalName("REMOVED")] Removed = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FieldError.cs b/src/V3/Stubs/FieldError.cs new file mode 100644 index 000000000..070f0c384 --- /dev/null +++ b/src/V3/Stubs/FieldError.cs @@ -0,0 +1,207 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/field_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/field_error.proto + public static partial class FieldErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/field_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FieldErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZmllbGRfZXJyb3Iu", + "cHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byLcAQoORmllbGRFcnJvckVudW0iyQEK", + "CkZpZWxkRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESDAoI", + "UkVRVUlSRUQQAhITCg9JTU1VVEFCTEVfRklFTEQQAxIRCg1JTlZBTElEX1ZB", + "TFVFEAQSFwoTVkFMVUVfTVVTVF9CRV9VTlNFVBAFEhoKFlJFUVVJUkVEX05P", + "TkVNUFRZX0xJU1QQBhIbChdGSUVMRF9DQU5OT1RfQkVfQ0xFQVJFRBAHEhUK", + "EUJMQUNLTElTVEVEX1ZBTFVFEAhC6gEKImNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnNCD0ZpZWxkRXJyb3JQcm90b1ABWkRnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "ZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FieldErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FieldErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FieldErrorEnum.Types.FieldError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible field errors. + /// + public sealed partial class FieldErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FieldErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FieldErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldErrorEnum(FieldErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldErrorEnum Clone() { + return new FieldErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FieldErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FieldErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FieldErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FieldErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible field errors. + /// + public enum FieldError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The required field was not present. + /// + [pbr::OriginalName("REQUIRED")] Required = 2, + /// + /// The field attempted to be mutated is immutable. + /// + [pbr::OriginalName("IMMUTABLE_FIELD")] ImmutableField = 3, + /// + /// The field's value is invalid. + /// + [pbr::OriginalName("INVALID_VALUE")] InvalidValue = 4, + /// + /// The field cannot be set. + /// + [pbr::OriginalName("VALUE_MUST_BE_UNSET")] ValueMustBeUnset = 5, + /// + /// The required repeated field was empty. + /// + [pbr::OriginalName("REQUIRED_NONEMPTY_LIST")] RequiredNonemptyList = 6, + /// + /// The field cannot be cleared. + /// + [pbr::OriginalName("FIELD_CANNOT_BE_CLEARED")] FieldCannotBeCleared = 7, + /// + /// The field's value is on a blacklist for this field. + /// + [pbr::OriginalName("BLACKLISTED_VALUE")] BlacklistedValue = 8, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FieldMaskError.cs b/src/V3/Stubs/FieldMaskError.cs new file mode 100644 index 000000000..9f752720c --- /dev/null +++ b/src/V3/Stubs/FieldMaskError.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/field_mask_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/field_mask_error.proto + public static partial class FieldMaskErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/field_mask_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FieldMaskErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZmllbGRfbWFza19l", + "cnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIqcBChJGaWVsZE1hc2tFcnJv", + "ckVudW0ikAEKDkZpZWxkTWFza0Vycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoH", + "VU5LTk9XThABEhYKEkZJRUxEX01BU0tfTUlTU0lORxAFEhoKFkZJRUxEX01B", + "U0tfTk9UX0FMTE9XRUQQBBITCg9GSUVMRF9OT1RfRk9VTkQQAhIXChNGSUVM", + "RF9IQVNfU1VCRklFTERTEANC7gEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lcnJvcnNCE0ZpZWxkTWFza0Vycm9yUHJvdG9QAVpEZ29vZ2xlLmdv", + "bGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3Yz", + "L2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5W", + "My5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJH", + "b29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FieldMaskErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FieldMaskErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FieldMaskErrorEnum.Types.FieldMaskError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible field mask errors. + /// + public sealed partial class FieldMaskErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FieldMaskErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FieldMaskErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldMaskErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldMaskErrorEnum(FieldMaskErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FieldMaskErrorEnum Clone() { + return new FieldMaskErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FieldMaskErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FieldMaskErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FieldMaskErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FieldMaskErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible field mask errors. + /// + public enum FieldMaskError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The field mask must be provided for update operations. + /// + [pbr::OriginalName("FIELD_MASK_MISSING")] FieldMaskMissing = 5, + /// + /// The field mask must be empty for create and remove operations. + /// + [pbr::OriginalName("FIELD_MASK_NOT_ALLOWED")] FieldMaskNotAllowed = 4, + /// + /// The field mask contained an invalid field. + /// + [pbr::OriginalName("FIELD_NOT_FOUND")] FieldNotFound = 2, + /// + /// The field mask updated a field with subfields. Fields with subfields may + /// be cleared, but not updated. To fix this, the field mask should select + /// all the subfields of the invalid field. + /// + [pbr::OriginalName("FIELD_HAS_SUBFIELDS")] FieldHasSubfields = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FinalAppUrl.cs b/src/V3/Stubs/FinalAppUrl.cs new file mode 100644 index 000000000..d64d41ae8 --- /dev/null +++ b/src/V3/Stubs/FinalAppUrl.cs @@ -0,0 +1,233 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/final_app_url.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/final_app_url.proto + public static partial class FinalAppUrlReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/final_app_url.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FinalAppUrlReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZmluYWxfYXBwX3Vy", + "bC5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uGkFnb29n", + "bGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9hcHBfdXJsX29wZXJhdGluZ19z", + "eXN0ZW1fdHlwZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnBy", + "b3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIqEBCgtGaW5hbEFw", + "cFVybBJnCgdvc190eXBlGAEgASgOMlYuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZW51bXMuQXBwVXJsT3BlcmF0aW5nU3lzdGVtVHlwZUVudW0uQXBwVXJs", + "T3BlcmF0aW5nU3lzdGVtVHlwZRIpCgN1cmwYAiABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWVC6wEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5jb21tb25CEEZpbmFsQXBwVXJsUHJvdG9QAVpEZ29vZ2xlLmdvbGFu", + "Zy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Nv", + "bW1vbjtjb21tb26iAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5D", + "b21tb27KAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xDb21tb27qAiJHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6Q29tbW9uYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.AppUrlOperatingSystemTypeReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.FinalAppUrl), global::Google.Ads.GoogleAds.V3.Common.FinalAppUrl.Parser, new[]{ "OsType", "Url" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A URL for deep linking into an app for the given operating system. + /// + public sealed partial class FinalAppUrl : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FinalAppUrl()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.FinalAppUrlReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FinalAppUrl() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FinalAppUrl(FinalAppUrl other) : this() { + osType_ = other.osType_; + Url = other.Url; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FinalAppUrl Clone() { + return new FinalAppUrl(this); + } + + /// Field number for the "os_type" field. + public const int OsTypeFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.AppUrlOperatingSystemTypeEnum.Types.AppUrlOperatingSystemType osType_ = 0; + /// + /// The operating system targeted by this URL. Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.AppUrlOperatingSystemTypeEnum.Types.AppUrlOperatingSystemType OsType { + get { return osType_; } + set { + osType_ = value; + } + } + + /// Field number for the "url" field. + public const int UrlFieldNumber = 2; + private static readonly pb::FieldCodec _single_url_codec = pb::FieldCodec.ForClassWrapper(18); + private string url_; + /// + /// The app deep link URL. Deep links specify a location in an app that + /// corresponds to the content you'd like to show, and should be of the form + /// {scheme}://{host_path} + /// The scheme identifies which app to open. For your app, you can use a custom + /// scheme that starts with the app's name. The host and path specify the + /// unique location in the app where your content exists. + /// Example: "exampleapp://productid_1234". Required. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Url { + get { return url_; } + set { + url_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FinalAppUrl); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FinalAppUrl other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (OsType != other.OsType) return false; + if (Url != other.Url) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (OsType != 0) hash ^= OsType.GetHashCode(); + if (url_ != null) hash ^= Url.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (OsType != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) OsType); + } + if (url_ != null) { + _single_url_codec.WriteTagAndValue(output, Url); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (OsType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) OsType); + } + if (url_ != null) { + size += _single_url_codec.CalculateSizeWithTag(Url); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FinalAppUrl other) { + if (other == null) { + return; + } + if (other.OsType != 0) { + OsType = other.OsType; + } + if (other.url_ != null) { + if (url_ == null || other.Url != "") { + Url = other.Url; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + OsType = (global::Google.Ads.GoogleAds.V3.Enums.AppUrlOperatingSystemTypeEnum.Types.AppUrlOperatingSystemType) input.ReadEnum(); + break; + } + case 18: { + string value = _single_url_codec.Read(input); + if (url_ == null || value != "") { + Url = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FlightPlaceholderField.cs b/src/V3/Stubs/FlightPlaceholderField.cs new file mode 100644 index 000000000..28667264f --- /dev/null +++ b/src/V3/Stubs/FlightPlaceholderField.cs @@ -0,0 +1,276 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/flight_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/flight_placeholder_field.proto + public static partial class FlightPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/flight_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FlightPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mbGlnaHRfcGxhY2Vo", + "b2xkZXJfZmllbGQucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIrIDChpGbGlnaHRQ", + "bGFjZWhvbGRlckZpZWxkRW51bSKTAwoWRmxpZ2h0UGxhY2Vob2xkZXJGaWVs", + "ZBIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARISCg5ERVNUSU5BVElP", + "Tl9JRBACEg0KCU9SSUdJTl9JRBADEhYKEkZMSUdIVF9ERVNDUklQVElPThAE", + "Eg8KC09SSUdJTl9OQU1FEAUSFAoQREVTVElOQVRJT05fTkFNRRAGEhAKDEZM", + "SUdIVF9QUklDRRAHEhMKD0ZPUk1BVFRFRF9QUklDRRAIEhUKEUZMSUdIVF9T", + "QUxFX1BSSUNFEAkSGAoURk9STUFUVEVEX1NBTEVfUFJJQ0UQChINCglJTUFH", + "RV9VUkwQCxIOCgpGSU5BTF9VUkxTEAwSFQoRRklOQUxfTU9CSUxFX1VSTFMQ", + "DRIQCgxUUkFDS0lOR19VUkwQDhIUChBBTkRST0lEX0FQUF9MSU5LEA8SGwoX", + "U0lNSUxBUl9ERVNUSU5BVElPTl9JRFMQEBIQCgxJT1NfQVBQX0xJTksQERIU", + "ChBJT1NfQVBQX1NUT1JFX0lEEBJC8QEKIWNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lbnVtc0IcRmxpZ2h0c1BsYWNlaG9sZGVyRmllbGRQcm90b1AB", + "WkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVu", + "dW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldEnum.Types.FlightPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Flight placeholder fields. + /// For more information about dynamic remarketing feeds, see + /// https://support.google.com/google-ads/answer/6053288. + /// + public sealed partial class FlightPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FlightPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FlightPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FlightPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FlightPlaceholderFieldEnum(FlightPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FlightPlaceholderFieldEnum Clone() { + return new FlightPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FlightPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FlightPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FlightPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FlightPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Flight placeholder fields. + /// + public enum FlightPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: STRING. Required. Destination id. Example: PAR, LON. + /// For feed items that only have destination id, destination id must be a + /// unique key. For feed items that have both destination id and origin id, + /// then the combination must be a unique key. + /// + [pbr::OriginalName("DESTINATION_ID")] DestinationId = 2, + /// + /// Data Type: STRING. Origin id. Example: PAR, LON. + /// Optional. Combination of destination id and origin id must be unique per + /// offer. + /// + [pbr::OriginalName("ORIGIN_ID")] OriginId = 3, + /// + /// Data Type: STRING. Required. Main headline with product name to be shown + /// in dynamic ad. + /// + [pbr::OriginalName("FLIGHT_DESCRIPTION")] FlightDescription = 4, + /// + /// Data Type: STRING. Shorter names are recommended. + /// + [pbr::OriginalName("ORIGIN_NAME")] OriginName = 5, + /// + /// Data Type: STRING. Shorter names are recommended. + /// + [pbr::OriginalName("DESTINATION_NAME")] DestinationName = 6, + /// + /// Data Type: STRING. Price to be shown in the ad. + /// Example: "100.00 USD" + /// + [pbr::OriginalName("FLIGHT_PRICE")] FlightPrice = 7, + /// + /// Data Type: STRING. Formatted price to be shown in the ad. + /// Example: "Starting at $100.00 USD", "$80 - $100" + /// + [pbr::OriginalName("FORMATTED_PRICE")] FormattedPrice = 8, + /// + /// Data Type: STRING. Sale price to be shown in the ad. + /// Example: "80.00 USD" + /// + [pbr::OriginalName("FLIGHT_SALE_PRICE")] FlightSalePrice = 9, + /// + /// Data Type: STRING. Formatted sale price to be shown in the ad. + /// Example: "On sale for $80.00", "$60 - $80" + /// + [pbr::OriginalName("FORMATTED_SALE_PRICE")] FormattedSalePrice = 10, + /// + /// Data Type: URL. Image to be displayed in the ad. + /// + [pbr::OriginalName("IMAGE_URL")] ImageUrl = 11, + /// + /// Data Type: URL_LIST. Required. Final URLs for the ad when using Upgraded + /// URLs. User will be redirected to these URLs when they click on an ad, or + /// when they click on a specific flight for ads that show multiple + /// flights. + /// + [pbr::OriginalName("FINAL_URLS")] FinalUrls = 12, + /// + /// Data Type: URL_LIST. Final mobile URLs for the ad when using Upgraded + /// URLs. + /// + [pbr::OriginalName("FINAL_MOBILE_URLS")] FinalMobileUrls = 13, + /// + /// Data Type: URL. Tracking template for the ad when using Upgraded URLs. + /// + [pbr::OriginalName("TRACKING_URL")] TrackingUrl = 14, + /// + /// Data Type: STRING. Android app link. Must be formatted as: + /// android-app://{package_id}/{scheme}/{host_path}. + /// The components are defined as follows: + /// package_id: app ID as specified in Google Play. + /// scheme: the scheme to pass to the application. Can be HTTP, or a custom + /// scheme. + /// host_path: identifies the specific content within your application. + /// + [pbr::OriginalName("ANDROID_APP_LINK")] AndroidAppLink = 15, + /// + /// Data Type: STRING_LIST. List of recommended destination IDs to show + /// together with this item. + /// + [pbr::OriginalName("SIMILAR_DESTINATION_IDS")] SimilarDestinationIds = 16, + /// + /// Data Type: STRING. iOS app link. + /// + [pbr::OriginalName("IOS_APP_LINK")] IosAppLink = 17, + /// + /// Data Type: INT64. iOS app store ID. + /// + [pbr::OriginalName("IOS_APP_STORE_ID")] IosAppStoreId = 18, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FrequencyCap.cs b/src/V3/Stubs/FrequencyCap.cs new file mode 100644 index 000000000..22d6821d2 --- /dev/null +++ b/src/V3/Stubs/FrequencyCap.cs @@ -0,0 +1,482 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/frequency_cap.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/frequency_cap.proto + public static partial class FrequencyCapReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/frequency_cap.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FrequencyCapReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZnJlcXVlbmN5X2Nh", + "cC5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uGjxnb29n", + "bGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mcmVxdWVuY3lfY2FwX2V2ZW50", + "X3R5cGUucHJvdG8aN2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2Zy", + "ZXF1ZW5jeV9jYXBfbGV2ZWwucHJvdG8aO2dvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL2VudW1zL2ZyZXF1ZW5jeV9jYXBfdGltZV91bml0LnByb3RvGh5nb29n", + "bGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3Rh", + "dGlvbnMucHJvdG8iewoRRnJlcXVlbmN5Q2FwRW50cnkSPAoDa2V5GAEgASgL", + "Mi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9uLkZyZXF1ZW5jeUNh", + "cEtleRIoCgNjYXAYAiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50MzJWYWx1", + "ZSLfAgoPRnJlcXVlbmN5Q2FwS2V5ElUKBWxldmVsGAEgASgOMkYuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXMuRnJlcXVlbmN5Q2FwTGV2ZWxFbnVt", + "LkZyZXF1ZW5jeUNhcExldmVsEmIKCmV2ZW50X3R5cGUYAyABKA4yTi5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5GcmVxdWVuY3lDYXBFdmVudFR5", + "cGVFbnVtLkZyZXF1ZW5jeUNhcEV2ZW50VHlwZRJfCgl0aW1lX3VuaXQYAiAB", + "KA4yTC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5GcmVxdWVuY3lD", + "YXBUaW1lVW5pdEVudW0uRnJlcXVlbmN5Q2FwVGltZVVuaXQSMAoLdGltZV9s", + "ZW5ndGgYBCABKAsyGy5nb29nbGUucHJvdG9idWYuSW50MzJWYWx1ZULsAQoi", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbkIRRnJlcXVlbmN5", + "Q2FwUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbjtjb21tb26iAgNHQUGqAh5H", + "b29nbGUuQWRzLkdvb2dsZUFkcy5WMy5Db21tb27KAh5Hb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xDb21tb27qAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6Q29tbW9uYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapEventTypeReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapLevelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapTimeUnitReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.FrequencyCapEntry), global::Google.Ads.GoogleAds.V3.Common.FrequencyCapEntry.Parser, new[]{ "Key", "Cap" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.FrequencyCapKey), global::Google.Ads.GoogleAds.V3.Common.FrequencyCapKey.Parser, new[]{ "Level", "EventType", "TimeUnit", "TimeLength" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A rule specifying the maximum number of times an ad (or some set of ads) can + /// be shown to a user over a particular time period. + /// + public sealed partial class FrequencyCapEntry : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FrequencyCapEntry()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.FrequencyCapReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapEntry() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapEntry(FrequencyCapEntry other) : this() { + key_ = other.key_ != null ? other.key_.Clone() : null; + Cap = other.Cap; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapEntry Clone() { + return new FrequencyCapEntry(this); + } + + /// Field number for the "key" field. + public const int KeyFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Common.FrequencyCapKey key_; + /// + /// The key of a particular frequency cap. There can be no more + /// than one frequency cap with the same key. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.FrequencyCapKey Key { + get { return key_; } + set { + key_ = value; + } + } + + /// Field number for the "cap" field. + public const int CapFieldNumber = 2; + private static readonly pb::FieldCodec _single_cap_codec = pb::FieldCodec.ForStructWrapper(18); + private int? cap_; + /// + /// Maximum number of events allowed during the time range by this cap. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int? Cap { + get { return cap_; } + set { + cap_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FrequencyCapEntry); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FrequencyCapEntry other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(Key, other.Key)) return false; + if (Cap != other.Cap) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (key_ != null) hash ^= Key.GetHashCode(); + if (cap_ != null) hash ^= Cap.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (key_ != null) { + output.WriteRawTag(10); + output.WriteMessage(Key); + } + if (cap_ != null) { + _single_cap_codec.WriteTagAndValue(output, Cap); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (key_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Key); + } + if (cap_ != null) { + size += _single_cap_codec.CalculateSizeWithTag(Cap); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FrequencyCapEntry other) { + if (other == null) { + return; + } + if (other.key_ != null) { + if (key_ == null) { + Key = new global::Google.Ads.GoogleAds.V3.Common.FrequencyCapKey(); + } + Key.MergeFrom(other.Key); + } + if (other.cap_ != null) { + if (cap_ == null || other.Cap != 0) { + Cap = other.Cap; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (key_ == null) { + Key = new global::Google.Ads.GoogleAds.V3.Common.FrequencyCapKey(); + } + input.ReadMessage(Key); + break; + } + case 18: { + int? value = _single_cap_codec.Read(input); + if (cap_ == null || value != 0) { + Cap = value; + } + break; + } + } + } + } + + } + + /// + /// A group of fields used as keys for a frequency cap. + /// There can be no more than one frequency cap with the same key. + /// + public sealed partial class FrequencyCapKey : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FrequencyCapKey()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.FrequencyCapReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapKey() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapKey(FrequencyCapKey other) : this() { + level_ = other.level_; + eventType_ = other.eventType_; + timeUnit_ = other.timeUnit_; + TimeLength = other.TimeLength; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapKey Clone() { + return new FrequencyCapKey(this); + } + + /// Field number for the "level" field. + public const int LevelFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapLevelEnum.Types.FrequencyCapLevel level_ = 0; + /// + /// The level on which the cap is to be applied (e.g. ad group ad, ad group). + /// The cap is applied to all the entities of this level. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapLevelEnum.Types.FrequencyCapLevel Level { + get { return level_; } + set { + level_ = value; + } + } + + /// Field number for the "event_type" field. + public const int EventTypeFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapEventTypeEnum.Types.FrequencyCapEventType eventType_ = 0; + /// + /// The type of event that the cap applies to (e.g. impression). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapEventTypeEnum.Types.FrequencyCapEventType EventType { + get { return eventType_; } + set { + eventType_ = value; + } + } + + /// Field number for the "time_unit" field. + public const int TimeUnitFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapTimeUnitEnum.Types.FrequencyCapTimeUnit timeUnit_ = 0; + /// + /// Unit of time the cap is defined at (e.g. day, week). + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapTimeUnitEnum.Types.FrequencyCapTimeUnit TimeUnit { + get { return timeUnit_; } + set { + timeUnit_ = value; + } + } + + /// Field number for the "time_length" field. + public const int TimeLengthFieldNumber = 4; + private static readonly pb::FieldCodec _single_timeLength_codec = pb::FieldCodec.ForStructWrapper(34); + private int? timeLength_; + /// + /// Number of time units the cap lasts. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int? TimeLength { + get { return timeLength_; } + set { + timeLength_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FrequencyCapKey); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FrequencyCapKey other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Level != other.Level) return false; + if (EventType != other.EventType) return false; + if (TimeUnit != other.TimeUnit) return false; + if (TimeLength != other.TimeLength) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Level != 0) hash ^= Level.GetHashCode(); + if (EventType != 0) hash ^= EventType.GetHashCode(); + if (TimeUnit != 0) hash ^= TimeUnit.GetHashCode(); + if (timeLength_ != null) hash ^= TimeLength.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Level != 0) { + output.WriteRawTag(8); + output.WriteEnum((int) Level); + } + if (TimeUnit != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) TimeUnit); + } + if (EventType != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) EventType); + } + if (timeLength_ != null) { + _single_timeLength_codec.WriteTagAndValue(output, TimeLength); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Level != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Level); + } + if (EventType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) EventType); + } + if (TimeUnit != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) TimeUnit); + } + if (timeLength_ != null) { + size += _single_timeLength_codec.CalculateSizeWithTag(TimeLength); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FrequencyCapKey other) { + if (other == null) { + return; + } + if (other.Level != 0) { + Level = other.Level; + } + if (other.EventType != 0) { + EventType = other.EventType; + } + if (other.TimeUnit != 0) { + TimeUnit = other.TimeUnit; + } + if (other.timeLength_ != null) { + if (timeLength_ == null || other.TimeLength != 0) { + TimeLength = other.TimeLength; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Level = (global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapLevelEnum.Types.FrequencyCapLevel) input.ReadEnum(); + break; + } + case 16: { + TimeUnit = (global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapTimeUnitEnum.Types.FrequencyCapTimeUnit) input.ReadEnum(); + break; + } + case 24: { + EventType = (global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapEventTypeEnum.Types.FrequencyCapEventType) input.ReadEnum(); + break; + } + case 34: { + int? value = _single_timeLength_codec.Read(input); + if (timeLength_ == null || value != 0) { + TimeLength = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FrequencyCapEventType.cs b/src/V3/Stubs/FrequencyCapEventType.cs new file mode 100644 index 000000000..b1fd5f754 --- /dev/null +++ b/src/V3/Stubs/FrequencyCapEventType.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/frequency_cap_event_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/frequency_cap_event_type.proto + public static partial class FrequencyCapEventTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/frequency_cap_event_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FrequencyCapEventTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mcmVxdWVuY3lfY2Fw", + "X2V2ZW50X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVu", + "dW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvInIKGUZyZXF1ZW5j", + "eUNhcEV2ZW50VHlwZUVudW0iVQoVRnJlcXVlbmN5Q2FwRXZlbnRUeXBlEg8K", + "C1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEg4KCklNUFJFU1NJT04QAhIO", + "CgpWSURFT19WSUVXEANC7wEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtc0IaRnJlcXVlbmN5Q2FwRXZlbnRUeXBlUHJvdG9QAVpCZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMu", + "VjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdv", + "b2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapEventTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapEventTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapEventTypeEnum.Types.FrequencyCapEventType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the type of event that the cap applies to. + /// + public sealed partial class FrequencyCapEventTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FrequencyCapEventTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapEventTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapEventTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapEventTypeEnum(FrequencyCapEventTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapEventTypeEnum Clone() { + return new FrequencyCapEventTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FrequencyCapEventTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FrequencyCapEventTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FrequencyCapEventTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FrequencyCapEventTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The type of event that the cap applies to (e.g. impression). + /// + public enum FrequencyCapEventType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The cap applies on ad impressions. + /// + [pbr::OriginalName("IMPRESSION")] Impression = 2, + /// + /// The cap applies on video ad views. + /// + [pbr::OriginalName("VIDEO_VIEW")] VideoView = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FrequencyCapLevel.cs b/src/V3/Stubs/FrequencyCapLevel.cs new file mode 100644 index 000000000..cd6076997 --- /dev/null +++ b/src/V3/Stubs/FrequencyCapLevel.cs @@ -0,0 +1,190 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/frequency_cap_level.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/frequency_cap_level.proto + public static partial class FrequencyCapLevelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/frequency_cap_level.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FrequencyCapLevelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mcmVxdWVuY3lfY2Fw", + "X2xldmVsLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxoc", + "Z29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJ3ChVGcmVxdWVuY3lDYXBM", + "ZXZlbEVudW0iXgoRRnJlcXVlbmN5Q2FwTGV2ZWwSDwoLVU5TUEVDSUZJRUQQ", + "ABILCgdVTktOT1dOEAESDwoLQURfR1JPVVBfQUQQAhIMCghBRF9HUk9VUBAD", + "EgwKCENBTVBBSUdOEARC6wEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtc0IWRnJlcXVlbmN5Q2FwTGV2ZWxQcm90b1ABWkJnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "ZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5F", + "bnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xl", + "OjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapLevelEnum), global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapLevelEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapLevelEnum.Types.FrequencyCapLevel) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the level on which the cap is to be applied. + /// + public sealed partial class FrequencyCapLevelEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FrequencyCapLevelEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapLevelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapLevelEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapLevelEnum(FrequencyCapLevelEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapLevelEnum Clone() { + return new FrequencyCapLevelEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FrequencyCapLevelEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FrequencyCapLevelEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FrequencyCapLevelEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FrequencyCapLevelEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The level on which the cap is to be applied (e.g ad group ad, ad group). + /// Cap is applied to all the resources of this level. + /// + public enum FrequencyCapLevel { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The cap is applied at the ad group ad level. + /// + [pbr::OriginalName("AD_GROUP_AD")] AdGroupAd = 2, + /// + /// The cap is applied at the ad group level. + /// + [pbr::OriginalName("AD_GROUP")] AdGroup = 3, + /// + /// The cap is applied at the campaign level. + /// + [pbr::OriginalName("CAMPAIGN")] Campaign = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FrequencyCapTimeUnit.cs b/src/V3/Stubs/FrequencyCapTimeUnit.cs new file mode 100644 index 000000000..2a6e4dc93 --- /dev/null +++ b/src/V3/Stubs/FrequencyCapTimeUnit.cs @@ -0,0 +1,189 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/frequency_cap_time_unit.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/frequency_cap_time_unit.proto + public static partial class FrequencyCapTimeUnitReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/frequency_cap_time_unit.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FrequencyCapTimeUnitReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9mcmVxdWVuY3lfY2Fw", + "X3RpbWVfdW5pdC5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ibgoYRnJlcXVlbmN5", + "Q2FwVGltZVVuaXRFbnVtIlIKFEZyZXF1ZW5jeUNhcFRpbWVVbml0Eg8KC1VO", + "U1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgcKA0RBWRACEggKBFdFRUsQAxIJ", + "CgVNT05USBAEQu4BCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXNCGUZyZXF1ZW5jeUNhcFRpbWVVbml0UHJvdG9QAVpCZ29vZ2xlLmdvbGFu", + "Zy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vu", + "dW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51", + "bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapTimeUnitEnum), global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapTimeUnitEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapTimeUnitEnum.Types.FrequencyCapTimeUnit) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the unit of time the cap is defined at. + /// + public sealed partial class FrequencyCapTimeUnitEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FrequencyCapTimeUnitEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.FrequencyCapTimeUnitReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapTimeUnitEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapTimeUnitEnum(FrequencyCapTimeUnitEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FrequencyCapTimeUnitEnum Clone() { + return new FrequencyCapTimeUnitEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FrequencyCapTimeUnitEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FrequencyCapTimeUnitEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FrequencyCapTimeUnitEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FrequencyCapTimeUnitEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Unit of time the cap is defined at (e.g. day, week). + /// + public enum FrequencyCapTimeUnit { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The cap would define limit per one day. + /// + [pbr::OriginalName("DAY")] Day = 2, + /// + /// The cap would define limit per one week. + /// + [pbr::OriginalName("WEEK")] Week = 3, + /// + /// The cap would define limit per one month. + /// + [pbr::OriginalName("MONTH")] Month = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FunctionError.cs b/src/V3/Stubs/FunctionError.cs new file mode 100644 index 000000000..dc8569aac --- /dev/null +++ b/src/V3/Stubs/FunctionError.cs @@ -0,0 +1,252 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/function_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/function_error.proto + public static partial class FunctionErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/function_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FunctionErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZnVuY3Rpb25fZXJy", + "b3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLBBAoRRnVuY3Rpb25FcnJvckVu", + "dW0iqwQKDUZ1bmN0aW9uRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktO", + "T1dOEAESGwoXSU5WQUxJRF9GVU5DVElPTl9GT1JNQVQQAhIWChJEQVRBX1RZ", + "UEVfTUlTTUFUQ0gQAxIgChxJTlZBTElEX0NPTkpVTkNUSU9OX09QRVJBTkRT", + "EAQSHgoaSU5WQUxJRF9OVU1CRVJfT0ZfT1BFUkFORFMQBRIYChRJTlZBTElE", + "X09QRVJBTkRfVFlQRRAGEhQKEElOVkFMSURfT1BFUkFUT1IQBxIgChxJTlZB", + "TElEX1JFUVVFU1RfQ09OVEVYVF9UWVBFEAgSKQolSU5WQUxJRF9GVU5DVElP", + "Tl9GT1JfQ0FMTF9QTEFDRUhPTERFUhAJEiQKIElOVkFMSURfRlVOQ1RJT05f", + "Rk9SX1BMQUNFSE9MREVSEAoSEwoPSU5WQUxJRF9PUEVSQU5EEAsSIgoeTUlT", + "U0lOR19DT05TVEFOVF9PUEVSQU5EX1ZBTFVFEAwSIgoeSU5WQUxJRF9DT05T", + "VEFOVF9PUEVSQU5EX1ZBTFVFEA0SEwoPSU5WQUxJRF9ORVNUSU5HEA4SIwof", + "TVVMVElQTEVfRkVFRF9JRFNfTk9UX1NVUFBPUlRFRBAPEi8KK0lOVkFMSURf", + "RlVOQ1RJT05fRk9SX0ZFRURfV0lUSF9GSVhFRF9TQ0hFTUEQEBIaChZJTlZB", + "TElEX0FUVFJJQlVURV9OQU1FEBFC7QEKImNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5lcnJvcnNCEkZ1bmN0aW9uRXJyb3JQcm90b1ABWkRnb29nbGUu", + "Z29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMv", + "djMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oC", + "Ikdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FunctionErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FunctionErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FunctionErrorEnum.Types.FunctionError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible function errors. + /// + public sealed partial class FunctionErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FunctionErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FunctionErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FunctionErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FunctionErrorEnum(FunctionErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FunctionErrorEnum Clone() { + return new FunctionErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FunctionErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FunctionErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FunctionErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FunctionErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible function errors. + /// + public enum FunctionError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The format of the function is not recognized as a supported function + /// format. + /// + [pbr::OriginalName("INVALID_FUNCTION_FORMAT")] InvalidFunctionFormat = 2, + /// + /// Operand data types do not match. + /// + [pbr::OriginalName("DATA_TYPE_MISMATCH")] DataTypeMismatch = 3, + /// + /// The operands cannot be used together in a conjunction. + /// + [pbr::OriginalName("INVALID_CONJUNCTION_OPERANDS")] InvalidConjunctionOperands = 4, + /// + /// Invalid numer of Operands. + /// + [pbr::OriginalName("INVALID_NUMBER_OF_OPERANDS")] InvalidNumberOfOperands = 5, + /// + /// Operand Type not supported. + /// + [pbr::OriginalName("INVALID_OPERAND_TYPE")] InvalidOperandType = 6, + /// + /// Operator not supported. + /// + [pbr::OriginalName("INVALID_OPERATOR")] InvalidOperator = 7, + /// + /// Request context type not supported. + /// + [pbr::OriginalName("INVALID_REQUEST_CONTEXT_TYPE")] InvalidRequestContextType = 8, + /// + /// The matching function is not allowed for call placeholders + /// + [pbr::OriginalName("INVALID_FUNCTION_FOR_CALL_PLACEHOLDER")] InvalidFunctionForCallPlaceholder = 9, + /// + /// The matching function is not allowed for the specified placeholder + /// + [pbr::OriginalName("INVALID_FUNCTION_FOR_PLACEHOLDER")] InvalidFunctionForPlaceholder = 10, + /// + /// Invalid operand. + /// + [pbr::OriginalName("INVALID_OPERAND")] InvalidOperand = 11, + /// + /// Missing value for the constant operand. + /// + [pbr::OriginalName("MISSING_CONSTANT_OPERAND_VALUE")] MissingConstantOperandValue = 12, + /// + /// The value of the constant operand is invalid. + /// + [pbr::OriginalName("INVALID_CONSTANT_OPERAND_VALUE")] InvalidConstantOperandValue = 13, + /// + /// Invalid function nesting. + /// + [pbr::OriginalName("INVALID_NESTING")] InvalidNesting = 14, + /// + /// The Feed ID was different from another Feed ID in the same function. + /// + [pbr::OriginalName("MULTIPLE_FEED_IDS_NOT_SUPPORTED")] MultipleFeedIdsNotSupported = 15, + /// + /// The matching function is invalid for use with a feed with a fixed schema. + /// + [pbr::OriginalName("INVALID_FUNCTION_FOR_FEED_WITH_FIXED_SCHEMA")] InvalidFunctionForFeedWithFixedSchema = 16, + /// + /// Invalid attribute name. + /// + [pbr::OriginalName("INVALID_ATTRIBUTE_NAME")] InvalidAttributeName = 17, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/FunctionParsingError.cs b/src/V3/Stubs/FunctionParsingError.cs new file mode 100644 index 000000000..57cb2cf1b --- /dev/null +++ b/src/V3/Stubs/FunctionParsingError.cs @@ -0,0 +1,228 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/function_parsing_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/function_parsing_error.proto + public static partial class FunctionParsingErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/function_parsing_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static FunctionParsingErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZnVuY3Rpb25fcGFy", + "c2luZ19lcnJvci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJy", + "b3JzGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIoIDChhGdW5jdGlv", + "blBhcnNpbmdFcnJvckVudW0i5QIKFEZ1bmN0aW9uUGFyc2luZ0Vycm9yEg8K", + "C1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhEKDU5PX01PUkVfSU5QVVQQ", + "AhIWChJFWFBFQ1RFRF9DSEFSQUNURVIQAxIYChRVTkVYUEVDVEVEX1NFUEFS", + "QVRPUhAEEhoKFlVOTUFUQ0hFRF9MRUZUX0JSQUNLRVQQBRIbChdVTk1BVENI", + "RURfUklHSFRfQlJBQ0tFVBAGEh0KGVRPT19NQU5ZX05FU1RFRF9GVU5DVElP", + "TlMQBxIeChpNSVNTSU5HX1JJR0hUX0hBTkRfT1BFUkFORBAIEhkKFUlOVkFM", + "SURfT1BFUkFUT1JfTkFNRRAJEi8KK0ZFRURfQVRUUklCVVRFX09QRVJBTkRf", + "QVJHVU1FTlRfTk9UX0lOVEVHRVIQChIPCgtOT19PUEVSQU5EUxALEhUKEVRP", + "T19NQU5ZX09QRVJBTkRTEAxC9AEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5lcnJvcnNCGUZ1bmN0aW9uUGFyc2luZ0Vycm9yUHJvdG9QAVpEZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2ds", + "ZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJv", + "cnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.FunctionParsingErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.FunctionParsingErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.FunctionParsingErrorEnum.Types.FunctionParsingError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible function parsing errors. + /// + public sealed partial class FunctionParsingErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new FunctionParsingErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.FunctionParsingErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FunctionParsingErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FunctionParsingErrorEnum(FunctionParsingErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public FunctionParsingErrorEnum Clone() { + return new FunctionParsingErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as FunctionParsingErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(FunctionParsingErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(FunctionParsingErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the FunctionParsingErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible function parsing errors. + /// + public enum FunctionParsingError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Unexpected end of function string. + /// + [pbr::OriginalName("NO_MORE_INPUT")] NoMoreInput = 2, + /// + /// Could not find an expected character. + /// + [pbr::OriginalName("EXPECTED_CHARACTER")] ExpectedCharacter = 3, + /// + /// Unexpected separator character. + /// + [pbr::OriginalName("UNEXPECTED_SEPARATOR")] UnexpectedSeparator = 4, + /// + /// Unmatched left bracket or parenthesis. + /// + [pbr::OriginalName("UNMATCHED_LEFT_BRACKET")] UnmatchedLeftBracket = 5, + /// + /// Unmatched right bracket or parenthesis. + /// + [pbr::OriginalName("UNMATCHED_RIGHT_BRACKET")] UnmatchedRightBracket = 6, + /// + /// Functions are nested too deeply. + /// + [pbr::OriginalName("TOO_MANY_NESTED_FUNCTIONS")] TooManyNestedFunctions = 7, + /// + /// Missing right-hand-side operand. + /// + [pbr::OriginalName("MISSING_RIGHT_HAND_OPERAND")] MissingRightHandOperand = 8, + /// + /// Invalid operator/function name. + /// + [pbr::OriginalName("INVALID_OPERATOR_NAME")] InvalidOperatorName = 9, + /// + /// Feed attribute operand's argument is not an integer. + /// + [pbr::OriginalName("FEED_ATTRIBUTE_OPERAND_ARGUMENT_NOT_INTEGER")] FeedAttributeOperandArgumentNotInteger = 10, + /// + /// Missing function operands. + /// + [pbr::OriginalName("NO_OPERANDS")] NoOperands = 11, + /// + /// Function had too many operands. + /// + [pbr::OriginalName("TOO_MANY_OPERANDS")] TooManyOperands = 12, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GenderType.cs b/src/V3/Stubs/GenderType.cs new file mode 100644 index 000000000..191be39d2 --- /dev/null +++ b/src/V3/Stubs/GenderType.cs @@ -0,0 +1,189 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/gender_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/gender_type.proto + public static partial class GenderTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/gender_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GenderTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9nZW5kZXJfdHlwZS5w", + "cm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdvb2dsZS9h", + "cGkvYW5ub3RhdGlvbnMucHJvdG8iZAoOR2VuZGVyVHlwZUVudW0iUgoKR2Vu", + "ZGVyVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIICgRNQUxF", + "EAoSCgoGRkVNQUxFEAsSEAoMVU5ERVRFUk1JTkVEEBRC5AEKIWNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IPR2VuZGVyVHlwZVByb3RvUAFa", + "Qmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51", + "bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3Rv", + "Mw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.GenderTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.GenderTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.GenderTypeEnum.Types.GenderType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the type of demographic genders. + /// + public sealed partial class GenderTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenderTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.GenderTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderTypeEnum(GenderTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderTypeEnum Clone() { + return new GenderTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenderTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenderTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenderTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the GenderTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The type of demographic genders (e.g. female). + /// + public enum GenderType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Male. + /// + [pbr::OriginalName("MALE")] Male = 10, + /// + /// Female. + /// + [pbr::OriginalName("FEMALE")] Female = 11, + /// + /// Undetermined gender. + /// + [pbr::OriginalName("UNDETERMINED")] Undetermined = 20, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GenderView.cs b/src/V3/Stubs/GenderView.cs new file mode 100644 index 000000000..9b890fa8c --- /dev/null +++ b/src/V3/Stubs/GenderView.cs @@ -0,0 +1,193 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/gender_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/gender_view.proto + public static partial class GenderViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/gender_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GenderViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZ2VuZGVyX3Zp", + "ZXcucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcxof", + "Z29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9y", + "ZXNvdXJjZS5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKq", + "AQoKR2VuZGVyVmlldxJCCg1yZXNvdXJjZV9uYW1lGAEgASgJQivgQQX6QSUK", + "I2dvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9HZW5kZXJWaWV3OljqQVUKI2dv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbS9HZW5kZXJWaWV3Ei5jdXN0b21lcnMv", + "e2N1c3RvbWVyfS9nZW5kZXJWaWV3cy97Z2VuZGVyX3ZpZXd9QvwBCiVjb20u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzQg9HZW5kZXJWaWV3", + "UHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBp", + "cy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNHQUGq", + "AiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29nbGVc", + "QWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.GenderView), global::Google.Ads.GoogleAds.V3.Resources.GenderView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A gender view. + /// + public sealed partial class GenderView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenderView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.GenderViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderView(GenderView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenderView Clone() { + return new GenderView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the gender view. + /// Gender view resource names have the form: + /// + /// `customers/{customer_id}/genderViews/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenderView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenderView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenderView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GenderViewService.cs b/src/V3/Stubs/GenderViewService.cs new file mode 100644 index 000000000..7102b9759 --- /dev/null +++ b/src/V3/Stubs/GenderViewService.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/gender_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/gender_view_service.proto + public static partial class GenderViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/gender_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GenderViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9nZW5kZXJfdmll", + "d19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcxozZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2dlbmRl", + "cl92aWV3LnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdn", + "b29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhh", + "dmlvci5wcm90byIyChRHZXRHZW5kZXJWaWV3UmVxdWVzdBIaCg1yZXNvdXJj", + "ZV9uYW1lGAEgASgJQgPgQQIy8AEKEUdlbmRlclZpZXdTZXJ2aWNlEr0BCg1H", + "ZXRHZW5kZXJWaWV3EjYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuR2V0R2VuZGVyVmlld1JlcXVlc3QaLS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXMuR2VuZGVyVmlldyJFgtPkkwIvEi0vdjMve3Jlc291", + "cmNlX25hbWU9Y3VzdG9tZXJzLyovZ2VuZGVyVmlld3MvKn3aQQ1yZXNvdXJj", + "ZV9uYW1lGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21C/QEKJGNvbS5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0IWR2VuZGVyVmlld1Nl", + "cnZpY2VQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29n", + "bGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNH", + "QUGqAiBHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2ds", + "ZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdv", + "b2dsZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.GenderViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetGenderViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetGenderViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [GenderViewService.GetGenderView][google.ads.googleads.v3.services.GenderViewService.GetGenderView]. + /// + public sealed partial class GetGenderViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetGenderViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GenderViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGenderViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGenderViewRequest(GetGenderViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGenderViewRequest Clone() { + return new GetGenderViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the gender view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetGenderViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetGenderViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetGenderViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GenderViewServiceClient.cs b/src/V3/Stubs/GenderViewServiceClient.cs new file mode 100644 index 000000000..a6b64c8af --- /dev/null +++ b/src/V3/Stubs/GenderViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class GenderViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static GenderViewServiceSettings GetDefault() => new GenderViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public GenderViewServiceSettings() { } + + private GenderViewServiceSettings(GenderViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetGenderViewSettings = existing.GetGenderViewSettings; + OnCopy(existing); + } + + partial void OnCopy(GenderViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// GenderViewServiceClient.GetGenderView and GenderViewServiceClient.GetGenderViewAsync. + /// + /// + /// The default GenderViewServiceClient.GetGenderView and + /// GenderViewServiceClient.GetGenderViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetGenderViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public GenderViewServiceSettings Clone() => new GenderViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class GenderViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public GenderViewServiceSettings Settings { get; set; } + + /// + public override GenderViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return GenderViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return GenderViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => GenderViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => GenderViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => GenderViewServiceClient.ChannelPool; + } + + /// + /// GenderViewService client wrapper, for convenient use. + /// + public abstract partial class GenderViewServiceClient + { + /// + /// The default endpoint for the GenderViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default GenderViewService scopes. + /// + /// + /// The default GenderViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GenderViewServiceClient client = await GenderViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GenderViewServiceClient.DefaultEndpoint.Host, GenderViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GenderViewServiceClient client = GenderViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, GenderViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GenderViewServiceClient client = GenderViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GenderViewServiceClient.DefaultEndpoint.Host, GenderViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GenderViewServiceClient client = GenderViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static GenderViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, GenderViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GenderViewServiceClient Create(grpccore::Channel channel, GenderViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GenderViewServiceClient Create(grpccore::CallInvoker callInvoker, GenderViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + GenderViewService.GenderViewServiceClient grpcClient = new GenderViewService.GenderViewServiceClient(callInvoker); + return new GenderViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC GenderViewService client. + /// + public virtual GenderViewService.GenderViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested gender view in full detail. + /// + /// + /// Required. The resource name of the gender view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGenderViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGenderViewAsync( + new GetGenderViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested gender view in full detail. + /// + /// + /// Required. The resource name of the gender view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGenderViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetGenderViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested gender view in full detail. + /// + /// + /// Required. The resource name of the gender view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GenderView GetGenderView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGenderView( + new GetGenderViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested gender view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGenderViewAsync( + GetGenderViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested gender view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGenderViewAsync( + GetGenderViewRequest request, + st::CancellationToken cancellationToken) => GetGenderViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested gender view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GenderView GetGenderView( + GetGenderViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// GenderViewService client wrapper implementation, for convenient use. + /// + public sealed partial class GenderViewServiceClientImpl : GenderViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetGenderView; + + /// + /// Constructs a client wrapper for the GenderViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public GenderViewServiceClientImpl(GenderViewService.GenderViewServiceClient grpcClient, GenderViewServiceSettings settings) + { + GrpcClient = grpcClient; + GenderViewServiceSettings effectiveSettings = settings ?? GenderViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetGenderView = clientHelper.BuildApiCall( + GrpcClient.GetGenderViewAsync, GrpcClient.GetGenderView, effectiveSettings.GetGenderViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetGenderView); + Modify_GetGenderViewApiCall(ref _callGetGenderView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetGenderViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(GenderViewService.GenderViewServiceClient grpcClient, GenderViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC GenderViewService client. + /// + public override GenderViewService.GenderViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetGenderViewRequest(ref GetGenderViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested gender view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetGenderViewAsync( + GetGenderViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGenderViewRequest(ref request, ref callSettings); + return _callGetGenderView.Async(request, callSettings); + } + + /// + /// Returns the requested gender view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::GenderView GetGenderView( + GetGenderViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGenderViewRequest(ref request, ref callSettings); + return _callGetGenderView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/GenderViewServiceGrpc.cs b/src/V3/Stubs/GenderViewServiceGrpc.cs new file mode 100644 index 000000000..ed1daa53b --- /dev/null +++ b/src/V3/Stubs/GenderViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/gender_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage gender views. + /// + public static partial class GenderViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.GenderViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetGenderViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetGenderViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_GenderView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.GenderView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetGenderView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetGenderView", + __Marshaller_google_ads_googleads_v3_services_GetGenderViewRequest, + __Marshaller_google_ads_googleads_v3_resources_GenderView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.GenderViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of GenderViewService + public abstract partial class GenderViewServiceBase + { + /// + /// Returns the requested gender view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetGenderView(global::Google.Ads.GoogleAds.V3.Services.GetGenderViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for GenderViewService + public partial class GenderViewServiceClient : grpc::ClientBase + { + /// Creates a new client for GenderViewService + /// The channel to use to make remote calls. + public GenderViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for GenderViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public GenderViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected GenderViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected GenderViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested gender view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GenderView GetGenderView(global::Google.Ads.GoogleAds.V3.Services.GetGenderViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGenderView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested gender view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GenderView GetGenderView(global::Google.Ads.GoogleAds.V3.Services.GetGenderViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetGenderView, null, options, request); + } + /// + /// Returns the requested gender view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGenderViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetGenderViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGenderViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested gender view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGenderViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetGenderViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetGenderView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override GenderViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new GenderViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(GenderViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetGenderView, serviceImpl.GetGenderView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, GenderViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetGenderView, serviceImpl.GetGenderView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/GeoTargetConstant.cs b/src/V3/Stubs/GeoTargetConstant.cs new file mode 100644 index 000000000..bf7d92e09 --- /dev/null +++ b/src/V3/Stubs/GeoTargetConstant.cs @@ -0,0 +1,421 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/geo_target_constant.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/geo_target_constant.proto + public static partial class GeoTargetConstantReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/geo_target_constant.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GeoTargetConstantReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZ2VvX3Rhcmdl", + "dF9jb25zdGFudC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9nZW9fdGFy", + "Z2V0X2NvbnN0YW50X3N0YXR1cy5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9i", + "ZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNvdXJjZS5wcm90bxoeZ29v", + "Z2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90", + "YXRpb25zLnByb3RvIq0EChFHZW9UYXJnZXRDb25zdGFudBJJCg1yZXNvdXJj", + "ZV9uYW1lGAEgASgJQjLgQQX6QSwKKmdvb2dsZWFkcy5nb29nbGVhcGlzLmNv", + "bS9HZW9UYXJnZXRDb25zdGFudBIsCgJpZBgDIAEoCzIbLmdvb2dsZS5wcm90", + "b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSLwoEbmFtZRgEIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEjcKDGNvdW50cnlfY29kZRgFIAEo", + "CzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEjYKC3Rhcmdl", + "dF90eXBlGAYgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPg", + "QQMSZwoGc3RhdHVzGAcgASgOMlIuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuR2VvVGFyZ2V0Q29uc3RhbnRTdGF0dXNFbnVtLkdlb1RhcmdldENv", + "bnN0YW50U3RhdHVzQgPgQQMSOQoOY2Fub25pY2FsX25hbWUYCCABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAzpZ6kFWCipnb29nbGVh", + "ZHMuZ29vZ2xlYXBpcy5jb20vR2VvVGFyZ2V0Q29uc3RhbnQSKGdlb1Rhcmdl", + "dENvbnN0YW50cy97Z2VvX3RhcmdldF9jb25zdGFudH1CgwIKJWNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNCFkdlb1RhcmdldENvbnN0", + "YW50UHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNH", + "QUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.GeoTargetConstantStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant), global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant.Parser, new[]{ "ResourceName", "Id", "Name", "CountryCode", "TargetType", "Status", "CanonicalName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A geo target constant. + /// + public sealed partial class GeoTargetConstant : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoTargetConstant()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstantReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstant() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstant(GeoTargetConstant other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + CountryCode = other.CountryCode; + TargetType = other.TargetType; + status_ = other.status_; + CanonicalName = other.CanonicalName; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstant Clone() { + return new GeoTargetConstant(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the geo target constant. + /// Geo target constant resource names have the form: + /// + /// `geoTargetConstants/{geo_target_constant_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the geo target constant. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// Output only. Geo target constant English name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 5; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(42); + private string countryCode_; + /// + /// Output only. The ISO-3166-1 alpha-2 country code that is associated with the target. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "target_type" field. + public const int TargetTypeFieldNumber = 6; + private static readonly pb::FieldCodec _single_targetType_codec = pb::FieldCodec.ForClassWrapper(50); + private string targetType_; + /// + /// Output only. Geo target constant target type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TargetType { + get { return targetType_; } + set { + targetType_ = value; + } + } + + + /// Field number for the "status" field. + public const int StatusFieldNumber = 7; + private global::Google.Ads.GoogleAds.V3.Enums.GeoTargetConstantStatusEnum.Types.GeoTargetConstantStatus status_ = 0; + /// + /// Output only. Geo target constant status. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.GeoTargetConstantStatusEnum.Types.GeoTargetConstantStatus Status { + get { return status_; } + set { + status_ = value; + } + } + + /// Field number for the "canonical_name" field. + public const int CanonicalNameFieldNumber = 8; + private static readonly pb::FieldCodec _single_canonicalName_codec = pb::FieldCodec.ForClassWrapper(66); + private string canonicalName_; + /// + /// Output only. The fully qualified English name, consisting of the target's name and that + /// of its parent and country. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CanonicalName { + get { return canonicalName_; } + set { + canonicalName_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoTargetConstant); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoTargetConstant other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (CountryCode != other.CountryCode) return false; + if (TargetType != other.TargetType) return false; + if (Status != other.Status) return false; + if (CanonicalName != other.CanonicalName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (targetType_ != null) hash ^= TargetType.GetHashCode(); + if (Status != 0) hash ^= Status.GetHashCode(); + if (canonicalName_ != null) hash ^= CanonicalName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (targetType_ != null) { + _single_targetType_codec.WriteTagAndValue(output, TargetType); + } + if (Status != 0) { + output.WriteRawTag(56); + output.WriteEnum((int) Status); + } + if (canonicalName_ != null) { + _single_canonicalName_codec.WriteTagAndValue(output, CanonicalName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (targetType_ != null) { + size += _single_targetType_codec.CalculateSizeWithTag(TargetType); + } + if (Status != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Status); + } + if (canonicalName_ != null) { + size += _single_canonicalName_codec.CalculateSizeWithTag(CanonicalName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoTargetConstant other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + if (other.targetType_ != null) { + if (targetType_ == null || other.TargetType != "") { + TargetType = other.TargetType; + } + } + if (other.Status != 0) { + Status = other.Status; + } + if (other.canonicalName_ != null) { + if (canonicalName_ == null || other.CanonicalName != "") { + CanonicalName = other.CanonicalName; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 42: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + case 50: { + string value = _single_targetType_codec.Read(input); + if (targetType_ == null || value != "") { + TargetType = value; + } + break; + } + case 56: { + Status = (global::Google.Ads.GoogleAds.V3.Enums.GeoTargetConstantStatusEnum.Types.GeoTargetConstantStatus) input.ReadEnum(); + break; + } + case 66: { + string value = _single_canonicalName_codec.Read(input); + if (canonicalName_ == null || value != "") { + CanonicalName = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GeoTargetConstantService.cs b/src/V3/Stubs/GeoTargetConstantService.cs new file mode 100644 index 000000000..94b8a3175 --- /dev/null +++ b/src/V3/Stubs/GeoTargetConstantService.cs @@ -0,0 +1,1184 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/geo_target_constant_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/geo_target_constant_service.proto + public static partial class GeoTargetConstantServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/geo_target_constant_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GeoTargetConstantServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9nZW9fdGFyZ2V0", + "X2NvbnN0YW50X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvZ2VvX3RhcmdldF9jb25zdGFudC5wcm90bxocZ29vZ2xlL2FwaS9hbm5v", + "dGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2ds", + "ZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93", + "cmFwcGVycy5wcm90byI5ChtHZXRHZW9UYXJnZXRDb25zdGFudFJlcXVlc3QS", + "GgoNcmVzb3VyY2VfbmFtZRgBIAEoCUID4EECIucDCiBTdWdnZXN0R2VvVGFy", + "Z2V0Q29uc3RhbnRzUmVxdWVzdBIsCgZsb2NhbGUYAyABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWUSMgoMY291bnRyeV9jb2RlGAUgASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEmoKDmxvY2F0aW9uX25hbWVz", + "GAEgASgLMlAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuU3Vn", + "Z2VzdEdlb1RhcmdldENvbnN0YW50c1JlcXVlc3QuTG9jYXRpb25OYW1lc0gA", + "EmQKC2dlb190YXJnZXRzGAIgASgLMk0uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMuU3VnZ2VzdEdlb1RhcmdldENvbnN0YW50c1JlcXVlc3Qu", + "R2VvVGFyZ2V0c0gAGjwKDUxvY2F0aW9uTmFtZXMSKwoFbmFtZXMYASADKAsy", + "HC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUaSAoKR2VvVGFyZ2V0cxI6", + "ChRnZW9fdGFyZ2V0X2NvbnN0YW50cxgBIAMoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZUIHCgVxdWVyeSKLAQohU3VnZ2VzdEdlb1RhcmdldENv", + "bnN0YW50c1Jlc3BvbnNlEmYKH2dlb190YXJnZXRfY29uc3RhbnRfc3VnZ2Vz", + "dGlvbnMYASADKAsyPS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5HZW9UYXJnZXRDb25zdGFudFN1Z2dlc3Rpb24i2AIKG0dlb1RhcmdldENv", + "bnN0YW50U3VnZ2VzdGlvbhIsCgZsb2NhbGUYASABKAsyHC5nb29nbGUucHJv", + "dG9idWYuU3RyaW5nVmFsdWUSKgoFcmVhY2gYAiABKAsyGy5nb29nbGUucHJv", + "dG9idWYuSW50NjRWYWx1ZRIxCgtzZWFyY2hfdGVybRgDIAEoCzIcLmdvb2ds", + "ZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJRChNnZW9fdGFyZ2V0X2NvbnN0YW50", + "GAQgASgLMjQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkdl", + "b1RhcmdldENvbnN0YW50ElkKG2dlb190YXJnZXRfY29uc3RhbnRfcGFyZW50", + "cxgFIAMoCzI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5H", + "ZW9UYXJnZXRDb25zdGFudDLZAwoYR2VvVGFyZ2V0Q29uc3RhbnRTZXJ2aWNl", + "Es0BChRHZXRHZW9UYXJnZXRDb25zdGFudBI9Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzLkdldEdlb1RhcmdldENvbnN0YW50UmVxdWVzdBo0", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5HZW9UYXJnZXRD", + "b25zdGFudCJAgtPkkwIqEigvdjMve3Jlc291cmNlX25hbWU9Z2VvVGFyZ2V0", + "Q29uc3RhbnRzLyp92kENcmVzb3VyY2VfbmFtZRLPAQoZU3VnZ2VzdEdlb1Rh", + "cmdldENvbnN0YW50cxJCLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzLlN1Z2dlc3RHZW9UYXJnZXRDb25zdGFudHNSZXF1ZXN0GkMuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuU3VnZ2VzdEdlb1RhcmdldENv", + "bnN0YW50c1Jlc3BvbnNlIimC0+STAiMiHi92My9nZW9UYXJnZXRDb25zdGFu", + "dHM6c3VnZ2VzdDoBKhobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQoQC", + "CiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCHUdlb1Rh", + "cmdldENvbnN0YW50U2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3Jn", + "L2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNl", + "cztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNl", + "cnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRH", + "b29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstantReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetGeoTargetConstantRequest), global::Google.Ads.GoogleAds.V3.Services.GetGeoTargetConstantRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest), global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Parser, new[]{ "Locale", "CountryCode", "LocationNames", "GeoTargets" }, new[]{ "Query" }, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.LocationNames), global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.LocationNames.Parser, new[]{ "Names" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.GeoTargets), global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.GeoTargets.Parser, new[]{ "GeoTargetConstants" }, null, null, null)}), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsResponse), global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsResponse.Parser, new[]{ "GeoTargetConstantSuggestions" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GeoTargetConstantSuggestion), global::Google.Ads.GoogleAds.V3.Services.GeoTargetConstantSuggestion.Parser, new[]{ "Locale", "Reach", "SearchTerm", "GeoTargetConstant", "GeoTargetConstantParents" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [GeoTargetConstantService.GetGeoTargetConstant][google.ads.googleads.v3.services.GeoTargetConstantService.GetGeoTargetConstant]. + /// + public sealed partial class GetGeoTargetConstantRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetGeoTargetConstantRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GeoTargetConstantServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGeoTargetConstantRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGeoTargetConstantRequest(GetGeoTargetConstantRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGeoTargetConstantRequest Clone() { + return new GetGeoTargetConstantRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the geo target constant to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetGeoTargetConstantRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetGeoTargetConstantRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetGeoTargetConstantRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [GeoTargetConstantService.SuggestGeoTargetConstantsRequest][]. + /// + public sealed partial class SuggestGeoTargetConstantsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SuggestGeoTargetConstantsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GeoTargetConstantServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SuggestGeoTargetConstantsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SuggestGeoTargetConstantsRequest(SuggestGeoTargetConstantsRequest other) : this() { + Locale = other.Locale; + CountryCode = other.CountryCode; + switch (other.QueryCase) { + case QueryOneofCase.LocationNames: + LocationNames = other.LocationNames.Clone(); + break; + case QueryOneofCase.GeoTargets: + GeoTargets = other.GeoTargets.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SuggestGeoTargetConstantsRequest Clone() { + return new SuggestGeoTargetConstantsRequest(this); + } + + /// Field number for the "locale" field. + public const int LocaleFieldNumber = 3; + private static readonly pb::FieldCodec _single_locale_codec = pb::FieldCodec.ForClassWrapper(26); + private string locale_; + /// + /// If possible, returned geo targets are translated using this locale. If not, + /// en is used by default. This is also used as a hint for returned geo + /// targets. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Locale { + get { return locale_; } + set { + locale_ = value; + } + } + + + /// Field number for the "country_code" field. + public const int CountryCodeFieldNumber = 5; + private static readonly pb::FieldCodec _single_countryCode_codec = pb::FieldCodec.ForClassWrapper(42); + private string countryCode_; + /// + /// Returned geo targets are restricted to this country code. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CountryCode { + get { return countryCode_; } + set { + countryCode_ = value; + } + } + + + /// Field number for the "location_names" field. + public const int LocationNamesFieldNumber = 1; + /// + /// The location names to search by. At most 25 names can be set. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.LocationNames LocationNames { + get { return queryCase_ == QueryOneofCase.LocationNames ? (global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.LocationNames) query_ : null; } + set { + query_ = value; + queryCase_ = value == null ? QueryOneofCase.None : QueryOneofCase.LocationNames; + } + } + + /// Field number for the "geo_targets" field. + public const int GeoTargetsFieldNumber = 2; + /// + /// The geo target constant resource names to filter by. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.GeoTargets GeoTargets { + get { return queryCase_ == QueryOneofCase.GeoTargets ? (global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.GeoTargets) query_ : null; } + set { + query_ = value; + queryCase_ = value == null ? QueryOneofCase.None : QueryOneofCase.GeoTargets; + } + } + + private object query_; + /// Enum of possible cases for the "query" oneof. + public enum QueryOneofCase { + None = 0, + LocationNames = 1, + GeoTargets = 2, + } + private QueryOneofCase queryCase_ = QueryOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public QueryOneofCase QueryCase { + get { return queryCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearQuery() { + queryCase_ = QueryOneofCase.None; + query_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SuggestGeoTargetConstantsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SuggestGeoTargetConstantsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Locale != other.Locale) return false; + if (CountryCode != other.CountryCode) return false; + if (!object.Equals(LocationNames, other.LocationNames)) return false; + if (!object.Equals(GeoTargets, other.GeoTargets)) return false; + if (QueryCase != other.QueryCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (locale_ != null) hash ^= Locale.GetHashCode(); + if (countryCode_ != null) hash ^= CountryCode.GetHashCode(); + if (queryCase_ == QueryOneofCase.LocationNames) hash ^= LocationNames.GetHashCode(); + if (queryCase_ == QueryOneofCase.GeoTargets) hash ^= GeoTargets.GetHashCode(); + hash ^= (int) queryCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (queryCase_ == QueryOneofCase.LocationNames) { + output.WriteRawTag(10); + output.WriteMessage(LocationNames); + } + if (queryCase_ == QueryOneofCase.GeoTargets) { + output.WriteRawTag(18); + output.WriteMessage(GeoTargets); + } + if (locale_ != null) { + _single_locale_codec.WriteTagAndValue(output, Locale); + } + if (countryCode_ != null) { + _single_countryCode_codec.WriteTagAndValue(output, CountryCode); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (locale_ != null) { + size += _single_locale_codec.CalculateSizeWithTag(Locale); + } + if (countryCode_ != null) { + size += _single_countryCode_codec.CalculateSizeWithTag(CountryCode); + } + if (queryCase_ == QueryOneofCase.LocationNames) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(LocationNames); + } + if (queryCase_ == QueryOneofCase.GeoTargets) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(GeoTargets); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SuggestGeoTargetConstantsRequest other) { + if (other == null) { + return; + } + if (other.locale_ != null) { + if (locale_ == null || other.Locale != "") { + Locale = other.Locale; + } + } + if (other.countryCode_ != null) { + if (countryCode_ == null || other.CountryCode != "") { + CountryCode = other.CountryCode; + } + } + switch (other.QueryCase) { + case QueryOneofCase.LocationNames: + if (LocationNames == null) { + LocationNames = new global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.LocationNames(); + } + LocationNames.MergeFrom(other.LocationNames); + break; + case QueryOneofCase.GeoTargets: + if (GeoTargets == null) { + GeoTargets = new global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.GeoTargets(); + } + GeoTargets.MergeFrom(other.GeoTargets); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.LocationNames subBuilder = new global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.LocationNames(); + if (queryCase_ == QueryOneofCase.LocationNames) { + subBuilder.MergeFrom(LocationNames); + } + input.ReadMessage(subBuilder); + LocationNames = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.GeoTargets subBuilder = new global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Types.GeoTargets(); + if (queryCase_ == QueryOneofCase.GeoTargets) { + subBuilder.MergeFrom(GeoTargets); + } + input.ReadMessage(subBuilder); + GeoTargets = subBuilder; + break; + } + case 26: { + string value = _single_locale_codec.Read(input); + if (locale_ == null || value != "") { + Locale = value; + } + break; + } + case 42: { + string value = _single_countryCode_codec.Read(input); + if (countryCode_ == null || value != "") { + CountryCode = value; + } + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the SuggestGeoTargetConstantsRequest message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// A list of location names. + /// + public sealed partial class LocationNames : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new LocationNames()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationNames() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationNames(LocationNames other) : this() { + names_ = other.names_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public LocationNames Clone() { + return new LocationNames(this); + } + + /// Field number for the "names" field. + public const int NamesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_names_codec + = pb::FieldCodec.ForClassWrapper(10); + private readonly pbc::RepeatedField names_ = new pbc::RepeatedField(); + /// + /// A list of location names. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Names { + get { return names_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as LocationNames); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(LocationNames other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!names_.Equals(other.names_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= names_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + names_.WriteTo(output, _repeated_names_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += names_.CalculateSize(_repeated_names_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(LocationNames other) { + if (other == null) { + return; + } + names_.Add(other.names_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + names_.AddEntriesFrom(input, _repeated_names_codec); + break; + } + } + } + } + + } + + /// + /// A list of geo target constant resource names. + /// + public sealed partial class GeoTargets : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoTargets()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Descriptor.NestedTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargets() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargets(GeoTargets other) : this() { + geoTargetConstants_ = other.geoTargetConstants_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargets Clone() { + return new GeoTargets(this); + } + + /// Field number for the "geo_target_constants" field. + public const int GeoTargetConstantsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_geoTargetConstants_codec + = pb::FieldCodec.ForClassWrapper(10); + private readonly pbc::RepeatedField geoTargetConstants_ = new pbc::RepeatedField(); + /// + /// A list of geo target constant resource names. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField GeoTargetConstants { + get { return geoTargetConstants_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoTargets); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoTargets other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!geoTargetConstants_.Equals(other.geoTargetConstants_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= geoTargetConstants_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + geoTargetConstants_.WriteTo(output, _repeated_geoTargetConstants_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += geoTargetConstants_.CalculateSize(_repeated_geoTargetConstants_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoTargets other) { + if (other == null) { + return; + } + geoTargetConstants_.Add(other.geoTargetConstants_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + geoTargetConstants_.AddEntriesFrom(input, _repeated_geoTargetConstants_codec); + break; + } + } + } + } + + } + + } + #endregion + + } + + /// + /// Response message for [GeoTargetConstantService.SuggestGeoTargetConstants][google.ads.googleads.v3.services.GeoTargetConstantService.SuggestGeoTargetConstants] + /// + public sealed partial class SuggestGeoTargetConstantsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SuggestGeoTargetConstantsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GeoTargetConstantServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SuggestGeoTargetConstantsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SuggestGeoTargetConstantsResponse(SuggestGeoTargetConstantsResponse other) : this() { + geoTargetConstantSuggestions_ = other.geoTargetConstantSuggestions_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SuggestGeoTargetConstantsResponse Clone() { + return new SuggestGeoTargetConstantsResponse(this); + } + + /// Field number for the "geo_target_constant_suggestions" field. + public const int GeoTargetConstantSuggestionsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_geoTargetConstantSuggestions_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Services.GeoTargetConstantSuggestion.Parser); + private readonly pbc::RepeatedField geoTargetConstantSuggestions_ = new pbc::RepeatedField(); + /// + /// Geo target constant suggestions. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField GeoTargetConstantSuggestions { + get { return geoTargetConstantSuggestions_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SuggestGeoTargetConstantsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SuggestGeoTargetConstantsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!geoTargetConstantSuggestions_.Equals(other.geoTargetConstantSuggestions_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= geoTargetConstantSuggestions_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + geoTargetConstantSuggestions_.WriteTo(output, _repeated_geoTargetConstantSuggestions_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += geoTargetConstantSuggestions_.CalculateSize(_repeated_geoTargetConstantSuggestions_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SuggestGeoTargetConstantsResponse other) { + if (other == null) { + return; + } + geoTargetConstantSuggestions_.Add(other.geoTargetConstantSuggestions_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + geoTargetConstantSuggestions_.AddEntriesFrom(input, _repeated_geoTargetConstantSuggestions_codec); + break; + } + } + } + } + + } + + /// + /// A geo target constant suggestion. + /// + public sealed partial class GeoTargetConstantSuggestion : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoTargetConstantSuggestion()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GeoTargetConstantServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantSuggestion() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantSuggestion(GeoTargetConstantSuggestion other) : this() { + Locale = other.Locale; + Reach = other.Reach; + SearchTerm = other.SearchTerm; + geoTargetConstant_ = other.geoTargetConstant_ != null ? other.geoTargetConstant_.Clone() : null; + geoTargetConstantParents_ = other.geoTargetConstantParents_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantSuggestion Clone() { + return new GeoTargetConstantSuggestion(this); + } + + /// Field number for the "locale" field. + public const int LocaleFieldNumber = 1; + private static readonly pb::FieldCodec _single_locale_codec = pb::FieldCodec.ForClassWrapper(10); + private string locale_; + /// + /// The language this GeoTargetConstantSuggestion is currently translated to. + /// It affects the name of geo target fields. For example, if locale=en, then + /// name=Spain. If locale=es, then name=España. The default locale will be + /// returned if no translation exists for the locale in the request. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Locale { + get { return locale_; } + set { + locale_ = value; + } + } + + + /// Field number for the "reach" field. + public const int ReachFieldNumber = 2; + private static readonly pb::FieldCodec _single_reach_codec = pb::FieldCodec.ForStructWrapper(18); + private long? reach_; + /// + /// Approximate user population that will be targeted, rounded to the + /// nearest 100. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Reach { + get { return reach_; } + set { + reach_ = value; + } + } + + + /// Field number for the "search_term" field. + public const int SearchTermFieldNumber = 3; + private static readonly pb::FieldCodec _single_searchTerm_codec = pb::FieldCodec.ForClassWrapper(26); + private string searchTerm_; + /// + /// If the request searched by location name, this is the location name that + /// matched the geo target. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string SearchTerm { + get { return searchTerm_; } + set { + searchTerm_ = value; + } + } + + + /// Field number for the "geo_target_constant" field. + public const int GeoTargetConstantFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant geoTargetConstant_; + /// + /// The GeoTargetConstant result. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant GeoTargetConstant { + get { return geoTargetConstant_; } + set { + geoTargetConstant_ = value; + } + } + + /// Field number for the "geo_target_constant_parents" field. + public const int GeoTargetConstantParentsFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_geoTargetConstantParents_codec + = pb::FieldCodec.ForMessage(42, global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant.Parser); + private readonly pbc::RepeatedField geoTargetConstantParents_ = new pbc::RepeatedField(); + /// + /// The list of parents of the geo target constant. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField GeoTargetConstantParents { + get { return geoTargetConstantParents_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoTargetConstantSuggestion); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoTargetConstantSuggestion other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Locale != other.Locale) return false; + if (Reach != other.Reach) return false; + if (SearchTerm != other.SearchTerm) return false; + if (!object.Equals(GeoTargetConstant, other.GeoTargetConstant)) return false; + if(!geoTargetConstantParents_.Equals(other.geoTargetConstantParents_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (locale_ != null) hash ^= Locale.GetHashCode(); + if (reach_ != null) hash ^= Reach.GetHashCode(); + if (searchTerm_ != null) hash ^= SearchTerm.GetHashCode(); + if (geoTargetConstant_ != null) hash ^= GeoTargetConstant.GetHashCode(); + hash ^= geoTargetConstantParents_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (locale_ != null) { + _single_locale_codec.WriteTagAndValue(output, Locale); + } + if (reach_ != null) { + _single_reach_codec.WriteTagAndValue(output, Reach); + } + if (searchTerm_ != null) { + _single_searchTerm_codec.WriteTagAndValue(output, SearchTerm); + } + if (geoTargetConstant_ != null) { + output.WriteRawTag(34); + output.WriteMessage(GeoTargetConstant); + } + geoTargetConstantParents_.WriteTo(output, _repeated_geoTargetConstantParents_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (locale_ != null) { + size += _single_locale_codec.CalculateSizeWithTag(Locale); + } + if (reach_ != null) { + size += _single_reach_codec.CalculateSizeWithTag(Reach); + } + if (searchTerm_ != null) { + size += _single_searchTerm_codec.CalculateSizeWithTag(SearchTerm); + } + if (geoTargetConstant_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(GeoTargetConstant); + } + size += geoTargetConstantParents_.CalculateSize(_repeated_geoTargetConstantParents_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoTargetConstantSuggestion other) { + if (other == null) { + return; + } + if (other.locale_ != null) { + if (locale_ == null || other.Locale != "") { + Locale = other.Locale; + } + } + if (other.reach_ != null) { + if (reach_ == null || other.Reach != 0L) { + Reach = other.Reach; + } + } + if (other.searchTerm_ != null) { + if (searchTerm_ == null || other.SearchTerm != "") { + SearchTerm = other.SearchTerm; + } + } + if (other.geoTargetConstant_ != null) { + if (geoTargetConstant_ == null) { + GeoTargetConstant = new global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant(); + } + GeoTargetConstant.MergeFrom(other.GeoTargetConstant); + } + geoTargetConstantParents_.Add(other.geoTargetConstantParents_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_locale_codec.Read(input); + if (locale_ == null || value != "") { + Locale = value; + } + break; + } + case 18: { + long? value = _single_reach_codec.Read(input); + if (reach_ == null || value != 0L) { + Reach = value; + } + break; + } + case 26: { + string value = _single_searchTerm_codec.Read(input); + if (searchTerm_ == null || value != "") { + SearchTerm = value; + } + break; + } + case 34: { + if (geoTargetConstant_ == null) { + GeoTargetConstant = new global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant(); + } + input.ReadMessage(GeoTargetConstant); + break; + } + case 42: { + geoTargetConstantParents_.AddEntriesFrom(input, _repeated_geoTargetConstantParents_codec); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GeoTargetConstantServiceClient.cs b/src/V3/Stubs/GeoTargetConstantServiceClient.cs new file mode 100644 index 000000000..831f21d35 --- /dev/null +++ b/src/V3/Stubs/GeoTargetConstantServiceClient.cs @@ -0,0 +1,775 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class GeoTargetConstantServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static GeoTargetConstantServiceSettings GetDefault() => new GeoTargetConstantServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public GeoTargetConstantServiceSettings() { } + + private GeoTargetConstantServiceSettings(GeoTargetConstantServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetGeoTargetConstantSettings = existing.GetGeoTargetConstantSettings; + SuggestGeoTargetConstantsSettings = existing.SuggestGeoTargetConstantsSettings; + OnCopy(existing); + } + + partial void OnCopy(GeoTargetConstantServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// GeoTargetConstantServiceClient.GetGeoTargetConstant and GeoTargetConstantServiceClient.GetGeoTargetConstantAsync. + /// + /// + /// The default GeoTargetConstantServiceClient.GetGeoTargetConstant and + /// GeoTargetConstantServiceClient.GetGeoTargetConstantAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetGeoTargetConstantSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// GeoTargetConstantServiceClient.SuggestGeoTargetConstants and GeoTargetConstantServiceClient.SuggestGeoTargetConstantsAsync. + /// + /// + /// The default GeoTargetConstantServiceClient.SuggestGeoTargetConstants and + /// GeoTargetConstantServiceClient.SuggestGeoTargetConstantsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings SuggestGeoTargetConstantsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public GeoTargetConstantServiceSettings Clone() => new GeoTargetConstantServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class GeoTargetConstantServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public GeoTargetConstantServiceSettings Settings { get; set; } + + /// + public override GeoTargetConstantServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return GeoTargetConstantServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return GeoTargetConstantServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => GeoTargetConstantServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => GeoTargetConstantServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => GeoTargetConstantServiceClient.ChannelPool; + } + + /// + /// GeoTargetConstantService client wrapper, for convenient use. + /// + public abstract partial class GeoTargetConstantServiceClient + { + /// + /// The default endpoint for the GeoTargetConstantService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default GeoTargetConstantService scopes. + /// + /// + /// The default GeoTargetConstantService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GeoTargetConstantServiceClient client = await GeoTargetConstantServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GeoTargetConstantServiceClient.DefaultEndpoint.Host, GeoTargetConstantServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GeoTargetConstantServiceClient client = GeoTargetConstantServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, GeoTargetConstantServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GeoTargetConstantServiceClient client = GeoTargetConstantServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GeoTargetConstantServiceClient.DefaultEndpoint.Host, GeoTargetConstantServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GeoTargetConstantServiceClient client = GeoTargetConstantServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static GeoTargetConstantServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, GeoTargetConstantServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GeoTargetConstantServiceClient Create(grpccore::Channel channel, GeoTargetConstantServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GeoTargetConstantServiceClient Create(grpccore::CallInvoker callInvoker, GeoTargetConstantServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + GeoTargetConstantService.GeoTargetConstantServiceClient grpcClient = new GeoTargetConstantService.GeoTargetConstantServiceClient(callInvoker); + return new GeoTargetConstantServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC GeoTargetConstantService client. + /// + public virtual GeoTargetConstantService.GeoTargetConstantServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested geo target constant in full detail. + /// + /// + /// Required. The resource name of the geo target constant to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGeoTargetConstantAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGeoTargetConstantAsync( + new GetGeoTargetConstantRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested geo target constant in full detail. + /// + /// + /// Required. The resource name of the geo target constant to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGeoTargetConstantAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetGeoTargetConstantAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested geo target constant in full detail. + /// + /// + /// Required. The resource name of the geo target constant to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GeoTargetConstant GetGeoTargetConstant( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGeoTargetConstant( + new GetGeoTargetConstantRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested geo target constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGeoTargetConstantAsync( + GetGeoTargetConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested geo target constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGeoTargetConstantAsync( + GetGeoTargetConstantRequest request, + st::CancellationToken cancellationToken) => GetGeoTargetConstantAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested geo target constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GeoTargetConstant GetGeoTargetConstant( + GetGeoTargetConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// + /// If possible, returned geo targets are translated using this locale. If not, + /// en is used by default. This is also used as a hint for returned geo + /// targets. + /// + /// + /// Returned geo targets are restricted to this country code. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task SuggestGeoTargetConstantsAsync( + string locale, + string countryCode, + gaxgrpc::CallSettings callSettings = null) => SuggestGeoTargetConstantsAsync( + new SuggestGeoTargetConstantsRequest + { + Locale = gax::GaxPreconditions.CheckNotNullOrEmpty(locale, nameof(locale)), + CountryCode = gax::GaxPreconditions.CheckNotNullOrEmpty(countryCode, nameof(countryCode)), + }, + callSettings); + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// + /// If possible, returned geo targets are translated using this locale. If not, + /// en is used by default. This is also used as a hint for returned geo + /// targets. + /// + /// + /// Returned geo targets are restricted to this country code. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task SuggestGeoTargetConstantsAsync( + string locale, + string countryCode, + st::CancellationToken cancellationToken) => SuggestGeoTargetConstantsAsync( + locale, + countryCode, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// + /// If possible, returned geo targets are translated using this locale. If not, + /// en is used by default. This is also used as a hint for returned geo + /// targets. + /// + /// + /// Returned geo targets are restricted to this country code. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual SuggestGeoTargetConstantsResponse SuggestGeoTargetConstants( + string locale, + string countryCode, + gaxgrpc::CallSettings callSettings = null) => SuggestGeoTargetConstants( + new SuggestGeoTargetConstantsRequest + { + Locale = gax::GaxPreconditions.CheckNotNullOrEmpty(locale, nameof(locale)), + CountryCode = gax::GaxPreconditions.CheckNotNullOrEmpty(countryCode, nameof(countryCode)), + }, + callSettings); + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task SuggestGeoTargetConstantsAsync( + SuggestGeoTargetConstantsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task SuggestGeoTargetConstantsAsync( + SuggestGeoTargetConstantsRequest request, + st::CancellationToken cancellationToken) => SuggestGeoTargetConstantsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual SuggestGeoTargetConstantsResponse SuggestGeoTargetConstants( + SuggestGeoTargetConstantsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// GeoTargetConstantService client wrapper implementation, for convenient use. + /// + public sealed partial class GeoTargetConstantServiceClientImpl : GeoTargetConstantServiceClient + { + private readonly gaxgrpc::ApiCall _callGetGeoTargetConstant; + private readonly gaxgrpc::ApiCall _callSuggestGeoTargetConstants; + + /// + /// Constructs a client wrapper for the GeoTargetConstantService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public GeoTargetConstantServiceClientImpl(GeoTargetConstantService.GeoTargetConstantServiceClient grpcClient, GeoTargetConstantServiceSettings settings) + { + GrpcClient = grpcClient; + GeoTargetConstantServiceSettings effectiveSettings = settings ?? GeoTargetConstantServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetGeoTargetConstant = clientHelper.BuildApiCall( + GrpcClient.GetGeoTargetConstantAsync, GrpcClient.GetGeoTargetConstant, effectiveSettings.GetGeoTargetConstantSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callSuggestGeoTargetConstants = clientHelper.BuildApiCall( + GrpcClient.SuggestGeoTargetConstantsAsync, GrpcClient.SuggestGeoTargetConstants, effectiveSettings.SuggestGeoTargetConstantsSettings); + Modify_ApiCall(ref _callGetGeoTargetConstant); + Modify_GetGeoTargetConstantApiCall(ref _callGetGeoTargetConstant); + Modify_ApiCall(ref _callSuggestGeoTargetConstants); + Modify_SuggestGeoTargetConstantsApiCall(ref _callSuggestGeoTargetConstants); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetGeoTargetConstantApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_SuggestGeoTargetConstantsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(GeoTargetConstantService.GeoTargetConstantServiceClient grpcClient, GeoTargetConstantServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC GeoTargetConstantService client. + /// + public override GeoTargetConstantService.GeoTargetConstantServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetGeoTargetConstantRequest(ref GetGeoTargetConstantRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_SuggestGeoTargetConstantsRequest(ref SuggestGeoTargetConstantsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested geo target constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetGeoTargetConstantAsync( + GetGeoTargetConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGeoTargetConstantRequest(ref request, ref callSettings); + return _callGetGeoTargetConstant.Async(request, callSettings); + } + + /// + /// Returns the requested geo target constant in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::GeoTargetConstant GetGeoTargetConstant( + GetGeoTargetConstantRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGeoTargetConstantRequest(ref request, ref callSettings); + return _callGetGeoTargetConstant.Sync(request, callSettings); + } + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task SuggestGeoTargetConstantsAsync( + SuggestGeoTargetConstantsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_SuggestGeoTargetConstantsRequest(ref request, ref callSettings); + return _callSuggestGeoTargetConstants.Async(request, callSettings); + } + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override SuggestGeoTargetConstantsResponse SuggestGeoTargetConstants( + SuggestGeoTargetConstantsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_SuggestGeoTargetConstantsRequest(ref request, ref callSettings); + return _callSuggestGeoTargetConstants.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/GeoTargetConstantServiceGrpc.cs b/src/V3/Stubs/GeoTargetConstantServiceGrpc.cs new file mode 100644 index 000000000..05ce9353a --- /dev/null +++ b/src/V3/Stubs/GeoTargetConstantServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/geo_target_constant_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch geo target constants. + /// + public static partial class GeoTargetConstantService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.GeoTargetConstantService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetGeoTargetConstantRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetGeoTargetConstantRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_GeoTargetConstant = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_SuggestGeoTargetConstantsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_SuggestGeoTargetConstantsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetGeoTargetConstant = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetGeoTargetConstant", + __Marshaller_google_ads_googleads_v3_services_GetGeoTargetConstantRequest, + __Marshaller_google_ads_googleads_v3_resources_GeoTargetConstant); + + static readonly grpc::Method __Method_SuggestGeoTargetConstants = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "SuggestGeoTargetConstants", + __Marshaller_google_ads_googleads_v3_services_SuggestGeoTargetConstantsRequest, + __Marshaller_google_ads_googleads_v3_services_SuggestGeoTargetConstantsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.GeoTargetConstantServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of GeoTargetConstantService + public abstract partial class GeoTargetConstantServiceBase + { + /// + /// Returns the requested geo target constant in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetGeoTargetConstant(global::Google.Ads.GoogleAds.V3.Services.GetGeoTargetConstantRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task SuggestGeoTargetConstants(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for GeoTargetConstantService + public partial class GeoTargetConstantServiceClient : grpc::ClientBase + { + /// Creates a new client for GeoTargetConstantService + /// The channel to use to make remote calls. + public GeoTargetConstantServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for GeoTargetConstantService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public GeoTargetConstantServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected GeoTargetConstantServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected GeoTargetConstantServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested geo target constant in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant GetGeoTargetConstant(global::Google.Ads.GoogleAds.V3.Services.GetGeoTargetConstantRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGeoTargetConstant(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested geo target constant in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant GetGeoTargetConstant(global::Google.Ads.GoogleAds.V3.Services.GetGeoTargetConstantRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetGeoTargetConstant, null, options, request); + } + /// + /// Returns the requested geo target constant in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGeoTargetConstantAsync(global::Google.Ads.GoogleAds.V3.Services.GetGeoTargetConstantRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGeoTargetConstantAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested geo target constant in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGeoTargetConstantAsync(global::Google.Ads.GoogleAds.V3.Services.GetGeoTargetConstantRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetGeoTargetConstant, null, options, request); + } + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsResponse SuggestGeoTargetConstants(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return SuggestGeoTargetConstants(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsResponse SuggestGeoTargetConstants(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_SuggestGeoTargetConstants, null, options, request); + } + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall SuggestGeoTargetConstantsAsync(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return SuggestGeoTargetConstantsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns GeoTargetConstant suggestions by location name or by resource name. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall SuggestGeoTargetConstantsAsync(global::Google.Ads.GoogleAds.V3.Services.SuggestGeoTargetConstantsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_SuggestGeoTargetConstants, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override GeoTargetConstantServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new GeoTargetConstantServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(GeoTargetConstantServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetGeoTargetConstant, serviceImpl.GetGeoTargetConstant) + .AddMethod(__Method_SuggestGeoTargetConstants, serviceImpl.SuggestGeoTargetConstants).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, GeoTargetConstantServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetGeoTargetConstant, serviceImpl.GetGeoTargetConstant); + serviceBinder.AddMethod(__Method_SuggestGeoTargetConstants, serviceImpl.SuggestGeoTargetConstants); + } + + } +} +#endregion diff --git a/src/V3/Stubs/GeoTargetConstantStatus.cs b/src/V3/Stubs/GeoTargetConstantStatus.cs new file mode 100644 index 000000000..1342d32c9 --- /dev/null +++ b/src/V3/Stubs/GeoTargetConstantStatus.cs @@ -0,0 +1,188 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/geo_target_constant_status.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/geo_target_constant_status.proto + public static partial class GeoTargetConstantStatusReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/geo_target_constant_status.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GeoTargetConstantStatusReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9nZW9fdGFyZ2V0X2Nv", + "bnN0YW50X3N0YXR1cy5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ieAobR2VvVGFy", + "Z2V0Q29uc3RhbnRTdGF0dXNFbnVtIlkKF0dlb1RhcmdldENvbnN0YW50U3Rh", + "dHVzEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB0VOQUJMRUQQ", + "AhITCg9SRU1PVkFMX1BMQU5ORUQQA0LxAQohY29tLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVudW1zQhxHZW9UYXJnZXRDb25zdGFudFN0YXR1c1Byb3Rv", + "UAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "RW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.GeoTargetConstantStatusEnum), global::Google.Ads.GoogleAds.V3.Enums.GeoTargetConstantStatusEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.GeoTargetConstantStatusEnum.Types.GeoTargetConstantStatus) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for describing the status of a geo target constant. + /// + public sealed partial class GeoTargetConstantStatusEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoTargetConstantStatusEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.GeoTargetConstantStatusReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantStatusEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantStatusEnum(GeoTargetConstantStatusEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantStatusEnum Clone() { + return new GeoTargetConstantStatusEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoTargetConstantStatusEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoTargetConstantStatusEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoTargetConstantStatusEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the GeoTargetConstantStatusEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible statuses of a geo target constant. + /// + public enum GeoTargetConstantStatus { + /// + /// No value has been specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received value is not known in this version. + /// + /// This is a response-only value. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The geo target constant is valid. + /// + [pbr::OriginalName("ENABLED")] Enabled = 2, + /// + /// The geo target constant is obsolete and will be removed. + /// + [pbr::OriginalName("REMOVAL_PLANNED")] RemovalPlanned = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GeoTargetConstantSuggestionError.cs b/src/V3/Stubs/GeoTargetConstantSuggestionError.cs new file mode 100644 index 000000000..9bf169a2a --- /dev/null +++ b/src/V3/Stubs/GeoTargetConstantSuggestionError.cs @@ -0,0 +1,198 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/geo_target_constant_suggestion_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/geo_target_constant_suggestion_error.proto + public static partial class GeoTargetConstantSuggestionErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/geo_target_constant_suggestion_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GeoTargetConstantSuggestionErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cklnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvZ2VvX3RhcmdldF9j", + "b25zdGFudF9zdWdnZXN0aW9uX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lcnJvcnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJv", + "dG8i2AEKJEdlb1RhcmdldENvbnN0YW50U3VnZ2VzdGlvbkVycm9yRW51bSKv", + "AQogR2VvVGFyZ2V0Q29uc3RhbnRTdWdnZXN0aW9uRXJyb3ISDwoLVU5TUEVD", + "SUZJRUQQABILCgdVTktOT1dOEAESHAoYTE9DQVRJT05fTkFNRV9TSVpFX0xJ", + "TUlUEAISFwoTTE9DQVRJT05fTkFNRV9MSU1JVBADEhgKFElOVkFMSURfQ09V", + "TlRSWV9DT0RFEAQSHAoYUkVRVUVTVF9QQVJBTUVURVJTX1VOU0VUEAVCgAIK", + "ImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNCJUdlb1Rhcmdl", + "dENvbnN0YW50U3VnZ2VzdGlvbkVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFu", + "Zy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vy", + "cm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5F", + "cnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.GeoTargetConstantSuggestionErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.GeoTargetConstantSuggestionErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.GeoTargetConstantSuggestionErrorEnum.Types.GeoTargetConstantSuggestionError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible geo target constant suggestion errors. + /// + public sealed partial class GeoTargetConstantSuggestionErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoTargetConstantSuggestionErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.GeoTargetConstantSuggestionErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantSuggestionErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantSuggestionErrorEnum(GeoTargetConstantSuggestionErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetConstantSuggestionErrorEnum Clone() { + return new GeoTargetConstantSuggestionErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoTargetConstantSuggestionErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoTargetConstantSuggestionErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoTargetConstantSuggestionErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the GeoTargetConstantSuggestionErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible geo target constant suggestion errors. + /// + public enum GeoTargetConstantSuggestionError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// A location name cannot be greater than 300 characters. + /// + [pbr::OriginalName("LOCATION_NAME_SIZE_LIMIT")] LocationNameSizeLimit = 2, + /// + /// At most 25 location names can be specified in a SuggestGeoTargetConstants + /// method. + /// + [pbr::OriginalName("LOCATION_NAME_LIMIT")] LocationNameLimit = 3, + /// + /// The country code is invalid. + /// + [pbr::OriginalName("INVALID_COUNTRY_CODE")] InvalidCountryCode = 4, + /// + /// Geo target constant resource names or location names must be provided in + /// the request. + /// + [pbr::OriginalName("REQUEST_PARAMETERS_UNSET")] RequestParametersUnset = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GeoTargetingRestriction.cs b/src/V3/Stubs/GeoTargetingRestriction.cs new file mode 100644 index 000000000..5ea0c792e --- /dev/null +++ b/src/V3/Stubs/GeoTargetingRestriction.cs @@ -0,0 +1,183 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/geo_targeting_restriction.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/geo_targeting_restriction.proto + public static partial class GeoTargetingRestrictionReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/geo_targeting_restriction.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GeoTargetingRestrictionReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9nZW9fdGFyZ2V0aW5n", + "X3Jlc3RyaWN0aW9uLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJwChtHZW9UYXJn", + "ZXRpbmdSZXN0cmljdGlvbkVudW0iUQoXR2VvVGFyZ2V0aW5nUmVzdHJpY3Rp", + "b24SDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESGAoUTE9DQVRJT05f", + "T0ZfUFJFU0VOQ0UQAkLxAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVudW1zQhxHZW9UYXJnZXRpbmdSZXN0cmljdGlvblByb3RvUAFaQmdvb2ds", + "ZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFk", + "cy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFH", + "b29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingRestrictionEnum), global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingRestrictionEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingRestrictionEnum.Types.GeoTargetingRestriction) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing feed item geo targeting restriction. + /// + public sealed partial class GeoTargetingRestrictionEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoTargetingRestrictionEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingRestrictionReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetingRestrictionEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetingRestrictionEnum(GeoTargetingRestrictionEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetingRestrictionEnum Clone() { + return new GeoTargetingRestrictionEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoTargetingRestrictionEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoTargetingRestrictionEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoTargetingRestrictionEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the GeoTargetingRestrictionEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// A restriction used to determine if the request context's + /// geo should be matched. + /// + public enum GeoTargetingRestriction { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Indicates that request context should match the physical location of + /// the user. + /// + [pbr::OriginalName("LOCATION_OF_PRESENCE")] LocationOfPresence = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GeoTargetingType.cs b/src/V3/Stubs/GeoTargetingType.cs new file mode 100644 index 000000000..a4d07557f --- /dev/null +++ b/src/V3/Stubs/GeoTargetingType.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/geo_targeting_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/geo_targeting_type.proto + public static partial class GeoTargetingTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/geo_targeting_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GeoTargetingTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9nZW9fdGFyZ2V0aW5n", + "X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIngKFEdlb1RhcmdldGluZ1R5", + "cGVFbnVtImAKEEdlb1RhcmdldGluZ1R5cGUSDwoLVU5TUEVDSUZJRUQQABIL", + "CgdVTktOT1dOEAESFAoQQVJFQV9PRl9JTlRFUkVTVBACEhgKFExPQ0FUSU9O", + "X09GX1BSRVNFTkNFEANC6gEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtc0IVR2VvVGFyZ2V0aW5nVHlwZVByb3RvUAFaQmdvb2dsZS5nb2xh", + "bmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9l", + "bnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVu", + "dW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6", + "OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingTypeEnum.Types.GeoTargetingType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible geo targeting types. + /// + public sealed partial class GeoTargetingTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeoTargetingTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetingTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetingTypeEnum(GeoTargetingTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeoTargetingTypeEnum Clone() { + return new GeoTargetingTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeoTargetingTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeoTargetingTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeoTargetingTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the GeoTargetingTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible geo targeting types. + /// + public enum GeoTargetingType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Location the user is interested in while making the query. + /// + [pbr::OriginalName("AREA_OF_INTEREST")] AreaOfInterest = 2, + /// + /// Location of the user issuing the query. + /// + [pbr::OriginalName("LOCATION_OF_PRESENCE")] LocationOfPresence = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GeographicView.cs b/src/V3/Stubs/GeographicView.cs new file mode 100644 index 000000000..9b3d5c060 --- /dev/null +++ b/src/V3/Stubs/GeographicView.cs @@ -0,0 +1,272 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/geographic_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/geographic_view.proto + public static partial class GeographicViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/geographic_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GeographicViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZ2VvZ3JhcGhp", + "Y192aWV3LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMaNmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2dlb190YXJnZXRp", + "bmdfdHlwZS5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90", + "bxoZZ29vZ2xlL2FwaS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVm", + "L3dyYXBwZXJzLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3Rv", + "IuACCg5HZW9ncmFwaGljVmlldxJGCg1yZXNvdXJjZV9uYW1lGAEgASgJQi/g", + "QQX6QSkKJ2dvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9HZW9ncmFwaGljVmll", + "dxJgCg1sb2NhdGlvbl90eXBlGAMgASgOMkQuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZW51bXMuR2VvVGFyZ2V0aW5nVHlwZUVudW0uR2VvVGFyZ2V0aW5n", + "VHlwZUID4EEDEj4KFGNvdW50cnlfY3JpdGVyaW9uX2lkGAQgASgLMhsuZ29v", + "Z2xlLnByb3RvYnVmLkludDY0VmFsdWVCA+BBAzpk6kFhCidnb29nbGVhZHMu", + "Z29vZ2xlYXBpcy5jb20vR2VvZ3JhcGhpY1ZpZXcSNmN1c3RvbWVycy97Y3Vz", + "dG9tZXJ9L2dlb2dyYXBoaWNWaWV3cy97Z2VvZ3JhcGhpY192aWV3fUKAAgol", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0ITR2VvZ3Jh", + "cGhpY1ZpZXdQcm90b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9n", + "b29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNl", + "c6ICA0dBQaoCIUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oC", + "IUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6", + "QWRzOjpHb29nbGVBZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.GeographicView), global::Google.Ads.GoogleAds.V3.Resources.GeographicView.Parser, new[]{ "ResourceName", "LocationType", "CountryCriterionId" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A geographic view. + /// + /// Geographic View includes all metrics aggregated at the country level, + /// one row per country. It reports metrics at either actual physical location of + /// the user or an area of interest. If other segment fields are used, you may + /// get more than one row per country. + /// + public sealed partial class GeographicView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GeographicView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.GeographicViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeographicView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeographicView(GeographicView other) : this() { + resourceName_ = other.resourceName_; + locationType_ = other.locationType_; + CountryCriterionId = other.CountryCriterionId; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GeographicView Clone() { + return new GeographicView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the geographic view. + /// Geographic view resource names have the form: + /// + /// `customers/{customer_id}/geographicViews/{country_criterion_id}~{location_type}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "location_type" field. + public const int LocationTypeFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingTypeEnum.Types.GeoTargetingType locationType_ = 0; + /// + /// Output only. Type of the geo targeting of the campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingTypeEnum.Types.GeoTargetingType LocationType { + get { return locationType_; } + set { + locationType_ = value; + } + } + + /// Field number for the "country_criterion_id" field. + public const int CountryCriterionIdFieldNumber = 4; + private static readonly pb::FieldCodec _single_countryCriterionId_codec = pb::FieldCodec.ForStructWrapper(34); + private long? countryCriterionId_; + /// + /// Output only. Criterion Id for the country. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CountryCriterionId { + get { return countryCriterionId_; } + set { + countryCriterionId_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GeographicView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GeographicView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (LocationType != other.LocationType) return false; + if (CountryCriterionId != other.CountryCriterionId) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (LocationType != 0) hash ^= LocationType.GetHashCode(); + if (countryCriterionId_ != null) hash ^= CountryCriterionId.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (LocationType != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) LocationType); + } + if (countryCriterionId_ != null) { + _single_countryCriterionId_codec.WriteTagAndValue(output, CountryCriterionId); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (LocationType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) LocationType); + } + if (countryCriterionId_ != null) { + size += _single_countryCriterionId_codec.CalculateSizeWithTag(CountryCriterionId); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GeographicView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.LocationType != 0) { + LocationType = other.LocationType; + } + if (other.countryCriterionId_ != null) { + if (countryCriterionId_ == null || other.CountryCriterionId != 0L) { + CountryCriterionId = other.CountryCriterionId; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 24: { + LocationType = (global::Google.Ads.GoogleAds.V3.Enums.GeoTargetingTypeEnum.Types.GeoTargetingType) input.ReadEnum(); + break; + } + case 34: { + long? value = _single_countryCriterionId_codec.Read(input); + if (countryCriterionId_ == null || value != 0L) { + CountryCriterionId = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GeographicViewService.cs b/src/V3/Stubs/GeographicViewService.cs new file mode 100644 index 000000000..8756546a2 --- /dev/null +++ b/src/V3/Stubs/GeographicViewService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/geographic_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/geographic_view_service.proto + public static partial class GeographicViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/geographic_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GeographicViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9nZW9ncmFwaGlj", + "X3ZpZXdfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXMaN2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9n", + "ZW9ncmFwaGljX3ZpZXcucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMu", + "cHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2Zp", + "ZWxkX2JlaGF2aW9yLnByb3RvIjYKGEdldEdlb2dyYXBoaWNWaWV3UmVxdWVz", + "dBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIyhAIKFUdlb2dyYXBoaWNW", + "aWV3U2VydmljZRLNAQoRR2V0R2VvZ3JhcGhpY1ZpZXcSOi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXRHZW9ncmFwaGljVmlld1JlcXVl", + "c3QaMS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuR2VvZ3Jh", + "cGhpY1ZpZXciSYLT5JMCMxIxL3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVy", + "cy8qL2dlb2dyYXBoaWNWaWV3cy8qfdpBDXJlc291cmNlX25hbWUaG8pBGGdv", + "b2dsZWFkcy5nb29nbGVhcGlzLmNvbUKBAgokY29tLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzQhpHZW9ncmFwaGljVmlld1NlcnZpY2VQcm90", + "b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.GeographicViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetGeographicViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetGeographicViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [GeographicViewService.GetGeographicView][google.ads.googleads.v3.services.GeographicViewService.GetGeographicView]. + /// + public sealed partial class GetGeographicViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetGeographicViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GeographicViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGeographicViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGeographicViewRequest(GetGeographicViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGeographicViewRequest Clone() { + return new GetGeographicViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the geographic view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetGeographicViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetGeographicViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetGeographicViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GeographicViewServiceClient.cs b/src/V3/Stubs/GeographicViewServiceClient.cs new file mode 100644 index 000000000..c122c8b05 --- /dev/null +++ b/src/V3/Stubs/GeographicViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class GeographicViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static GeographicViewServiceSettings GetDefault() => new GeographicViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public GeographicViewServiceSettings() { } + + private GeographicViewServiceSettings(GeographicViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetGeographicViewSettings = existing.GetGeographicViewSettings; + OnCopy(existing); + } + + partial void OnCopy(GeographicViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// GeographicViewServiceClient.GetGeographicView and GeographicViewServiceClient.GetGeographicViewAsync. + /// + /// + /// The default GeographicViewServiceClient.GetGeographicView and + /// GeographicViewServiceClient.GetGeographicViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetGeographicViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public GeographicViewServiceSettings Clone() => new GeographicViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class GeographicViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public GeographicViewServiceSettings Settings { get; set; } + + /// + public override GeographicViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return GeographicViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return GeographicViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => GeographicViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => GeographicViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => GeographicViewServiceClient.ChannelPool; + } + + /// + /// GeographicViewService client wrapper, for convenient use. + /// + public abstract partial class GeographicViewServiceClient + { + /// + /// The default endpoint for the GeographicViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default GeographicViewService scopes. + /// + /// + /// The default GeographicViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GeographicViewServiceClient client = await GeographicViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GeographicViewServiceClient.DefaultEndpoint.Host, GeographicViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GeographicViewServiceClient client = GeographicViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, GeographicViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GeographicViewServiceClient client = GeographicViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GeographicViewServiceClient.DefaultEndpoint.Host, GeographicViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GeographicViewServiceClient client = GeographicViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static GeographicViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, GeographicViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GeographicViewServiceClient Create(grpccore::Channel channel, GeographicViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GeographicViewServiceClient Create(grpccore::CallInvoker callInvoker, GeographicViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + GeographicViewService.GeographicViewServiceClient grpcClient = new GeographicViewService.GeographicViewServiceClient(callInvoker); + return new GeographicViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC GeographicViewService client. + /// + public virtual GeographicViewService.GeographicViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested geographic view in full detail. + /// + /// + /// Required. The resource name of the geographic view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGeographicViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGeographicViewAsync( + new GetGeographicViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested geographic view in full detail. + /// + /// + /// Required. The resource name of the geographic view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGeographicViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetGeographicViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested geographic view in full detail. + /// + /// + /// Required. The resource name of the geographic view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GeographicView GetGeographicView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGeographicView( + new GetGeographicViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested geographic view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGeographicViewAsync( + GetGeographicViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested geographic view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGeographicViewAsync( + GetGeographicViewRequest request, + st::CancellationToken cancellationToken) => GetGeographicViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested geographic view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GeographicView GetGeographicView( + GetGeographicViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// GeographicViewService client wrapper implementation, for convenient use. + /// + public sealed partial class GeographicViewServiceClientImpl : GeographicViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetGeographicView; + + /// + /// Constructs a client wrapper for the GeographicViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public GeographicViewServiceClientImpl(GeographicViewService.GeographicViewServiceClient grpcClient, GeographicViewServiceSettings settings) + { + GrpcClient = grpcClient; + GeographicViewServiceSettings effectiveSettings = settings ?? GeographicViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetGeographicView = clientHelper.BuildApiCall( + GrpcClient.GetGeographicViewAsync, GrpcClient.GetGeographicView, effectiveSettings.GetGeographicViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetGeographicView); + Modify_GetGeographicViewApiCall(ref _callGetGeographicView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetGeographicViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(GeographicViewService.GeographicViewServiceClient grpcClient, GeographicViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC GeographicViewService client. + /// + public override GeographicViewService.GeographicViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetGeographicViewRequest(ref GetGeographicViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested geographic view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetGeographicViewAsync( + GetGeographicViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGeographicViewRequest(ref request, ref callSettings); + return _callGetGeographicView.Async(request, callSettings); + } + + /// + /// Returns the requested geographic view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::GeographicView GetGeographicView( + GetGeographicViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGeographicViewRequest(ref request, ref callSettings); + return _callGetGeographicView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/GeographicViewServiceGrpc.cs b/src/V3/Stubs/GeographicViewServiceGrpc.cs new file mode 100644 index 000000000..29e4f42e1 --- /dev/null +++ b/src/V3/Stubs/GeographicViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/geographic_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage geographic views. + /// + public static partial class GeographicViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.GeographicViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetGeographicViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetGeographicViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_GeographicView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.GeographicView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetGeographicView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetGeographicView", + __Marshaller_google_ads_googleads_v3_services_GetGeographicViewRequest, + __Marshaller_google_ads_googleads_v3_resources_GeographicView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.GeographicViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of GeographicViewService + public abstract partial class GeographicViewServiceBase + { + /// + /// Returns the requested geographic view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetGeographicView(global::Google.Ads.GoogleAds.V3.Services.GetGeographicViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for GeographicViewService + public partial class GeographicViewServiceClient : grpc::ClientBase + { + /// Creates a new client for GeographicViewService + /// The channel to use to make remote calls. + public GeographicViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for GeographicViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public GeographicViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected GeographicViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected GeographicViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested geographic view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GeographicView GetGeographicView(global::Google.Ads.GoogleAds.V3.Services.GetGeographicViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGeographicView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested geographic view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GeographicView GetGeographicView(global::Google.Ads.GoogleAds.V3.Services.GetGeographicViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetGeographicView, null, options, request); + } + /// + /// Returns the requested geographic view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGeographicViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetGeographicViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGeographicViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested geographic view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGeographicViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetGeographicViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetGeographicView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override GeographicViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new GeographicViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(GeographicViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetGeographicView, serviceImpl.GetGeographicView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, GeographicViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetGeographicView, serviceImpl.GetGeographicView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/GoogleAdsField.cs b/src/V3/Stubs/GoogleAdsField.cs new file mode 100644 index 000000000..0a4bb905d --- /dev/null +++ b/src/V3/Stubs/GoogleAdsField.cs @@ -0,0 +1,639 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/google_ads_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/google_ads_field.proto + public static partial class GoogleAdsFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/google_ads_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GoogleAdsFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZ29vZ2xlX2Fk", + "c19maWVsZC5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzGj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9nb29nbGVfYWRz", + "X2ZpZWxkX2NhdGVnb3J5LnByb3RvGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcy9nb29nbGVfYWRzX2ZpZWxkX2RhdGFfdHlwZS5wcm90bxofZ29v", + "Z2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9yZXNv", + "dXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3RvGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvItMHCg5Hb29nbGVBZHNGaWVs", + "ZBJGCg1yZXNvdXJjZV9uYW1lGAEgASgJQi/gQQX6QSkKJ2dvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbS9Hb29nbGVBZHNGaWVsZBIvCgRuYW1lGAIgASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMSZwoIY2F0ZWdvcnkY", + "AyABKA4yUC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5Hb29nbGVB", + "ZHNGaWVsZENhdGVnb3J5RW51bS5Hb29nbGVBZHNGaWVsZENhdGVnb3J5QgPg", + "QQMSMwoKc2VsZWN0YWJsZRgEIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5Cb29s", + "VmFsdWVCA+BBAxIzCgpmaWx0ZXJhYmxlGAUgASgLMhouZ29vZ2xlLnByb3Rv", + "YnVmLkJvb2xWYWx1ZUID4EEDEjEKCHNvcnRhYmxlGAYgASgLMhouZ29vZ2xl", + "LnByb3RvYnVmLkJvb2xWYWx1ZUID4EEDEjoKD3NlbGVjdGFibGVfd2l0aBgH", + "IAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEj4KE2F0", + "dHJpYnV0ZV9yZXNvdXJjZXMYCCADKAsyHC5nb29nbGUucHJvdG9idWYuU3Ry", + "aW5nVmFsdWVCA+BBAxIyCgdtZXRyaWNzGAkgAygLMhwuZ29vZ2xlLnByb3Rv", + "YnVmLlN0cmluZ1ZhbHVlQgPgQQMSMwoIc2VnbWVudHMYCiADKAsyHC5nb29n", + "bGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxI2CgtlbnVtX3ZhbHVlcxgL", + "IAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEmgKCWRh", + "dGFfdHlwZRgMIAEoDjJQLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "Lkdvb2dsZUFkc0ZpZWxkRGF0YVR5cGVFbnVtLkdvb2dsZUFkc0ZpZWxkRGF0", + "YVR5cGVCA+BBAxIzCgh0eXBlX3VybBgNIAEoCzIcLmdvb2dsZS5wcm90b2J1", + "Zi5TdHJpbmdWYWx1ZUID4EEDEjQKC2lzX3JlcGVhdGVkGA4gASgLMhouZ29v", + "Z2xlLnByb3RvYnVmLkJvb2xWYWx1ZUID4EEDOlDqQU0KJ2dvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbS9Hb29nbGVBZHNGaWVsZBIiZ29vZ2xlQWRzRmllbGRz", + "L3tnb29nbGVfYWRzX2ZpZWxkfUKAAgolY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlc0ITR29vZ2xlQWRzRmllbGRQcm90b1ABWkpnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRz", + "XFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpS", + "ZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldCategoryReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldDataTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.GoogleAdsField), global::Google.Ads.GoogleAds.V3.Resources.GoogleAdsField.Parser, new[]{ "ResourceName", "Name", "Category", "Selectable", "Filterable", "Sortable", "SelectableWith", "AttributeResources", "Metrics", "Segments", "EnumValues", "DataType", "TypeUrl", "IsRepeated" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A field or resource (artifact) used by GoogleAdsService. + /// + public sealed partial class GoogleAdsField : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GoogleAdsField()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.GoogleAdsFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsField() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsField(GoogleAdsField other) : this() { + resourceName_ = other.resourceName_; + Name = other.Name; + category_ = other.category_; + Selectable = other.Selectable; + Filterable = other.Filterable; + Sortable = other.Sortable; + selectableWith_ = other.selectableWith_.Clone(); + attributeResources_ = other.attributeResources_.Clone(); + metrics_ = other.metrics_.Clone(); + segments_ = other.segments_.Clone(); + enumValues_ = other.enumValues_.Clone(); + dataType_ = other.dataType_; + TypeUrl = other.TypeUrl; + IsRepeated = other.IsRepeated; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsField Clone() { + return new GoogleAdsField(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the artifact. + /// Artifact resource names have the form: + /// + /// `googleAdsFields/{name}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "name" field. + public const int NameFieldNumber = 2; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(18); + private string name_; + /// + /// Output only. The name of the artifact. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "category" field. + public const int CategoryFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldCategoryEnum.Types.GoogleAdsFieldCategory category_ = 0; + /// + /// Output only. The category of the artifact. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldCategoryEnum.Types.GoogleAdsFieldCategory Category { + get { return category_; } + set { + category_ = value; + } + } + + /// Field number for the "selectable" field. + public const int SelectableFieldNumber = 4; + private static readonly pb::FieldCodec _single_selectable_codec = pb::FieldCodec.ForStructWrapper(34); + private bool? selectable_; + /// + /// Output only. Whether the artifact can be used in a SELECT clause in search + /// queries. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Selectable { + get { return selectable_; } + set { + selectable_ = value; + } + } + + + /// Field number for the "filterable" field. + public const int FilterableFieldNumber = 5; + private static readonly pb::FieldCodec _single_filterable_codec = pb::FieldCodec.ForStructWrapper(42); + private bool? filterable_; + /// + /// Output only. Whether the artifact can be used in a WHERE clause in search + /// queries. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Filterable { + get { return filterable_; } + set { + filterable_ = value; + } + } + + + /// Field number for the "sortable" field. + public const int SortableFieldNumber = 6; + private static readonly pb::FieldCodec _single_sortable_codec = pb::FieldCodec.ForStructWrapper(50); + private bool? sortable_; + /// + /// Output only. Whether the artifact can be used in a ORDER BY clause in search + /// queries. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? Sortable { + get { return sortable_; } + set { + sortable_ = value; + } + } + + + /// Field number for the "selectable_with" field. + public const int SelectableWithFieldNumber = 7; + private static readonly pb::FieldCodec _repeated_selectableWith_codec + = pb::FieldCodec.ForClassWrapper(58); + private readonly pbc::RepeatedField selectableWith_ = new pbc::RepeatedField(); + /// + /// Output only. The names of all resources, segments, and metrics that are selectable with + /// the described artifact. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField SelectableWith { + get { return selectableWith_; } + } + + /// Field number for the "attribute_resources" field. + public const int AttributeResourcesFieldNumber = 8; + private static readonly pb::FieldCodec _repeated_attributeResources_codec + = pb::FieldCodec.ForClassWrapper(66); + private readonly pbc::RepeatedField attributeResources_ = new pbc::RepeatedField(); + /// + /// Output only. The names of all resources that are selectable with the described + /// artifact. Fields from these resources do not segment metrics when included + /// in search queries. + /// + /// This field is only set for artifacts whose category is RESOURCE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField AttributeResources { + get { return attributeResources_; } + } + + /// Field number for the "metrics" field. + public const int MetricsFieldNumber = 9; + private static readonly pb::FieldCodec _repeated_metrics_codec + = pb::FieldCodec.ForClassWrapper(74); + private readonly pbc::RepeatedField metrics_ = new pbc::RepeatedField(); + /// + /// Output only. At and beyond version V1 this field lists the names of all metrics that are + /// selectable with the described artifact when it is used in the FROM clause. + /// It is only set for artifacts whose category is RESOURCE. + /// + /// Before version V1 this field lists the names of all metrics that are + /// selectable with the described artifact. It is only set for artifacts whose + /// category is either RESOURCE or SEGMENT + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Metrics { + get { return metrics_; } + } + + /// Field number for the "segments" field. + public const int SegmentsFieldNumber = 10; + private static readonly pb::FieldCodec _repeated_segments_codec + = pb::FieldCodec.ForClassWrapper(82); + private readonly pbc::RepeatedField segments_ = new pbc::RepeatedField(); + /// + /// Output only. At and beyond version V1 this field lists the names of all artifacts, + /// whether a segment or another resource, that segment metrics when included + /// in search queries and when the described artifact is used in the FROM + /// clause. It is only set for artifacts whose category is RESOURCE. + /// + /// Before version V1 this field lists the names of all artifacts, whether a + /// segment or another resource, that segment metrics when included in search + /// queries. It is only set for artifacts of category RESOURCE, SEGMENT or + /// METRIC. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Segments { + get { return segments_; } + } + + /// Field number for the "enum_values" field. + public const int EnumValuesFieldNumber = 11; + private static readonly pb::FieldCodec _repeated_enumValues_codec + = pb::FieldCodec.ForClassWrapper(90); + private readonly pbc::RepeatedField enumValues_ = new pbc::RepeatedField(); + /// + /// Output only. Values the artifact can assume if it is a field of type ENUM. + /// + /// This field is only set for artifacts of category SEGMENT or ATTRIBUTE. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField EnumValues { + get { return enumValues_; } + } + + /// Field number for the "data_type" field. + public const int DataTypeFieldNumber = 12; + private global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldDataTypeEnum.Types.GoogleAdsFieldDataType dataType_ = 0; + /// + /// Output only. This field determines the operators that can be used with the artifact + /// in WHERE clauses. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldDataTypeEnum.Types.GoogleAdsFieldDataType DataType { + get { return dataType_; } + set { + dataType_ = value; + } + } + + /// Field number for the "type_url" field. + public const int TypeUrlFieldNumber = 13; + private static readonly pb::FieldCodec _single_typeUrl_codec = pb::FieldCodec.ForClassWrapper(106); + private string typeUrl_; + /// + /// Output only. The URL of proto describing the artifact's data type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TypeUrl { + get { return typeUrl_; } + set { + typeUrl_ = value; + } + } + + + /// Field number for the "is_repeated" field. + public const int IsRepeatedFieldNumber = 14; + private static readonly pb::FieldCodec _single_isRepeated_codec = pb::FieldCodec.ForStructWrapper(114); + private bool? isRepeated_; + /// + /// Output only. Whether the field artifact is repeated. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool? IsRepeated { + get { return isRepeated_; } + set { + isRepeated_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GoogleAdsField); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GoogleAdsField other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Name != other.Name) return false; + if (Category != other.Category) return false; + if (Selectable != other.Selectable) return false; + if (Filterable != other.Filterable) return false; + if (Sortable != other.Sortable) return false; + if(!selectableWith_.Equals(other.selectableWith_)) return false; + if(!attributeResources_.Equals(other.attributeResources_)) return false; + if(!metrics_.Equals(other.metrics_)) return false; + if(!segments_.Equals(other.segments_)) return false; + if(!enumValues_.Equals(other.enumValues_)) return false; + if (DataType != other.DataType) return false; + if (TypeUrl != other.TypeUrl) return false; + if (IsRepeated != other.IsRepeated) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (Category != 0) hash ^= Category.GetHashCode(); + if (selectable_ != null) hash ^= Selectable.GetHashCode(); + if (filterable_ != null) hash ^= Filterable.GetHashCode(); + if (sortable_ != null) hash ^= Sortable.GetHashCode(); + hash ^= selectableWith_.GetHashCode(); + hash ^= attributeResources_.GetHashCode(); + hash ^= metrics_.GetHashCode(); + hash ^= segments_.GetHashCode(); + hash ^= enumValues_.GetHashCode(); + if (DataType != 0) hash ^= DataType.GetHashCode(); + if (typeUrl_ != null) hash ^= TypeUrl.GetHashCode(); + if (isRepeated_ != null) hash ^= IsRepeated.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (Category != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Category); + } + if (selectable_ != null) { + _single_selectable_codec.WriteTagAndValue(output, Selectable); + } + if (filterable_ != null) { + _single_filterable_codec.WriteTagAndValue(output, Filterable); + } + if (sortable_ != null) { + _single_sortable_codec.WriteTagAndValue(output, Sortable); + } + selectableWith_.WriteTo(output, _repeated_selectableWith_codec); + attributeResources_.WriteTo(output, _repeated_attributeResources_codec); + metrics_.WriteTo(output, _repeated_metrics_codec); + segments_.WriteTo(output, _repeated_segments_codec); + enumValues_.WriteTo(output, _repeated_enumValues_codec); + if (DataType != 0) { + output.WriteRawTag(96); + output.WriteEnum((int) DataType); + } + if (typeUrl_ != null) { + _single_typeUrl_codec.WriteTagAndValue(output, TypeUrl); + } + if (isRepeated_ != null) { + _single_isRepeated_codec.WriteTagAndValue(output, IsRepeated); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (Category != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Category); + } + if (selectable_ != null) { + size += _single_selectable_codec.CalculateSizeWithTag(Selectable); + } + if (filterable_ != null) { + size += _single_filterable_codec.CalculateSizeWithTag(Filterable); + } + if (sortable_ != null) { + size += _single_sortable_codec.CalculateSizeWithTag(Sortable); + } + size += selectableWith_.CalculateSize(_repeated_selectableWith_codec); + size += attributeResources_.CalculateSize(_repeated_attributeResources_codec); + size += metrics_.CalculateSize(_repeated_metrics_codec); + size += segments_.CalculateSize(_repeated_segments_codec); + size += enumValues_.CalculateSize(_repeated_enumValues_codec); + if (DataType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DataType); + } + if (typeUrl_ != null) { + size += _single_typeUrl_codec.CalculateSizeWithTag(TypeUrl); + } + if (isRepeated_ != null) { + size += _single_isRepeated_codec.CalculateSizeWithTag(IsRepeated); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GoogleAdsField other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.Category != 0) { + Category = other.Category; + } + if (other.selectable_ != null) { + if (selectable_ == null || other.Selectable != false) { + Selectable = other.Selectable; + } + } + if (other.filterable_ != null) { + if (filterable_ == null || other.Filterable != false) { + Filterable = other.Filterable; + } + } + if (other.sortable_ != null) { + if (sortable_ == null || other.Sortable != false) { + Sortable = other.Sortable; + } + } + selectableWith_.Add(other.selectableWith_); + attributeResources_.Add(other.attributeResources_); + metrics_.Add(other.metrics_); + segments_.Add(other.segments_); + enumValues_.Add(other.enumValues_); + if (other.DataType != 0) { + DataType = other.DataType; + } + if (other.typeUrl_ != null) { + if (typeUrl_ == null || other.TypeUrl != "") { + TypeUrl = other.TypeUrl; + } + } + if (other.isRepeated_ != null) { + if (isRepeated_ == null || other.IsRepeated != false) { + IsRepeated = other.IsRepeated; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 24: { + Category = (global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldCategoryEnum.Types.GoogleAdsFieldCategory) input.ReadEnum(); + break; + } + case 34: { + bool? value = _single_selectable_codec.Read(input); + if (selectable_ == null || value != false) { + Selectable = value; + } + break; + } + case 42: { + bool? value = _single_filterable_codec.Read(input); + if (filterable_ == null || value != false) { + Filterable = value; + } + break; + } + case 50: { + bool? value = _single_sortable_codec.Read(input); + if (sortable_ == null || value != false) { + Sortable = value; + } + break; + } + case 58: { + selectableWith_.AddEntriesFrom(input, _repeated_selectableWith_codec); + break; + } + case 66: { + attributeResources_.AddEntriesFrom(input, _repeated_attributeResources_codec); + break; + } + case 74: { + metrics_.AddEntriesFrom(input, _repeated_metrics_codec); + break; + } + case 82: { + segments_.AddEntriesFrom(input, _repeated_segments_codec); + break; + } + case 90: { + enumValues_.AddEntriesFrom(input, _repeated_enumValues_codec); + break; + } + case 96: { + DataType = (global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldDataTypeEnum.Types.GoogleAdsFieldDataType) input.ReadEnum(); + break; + } + case 106: { + string value = _single_typeUrl_codec.Read(input); + if (typeUrl_ == null || value != "") { + TypeUrl = value; + } + break; + } + case 114: { + bool? value = _single_isRepeated_codec.Read(input); + if (isRepeated_ == null || value != false) { + IsRepeated = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GoogleAdsFieldCategory.cs b/src/V3/Stubs/GoogleAdsFieldCategory.cs new file mode 100644 index 000000000..e40fbed77 --- /dev/null +++ b/src/V3/Stubs/GoogleAdsFieldCategory.cs @@ -0,0 +1,199 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/google_ads_field_category.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/google_ads_field_category.proto + public static partial class GoogleAdsFieldCategoryReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/google_ads_field_category.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GoogleAdsFieldCategoryReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9nb29nbGVfYWRzX2Zp", + "ZWxkX2NhdGVnb3J5LnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKKAQoaR29vZ2xl", + "QWRzRmllbGRDYXRlZ29yeUVudW0ibAoWR29vZ2xlQWRzRmllbGRDYXRlZ29y", + "eRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIMCghSRVNPVVJDRRAC", + "Eg0KCUFUVFJJQlVURRADEgsKB1NFR01FTlQQBRIKCgZNRVRSSUMQBkLwAQoh", + "Y29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhtHb29nbGVBZHNG", + "aWVsZENhdGVnb3J5UHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogID", + "R0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVc", + "QWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVB", + "ZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldCategoryEnum), global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldCategoryEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldCategoryEnum.Types.GoogleAdsFieldCategory) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum that determines if the described artifact is a resource + /// or a field, and if it is a field, when it segments search queries. + /// + public sealed partial class GoogleAdsFieldCategoryEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GoogleAdsFieldCategoryEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldCategoryReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFieldCategoryEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFieldCategoryEnum(GoogleAdsFieldCategoryEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFieldCategoryEnum Clone() { + return new GoogleAdsFieldCategoryEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GoogleAdsFieldCategoryEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GoogleAdsFieldCategoryEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GoogleAdsFieldCategoryEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the GoogleAdsFieldCategoryEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The category of the artifact. + /// + public enum GoogleAdsFieldCategory { + /// + /// Unspecified + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Unknown + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The described artifact is a resource. + /// + [pbr::OriginalName("RESOURCE")] Resource = 2, + /// + /// The described artifact is a field and is an attribute of a resource. + /// Including a resource attribute field in a query may segment the query if + /// the resource to which it is attributed segments the resource found in + /// the FROM clause. + /// + [pbr::OriginalName("ATTRIBUTE")] Attribute = 3, + /// + /// The described artifact is a field and always segments search queries. + /// + [pbr::OriginalName("SEGMENT")] Segment = 5, + /// + /// The described artifact is a field and is a metric. It never segments + /// search queries. + /// + [pbr::OriginalName("METRIC")] Metric = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GoogleAdsFieldDataType.cs b/src/V3/Stubs/GoogleAdsFieldDataType.cs new file mode 100644 index 000000000..1711eb508 --- /dev/null +++ b/src/V3/Stubs/GoogleAdsFieldDataType.cs @@ -0,0 +1,249 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/google_ads_field_data_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/google_ads_field_data_type.proto + public static partial class GoogleAdsFieldDataTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/google_ads_field_data_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GoogleAdsFieldDataTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9nb29nbGVfYWRzX2Zp", + "ZWxkX2RhdGFfdHlwZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i2wEKGkdvb2ds", + "ZUFkc0ZpZWxkRGF0YVR5cGVFbnVtIrwBChZHb29nbGVBZHNGaWVsZERhdGFU", + "eXBlEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgsKB0JPT0xFQU4Q", + "AhIICgREQVRFEAMSCgoGRE9VQkxFEAQSCAoERU5VTRAFEgkKBUZMT0FUEAYS", + "CQoFSU5UMzIQBxIJCgVJTlQ2NBAIEgsKB01FU1NBR0UQCRIRCg1SRVNPVVJD", + "RV9OQU1FEAoSCgoGU1RSSU5HEAsSCgoGVUlOVDY0EAxC8AEKIWNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IbR29vZ2xlQWRzRmllbGREYXRh", + "VHlwZVByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29n", + "bGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6", + "RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldDataTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldDataTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldDataTypeEnum.Types.GoogleAdsFieldDataType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container holding the various data types. + /// + public sealed partial class GoogleAdsFieldDataTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GoogleAdsFieldDataTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.GoogleAdsFieldDataTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFieldDataTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFieldDataTypeEnum(GoogleAdsFieldDataTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsFieldDataTypeEnum Clone() { + return new GoogleAdsFieldDataTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GoogleAdsFieldDataTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GoogleAdsFieldDataTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GoogleAdsFieldDataTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the GoogleAdsFieldDataTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// These are the various types a GoogleAdsService artifact may take on. + /// + public enum GoogleAdsFieldDataType { + /// + /// Unspecified + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Unknown + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Maps to google.protobuf.BoolValue + /// + /// Applicable operators: =, != + /// + [pbr::OriginalName("BOOLEAN")] Boolean = 2, + /// + /// Maps to google.protobuf.StringValue. It can be compared using the set of + /// operators specific to dates however. + /// + /// Applicable operators: =, <, >, <=, >=, BETWEEN, DURING, and IN + /// + [pbr::OriginalName("DATE")] Date = 3, + /// + /// Maps to google.protobuf.DoubleValue + /// + /// Applicable operators: =, !=, <, >, IN, NOT IN + /// + [pbr::OriginalName("DOUBLE")] Double = 4, + /// + /// Maps to an enum. It's specific definition can be found at type_url. + /// + /// Applicable operators: =, !=, IN, NOT IN + /// + [pbr::OriginalName("ENUM")] Enum = 5, + /// + /// Maps to google.protobuf.FloatValue + /// + /// Applicable operators: =, !=, <, >, IN, NOT IN + /// + [pbr::OriginalName("FLOAT")] Float = 6, + /// + /// Maps to google.protobuf.Int32Value + /// + /// Applicable operators: =, !=, <, >, <=, >=, BETWEEN, IN, NOT IN + /// + [pbr::OriginalName("INT32")] Int32 = 7, + /// + /// Maps to google.protobuf.Int64Value + /// + /// Applicable operators: =, !=, <, >, <=, >=, BETWEEN, IN, NOT IN + /// + [pbr::OriginalName("INT64")] Int64 = 8, + /// + /// Maps to a protocol buffer message type. The data type's details can be + /// found in type_url. + /// + /// No operators work with MESSAGE fields. + /// + [pbr::OriginalName("MESSAGE")] Message = 9, + /// + /// Maps to google.protobuf.StringValue. Represents the resource name + /// (unique id) of a resource or one of its foreign keys. + /// + /// No operators work with RESOURCE_NAME fields. + /// + [pbr::OriginalName("RESOURCE_NAME")] ResourceName = 10, + /// + /// Maps to google.protobuf.StringValue. + /// + /// Applicable operators: =, !=, LIKE, NOT LIKE, IN, NOT IN + /// + [pbr::OriginalName("STRING")] String = 11, + /// + /// Maps to google.protobuf.UInt64Value + /// + /// Applicable operators: =, !=, <, >, <=, >=, BETWEEN, IN, NOT IN + /// + [pbr::OriginalName("UINT64")] Uint64 = 12, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GoogleAdsFieldService.cs b/src/V3/Stubs/GoogleAdsFieldService.cs new file mode 100644 index 000000000..b6eaef12a --- /dev/null +++ b/src/V3/Stubs/GoogleAdsFieldService.cs @@ -0,0 +1,599 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/google_ads_field_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/google_ads_field_service.proto + public static partial class GoogleAdsFieldServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/google_ads_field_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GoogleAdsFieldServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9nb29nbGVfYWRz", + "X2ZpZWxkX3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "Z29vZ2xlX2Fkc19maWVsZC5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkv", + "ZmllbGRfYmVoYXZpb3IucHJvdG8iNgoYR2V0R29vZ2xlQWRzRmllbGRSZXF1", + "ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiJZChxTZWFyY2hHb29n", + "bGVBZHNGaWVsZHNSZXF1ZXN0EhIKBXF1ZXJ5GAEgASgJQgPgQQISEgoKcGFn", + "ZV90b2tlbhgCIAEoCRIRCglwYWdlX3NpemUYAyABKAUimQEKHVNlYXJjaEdv", + "b2dsZUFkc0ZpZWxkc1Jlc3BvbnNlEkIKB3Jlc3VsdHMYASADKAsyMS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuR29vZ2xlQWRzRmllbGQS", + "FwoPbmV4dF9wYWdlX3Rva2VuGAIgASgJEhsKE3RvdGFsX3Jlc3VsdHNfY291", + "bnQYAyABKAMywgMKFUdvb2dsZUFkc0ZpZWxkU2VydmljZRLBAQoRR2V0R29v", + "Z2xlQWRzRmllbGQSOi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5HZXRHb29nbGVBZHNGaWVsZFJlcXVlc3QaMS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5yZXNvdXJjZXMuR29vZ2xlQWRzRmllbGQiPYLT5JMCJxIlL3Yz", + "L3tyZXNvdXJjZV9uYW1lPWdvb2dsZUFkc0ZpZWxkcy8qfdpBDXJlc291cmNl", + "X25hbWUSxwEKFVNlYXJjaEdvb2dsZUFkc0ZpZWxkcxI+Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLlNlYXJjaEdvb2dsZUFkc0ZpZWxkc1Jl", + "cXVlc3QaPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5TZWFy", + "Y2hHb29nbGVBZHNGaWVsZHNSZXNwb25zZSItgtPkkwIfIhovdjMvZ29vZ2xl", + "QWRzRmllbGRzOnNlYXJjaDoBKtpBBXF1ZXJ5GhvKQRhnb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb21CgQIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlc0IaR29vZ2xlQWRzRmllbGRTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29n", + "bGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xT", + "ZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNl", + "c2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.GoogleAdsFieldReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetGoogleAdsFieldRequest), global::Google.Ads.GoogleAds.V3.Services.GetGoogleAdsFieldRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsRequest), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsRequest.Parser, new[]{ "Query", "PageToken", "PageSize" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsResponse), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsResponse.Parser, new[]{ "Results", "NextPageToken", "TotalResultsCount" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [GoogleAdsFieldService.GetGoogleAdsField][google.ads.googleads.v3.services.GoogleAdsFieldService.GetGoogleAdsField]. + /// + public sealed partial class GetGoogleAdsFieldRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetGoogleAdsFieldRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsFieldServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGoogleAdsFieldRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGoogleAdsFieldRequest(GetGoogleAdsFieldRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGoogleAdsFieldRequest Clone() { + return new GetGoogleAdsFieldRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the field to get. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetGoogleAdsFieldRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetGoogleAdsFieldRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetGoogleAdsFieldRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [GoogleAdsFieldService.SearchGoogleAdsFields][google.ads.googleads.v3.services.GoogleAdsFieldService.SearchGoogleAdsFields]. + /// + public sealed partial class SearchGoogleAdsFieldsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SearchGoogleAdsFieldsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsFieldServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsFieldsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsFieldsRequest(SearchGoogleAdsFieldsRequest other) : this() { + query_ = other.query_; + pageToken_ = other.pageToken_; + pageSize_ = other.pageSize_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsFieldsRequest Clone() { + return new SearchGoogleAdsFieldsRequest(this); + } + + /// Field number for the "query" field. + public const int QueryFieldNumber = 1; + private string query_ = ""; + /// + /// Required. The query string. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Query { + get { return query_; } + set { + query_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "page_token" field. + public const int PageTokenFieldNumber = 2; + private string pageToken_ = ""; + /// + /// Token of the page to retrieve. If not specified, the first page of + /// results will be returned. Use the value obtained from `next_page_token` + /// in the previous response in order to request the next page of results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PageToken { + get { return pageToken_; } + set { + pageToken_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "page_size" field. + public const int PageSizeFieldNumber = 3; + private int pageSize_; + /// + /// Number of elements to retrieve in a single page. + /// When too large a page is requested, the server may decide to further + /// limit the number of returned resources. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int PageSize { + get { return pageSize_; } + set { + pageSize_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SearchGoogleAdsFieldsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SearchGoogleAdsFieldsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Query != other.Query) return false; + if (PageToken != other.PageToken) return false; + if (PageSize != other.PageSize) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (Query.Length != 0) hash ^= Query.GetHashCode(); + if (PageToken.Length != 0) hash ^= PageToken.GetHashCode(); + if (PageSize != 0) hash ^= PageSize.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (Query.Length != 0) { + output.WriteRawTag(10); + output.WriteString(Query); + } + if (PageToken.Length != 0) { + output.WriteRawTag(18); + output.WriteString(PageToken); + } + if (PageSize != 0) { + output.WriteRawTag(24); + output.WriteInt32(PageSize); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (Query.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Query); + } + if (PageToken.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(PageToken); + } + if (PageSize != 0) { + size += 1 + pb::CodedOutputStream.ComputeInt32Size(PageSize); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SearchGoogleAdsFieldsRequest other) { + if (other == null) { + return; + } + if (other.Query.Length != 0) { + Query = other.Query; + } + if (other.PageToken.Length != 0) { + PageToken = other.PageToken; + } + if (other.PageSize != 0) { + PageSize = other.PageSize; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + Query = input.ReadString(); + break; + } + case 18: { + PageToken = input.ReadString(); + break; + } + case 24: { + PageSize = input.ReadInt32(); + break; + } + } + } + } + + } + + /// + /// Response message for [GoogleAdsFieldService.SearchGoogleAdsFields][google.ads.googleads.v3.services.GoogleAdsFieldService.SearchGoogleAdsFields]. + /// + public sealed partial class SearchGoogleAdsFieldsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SearchGoogleAdsFieldsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsFieldServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsFieldsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsFieldsResponse(SearchGoogleAdsFieldsResponse other) : this() { + results_ = other.results_.Clone(); + nextPageToken_ = other.nextPageToken_; + totalResultsCount_ = other.totalResultsCount_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsFieldsResponse Clone() { + return new SearchGoogleAdsFieldsResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Resources.GoogleAdsField.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// The list of fields that matched the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + /// Field number for the "next_page_token" field. + public const int NextPageTokenFieldNumber = 2; + private string nextPageToken_ = ""; + /// + /// Pagination token used to retrieve the next page of results. Pass the + /// content of this string as the `page_token` attribute of the next request. + /// `next_page_token` is not returned for the last page. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string NextPageToken { + get { return nextPageToken_; } + set { + nextPageToken_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "total_results_count" field. + public const int TotalResultsCountFieldNumber = 3; + private long totalResultsCount_; + /// + /// Total number of results that match the query ignoring the LIMIT clause. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long TotalResultsCount { + get { return totalResultsCount_; } + set { + totalResultsCount_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SearchGoogleAdsFieldsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SearchGoogleAdsFieldsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + if (NextPageToken != other.NextPageToken) return false; + if (TotalResultsCount != other.TotalResultsCount) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (NextPageToken.Length != 0) hash ^= NextPageToken.GetHashCode(); + if (TotalResultsCount != 0L) hash ^= TotalResultsCount.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (NextPageToken.Length != 0) { + output.WriteRawTag(18); + output.WriteString(NextPageToken); + } + if (TotalResultsCount != 0L) { + output.WriteRawTag(24); + output.WriteInt64(TotalResultsCount); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (NextPageToken.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(NextPageToken); + } + if (TotalResultsCount != 0L) { + size += 1 + pb::CodedOutputStream.ComputeInt64Size(TotalResultsCount); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SearchGoogleAdsFieldsResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + if (other.NextPageToken.Length != 0) { + NextPageToken = other.NextPageToken; + } + if (other.TotalResultsCount != 0L) { + TotalResultsCount = other.TotalResultsCount; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 18: { + NextPageToken = input.ReadString(); + break; + } + case 24: { + TotalResultsCount = input.ReadInt64(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GoogleAdsFieldServiceClient.cs b/src/V3/Stubs/GoogleAdsFieldServiceClient.cs new file mode 100644 index 000000000..7cb8ac763 --- /dev/null +++ b/src/V3/Stubs/GoogleAdsFieldServiceClient.cs @@ -0,0 +1,755 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class GoogleAdsFieldServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static GoogleAdsFieldServiceSettings GetDefault() => new GoogleAdsFieldServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public GoogleAdsFieldServiceSettings() { } + + private GoogleAdsFieldServiceSettings(GoogleAdsFieldServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetGoogleAdsFieldSettings = existing.GetGoogleAdsFieldSettings; + SearchGoogleAdsFieldsSettings = existing.SearchGoogleAdsFieldsSettings; + OnCopy(existing); + } + + partial void OnCopy(GoogleAdsFieldServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// GoogleAdsFieldServiceClient.GetGoogleAdsField and GoogleAdsFieldServiceClient.GetGoogleAdsFieldAsync. + /// + /// + /// The default GoogleAdsFieldServiceClient.GetGoogleAdsField and + /// GoogleAdsFieldServiceClient.GetGoogleAdsFieldAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetGoogleAdsFieldSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// GoogleAdsFieldServiceClient.SearchGoogleAdsFields and GoogleAdsFieldServiceClient.SearchGoogleAdsFieldsAsync. + /// + /// + /// The default GoogleAdsFieldServiceClient.SearchGoogleAdsFields and + /// GoogleAdsFieldServiceClient.SearchGoogleAdsFieldsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings SearchGoogleAdsFieldsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public GoogleAdsFieldServiceSettings Clone() => new GoogleAdsFieldServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class GoogleAdsFieldServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public GoogleAdsFieldServiceSettings Settings { get; set; } + + /// + public override GoogleAdsFieldServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return GoogleAdsFieldServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return GoogleAdsFieldServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => GoogleAdsFieldServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => GoogleAdsFieldServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => GoogleAdsFieldServiceClient.ChannelPool; + } + + /// + /// GoogleAdsFieldService client wrapper, for convenient use. + /// + public abstract partial class GoogleAdsFieldServiceClient + { + /// + /// The default endpoint for the GoogleAdsFieldService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default GoogleAdsFieldService scopes. + /// + /// + /// The default GoogleAdsFieldService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GoogleAdsFieldServiceClient client = await GoogleAdsFieldServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GoogleAdsFieldServiceClient.DefaultEndpoint.Host, GoogleAdsFieldServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GoogleAdsFieldServiceClient client = GoogleAdsFieldServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, GoogleAdsFieldServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GoogleAdsFieldServiceClient client = GoogleAdsFieldServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GoogleAdsFieldServiceClient.DefaultEndpoint.Host, GoogleAdsFieldServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GoogleAdsFieldServiceClient client = GoogleAdsFieldServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static GoogleAdsFieldServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, GoogleAdsFieldServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GoogleAdsFieldServiceClient Create(grpccore::Channel channel, GoogleAdsFieldServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GoogleAdsFieldServiceClient Create(grpccore::CallInvoker callInvoker, GoogleAdsFieldServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + GoogleAdsFieldService.GoogleAdsFieldServiceClient grpcClient = new GoogleAdsFieldService.GoogleAdsFieldServiceClient(callInvoker); + return new GoogleAdsFieldServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC GoogleAdsFieldService client. + /// + public virtual GoogleAdsFieldService.GoogleAdsFieldServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns just the requested field. + /// + /// + /// Required. The resource name of the field to get. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGoogleAdsFieldAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGoogleAdsFieldAsync( + new GetGoogleAdsFieldRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns just the requested field. + /// + /// + /// Required. The resource name of the field to get. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGoogleAdsFieldAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetGoogleAdsFieldAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns just the requested field. + /// + /// + /// Required. The resource name of the field to get. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GoogleAdsField GetGoogleAdsField( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGoogleAdsField( + new GetGoogleAdsFieldRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns just the requested field. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGoogleAdsFieldAsync( + GetGoogleAdsFieldRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns just the requested field. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGoogleAdsFieldAsync( + GetGoogleAdsFieldRequest request, + st::CancellationToken cancellationToken) => GetGoogleAdsFieldAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns just the requested field. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GoogleAdsField GetGoogleAdsField( + GetGoogleAdsFieldRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns all fields that match the search query. + /// + /// + /// Required. The query string. + /// + /// + /// The token returned from the previous request. + /// A value of null or an empty string retrieves the first page. + /// + /// + /// The size of page to request. The response will not be larger than this, but may be smaller. + /// A value of null or 0 uses a server-defined page size. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public virtual gax::PagedAsyncEnumerable SearchGoogleAdsFieldsAsync( + string query, + string pageToken = null, + int? pageSize = null, + gaxgrpc::CallSettings callSettings = null) => SearchGoogleAdsFieldsAsync( + new SearchGoogleAdsFieldsRequest + { + Query = gax::GaxPreconditions.CheckNotNullOrEmpty(query, nameof(query)), + PageToken = pageToken ?? "", + PageSize = pageSize ?? 0, + }, + callSettings); + + /// + /// Returns all fields that match the search query. + /// + /// + /// Required. The query string. + /// + /// + /// The token returned from the previous request. + /// A value of null or an empty string retrieves the first page. + /// + /// + /// The size of page to request. The response will not be larger than this, but may be smaller. + /// A value of null or 0 uses a server-defined page size. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public virtual gax::PagedEnumerable SearchGoogleAdsFields( + string query, + string pageToken = null, + int? pageSize = null, + gaxgrpc::CallSettings callSettings = null) => SearchGoogleAdsFields( + new SearchGoogleAdsFieldsRequest + { + Query = gax::GaxPreconditions.CheckNotNullOrEmpty(query, nameof(query)), + PageToken = pageToken ?? "", + PageSize = pageSize ?? 0, + }, + callSettings); + + /// + /// Returns all fields that match the search query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public virtual gax::PagedAsyncEnumerable SearchGoogleAdsFieldsAsync( + SearchGoogleAdsFieldsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns all fields that match the search query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public virtual gax::PagedEnumerable SearchGoogleAdsFields( + SearchGoogleAdsFieldsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// GoogleAdsFieldService client wrapper implementation, for convenient use. + /// + public sealed partial class GoogleAdsFieldServiceClientImpl : GoogleAdsFieldServiceClient + { + private readonly gaxgrpc::ApiCall _callGetGoogleAdsField; + private readonly gaxgrpc::ApiCall _callSearchGoogleAdsFields; + + /// + /// Constructs a client wrapper for the GoogleAdsFieldService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public GoogleAdsFieldServiceClientImpl(GoogleAdsFieldService.GoogleAdsFieldServiceClient grpcClient, GoogleAdsFieldServiceSettings settings) + { + GrpcClient = grpcClient; + GoogleAdsFieldServiceSettings effectiveSettings = settings ?? GoogleAdsFieldServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetGoogleAdsField = clientHelper.BuildApiCall( + GrpcClient.GetGoogleAdsFieldAsync, GrpcClient.GetGoogleAdsField, effectiveSettings.GetGoogleAdsFieldSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callSearchGoogleAdsFields = clientHelper.BuildApiCall( + GrpcClient.SearchGoogleAdsFieldsAsync, GrpcClient.SearchGoogleAdsFields, effectiveSettings.SearchGoogleAdsFieldsSettings); + Modify_ApiCall(ref _callGetGoogleAdsField); + Modify_GetGoogleAdsFieldApiCall(ref _callGetGoogleAdsField); + Modify_ApiCall(ref _callSearchGoogleAdsFields); + Modify_SearchGoogleAdsFieldsApiCall(ref _callSearchGoogleAdsFields); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetGoogleAdsFieldApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_SearchGoogleAdsFieldsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(GoogleAdsFieldService.GoogleAdsFieldServiceClient grpcClient, GoogleAdsFieldServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC GoogleAdsFieldService client. + /// + public override GoogleAdsFieldService.GoogleAdsFieldServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetGoogleAdsFieldRequest(ref GetGoogleAdsFieldRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_SearchGoogleAdsFieldsRequest(ref SearchGoogleAdsFieldsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns just the requested field. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetGoogleAdsFieldAsync( + GetGoogleAdsFieldRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGoogleAdsFieldRequest(ref request, ref callSettings); + return _callGetGoogleAdsField.Async(request, callSettings); + } + + /// + /// Returns just the requested field. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::GoogleAdsField GetGoogleAdsField( + GetGoogleAdsFieldRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGoogleAdsFieldRequest(ref request, ref callSettings); + return _callGetGoogleAdsField.Sync(request, callSettings); + } + + /// + /// Returns all fields that match the search query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public override gax::PagedAsyncEnumerable SearchGoogleAdsFieldsAsync( + SearchGoogleAdsFieldsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_SearchGoogleAdsFieldsRequest(ref request, ref callSettings); + return new gaxgrpc::GrpcPagedAsyncEnumerable(_callSearchGoogleAdsFields, request, callSettings); + } + + /// + /// Returns all fields that match the search query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public override gax::PagedEnumerable SearchGoogleAdsFields( + SearchGoogleAdsFieldsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_SearchGoogleAdsFieldsRequest(ref request, ref callSettings); + return new gaxgrpc::GrpcPagedEnumerable(_callSearchGoogleAdsFields, request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + public partial class SearchGoogleAdsFieldsRequest : gaxgrpc::IPageRequest { } + public partial class SearchGoogleAdsFieldsResponse : gaxgrpc::IPageResponse + { + /// + /// Returns an enumerator that iterates through the resources in this response. + /// + public scg::IEnumerator GetEnumerator() => Results.GetEnumerator(); + + /// + sc::IEnumerator sc::IEnumerable.GetEnumerator() => GetEnumerator(); + } + + +} diff --git a/src/V3/Stubs/GoogleAdsFieldServiceGrpc.cs b/src/V3/Stubs/GoogleAdsFieldServiceGrpc.cs new file mode 100644 index 000000000..6e207fc95 --- /dev/null +++ b/src/V3/Stubs/GoogleAdsFieldServiceGrpc.cs @@ -0,0 +1,224 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/google_ads_field_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch Google Ads API fields. + /// + public static partial class GoogleAdsFieldService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.GoogleAdsFieldService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetGoogleAdsFieldRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetGoogleAdsFieldRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_GoogleAdsField = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.GoogleAdsField.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsFieldsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsFieldsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetGoogleAdsField = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetGoogleAdsField", + __Marshaller_google_ads_googleads_v3_services_GetGoogleAdsFieldRequest, + __Marshaller_google_ads_googleads_v3_resources_GoogleAdsField); + + static readonly grpc::Method __Method_SearchGoogleAdsFields = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "SearchGoogleAdsFields", + __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsFieldsRequest, + __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsFieldsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsFieldServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of GoogleAdsFieldService + public abstract partial class GoogleAdsFieldServiceBase + { + /// + /// Returns just the requested field. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetGoogleAdsField(global::Google.Ads.GoogleAds.V3.Services.GetGoogleAdsFieldRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Returns all fields that match the search query. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task SearchGoogleAdsFields(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for GoogleAdsFieldService + public partial class GoogleAdsFieldServiceClient : grpc::ClientBase + { + /// Creates a new client for GoogleAdsFieldService + /// The channel to use to make remote calls. + public GoogleAdsFieldServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for GoogleAdsFieldService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public GoogleAdsFieldServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected GoogleAdsFieldServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected GoogleAdsFieldServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns just the requested field. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GoogleAdsField GetGoogleAdsField(global::Google.Ads.GoogleAds.V3.Services.GetGoogleAdsFieldRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGoogleAdsField(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns just the requested field. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GoogleAdsField GetGoogleAdsField(global::Google.Ads.GoogleAds.V3.Services.GetGoogleAdsFieldRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetGoogleAdsField, null, options, request); + } + /// + /// Returns just the requested field. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGoogleAdsFieldAsync(global::Google.Ads.GoogleAds.V3.Services.GetGoogleAdsFieldRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGoogleAdsFieldAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns just the requested field. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGoogleAdsFieldAsync(global::Google.Ads.GoogleAds.V3.Services.GetGoogleAdsFieldRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetGoogleAdsField, null, options, request); + } + /// + /// Returns all fields that match the search query. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsResponse SearchGoogleAdsFields(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return SearchGoogleAdsFields(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all fields that match the search query. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsResponse SearchGoogleAdsFields(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_SearchGoogleAdsFields, null, options, request); + } + /// + /// Returns all fields that match the search query. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall SearchGoogleAdsFieldsAsync(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return SearchGoogleAdsFieldsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all fields that match the search query. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall SearchGoogleAdsFieldsAsync(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsFieldsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_SearchGoogleAdsFields, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override GoogleAdsFieldServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new GoogleAdsFieldServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(GoogleAdsFieldServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetGoogleAdsField, serviceImpl.GetGoogleAdsField) + .AddMethod(__Method_SearchGoogleAdsFields, serviceImpl.SearchGoogleAdsFields).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, GoogleAdsFieldServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetGoogleAdsField, serviceImpl.GetGoogleAdsField); + serviceBinder.AddMethod(__Method_SearchGoogleAdsFields, serviceImpl.SearchGoogleAdsFields); + } + + } +} +#endregion diff --git a/src/V3/Stubs/GoogleAdsService.cs b/src/V3/Stubs/GoogleAdsService.cs new file mode 100644 index 000000000..15c826150 --- /dev/null +++ b/src/V3/Stubs/GoogleAdsService.cs @@ -0,0 +1,9329 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/google_ads_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/google_ads_service.proto + public static partial class GoogleAdsServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/google_ads_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GoogleAdsServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9nb29nbGVfYWRz", + "X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzGixnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vbWV0cmljcy5w", + "cm90bxotZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL3NlZ21lbnRz", + "LnByb3RvGjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9zdW1tYXJ5", + "X3Jvd19zZXR0aW5nLnByb3RvGjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9y", + "ZXNvdXJjZXMvYWNjb3VudF9idWRnZXQucHJvdG8aP2dvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL3Jlc291cmNlcy9hY2NvdW50X2J1ZGdldF9wcm9wb3NhbC5w", + "cm90bxowZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2FkX2dy", + "b3VwLnByb3RvGjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "YWRfZ3JvdXBfYWQucHJvdG8aPmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jl", + "c291cmNlcy9hZF9ncm91cF9hZF9hc3NldF92aWV3LnByb3RvGjlnb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBfYWRfbGFiZWwu", + "cHJvdG8aPmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9hZF9n", + "cm91cF9hdWRpZW5jZV92aWV3LnByb3RvGj1nb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9yZXNvdXJjZXMvYWRfZ3JvdXBfYmlkX21vZGlmaWVyLnByb3RvGjpn", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBfY3Jp", + "dGVyaW9uLnByb3RvGkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvYWRfZ3JvdXBfY3JpdGVyaW9uX2xhYmVsLnByb3RvGkVnb29nbGUvYWRz", + "L2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWRfZ3JvdXBfY3JpdGVyaW9uX3Np", + "bXVsYXRpb24ucHJvdG8aQmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcy9hZF9ncm91cF9leHRlbnNpb25fc2V0dGluZy5wcm90bxo1Z29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2FkX2dyb3VwX2ZlZWQucHJv", + "dG8aNmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9hZF9ncm91", + "cF9sYWJlbC5wcm90bxo7Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzL2FkX2dyb3VwX3NpbXVsYXRpb24ucHJvdG8aNGdvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL3Jlc291cmNlcy9hZF9wYXJhbWV0ZXIucHJvdG8aOGdvb2ds", + "ZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9hZF9zY2hlZHVsZV92aWV3", + "LnByb3RvGjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvYWdl", + "X3JhbmdlX3ZpZXcucHJvdG8aLWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jl", + "c291cmNlcy9hc3NldC5wcm90bxo4Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "cmVzb3VyY2VzL2JpZGRpbmdfc3RyYXRlZ3kucHJvdG8aNWdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL3Jlc291cmNlcy9iaWxsaW5nX3NldHVwLnByb3RvGjBn", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ24ucHJv", + "dG8aPmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9jYW1wYWln", + "bl9hdWRpZW5jZV92aWV3LnByb3RvGj1nb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9yZXNvdXJjZXMvY2FtcGFpZ25fYmlkX21vZGlmaWVyLnByb3RvGjdnb29n", + "bGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2FtcGFpZ25fYnVkZ2V0", + "LnByb3RvGjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY2Ft", + "cGFpZ25fY3JpdGVyaW9uLnByb3RvGkVnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9yZXNvdXJjZXMvY2FtcGFpZ25fY3JpdGVyaW9uX3NpbXVsYXRpb24ucHJv", + "dG8aNmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9jYW1wYWln", + "bl9kcmFmdC5wcm90bxo7Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzL2NhbXBhaWduX2V4cGVyaW1lbnQucHJvdG8aQmdvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL3Jlc291cmNlcy9jYW1wYWlnbl9leHRlbnNpb25fc2V0dGlu", + "Zy5wcm90bxo1Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2Nh", + "bXBhaWduX2ZlZWQucHJvdG8aNmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jl", + "c291cmNlcy9jYW1wYWlnbl9sYWJlbC5wcm90bxo7Z29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvcmVzb3VyY2VzL2NhbXBhaWduX3NoYXJlZF9zZXQucHJvdG8a", + "OGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9jYXJyaWVyX2Nv", + "bnN0YW50LnByb3RvGjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvY2hhbmdlX3N0YXR1cy5wcm90bxoyZ29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvcmVzb3VyY2VzL2NsaWNrX3ZpZXcucHJvdG8aOWdvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL3Jlc291cmNlcy9jb252ZXJzaW9uX2FjdGlvbi5wcm90bxo5", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2N1cnJlbmN5X2Nv", + "bnN0YW50LnByb3RvGjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvY3VzdG9tX2ludGVyZXN0LnByb3RvGjBnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9yZXNvdXJjZXMvY3VzdG9tZXIucHJvdG8aN2dvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL3Jlc291cmNlcy9jdXN0b21lcl9jbGllbnQucHJvdG8aPGdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9jdXN0b21lcl9jbGll", + "bnRfbGluay5wcm90bxpCZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzL2N1c3RvbWVyX2V4dGVuc2lvbl9zZXR0aW5nLnByb3RvGjVnb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJfZmVlZC5wcm90", + "bxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2N1c3RvbWVy", + "X2xhYmVsLnByb3RvGj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvY3VzdG9tZXJfbWFuYWdlcl9saW5rLnByb3RvGkNnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9yZXNvdXJjZXMvY3VzdG9tZXJfbmVnYXRpdmVfY3JpdGVy", + "aW9uLnByb3RvGj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "ZGV0YWlsX3BsYWNlbWVudF92aWV3LnByb3RvGjxnb29nbGUvYWRzL2dvb2ds", + "ZWFkcy92My9yZXNvdXJjZXMvZGlzcGxheV9rZXl3b3JkX3ZpZXcucHJvdG8a", + "NWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9kaXN0YW5jZV92", + "aWV3LnByb3RvGjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "ZG9tYWluX2NhdGVnb3J5LnByb3RvGktnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9yZXNvdXJjZXMvZHluYW1pY19zZWFyY2hfYWRzX3NlYXJjaF90ZXJtX3Zp", + "ZXcucHJvdG8aQmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9l", + "eHBhbmRlZF9sYW5kaW5nX3BhZ2Vfdmlldy5wcm90bxo7Z29vZ2xlL2Fkcy9n", + "b29nbGVhZHMvdjMvcmVzb3VyY2VzL2V4dGVuc2lvbl9mZWVkX2l0ZW0ucHJv", + "dG8aLGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9mZWVkLnBy", + "b3RvGjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZmVlZF9p", + "dGVtLnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "ZmVlZF9pdGVtX3RhcmdldC5wcm90bxo0Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvcmVzb3VyY2VzL2ZlZWRfbWFwcGluZy5wcm90bxo9Z29vZ2xlL2Fkcy9n", + "b29nbGVhZHMvdjMvcmVzb3VyY2VzL2ZlZWRfcGxhY2Vob2xkZXJfdmlldy5w", + "cm90bxozZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2dlbmRl", + "cl92aWV3LnByb3RvGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvZ2VvX3RhcmdldF9jb25zdGFudC5wcm90bxo3Z29vZ2xlL2Fkcy9nb29n", + "bGVhZHMvdjMvcmVzb3VyY2VzL2dlb2dyYXBoaWNfdmlldy5wcm90bxo8Z29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL2dyb3VwX3BsYWNlbWVu", + "dF92aWV3LnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJj", + "ZXMvaG90ZWxfZ3JvdXBfdmlldy5wcm90bxo+Z29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvcmVzb3VyY2VzL2hvdGVsX3BlcmZvcm1hbmNlX3ZpZXcucHJvdG8a", + "NGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9rZXl3b3JkX3Bs", + "YW4ucHJvdG8aPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9r", + "ZXl3b3JkX3BsYW5fYWRfZ3JvdXAucHJvdG8aPWdvb2dsZS9hZHMvZ29vZ2xl", + "YWRzL3YzL3Jlc291cmNlcy9rZXl3b3JkX3BsYW5fY2FtcGFpZ24ucHJvdG8a", + "PGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9rZXl3b3JkX3Bs", + "YW5fa2V5d29yZC5wcm90bxpFZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVz", + "b3VyY2VzL2tleXdvcmRfcGxhbl9uZWdhdGl2ZV9rZXl3b3JkLnByb3RvGjRn", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMva2V5d29yZF92aWV3", + "LnByb3RvGi1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvbGFi", + "ZWwucHJvdG8aOWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9s", + "YW5kaW5nX3BhZ2Vfdmlldy5wcm90bxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvcmVzb3VyY2VzL2xhbmd1YWdlX2NvbnN0YW50LnByb3RvGjVnb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvbG9jYXRpb25fdmlldy5wcm90", + "bxo+Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL21hbmFnZWRf", + "cGxhY2VtZW50X3ZpZXcucHJvdG8aMmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L3Jlc291cmNlcy9tZWRpYV9maWxlLnByb3RvGkRnb29nbGUvYWRzL2dvb2ds", + "ZWFkcy92My9yZXNvdXJjZXMvbW9iaWxlX2FwcF9jYXRlZ29yeV9jb25zdGFu", + "dC5wcm90bxo+Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL21v", + "YmlsZV9kZXZpY2VfY29uc3RhbnQucHJvdG8aMmdvb2dsZS9hZHMvZ29vZ2xl", + "YWRzL3YzL3Jlc291cmNlcy9tdXRhdGVfam9iLnByb3RvGklnb29nbGUvYWRz", + "L2dvb2dsZWFkcy92My9yZXNvdXJjZXMvb3BlcmF0aW5nX3N5c3RlbV92ZXJz", + "aW9uX2NvbnN0YW50LnByb3RvGkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9y", + "ZXNvdXJjZXMvcGFpZF9vcmdhbmljX3NlYXJjaF90ZXJtX3ZpZXcucHJvdG8a", + "PGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9wYXJlbnRhbF9z", + "dGF0dXNfdmlldy5wcm90bxpJZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVz", + "b3VyY2VzL3Byb2R1Y3RfYmlkZGluZ19jYXRlZ29yeV9jb25zdGFudC5wcm90", + "bxo6Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL3Byb2R1Y3Rf", + "Z3JvdXBfdmlldy5wcm90bxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVz", + "b3VyY2VzL3JlY29tbWVuZGF0aW9uLnByb3RvGjpnb29nbGUvYWRzL2dvb2ds", + "ZWFkcy92My9yZXNvdXJjZXMvcmVtYXJrZXRpbmdfYWN0aW9uLnByb3RvGjhn", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvc2VhcmNoX3Rlcm1f", + "dmlldy5wcm90bxo4Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2Vz", + "L3NoYXJlZF9jcml0ZXJpb24ucHJvdG8aMmdvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL3Jlc291cmNlcy9zaGFyZWRfc2V0LnByb3RvGkFnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9yZXNvdXJjZXMvc2hvcHBpbmdfcGVyZm9ybWFuY2Vfdmll", + "dy5wcm90bxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzL3Rv", + "cGljX2NvbnN0YW50LnByb3RvGjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9y", + "ZXNvdXJjZXMvdG9waWNfdmlldy5wcm90bxo1Z29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvcmVzb3VyY2VzL3VzZXJfaW50ZXJlc3QucHJvdG8aMWdvb2dsZS9h", + "ZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy91c2VyX2xpc3QucHJvdG8aOmdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy91c2VyX2xvY2F0aW9u", + "X3ZpZXcucHJvdG8aLWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNl", + "cy92aWRlby5wcm90bxpAZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvc2Vydmlj", + "ZXMvYWRfZ3JvdXBfYWRfbGFiZWxfc2VydmljZS5wcm90bxo6Z29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvc2VydmljZXMvYWRfZ3JvdXBfYWRfc2VydmljZS5w", + "cm90bxpEZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXMvYWRfZ3Jv", + "dXBfYmlkX21vZGlmaWVyX3NlcnZpY2UucHJvdG8aR2dvb2dsZS9hZHMvZ29v", + "Z2xlYWRzL3YzL3NlcnZpY2VzL2FkX2dyb3VwX2NyaXRlcmlvbl9sYWJlbF9z", + "ZXJ2aWNlLnByb3RvGkFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNl", + "cy9hZF9ncm91cF9jcml0ZXJpb25fc2VydmljZS5wcm90bxpJZ29vZ2xlL2Fk", + "cy9nb29nbGVhZHMvdjMvc2VydmljZXMvYWRfZ3JvdXBfZXh0ZW5zaW9uX3Nl", + "dHRpbmdfc2VydmljZS5wcm90bxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMv", + "c2VydmljZXMvYWRfZ3JvdXBfZmVlZF9zZXJ2aWNlLnByb3RvGj1nb29nbGUv", + "YWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9hZF9ncm91cF9sYWJlbF9zZXJ2", + "aWNlLnByb3RvGjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9h", + "ZF9ncm91cF9zZXJ2aWNlLnByb3RvGjtnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9zZXJ2aWNlcy9hZF9wYXJhbWV0ZXJfc2VydmljZS5wcm90bxo0Z29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXMvYXNzZXRfc2VydmljZS5wcm90", + "bxo/Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXMvYmlkZGluZ19z", + "dHJhdGVneV9zZXJ2aWNlLnByb3RvGkRnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9zZXJ2aWNlcy9jYW1wYWlnbl9iaWRfbW9kaWZpZXJfc2VydmljZS5wcm90", + "bxo+Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXMvY2FtcGFpZ25f", + "YnVkZ2V0X3NlcnZpY2UucHJvdG8aQWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L3NlcnZpY2VzL2NhbXBhaWduX2NyaXRlcmlvbl9zZXJ2aWNlLnByb3RvGj1n", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jYW1wYWlnbl9kcmFm", + "dF9zZXJ2aWNlLnByb3RvGkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2", + "aWNlcy9jYW1wYWlnbl9leHBlcmltZW50X3NlcnZpY2UucHJvdG8aSWdvb2ds", + "ZS9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzL2NhbXBhaWduX2V4dGVuc2lv", + "bl9zZXR0aW5nX3NlcnZpY2UucHJvdG8aPGdvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL3NlcnZpY2VzL2NhbXBhaWduX2ZlZWRfc2VydmljZS5wcm90bxo9Z29v", + "Z2xlL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXMvY2FtcGFpZ25fbGFiZWxf", + "c2VydmljZS5wcm90bxo3Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvc2Vydmlj", + "ZXMvY2FtcGFpZ25fc2VydmljZS5wcm90bxpCZ29vZ2xlL2Fkcy9nb29nbGVh", + "ZHMvdjMvc2VydmljZXMvY2FtcGFpZ25fc2hhcmVkX3NldF9zZXJ2aWNlLnBy", + "b3RvGkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9jb252ZXJz", + "aW9uX2FjdGlvbl9zZXJ2aWNlLnByb3RvGklnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9zZXJ2aWNlcy9jdXN0b21lcl9leHRlbnNpb25fc2V0dGluZ19zZXJ2", + "aWNlLnByb3RvGjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9j", + "dXN0b21lcl9mZWVkX3NlcnZpY2UucHJvdG8aPWdvb2dsZS9hZHMvZ29vZ2xl", + "YWRzL3YzL3NlcnZpY2VzL2N1c3RvbWVyX2xhYmVsX3NlcnZpY2UucHJvdG8a", + "Smdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzL2N1c3RvbWVyX25l", + "Z2F0aXZlX2NyaXRlcmlvbl9zZXJ2aWNlLnByb3RvGjdnb29nbGUvYWRzL2dv", + "b2dsZWFkcy92My9zZXJ2aWNlcy9jdXN0b21lcl9zZXJ2aWNlLnByb3RvGkJn", + "b29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9leHRlbnNpb25fZmVl", + "ZF9pdGVtX3NlcnZpY2UucHJvdG8aOGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3Yz", + "L3NlcnZpY2VzL2ZlZWRfaXRlbV9zZXJ2aWNlLnByb3RvGj9nb29nbGUvYWRz", + "L2dvb2dsZWFkcy92My9zZXJ2aWNlcy9mZWVkX2l0ZW1fdGFyZ2V0X3NlcnZp", + "Y2UucHJvdG8aO2dvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzL2Zl", + "ZWRfbWFwcGluZ19zZXJ2aWNlLnByb3RvGjNnb29nbGUvYWRzL2dvb2dsZWFk", + "cy92My9zZXJ2aWNlcy9mZWVkX3NlcnZpY2UucHJvdG8aNGdvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL3NlcnZpY2VzL2xhYmVsX3NlcnZpY2UucHJvdG8aOWdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3NlcnZpY2VzL21lZGlhX2ZpbGVfc2Vy", + "dmljZS5wcm90bxpBZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXMv", + "cmVtYXJrZXRpbmdfYWN0aW9uX3NlcnZpY2UucHJvdG8aP2dvb2dsZS9hZHMv", + "Z29vZ2xlYWRzL3YzL3NlcnZpY2VzL3NoYXJlZF9jcml0ZXJpb25fc2Vydmlj", + "ZS5wcm90bxo5Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXMvc2hh", + "cmVkX3NldF9zZXJ2aWNlLnByb3RvGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92", + "My9zZXJ2aWNlcy91c2VyX2xpc3Rfc2VydmljZS5wcm90bxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8a", + "H2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aIGdvb2dsZS9wcm90", + "b2J1Zi9maWVsZF9tYXNrLnByb3RvGhdnb29nbGUvcnBjL3N0YXR1cy5wcm90", + "byKNAgoWU2VhcmNoR29vZ2xlQWRzUmVxdWVzdBIYCgtjdXN0b21lcl9pZBgB", + "IAEoCUID4EECEhIKBXF1ZXJ5GAIgASgJQgPgQQISEgoKcGFnZV90b2tlbhgD", + "IAEoCRIRCglwYWdlX3NpemUYBCABKAUSFQoNdmFsaWRhdGVfb25seRgFIAEo", + "CBIiChpyZXR1cm5fdG90YWxfcmVzdWx0c19jb3VudBgHIAEoCBJjChNzdW1t", + "YXJ5X3Jvd19zZXR0aW5nGAggASgOMkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZW51bXMuU3VtbWFyeVJvd1NldHRpbmdFbnVtLlN1bW1hcnlSb3dTZXR0", + "aW5nIoUCChdTZWFyY2hHb29nbGVBZHNSZXNwb25zZRI/CgdyZXN1bHRzGAEg", + "AygLMi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR29vZ2xl", + "QWRzUm93EhcKD25leHRfcGFnZV90b2tlbhgCIAEoCRIbChN0b3RhbF9yZXN1", + "bHRzX2NvdW50GAMgASgDEi4KCmZpZWxkX21hc2sYBSABKAsyGi5nb29nbGUu", + "cHJvdG9idWYuRmllbGRNYXNrEkMKC3N1bW1hcnlfcm93GAYgASgLMi4uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR29vZ2xlQWRzUm93IrEB", + "ChxTZWFyY2hHb29nbGVBZHNTdHJlYW1SZXF1ZXN0EhgKC2N1c3RvbWVyX2lk", + "GAEgASgJQgPgQQISEgoFcXVlcnkYAiABKAlCA+BBAhJjChNzdW1tYXJ5X3Jv", + "d19zZXR0aW5nGAMgASgOMkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMuU3VtbWFyeVJvd1NldHRpbmdFbnVtLlN1bW1hcnlSb3dTZXR0aW5nItUB", + "Ch1TZWFyY2hHb29nbGVBZHNTdHJlYW1SZXNwb25zZRI/CgdyZXN1bHRzGAEg", + "AygLMi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR29vZ2xl", + "QWRzUm93Ei4KCmZpZWxkX21hc2sYAiABKAsyGi5nb29nbGUucHJvdG9idWYu", + "RmllbGRNYXNrEkMKC3N1bW1hcnlfcm93GAMgASgLMi4uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuR29vZ2xlQWRzUm93Itw9CgxHb29nbGVB", + "ZHNSb3cSSAoOYWNjb3VudF9idWRnZXQYKiABKAsyMC5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5yZXNvdXJjZXMuQWNjb3VudEJ1ZGdldBJZChdhY2NvdW50", + "X2J1ZGdldF9wcm9wb3NhbBgrIAEoCzI4Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5BY2NvdW50QnVkZ2V0UHJvcG9zYWwSPAoIYWRfZ3Jv", + "dXAYAyABKAsyKi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMu", + "QWRHcm91cBJBCgthZF9ncm91cF9hZBgQIAEoCzIsLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5BZEdyb3VwQWQSVgoWYWRfZ3JvdXBfYWRf", + "YXNzZXRfdmlldxiDASABKAsyNS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMuQWRHcm91cEFkQXNzZXRWaWV3EkwKEWFkX2dyb3VwX2FkX2xh", + "YmVsGHggASgLMjEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "LkFkR3JvdXBBZExhYmVsElYKFmFkX2dyb3VwX2F1ZGllbmNlX3ZpZXcYOSAB", + "KAsyNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91", + "cEF1ZGllbmNlVmlldxJUChVhZF9ncm91cF9iaWRfbW9kaWZpZXIYGCABKAsy", + "NS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cEJp", + "ZE1vZGlmaWVyEk8KEmFkX2dyb3VwX2NyaXRlcmlvbhgRIAEoCzIzLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZEdyb3VwQ3JpdGVyaW9u", + "EloKGGFkX2dyb3VwX2NyaXRlcmlvbl9sYWJlbBh5IAEoCzI4Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZEdyb3VwQ3JpdGVyaW9uTGFi", + "ZWwSZAodYWRfZ3JvdXBfY3JpdGVyaW9uX3NpbXVsYXRpb24YbiABKAsyPS5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRHcm91cENyaXRl", + "cmlvblNpbXVsYXRpb24SXgoaYWRfZ3JvdXBfZXh0ZW5zaW9uX3NldHRpbmcY", + "cCABKAsyOi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQWRH", + "cm91cEV4dGVuc2lvblNldHRpbmcSRQoNYWRfZ3JvdXBfZmVlZBhDIAEoCzIu", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5BZEdyb3VwRmVl", + "ZBJHCg5hZF9ncm91cF9sYWJlbBhzIAEoCzIvLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlcy5BZEdyb3VwTGFiZWwSUQoTYWRfZ3JvdXBfc2lt", + "dWxhdGlvbhhrIAEoCzI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291", + "cmNlcy5BZEdyb3VwU2ltdWxhdGlvbhJFCgxhZF9wYXJhbWV0ZXIYggEgASgL", + "Mi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkFkUGFyYW1l", + "dGVyEkcKDmFnZV9yYW5nZV92aWV3GDAgASgLMi8uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMucmVzb3VyY2VzLkFnZVJhbmdlVmlldxJLChBhZF9zY2hlZHVs", + "ZV92aWV3GFkgASgLMjEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkFkU2NoZWR1bGVWaWV3EkoKD2RvbWFpbl9jYXRlZ29yeRhbIAEoCzIx", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5Eb21haW5DYXRl", + "Z29yeRI3CgVhc3NldBhpIAEoCzIoLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlcy5Bc3NldBJMChBiaWRkaW5nX3N0cmF0ZWd5GBIgASgLMjIu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkJpZGRpbmdTdHJh", + "dGVneRJGCg1iaWxsaW5nX3NldHVwGCkgASgLMi8uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMucmVzb3VyY2VzLkJpbGxpbmdTZXR1cBJKCg9jYW1wYWlnbl9i", + "dWRnZXQYEyABKAsyMS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMuQ2FtcGFpZ25CdWRnZXQSPQoIY2FtcGFpZ24YAiABKAsyKy5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2FtcGFpZ24SVwoWY2FtcGFp", + "Z25fYXVkaWVuY2VfdmlldxhFIAEoCzI3Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5DYW1wYWlnbkF1ZGllbmNlVmlldxJVChVjYW1wYWln", + "bl9iaWRfbW9kaWZpZXIYGiABKAsyNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5yZXNvdXJjZXMuQ2FtcGFpZ25CaWRNb2RpZmllchJQChJjYW1wYWlnbl9j", + "cml0ZXJpb24YFCABKAsyNC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNv", + "dXJjZXMuQ2FtcGFpZ25Dcml0ZXJpb24SZQodY2FtcGFpZ25fY3JpdGVyaW9u", + "X3NpbXVsYXRpb24YbyABKAsyPi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMuQ2FtcGFpZ25Dcml0ZXJpb25TaW11bGF0aW9uEkgKDmNhbXBh", + "aWduX2RyYWZ0GDEgASgLMjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLkNhbXBhaWduRHJhZnQSUgoTY2FtcGFpZ25fZXhwZXJpbWVudBhU", + "IAEoCzI1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DYW1w", + "YWlnbkV4cGVyaW1lbnQSXwoaY2FtcGFpZ25fZXh0ZW5zaW9uX3NldHRpbmcY", + "cSABKAsyOy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2Ft", + "cGFpZ25FeHRlbnNpb25TZXR0aW5nEkYKDWNhbXBhaWduX2ZlZWQYPyABKAsy", + "Ly5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2FtcGFpZ25G", + "ZWVkEkgKDmNhbXBhaWduX2xhYmVsGGwgASgLMjAuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMucmVzb3VyY2VzLkNhbXBhaWduTGFiZWwSUQoTY2FtcGFpZ25f", + "c2hhcmVkX3NldBgeIAEoCzI0Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlcy5DYW1wYWlnblNoYXJlZFNldBJMChBjYXJyaWVyX2NvbnN0YW50", + "GEIgASgLMjIuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNh", + "cnJpZXJDb25zdGFudBJGCg1jaGFuZ2Vfc3RhdHVzGCUgASgLMi8uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkNoYW5nZVN0YXR1cxJOChFj", + "b252ZXJzaW9uX2FjdGlvbhhnIAEoCzIzLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5Db252ZXJzaW9uQWN0aW9uEkAKCmNsaWNrX3ZpZXcY", + "eiABKAsyLC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ2xp", + "Y2tWaWV3Ek8KEWN1cnJlbmN5X2NvbnN0YW50GIYBIAEoCzIzLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DdXJyZW5jeUNvbnN0YW50EkoK", + "D2N1c3RvbV9pbnRlcmVzdBhoIAEoCzIxLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5DdXN0b21JbnRlcmVzdBI9CghjdXN0b21lchgBIAEo", + "CzIrLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DdXN0b21l", + "chJVChVjdXN0b21lcl9tYW5hZ2VyX2xpbmsYPSABKAsyNi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuQ3VzdG9tZXJNYW5hZ2VyTGluaxJT", + "ChRjdXN0b21lcl9jbGllbnRfbGluaxg+IAEoCzI1Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5DdXN0b21lckNsaWVudExpbmsSSgoPY3Vz", + "dG9tZXJfY2xpZW50GEYgASgLMjEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzLkN1c3RvbWVyQ2xpZW50El8KGmN1c3RvbWVyX2V4dGVuc2lv", + "bl9zZXR0aW5nGHIgASgLMjsuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLkN1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZxJGCg1jdXN0b21lcl9m", + "ZWVkGEAgASgLMi8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2Vz", + "LkN1c3RvbWVyRmVlZBJICg5jdXN0b21lcl9sYWJlbBh8IAEoCzIwLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DdXN0b21lckxhYmVsEmEK", + "G2N1c3RvbWVyX25lZ2F0aXZlX2NyaXRlcmlvbhhYIAEoCzI8Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5DdXN0b21lck5lZ2F0aXZlQ3Jp", + "dGVyaW9uElUKFWRldGFpbF9wbGFjZW1lbnRfdmlldxh2IAEoCzI2Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5EZXRhaWxQbGFjZW1lbnRW", + "aWV3ElMKFGRpc3BsYXlfa2V5d29yZF92aWV3GC8gASgLMjUuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkRpc3BsYXlLZXl3b3JkVmlldxJH", + "Cg1kaXN0YW5jZV92aWV3GIQBIAEoCzIvLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5EaXN0YW5jZVZpZXcSbgojZHluYW1pY19zZWFyY2hf", + "YWRzX3NlYXJjaF90ZXJtX3ZpZXcYaiABKAsyQS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5yZXNvdXJjZXMuRHluYW1pY1NlYXJjaEFkc1NlYXJjaFRlcm1W", + "aWV3El8KGmV4cGFuZGVkX2xhbmRpbmdfcGFnZV92aWV3GIABIAEoCzI6Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5FeHBhbmRlZExhbmRp", + "bmdQYWdlVmlldxJRChNleHRlbnNpb25fZmVlZF9pdGVtGFUgASgLMjQuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkV4dGVuc2lvbkZlZWRJ", + "dGVtEjUKBGZlZWQYLiABKAsyJy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMuRmVlZBI+CglmZWVkX2l0ZW0YMiABKAsyKy5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuRmVlZEl0ZW0SSwoQZmVlZF9pdGVt", + "X3RhcmdldBh0IAEoCzIxLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291", + "cmNlcy5GZWVkSXRlbVRhcmdldBJECgxmZWVkX21hcHBpbmcYOiABKAsyLi5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuRmVlZE1hcHBpbmcS", + "VQoVZmVlZF9wbGFjZWhvbGRlcl92aWV3GGEgASgLMjYuZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMucmVzb3VyY2VzLkZlZWRQbGFjZWhvbGRlclZpZXcSQgoL", + "Z2VuZGVyX3ZpZXcYKCABKAsyLS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMuR2VuZGVyVmlldxJRChNnZW9fdGFyZ2V0X2NvbnN0YW50GBcg", + "ASgLMjQuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLkdlb1Rh", + "cmdldENvbnN0YW50EkoKD2dlb2dyYXBoaWNfdmlldxh9IAEoCzIxLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5HZW9ncmFwaGljVmlldxJT", + "ChRncm91cF9wbGFjZW1lbnRfdmlldxh3IAEoCzI1Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5Hcm91cFBsYWNlbWVudFZpZXcSSwoQaG90", + "ZWxfZ3JvdXBfdmlldxgzIAEoCzIxLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlcy5Ib3RlbEdyb3VwVmlldxJXChZob3RlbF9wZXJmb3JtYW5j", + "ZV92aWV3GEcgASgLMjcuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkhvdGVsUGVyZm9ybWFuY2VWaWV3EkQKDGtleXdvcmRfdmlldxgVIAEo", + "CzIuLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5LZXl3b3Jk", + "VmlldxJECgxrZXl3b3JkX3BsYW4YICABKAsyLi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5yZXNvdXJjZXMuS2V5d29yZFBsYW4SVQoVa2V5d29yZF9wbGFu", + "X2NhbXBhaWduGCEgASgLMjYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLktleXdvcmRQbGFuQ2FtcGFpZ24SZAoda2V5d29yZF9wbGFuX25l", + "Z2F0aXZlX2tleXdvcmQYIiABKAsyPS5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5yZXNvdXJjZXMuS2V5d29yZFBsYW5OZWdhdGl2ZUtleXdvcmQSVAoVa2V5", + "d29yZF9wbGFuX2FkX2dyb3VwGCMgASgLMjUuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMucmVzb3VyY2VzLktleXdvcmRQbGFuQWRHcm91cBJTChRrZXl3b3Jk", + "X3BsYW5fa2V5d29yZBgkIAEoCzI1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlcy5LZXl3b3JkUGxhbktleXdvcmQSNwoFbGFiZWwYNCABKAsy", + "KC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuTGFiZWwSTQoR", + "bGFuZGluZ19wYWdlX3ZpZXcYfiABKAsyMi5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXMuTGFuZGluZ1BhZ2VWaWV3Ek4KEWxhbmd1YWdlX2Nv", + "bnN0YW50GDcgASgLMjMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkxhbmd1YWdlQ29uc3RhbnQSRgoNbG9jYXRpb25fdmlldxh7IAEoCzIv", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5Mb2NhdGlvblZp", + "ZXcSVwoWbWFuYWdlZF9wbGFjZW1lbnRfdmlldxg1IAEoCzI3Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5NYW5hZ2VkUGxhY2VtZW50Vmll", + "dxJACgptZWRpYV9maWxlGFogASgLMiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzLk1lZGlhRmlsZRJiChxtb2JpbGVfYXBwX2NhdGVnb3J5", + "X2NvbnN0YW50GFcgASgLMjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLk1vYmlsZUFwcENhdGVnb3J5Q29uc3RhbnQSVwoWbW9iaWxlX2Rl", + "dmljZV9jb25zdGFudBhiIAEoCzI3Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnJlc291cmNlcy5Nb2JpbGVEZXZpY2VDb25zdGFudBJACgptdXRhdGVfam9i", + "GH8gASgLMiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLk11", + "dGF0ZUpvYhJsCiFvcGVyYXRpbmdfc3lzdGVtX3ZlcnNpb25fY29uc3RhbnQY", + "ViABKAsyQS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuT3Bl", + "cmF0aW5nU3lzdGVtVmVyc2lvbkNvbnN0YW50EmQKHXBhaWRfb3JnYW5pY19z", + "ZWFyY2hfdGVybV92aWV3GIEBIAEoCzI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5QYWlkT3JnYW5pY1NlYXJjaFRlcm1WaWV3ElMKFHBh", + "cmVudGFsX3N0YXR1c192aWV3GC0gASgLMjUuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMucmVzb3VyY2VzLlBhcmVudGFsU3RhdHVzVmlldxJsCiFwcm9kdWN0", + "X2JpZGRpbmdfY2F0ZWdvcnlfY29uc3RhbnQYbSABKAsyQS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuUHJvZHVjdEJpZGRpbmdDYXRlZ29y", + "eUNvbnN0YW50Ek8KEnByb2R1Y3RfZ3JvdXBfdmlldxg2IAEoCzIzLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5Qcm9kdWN0R3JvdXBWaWV3", + "EkkKDnJlY29tbWVuZGF0aW9uGBYgASgLMjEuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMucmVzb3VyY2VzLlJlY29tbWVuZGF0aW9uEksKEHNlYXJjaF90ZXJt", + "X3ZpZXcYRCABKAsyMS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJj", + "ZXMuU2VhcmNoVGVybVZpZXcSTAoQc2hhcmVkX2NyaXRlcmlvbhgdIAEoCzIy", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5TaGFyZWRDcml0", + "ZXJpb24SQAoKc2hhcmVkX3NldBgbIAEoCzIsLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlcy5TaGFyZWRTZXQSXQoZc2hvcHBpbmdfcGVyZm9y", + "bWFuY2Vfdmlldxh1IAEoCzI6Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlcy5TaG9wcGluZ1BlcmZvcm1hbmNlVmlldxJACgp0b3BpY192aWV3", + "GCwgASgLMiwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLlRv", + "cGljVmlldxJGCg11c2VyX2ludGVyZXN0GDsgASgLMi8uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMucmVzb3VyY2VzLlVzZXJJbnRlcmVzdBI+Cgl1c2VyX2xp", + "c3QYJiABKAsyKy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMu", + "VXNlckxpc3QSUAoSdXNlcl9sb2NhdGlvbl92aWV3GIcBIAEoCzIzLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5Vc2VyTG9jYXRpb25WaWV3", + "ElAKEnJlbWFya2V0aW5nX2FjdGlvbhg8IAEoCzI0Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5SZW1hcmtldGluZ0FjdGlvbhJICg50b3Bp", + "Y19jb25zdGFudBgfIAEoCzIwLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlcy5Ub3BpY0NvbnN0YW50EjcKBXZpZGVvGCcgASgLMiguZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLlZpZGVvEjgKB21ldHJpY3MY", + "BCABKAsyJy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5jb21tb24uTWV0cmlj", + "cxI6CghzZWdtZW50cxhmIAEoCzIoLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmNvbW1vbi5TZWdtZW50cyK1AQoWTXV0YXRlR29vZ2xlQWRzUmVxdWVzdBIY", + "CgtjdXN0b21lcl9pZBgBIAEoCUID4EECElEKEW11dGF0ZV9vcGVyYXRpb25z", + "GAIgAygLMjEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0", + "YXRlT3BlcmF0aW9uQgPgQQISFwoPcGFydGlhbF9mYWlsdXJlGAMgASgIEhUK", + "DXZhbGlkYXRlX29ubHkYBCABKAgiqwEKF011dGF0ZUdvb2dsZUFkc1Jlc3Bv", + "bnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJvchgDIAEoCzISLmdvb2dsZS5y", + "cGMuU3RhdHVzEl0KGm11dGF0ZV9vcGVyYXRpb25fcmVzcG9uc2VzGAEgAygL", + "MjkuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlT3Bl", + "cmF0aW9uUmVzcG9uc2UisB0KD011dGF0ZU9wZXJhdGlvbhJgChthZF9ncm91", + "cF9hZF9sYWJlbF9vcGVyYXRpb24YESABKAsyOS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5BZEdyb3VwQWRMYWJlbE9wZXJhdGlvbkgAElUK", + "FWFkX2dyb3VwX2FkX29wZXJhdGlvbhgBIAEoCzI0Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLkFkR3JvdXBBZE9wZXJhdGlvbkgAEmgKH2Fk", + "X2dyb3VwX2JpZF9tb2RpZmllcl9vcGVyYXRpb24YAiABKAsyPS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5BZEdyb3VwQmlkTW9kaWZpZXJP", + "cGVyYXRpb25IABJuCiJhZF9ncm91cF9jcml0ZXJpb25fbGFiZWxfb3BlcmF0", + "aW9uGBIgASgLMkAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "QWRHcm91cENyaXRlcmlvbkxhYmVsT3BlcmF0aW9uSAASYwocYWRfZ3JvdXBf", + "Y3JpdGVyaW9uX29wZXJhdGlvbhgDIAEoCzI7Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzLkFkR3JvdXBDcml0ZXJpb25PcGVyYXRpb25IABJy", + "CiRhZF9ncm91cF9leHRlbnNpb25fc2V0dGluZ19vcGVyYXRpb24YEyABKAsy", + "Qi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5BZEdyb3VwRXh0", + "ZW5zaW9uU2V0dGluZ09wZXJhdGlvbkgAElkKF2FkX2dyb3VwX2ZlZWRfb3Bl", + "cmF0aW9uGBQgASgLMjYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuQWRHcm91cEZlZWRPcGVyYXRpb25IABJbChhhZF9ncm91cF9sYWJlbF9v", + "cGVyYXRpb24YFSABKAsyNy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5BZEdyb3VwTGFiZWxPcGVyYXRpb25IABJQChJhZF9ncm91cF9vcGVy", + "YXRpb24YBSABKAsyMi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5BZEdyb3VwT3BlcmF0aW9uSAASWAoWYWRfcGFyYW1ldGVyX29wZXJhdGlv", + "bhgWIAEoCzI2Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkFk", + "UGFyYW1ldGVyT3BlcmF0aW9uSAASSwoPYXNzZXRfb3BlcmF0aW9uGBcgASgL", + "MjAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQXNzZXRPcGVy", + "YXRpb25IABJgChpiaWRkaW5nX3N0cmF0ZWd5X29wZXJhdGlvbhgGIAEoCzI6", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkJpZGRpbmdTdHJh", + "dGVneU9wZXJhdGlvbkgAEmkKH2NhbXBhaWduX2JpZF9tb2RpZmllcl9vcGVy", + "YXRpb24YByABKAsyPi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5DYW1wYWlnbkJpZE1vZGlmaWVyT3BlcmF0aW9uSAASXgoZY2FtcGFpZ25f", + "YnVkZ2V0X29wZXJhdGlvbhgIIAEoCzI5Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLkNhbXBhaWduQnVkZ2V0T3BlcmF0aW9uSAASZAocY2Ft", + "cGFpZ25fY3JpdGVyaW9uX29wZXJhdGlvbhgNIAEoCzI8Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLkNhbXBhaWduQ3JpdGVyaW9uT3BlcmF0", + "aW9uSAASXAoYY2FtcGFpZ25fZHJhZnRfb3BlcmF0aW9uGBggASgLMjguZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ2FtcGFpZ25EcmFmdE9w", + "ZXJhdGlvbkgAEmYKHWNhbXBhaWduX2V4cGVyaW1lbnRfb3BlcmF0aW9uGBkg", + "ASgLMj0uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ2FtcGFp", + "Z25FeHBlcmltZW50T3BlcmF0aW9uSAAScwokY2FtcGFpZ25fZXh0ZW5zaW9u", + "X3NldHRpbmdfb3BlcmF0aW9uGBogASgLMkMuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuQ2FtcGFpZ25FeHRlbnNpb25TZXR0aW5nT3BlcmF0", + "aW9uSAASWgoXY2FtcGFpZ25fZmVlZF9vcGVyYXRpb24YGyABKAsyNy5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5DYW1wYWlnbkZlZWRPcGVy", + "YXRpb25IABJcChhjYW1wYWlnbl9sYWJlbF9vcGVyYXRpb24YHCABKAsyOC5n", + "b29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5DYW1wYWlnbkxhYmVs", + "T3BlcmF0aW9uSAASUQoSY2FtcGFpZ25fb3BlcmF0aW9uGAogASgLMjMuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ2FtcGFpZ25PcGVyYXRp", + "b25IABJlCh1jYW1wYWlnbl9zaGFyZWRfc2V0X29wZXJhdGlvbhgLIAEoCzI8", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkNhbXBhaWduU2hh", + "cmVkU2V0T3BlcmF0aW9uSAASYgobY29udmVyc2lvbl9hY3Rpb25fb3BlcmF0", + "aW9uGAwgASgLMjsuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "Q29udmVyc2lvbkFjdGlvbk9wZXJhdGlvbkgAEnMKJGN1c3RvbWVyX2V4dGVu", + "c2lvbl9zZXR0aW5nX29wZXJhdGlvbhgeIAEoCzJDLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLkN1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ09w", + "ZXJhdGlvbkgAEloKF2N1c3RvbWVyX2ZlZWRfb3BlcmF0aW9uGB8gASgLMjcu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ3VzdG9tZXJGZWVk", + "T3BlcmF0aW9uSAASXAoYY3VzdG9tZXJfbGFiZWxfb3BlcmF0aW9uGCAgASgL", + "MjguZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuQ3VzdG9tZXJM", + "YWJlbE9wZXJhdGlvbkgAEnUKJWN1c3RvbWVyX25lZ2F0aXZlX2NyaXRlcmlv", + "bl9vcGVyYXRpb24YIiABKAsyRC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5DdXN0b21lck5lZ2F0aXZlQ3JpdGVyaW9uT3BlcmF0aW9uSAAS", + "UQoSY3VzdG9tZXJfb3BlcmF0aW9uGCMgASgLMjMuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXMuQ3VzdG9tZXJPcGVyYXRpb25IABJlCh1leHRl", + "bnNpb25fZmVlZF9pdGVtX29wZXJhdGlvbhgkIAEoCzI8Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLkV4dGVuc2lvbkZlZWRJdGVtT3BlcmF0", + "aW9uSAASUgoTZmVlZF9pdGVtX29wZXJhdGlvbhglIAEoCzIzLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkZlZWRJdGVtT3BlcmF0aW9uSAAS", + "XwoaZmVlZF9pdGVtX3RhcmdldF9vcGVyYXRpb24YJiABKAsyOS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5GZWVkSXRlbVRhcmdldE9wZXJh", + "dGlvbkgAElgKFmZlZWRfbWFwcGluZ19vcGVyYXRpb24YJyABKAsyNi5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5GZWVkTWFwcGluZ09wZXJh", + "dGlvbkgAEkkKDmZlZWRfb3BlcmF0aW9uGCggASgLMi8uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuRmVlZE9wZXJhdGlvbkgAEksKD2xhYmVs", + "X29wZXJhdGlvbhgpIAEoCzIwLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzLkxhYmVsT3BlcmF0aW9uSAASVAoUbWVkaWFfZmlsZV9vcGVyYXRp", + "b24YKiABKAsyNC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5N", + "ZWRpYUZpbGVPcGVyYXRpb25IABJkChxyZW1hcmtldGluZ19hY3Rpb25fb3Bl", + "cmF0aW9uGCsgASgLMjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuUmVtYXJrZXRpbmdBY3Rpb25PcGVyYXRpb25IABJgChpzaGFyZWRfY3Jp", + "dGVyaW9uX29wZXJhdGlvbhgOIAEoCzI6Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLlNoYXJlZENyaXRlcmlvbk9wZXJhdGlvbkgAElQKFHNo", + "YXJlZF9zZXRfb3BlcmF0aW9uGA8gASgLMjQuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuU2hhcmVkU2V0T3BlcmF0aW9uSAASUgoTdXNlcl9s", + "aXN0X29wZXJhdGlvbhgQIAEoCzIzLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLlVzZXJMaXN0T3BlcmF0aW9uSABCCwoJb3BlcmF0aW9uIrYd", + "ChdNdXRhdGVPcGVyYXRpb25SZXNwb25zZRJgChhhZF9ncm91cF9hZF9sYWJl", + "bF9yZXN1bHQYESABKAsyPC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5NdXRhdGVBZEdyb3VwQWRMYWJlbFJlc3VsdEgAElUKEmFkX2dyb3Vw", + "X2FkX3Jlc3VsdBgBIAEoCzI3Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzLk11dGF0ZUFkR3JvdXBBZFJlc3VsdEgAEmgKHGFkX2dyb3VwX2Jp", + "ZF9tb2RpZmllcl9yZXN1bHQYAiABKAsyQC5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcy5NdXRhdGVBZEdyb3VwQmlkTW9kaWZpZXJSZXN1bHRI", + "ABJuCh9hZF9ncm91cF9jcml0ZXJpb25fbGFiZWxfcmVzdWx0GBIgASgLMkMu", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQWRHcm91", + "cENyaXRlcmlvbkxhYmVsUmVzdWx0SAASYwoZYWRfZ3JvdXBfY3JpdGVyaW9u", + "X3Jlc3VsdBgDIAEoCzI+Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzLk11dGF0ZUFkR3JvdXBDcml0ZXJpb25SZXN1bHRIABJyCiFhZF9ncm91", + "cF9leHRlbnNpb25fc2V0dGluZ19yZXN1bHQYEyABKAsyRS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVBZEdyb3VwRXh0ZW5zaW9u", + "U2V0dGluZ1Jlc3VsdEgAElkKFGFkX2dyb3VwX2ZlZWRfcmVzdWx0GBQgASgL", + "MjkuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQWRH", + "cm91cEZlZWRSZXN1bHRIABJbChVhZF9ncm91cF9sYWJlbF9yZXN1bHQYFSAB", + "KAsyOi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVB", + "ZEdyb3VwTGFiZWxSZXN1bHRIABJQCg9hZF9ncm91cF9yZXN1bHQYBSABKAsy", + "NS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVBZEdy", + "b3VwUmVzdWx0SAASWAoTYWRfcGFyYW1ldGVyX3Jlc3VsdBgWIAEoCzI5Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUFkUGFyYW1l", + "dGVyUmVzdWx0SAASSwoMYXNzZXRfcmVzdWx0GBcgASgLMjMuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQXNzZXRSZXN1bHRIABJg", + "ChdiaWRkaW5nX3N0cmF0ZWd5X3Jlc3VsdBgGIAEoCzI9Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUJpZGRpbmdTdHJhdGVneVJl", + "c3VsdEgAEmkKHGNhbXBhaWduX2JpZF9tb2RpZmllcl9yZXN1bHQYByABKAsy", + "QS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDYW1w", + "YWlnbkJpZE1vZGlmaWVyUmVzdWx0SAASXgoWY2FtcGFpZ25fYnVkZ2V0X3Jl", + "c3VsdBgIIAEoCzI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2Vz", + "Lk11dGF0ZUNhbXBhaWduQnVkZ2V0UmVzdWx0SAASZAoZY2FtcGFpZ25fY3Jp", + "dGVyaW9uX3Jlc3VsdBgNIAEoCzI/Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLk11dGF0ZUNhbXBhaWduQ3JpdGVyaW9uUmVzdWx0SAASXAoV", + "Y2FtcGFpZ25fZHJhZnRfcmVzdWx0GBggASgLMjsuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ2FtcGFpZ25EcmFmdFJlc3VsdEgA", + "EmYKGmNhbXBhaWduX2V4cGVyaW1lbnRfcmVzdWx0GBkgASgLMkAuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ2FtcGFpZ25FeHBl", + "cmltZW50UmVzdWx0SAAScwohY2FtcGFpZ25fZXh0ZW5zaW9uX3NldHRpbmdf", + "cmVzdWx0GBogASgLMkYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vydmlj", + "ZXMuTXV0YXRlQ2FtcGFpZ25FeHRlbnNpb25TZXR0aW5nUmVzdWx0SAASWgoU", + "Y2FtcGFpZ25fZmVlZF9yZXN1bHQYGyABKAsyOi5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDYW1wYWlnbkZlZWRSZXN1bHRIABJc", + "ChVjYW1wYWlnbl9sYWJlbF9yZXN1bHQYHCABKAsyOy5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVDYW1wYWlnbkxhYmVsUmVzdWx0", + "SAASUQoPY2FtcGFpZ25fcmVzdWx0GAogASgLMjYuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ2FtcGFpZ25SZXN1bHRIABJlChpj", + "YW1wYWlnbl9zaGFyZWRfc2V0X3Jlc3VsdBgLIAEoCzI/Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUNhbXBhaWduU2hhcmVkU2V0", + "UmVzdWx0SAASYgoYY29udmVyc2lvbl9hY3Rpb25fcmVzdWx0GAwgASgLMj4u", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ29udmVy", + "c2lvbkFjdGlvblJlc3VsdEgAEnMKIWN1c3RvbWVyX2V4dGVuc2lvbl9zZXR0", + "aW5nX3Jlc3VsdBgeIAEoCzJGLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzLk11dGF0ZUN1c3RvbWVyRXh0ZW5zaW9uU2V0dGluZ1Jlc3VsdEgA", + "EloKFGN1c3RvbWVyX2ZlZWRfcmVzdWx0GB8gASgLMjouZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ3VzdG9tZXJGZWVkUmVzdWx0", + "SAASXAoVY3VzdG9tZXJfbGFiZWxfcmVzdWx0GCAgASgLMjsuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlQ3VzdG9tZXJMYWJlbFJl", + "c3VsdEgAEnQKImN1c3RvbWVyX25lZ2F0aXZlX2NyaXRlcmlvbl9yZXN1bHQY", + "IiABKAsyRi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRh", + "dGVDdXN0b21lck5lZ2F0aXZlQ3JpdGVyaWFSZXN1bHRIABJRCg9jdXN0b21l", + "cl9yZXN1bHQYIyABKAsyNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5NdXRhdGVDdXN0b21lclJlc3VsdEgAEmUKGmV4dGVuc2lvbl9mZWVk", + "X2l0ZW1fcmVzdWx0GCQgASgLMj8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXMuTXV0YXRlRXh0ZW5zaW9uRmVlZEl0ZW1SZXN1bHRIABJSChBm", + "ZWVkX2l0ZW1fcmVzdWx0GCUgASgLMjYuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMuTXV0YXRlRmVlZEl0ZW1SZXN1bHRIABJfChdmZWVkX2l0", + "ZW1fdGFyZ2V0X3Jlc3VsdBgmIAEoCzI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLk11dGF0ZUZlZWRJdGVtVGFyZ2V0UmVzdWx0SAASWAoT", + "ZmVlZF9tYXBwaW5nX3Jlc3VsdBgnIAEoCzI5Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzLk11dGF0ZUZlZWRNYXBwaW5nUmVzdWx0SAASSQoL", + "ZmVlZF9yZXN1bHQYKCABKAsyMi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5NdXRhdGVGZWVkUmVzdWx0SAASSwoMbGFiZWxfcmVzdWx0GCkg", + "ASgLMjMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRl", + "TGFiZWxSZXN1bHRIABJUChFtZWRpYV9maWxlX3Jlc3VsdBgqIAEoCzI3Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZU1lZGlhRmls", + "ZVJlc3VsdEgAEmQKGXJlbWFya2V0aW5nX2FjdGlvbl9yZXN1bHQYKyABKAsy", + "Py5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVSZW1h", + "cmtldGluZ0FjdGlvblJlc3VsdEgAEmAKF3NoYXJlZF9jcml0ZXJpb25fcmVz", + "dWx0GA4gASgLMj0uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "TXV0YXRlU2hhcmVkQ3JpdGVyaW9uUmVzdWx0SAASVAoRc2hhcmVkX3NldF9y", + "ZXN1bHQYDyABKAsyNy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNl", + "cy5NdXRhdGVTaGFyZWRTZXRSZXN1bHRIABJSChB1c2VyX2xpc3RfcmVzdWx0", + "GBAgASgLMjYuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0", + "YXRlVXNlckxpc3RSZXN1bHRIAEIKCghyZXNwb25zZTLCBQoQR29vZ2xlQWRz", + "U2VydmljZRLMAQoGU2VhcmNoEjguZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXMuU2VhcmNoR29vZ2xlQWRzUmVxdWVzdBo5Lmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLnNlcnZpY2VzLlNlYXJjaEdvb2dsZUFkc1Jlc3BvbnNl", + "Ik2C0+STAjMiLi92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2dvb2ds", + "ZUFkczpzZWFyY2g6ASraQRFjdXN0b21lcl9pZCxxdWVyeRLmAQoMU2VhcmNo", + "U3RyZWFtEj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuU2Vh", + "cmNoR29vZ2xlQWRzU3RyZWFtUmVxdWVzdBo/Lmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzLlNlYXJjaEdvb2dsZUFkc1N0cmVhbVJlc3BvbnNl", + "IlOC0+STAjkiNC92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2dvb2ds", + "ZUFkczpzZWFyY2hTdHJlYW06ASraQRFjdXN0b21lcl9pZCxxdWVyeTABEtgB", + "CgZNdXRhdGUSOC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5N", + "dXRhdGVHb29nbGVBZHNSZXF1ZXN0GjkuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuc2VydmljZXMuTXV0YXRlR29vZ2xlQWRzUmVzcG9uc2UiWYLT5JMCMyIu", + "L3YzL2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn0vZ29vZ2xlQWRzOm11dGF0", + "ZToBKtpBHWN1c3RvbWVyX2lkLG11dGF0ZV9vcGVyYXRpb25zGhvKQRhnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb21C/AEKJGNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlc0IVR29vZ2xlQWRzU2VydmljZVByb3RvUAFaSGdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2Vy", + "dmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.MetricsReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Common.SegmentsReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.SummaryRowSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposalReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifierReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulationReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeedReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulationReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdParameterReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AdScheduleViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AgeRangeViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.AssetReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategyReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.BillingSetupReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifierReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignBudgetReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulationReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignDraftReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignExperimentReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignFeedReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignLabelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSetReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CarrierConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ChangeStatusReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ClickViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ConversionActionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomInterestReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerClientReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLinkReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSettingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerFeedReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerLabelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLinkReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.DistanceViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.DomainCategoryReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItemReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.FeedReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.FeedItemReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.FeedItemTargetReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.FeedMappingReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.GenderViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.GeographicViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.HotelGroupViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroupReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaignReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeywordReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeywordReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.KeywordViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.LabelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.LandingPageViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.LanguageConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.LocationViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ManagedPlacementViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.MediaFileReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.MobileAppCategoryConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.MobileDeviceConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.MutateJobReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.OperatingSystemVersionConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.PaidOrganicSearchTermViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ParentalStatusViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ProductBiddingCategoryConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ProductGroupViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.RecommendationReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.RemarketingActionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.SearchTermViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.SharedCriterionReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.SharedSetReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.ShoppingPerformanceViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.TopicConstantReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.TopicViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.UserInterestReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.UserListReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.UserLocationViewReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.VideoReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupAdServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdGroupServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AdParameterServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.AssetServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignDraftServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignFeedServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignLabelServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.ConversionActionServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CustomerFeedServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CustomerLabelServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.CustomerServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.FeedItemServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.FeedMappingServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.FeedServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.LabelServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.MediaFileServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.RemarketingActionServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.SharedCriterionServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.SharedSetServiceReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Services.UserListServiceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsRequest), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsRequest.Parser, new[]{ "CustomerId", "Query", "PageToken", "PageSize", "ValidateOnly", "ReturnTotalResultsCount", "SummaryRowSetting" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsResponse), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsResponse.Parser, new[]{ "Results", "NextPageToken", "TotalResultsCount", "FieldMask", "SummaryRow" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamRequest), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamRequest.Parser, new[]{ "CustomerId", "Query", "SummaryRowSetting" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamResponse), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamResponse.Parser, new[]{ "Results", "FieldMask", "SummaryRow" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow), global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow.Parser, new[]{ "AccountBudget", "AccountBudgetProposal", "AdGroup", "AdGroupAd", "AdGroupAdAssetView", "AdGroupAdLabel", "AdGroupAudienceView", "AdGroupBidModifier", "AdGroupCriterion", "AdGroupCriterionLabel", "AdGroupCriterionSimulation", "AdGroupExtensionSetting", "AdGroupFeed", "AdGroupLabel", "AdGroupSimulation", "AdParameter", "AgeRangeView", "AdScheduleView", "DomainCategory", "Asset", "BiddingStrategy", "BillingSetup", "CampaignBudget", "Campaign", "CampaignAudienceView", "CampaignBidModifier", "CampaignCriterion", "CampaignCriterionSimulation", "CampaignDraft", "CampaignExperiment", "CampaignExtensionSetting", "CampaignFeed", "CampaignLabel", "CampaignSharedSet", "CarrierConstant", "ChangeStatus", "ConversionAction", "ClickView", "CurrencyConstant", "CustomInterest", "Customer", "CustomerManagerLink", "CustomerClientLink", "CustomerClient", "CustomerExtensionSetting", "CustomerFeed", "CustomerLabel", "CustomerNegativeCriterion", "DetailPlacementView", "DisplayKeywordView", "DistanceView", "DynamicSearchAdsSearchTermView", "ExpandedLandingPageView", "ExtensionFeedItem", "Feed", "FeedItem", "FeedItemTarget", "FeedMapping", "FeedPlaceholderView", "GenderView", "GeoTargetConstant", "GeographicView", "GroupPlacementView", "HotelGroupView", "HotelPerformanceView", "KeywordView", "KeywordPlan", "KeywordPlanCampaign", "KeywordPlanNegativeKeyword", "KeywordPlanAdGroup", "KeywordPlanKeyword", "Label", "LandingPageView", "LanguageConstant", "LocationView", "ManagedPlacementView", "MediaFile", "MobileAppCategoryConstant", "MobileDeviceConstant", "MutateJob", "OperatingSystemVersionConstant", "PaidOrganicSearchTermView", "ParentalStatusView", "ProductBiddingCategoryConstant", "ProductGroupView", "Recommendation", "SearchTermView", "SharedCriterion", "SharedSet", "ShoppingPerformanceView", "TopicView", "UserInterest", "UserList", "UserLocationView", "RemarketingAction", "TopicConstant", "Video", "Metrics", "Segments" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsRequest.Parser, new[]{ "CustomerId", "MutateOperations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsResponse.Parser, new[]{ "PartialFailureError", "MutateOperationResponses" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateOperation), global::Google.Ads.GoogleAds.V3.Services.MutateOperation.Parser, new[]{ "AdGroupAdLabelOperation", "AdGroupAdOperation", "AdGroupBidModifierOperation", "AdGroupCriterionLabelOperation", "AdGroupCriterionOperation", "AdGroupExtensionSettingOperation", "AdGroupFeedOperation", "AdGroupLabelOperation", "AdGroupOperation", "AdParameterOperation", "AssetOperation", "BiddingStrategyOperation", "CampaignBidModifierOperation", "CampaignBudgetOperation", "CampaignCriterionOperation", "CampaignDraftOperation", "CampaignExperimentOperation", "CampaignExtensionSettingOperation", "CampaignFeedOperation", "CampaignLabelOperation", "CampaignOperation", "CampaignSharedSetOperation", "ConversionActionOperation", "CustomerExtensionSettingOperation", "CustomerFeedOperation", "CustomerLabelOperation", "CustomerNegativeCriterionOperation", "CustomerOperation", "ExtensionFeedItemOperation", "FeedItemOperation", "FeedItemTargetOperation", "FeedMappingOperation", "FeedOperation", "LabelOperation", "MediaFileOperation", "RemarketingActionOperation", "SharedCriterionOperation", "SharedSetOperation", "UserListOperation" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateOperationResponse), global::Google.Ads.GoogleAds.V3.Services.MutateOperationResponse.Parser, new[]{ "AdGroupAdLabelResult", "AdGroupAdResult", "AdGroupBidModifierResult", "AdGroupCriterionLabelResult", "AdGroupCriterionResult", "AdGroupExtensionSettingResult", "AdGroupFeedResult", "AdGroupLabelResult", "AdGroupResult", "AdParameterResult", "AssetResult", "BiddingStrategyResult", "CampaignBidModifierResult", "CampaignBudgetResult", "CampaignCriterionResult", "CampaignDraftResult", "CampaignExperimentResult", "CampaignExtensionSettingResult", "CampaignFeedResult", "CampaignLabelResult", "CampaignResult", "CampaignSharedSetResult", "ConversionActionResult", "CustomerExtensionSettingResult", "CustomerFeedResult", "CustomerLabelResult", "CustomerNegativeCriterionResult", "CustomerResult", "ExtensionFeedItemResult", "FeedItemResult", "FeedItemTargetResult", "FeedMappingResult", "FeedResult", "LabelResult", "MediaFileResult", "RemarketingActionResult", "SharedCriterionResult", "SharedSetResult", "UserListResult" }, new[]{ "Response" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [GoogleAdsService.Search][google.ads.googleads.v3.services.GoogleAdsService.Search]. + /// + public sealed partial class SearchGoogleAdsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SearchGoogleAdsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsRequest(SearchGoogleAdsRequest other) : this() { + customerId_ = other.customerId_; + query_ = other.query_; + pageToken_ = other.pageToken_; + pageSize_ = other.pageSize_; + validateOnly_ = other.validateOnly_; + returnTotalResultsCount_ = other.returnTotalResultsCount_; + summaryRowSetting_ = other.summaryRowSetting_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsRequest Clone() { + return new SearchGoogleAdsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer being queried. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "query" field. + public const int QueryFieldNumber = 2; + private string query_ = ""; + /// + /// Required. The query string. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Query { + get { return query_; } + set { + query_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "page_token" field. + public const int PageTokenFieldNumber = 3; + private string pageToken_ = ""; + /// + /// Token of the page to retrieve. If not specified, the first + /// page of results will be returned. Use the value obtained from + /// `next_page_token` in the previous response in order to request + /// the next page of results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PageToken { + get { return pageToken_; } + set { + pageToken_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "page_size" field. + public const int PageSizeFieldNumber = 4; + private int pageSize_; + /// + /// Number of elements to retrieve in a single page. + /// When too large a page is requested, the server may decide to + /// further limit the number of returned resources. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int PageSize { + get { return pageSize_; } + set { + pageSize_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 5; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + /// Field number for the "return_total_results_count" field. + public const int ReturnTotalResultsCountFieldNumber = 7; + private bool returnTotalResultsCount_; + /// + /// If true, the total number of results that match the query ignoring the + /// LIMIT clause will be included in the response. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ReturnTotalResultsCount { + get { return returnTotalResultsCount_; } + set { + returnTotalResultsCount_ = value; + } + } + + /// Field number for the "summary_row_setting" field. + public const int SummaryRowSettingFieldNumber = 8; + private global::Google.Ads.GoogleAds.V3.Enums.SummaryRowSettingEnum.Types.SummaryRowSetting summaryRowSetting_ = 0; + /// + /// Determines whether a summary row will be returned. By default, summary row + /// is not returned. If requested, the summary row will be sent in a response + /// by itself after all other query results are returned. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SummaryRowSettingEnum.Types.SummaryRowSetting SummaryRowSetting { + get { return summaryRowSetting_; } + set { + summaryRowSetting_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SearchGoogleAdsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SearchGoogleAdsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (Query != other.Query) return false; + if (PageToken != other.PageToken) return false; + if (PageSize != other.PageSize) return false; + if (ValidateOnly != other.ValidateOnly) return false; + if (ReturnTotalResultsCount != other.ReturnTotalResultsCount) return false; + if (SummaryRowSetting != other.SummaryRowSetting) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (Query.Length != 0) hash ^= Query.GetHashCode(); + if (PageToken.Length != 0) hash ^= PageToken.GetHashCode(); + if (PageSize != 0) hash ^= PageSize.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (ReturnTotalResultsCount != false) hash ^= ReturnTotalResultsCount.GetHashCode(); + if (SummaryRowSetting != 0) hash ^= SummaryRowSetting.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (Query.Length != 0) { + output.WriteRawTag(18); + output.WriteString(Query); + } + if (PageToken.Length != 0) { + output.WriteRawTag(26); + output.WriteString(PageToken); + } + if (PageSize != 0) { + output.WriteRawTag(32); + output.WriteInt32(PageSize); + } + if (ValidateOnly != false) { + output.WriteRawTag(40); + output.WriteBool(ValidateOnly); + } + if (ReturnTotalResultsCount != false) { + output.WriteRawTag(56); + output.WriteBool(ReturnTotalResultsCount); + } + if (SummaryRowSetting != 0) { + output.WriteRawTag(64); + output.WriteEnum((int) SummaryRowSetting); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (Query.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Query); + } + if (PageToken.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(PageToken); + } + if (PageSize != 0) { + size += 1 + pb::CodedOutputStream.ComputeInt32Size(PageSize); + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (ReturnTotalResultsCount != false) { + size += 1 + 1; + } + if (SummaryRowSetting != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) SummaryRowSetting); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SearchGoogleAdsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.Query.Length != 0) { + Query = other.Query; + } + if (other.PageToken.Length != 0) { + PageToken = other.PageToken; + } + if (other.PageSize != 0) { + PageSize = other.PageSize; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + if (other.ReturnTotalResultsCount != false) { + ReturnTotalResultsCount = other.ReturnTotalResultsCount; + } + if (other.SummaryRowSetting != 0) { + SummaryRowSetting = other.SummaryRowSetting; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + Query = input.ReadString(); + break; + } + case 26: { + PageToken = input.ReadString(); + break; + } + case 32: { + PageSize = input.ReadInt32(); + break; + } + case 40: { + ValidateOnly = input.ReadBool(); + break; + } + case 56: { + ReturnTotalResultsCount = input.ReadBool(); + break; + } + case 64: { + SummaryRowSetting = (global::Google.Ads.GoogleAds.V3.Enums.SummaryRowSettingEnum.Types.SummaryRowSetting) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Response message for [GoogleAdsService.Search][google.ads.googleads.v3.services.GoogleAdsService.Search]. + /// + public sealed partial class SearchGoogleAdsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SearchGoogleAdsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsResponse(SearchGoogleAdsResponse other) : this() { + results_ = other.results_.Clone(); + nextPageToken_ = other.nextPageToken_; + totalResultsCount_ = other.totalResultsCount_; + fieldMask_ = other.fieldMask_ != null ? other.fieldMask_.Clone() : null; + summaryRow_ = other.summaryRow_ != null ? other.summaryRow_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsResponse Clone() { + return new SearchGoogleAdsResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// The list of rows that matched the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + /// Field number for the "next_page_token" field. + public const int NextPageTokenFieldNumber = 2; + private string nextPageToken_ = ""; + /// + /// Pagination token used to retrieve the next page of results. + /// Pass the content of this string as the `page_token` attribute of + /// the next request. `next_page_token` is not returned for the last + /// page. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string NextPageToken { + get { return nextPageToken_; } + set { + nextPageToken_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "total_results_count" field. + public const int TotalResultsCountFieldNumber = 3; + private long totalResultsCount_; + /// + /// Total number of results that match the query ignoring the LIMIT + /// clause. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long TotalResultsCount { + get { return totalResultsCount_; } + set { + totalResultsCount_ = value; + } + } + + /// Field number for the "field_mask" field. + public const int FieldMaskFieldNumber = 5; + private global::Google.Protobuf.WellKnownTypes.FieldMask fieldMask_; + /// + /// FieldMask that represents what fields were requested by the user. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask FieldMask { + get { return fieldMask_; } + set { + fieldMask_ = value; + } + } + + /// Field number for the "summary_row" field. + public const int SummaryRowFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow summaryRow_; + /// + /// Summary row that contains summary of metrics in results. + /// Summary of metrics means aggregation of metrics across all results, + /// here aggregation could be sum, average, rate, etc. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow SummaryRow { + get { return summaryRow_; } + set { + summaryRow_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SearchGoogleAdsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SearchGoogleAdsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + if (NextPageToken != other.NextPageToken) return false; + if (TotalResultsCount != other.TotalResultsCount) return false; + if (!object.Equals(FieldMask, other.FieldMask)) return false; + if (!object.Equals(SummaryRow, other.SummaryRow)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (NextPageToken.Length != 0) hash ^= NextPageToken.GetHashCode(); + if (TotalResultsCount != 0L) hash ^= TotalResultsCount.GetHashCode(); + if (fieldMask_ != null) hash ^= FieldMask.GetHashCode(); + if (summaryRow_ != null) hash ^= SummaryRow.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (NextPageToken.Length != 0) { + output.WriteRawTag(18); + output.WriteString(NextPageToken); + } + if (TotalResultsCount != 0L) { + output.WriteRawTag(24); + output.WriteInt64(TotalResultsCount); + } + if (fieldMask_ != null) { + output.WriteRawTag(42); + output.WriteMessage(FieldMask); + } + if (summaryRow_ != null) { + output.WriteRawTag(50); + output.WriteMessage(SummaryRow); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (NextPageToken.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(NextPageToken); + } + if (TotalResultsCount != 0L) { + size += 1 + pb::CodedOutputStream.ComputeInt64Size(TotalResultsCount); + } + if (fieldMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(FieldMask); + } + if (summaryRow_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(SummaryRow); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SearchGoogleAdsResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + if (other.NextPageToken.Length != 0) { + NextPageToken = other.NextPageToken; + } + if (other.TotalResultsCount != 0L) { + TotalResultsCount = other.TotalResultsCount; + } + if (other.fieldMask_ != null) { + if (fieldMask_ == null) { + FieldMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + FieldMask.MergeFrom(other.FieldMask); + } + if (other.summaryRow_ != null) { + if (summaryRow_ == null) { + SummaryRow = new global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow(); + } + SummaryRow.MergeFrom(other.SummaryRow); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 18: { + NextPageToken = input.ReadString(); + break; + } + case 24: { + TotalResultsCount = input.ReadInt64(); + break; + } + case 42: { + if (fieldMask_ == null) { + FieldMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(FieldMask); + break; + } + case 50: { + if (summaryRow_ == null) { + SummaryRow = new global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow(); + } + input.ReadMessage(SummaryRow); + break; + } + } + } + } + + } + + /// + /// Request message for [GoogleAdsService.SearchStream][google.ads.googleads.v3.services.GoogleAdsService.SearchStream]. + /// Next tag: 5 + /// + public sealed partial class SearchGoogleAdsStreamRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SearchGoogleAdsStreamRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsStreamRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsStreamRequest(SearchGoogleAdsStreamRequest other) : this() { + customerId_ = other.customerId_; + query_ = other.query_; + summaryRowSetting_ = other.summaryRowSetting_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsStreamRequest Clone() { + return new SearchGoogleAdsStreamRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer being queried. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "query" field. + public const int QueryFieldNumber = 2; + private string query_ = ""; + /// + /// Required. The query string. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Query { + get { return query_; } + set { + query_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "summary_row_setting" field. + public const int SummaryRowSettingFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.SummaryRowSettingEnum.Types.SummaryRowSetting summaryRowSetting_ = 0; + /// + /// Determines whether a summary row will be returned. By default, summary row + /// is not returned. If requested, the summary row will be sent in a response + /// by itself after all other query results are returned. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.SummaryRowSettingEnum.Types.SummaryRowSetting SummaryRowSetting { + get { return summaryRowSetting_; } + set { + summaryRowSetting_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SearchGoogleAdsStreamRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SearchGoogleAdsStreamRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (Query != other.Query) return false; + if (SummaryRowSetting != other.SummaryRowSetting) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (Query.Length != 0) hash ^= Query.GetHashCode(); + if (SummaryRowSetting != 0) hash ^= SummaryRowSetting.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (Query.Length != 0) { + output.WriteRawTag(18); + output.WriteString(Query); + } + if (SummaryRowSetting != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) SummaryRowSetting); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (Query.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Query); + } + if (SummaryRowSetting != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) SummaryRowSetting); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SearchGoogleAdsStreamRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.Query.Length != 0) { + Query = other.Query; + } + if (other.SummaryRowSetting != 0) { + SummaryRowSetting = other.SummaryRowSetting; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + Query = input.ReadString(); + break; + } + case 24: { + SummaryRowSetting = (global::Google.Ads.GoogleAds.V3.Enums.SummaryRowSettingEnum.Types.SummaryRowSetting) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Response message for [GoogleAdsService.SearchStream][google.ads.googleads.v3.services.GoogleAdsService.SearchStream]. + /// + public sealed partial class SearchGoogleAdsStreamResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new SearchGoogleAdsStreamResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsStreamResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsStreamResponse(SearchGoogleAdsStreamResponse other) : this() { + results_ = other.results_.Clone(); + fieldMask_ = other.fieldMask_ != null ? other.fieldMask_.Clone() : null; + summaryRow_ = other.summaryRow_ != null ? other.summaryRow_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SearchGoogleAdsStreamResponse Clone() { + return new SearchGoogleAdsStreamResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// The list of rows that matched the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + /// Field number for the "field_mask" field. + public const int FieldMaskFieldNumber = 2; + private global::Google.Protobuf.WellKnownTypes.FieldMask fieldMask_; + /// + /// FieldMask that represents what fields were requested by the user. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask FieldMask { + get { return fieldMask_; } + set { + fieldMask_ = value; + } + } + + /// Field number for the "summary_row" field. + public const int SummaryRowFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow summaryRow_; + /// + /// Summary row that contains summary of metrics in results. + /// Summary of metrics means aggregation of metrics across all results, + /// here aggregation could be sum, average, rate, etc. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow SummaryRow { + get { return summaryRow_; } + set { + summaryRow_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as SearchGoogleAdsStreamResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(SearchGoogleAdsStreamResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + if (!object.Equals(FieldMask, other.FieldMask)) return false; + if (!object.Equals(SummaryRow, other.SummaryRow)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (fieldMask_ != null) hash ^= FieldMask.GetHashCode(); + if (summaryRow_ != null) hash ^= SummaryRow.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (fieldMask_ != null) { + output.WriteRawTag(18); + output.WriteMessage(FieldMask); + } + if (summaryRow_ != null) { + output.WriteRawTag(26); + output.WriteMessage(SummaryRow); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (fieldMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(FieldMask); + } + if (summaryRow_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(SummaryRow); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(SearchGoogleAdsStreamResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + if (other.fieldMask_ != null) { + if (fieldMask_ == null) { + FieldMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + FieldMask.MergeFrom(other.FieldMask); + } + if (other.summaryRow_ != null) { + if (summaryRow_ == null) { + SummaryRow = new global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow(); + } + SummaryRow.MergeFrom(other.SummaryRow); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 18: { + if (fieldMask_ == null) { + FieldMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(FieldMask); + break; + } + case 26: { + if (summaryRow_ == null) { + SummaryRow = new global::Google.Ads.GoogleAds.V3.Services.GoogleAdsRow(); + } + input.ReadMessage(SummaryRow); + break; + } + } + } + } + + } + + /// + /// A returned row from the query. + /// + public sealed partial class GoogleAdsRow : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GoogleAdsRow()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsRow() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsRow(GoogleAdsRow other) : this() { + accountBudget_ = other.accountBudget_ != null ? other.accountBudget_.Clone() : null; + accountBudgetProposal_ = other.accountBudgetProposal_ != null ? other.accountBudgetProposal_.Clone() : null; + adGroup_ = other.adGroup_ != null ? other.adGroup_.Clone() : null; + adGroupAd_ = other.adGroupAd_ != null ? other.adGroupAd_.Clone() : null; + adGroupAdAssetView_ = other.adGroupAdAssetView_ != null ? other.adGroupAdAssetView_.Clone() : null; + adGroupAdLabel_ = other.adGroupAdLabel_ != null ? other.adGroupAdLabel_.Clone() : null; + adGroupAudienceView_ = other.adGroupAudienceView_ != null ? other.adGroupAudienceView_.Clone() : null; + adGroupBidModifier_ = other.adGroupBidModifier_ != null ? other.adGroupBidModifier_.Clone() : null; + adGroupCriterion_ = other.adGroupCriterion_ != null ? other.adGroupCriterion_.Clone() : null; + adGroupCriterionLabel_ = other.adGroupCriterionLabel_ != null ? other.adGroupCriterionLabel_.Clone() : null; + adGroupCriterionSimulation_ = other.adGroupCriterionSimulation_ != null ? other.adGroupCriterionSimulation_.Clone() : null; + adGroupExtensionSetting_ = other.adGroupExtensionSetting_ != null ? other.adGroupExtensionSetting_.Clone() : null; + adGroupFeed_ = other.adGroupFeed_ != null ? other.adGroupFeed_.Clone() : null; + adGroupLabel_ = other.adGroupLabel_ != null ? other.adGroupLabel_.Clone() : null; + adGroupSimulation_ = other.adGroupSimulation_ != null ? other.adGroupSimulation_.Clone() : null; + adParameter_ = other.adParameter_ != null ? other.adParameter_.Clone() : null; + ageRangeView_ = other.ageRangeView_ != null ? other.ageRangeView_.Clone() : null; + adScheduleView_ = other.adScheduleView_ != null ? other.adScheduleView_.Clone() : null; + domainCategory_ = other.domainCategory_ != null ? other.domainCategory_.Clone() : null; + asset_ = other.asset_ != null ? other.asset_.Clone() : null; + biddingStrategy_ = other.biddingStrategy_ != null ? other.biddingStrategy_.Clone() : null; + billingSetup_ = other.billingSetup_ != null ? other.billingSetup_.Clone() : null; + campaignBudget_ = other.campaignBudget_ != null ? other.campaignBudget_.Clone() : null; + campaign_ = other.campaign_ != null ? other.campaign_.Clone() : null; + campaignAudienceView_ = other.campaignAudienceView_ != null ? other.campaignAudienceView_.Clone() : null; + campaignBidModifier_ = other.campaignBidModifier_ != null ? other.campaignBidModifier_.Clone() : null; + campaignCriterion_ = other.campaignCriterion_ != null ? other.campaignCriterion_.Clone() : null; + campaignCriterionSimulation_ = other.campaignCriterionSimulation_ != null ? other.campaignCriterionSimulation_.Clone() : null; + campaignDraft_ = other.campaignDraft_ != null ? other.campaignDraft_.Clone() : null; + campaignExperiment_ = other.campaignExperiment_ != null ? other.campaignExperiment_.Clone() : null; + campaignExtensionSetting_ = other.campaignExtensionSetting_ != null ? other.campaignExtensionSetting_.Clone() : null; + campaignFeed_ = other.campaignFeed_ != null ? other.campaignFeed_.Clone() : null; + campaignLabel_ = other.campaignLabel_ != null ? other.campaignLabel_.Clone() : null; + campaignSharedSet_ = other.campaignSharedSet_ != null ? other.campaignSharedSet_.Clone() : null; + carrierConstant_ = other.carrierConstant_ != null ? other.carrierConstant_.Clone() : null; + changeStatus_ = other.changeStatus_ != null ? other.changeStatus_.Clone() : null; + conversionAction_ = other.conversionAction_ != null ? other.conversionAction_.Clone() : null; + clickView_ = other.clickView_ != null ? other.clickView_.Clone() : null; + currencyConstant_ = other.currencyConstant_ != null ? other.currencyConstant_.Clone() : null; + customInterest_ = other.customInterest_ != null ? other.customInterest_.Clone() : null; + customer_ = other.customer_ != null ? other.customer_.Clone() : null; + customerManagerLink_ = other.customerManagerLink_ != null ? other.customerManagerLink_.Clone() : null; + customerClientLink_ = other.customerClientLink_ != null ? other.customerClientLink_.Clone() : null; + customerClient_ = other.customerClient_ != null ? other.customerClient_.Clone() : null; + customerExtensionSetting_ = other.customerExtensionSetting_ != null ? other.customerExtensionSetting_.Clone() : null; + customerFeed_ = other.customerFeed_ != null ? other.customerFeed_.Clone() : null; + customerLabel_ = other.customerLabel_ != null ? other.customerLabel_.Clone() : null; + customerNegativeCriterion_ = other.customerNegativeCriterion_ != null ? other.customerNegativeCriterion_.Clone() : null; + detailPlacementView_ = other.detailPlacementView_ != null ? other.detailPlacementView_.Clone() : null; + displayKeywordView_ = other.displayKeywordView_ != null ? other.displayKeywordView_.Clone() : null; + distanceView_ = other.distanceView_ != null ? other.distanceView_.Clone() : null; + dynamicSearchAdsSearchTermView_ = other.dynamicSearchAdsSearchTermView_ != null ? other.dynamicSearchAdsSearchTermView_.Clone() : null; + expandedLandingPageView_ = other.expandedLandingPageView_ != null ? other.expandedLandingPageView_.Clone() : null; + extensionFeedItem_ = other.extensionFeedItem_ != null ? other.extensionFeedItem_.Clone() : null; + feed_ = other.feed_ != null ? other.feed_.Clone() : null; + feedItem_ = other.feedItem_ != null ? other.feedItem_.Clone() : null; + feedItemTarget_ = other.feedItemTarget_ != null ? other.feedItemTarget_.Clone() : null; + feedMapping_ = other.feedMapping_ != null ? other.feedMapping_.Clone() : null; + feedPlaceholderView_ = other.feedPlaceholderView_ != null ? other.feedPlaceholderView_.Clone() : null; + genderView_ = other.genderView_ != null ? other.genderView_.Clone() : null; + geoTargetConstant_ = other.geoTargetConstant_ != null ? other.geoTargetConstant_.Clone() : null; + geographicView_ = other.geographicView_ != null ? other.geographicView_.Clone() : null; + groupPlacementView_ = other.groupPlacementView_ != null ? other.groupPlacementView_.Clone() : null; + hotelGroupView_ = other.hotelGroupView_ != null ? other.hotelGroupView_.Clone() : null; + hotelPerformanceView_ = other.hotelPerformanceView_ != null ? other.hotelPerformanceView_.Clone() : null; + keywordView_ = other.keywordView_ != null ? other.keywordView_.Clone() : null; + keywordPlan_ = other.keywordPlan_ != null ? other.keywordPlan_.Clone() : null; + keywordPlanCampaign_ = other.keywordPlanCampaign_ != null ? other.keywordPlanCampaign_.Clone() : null; + keywordPlanNegativeKeyword_ = other.keywordPlanNegativeKeyword_ != null ? other.keywordPlanNegativeKeyword_.Clone() : null; + keywordPlanAdGroup_ = other.keywordPlanAdGroup_ != null ? other.keywordPlanAdGroup_.Clone() : null; + keywordPlanKeyword_ = other.keywordPlanKeyword_ != null ? other.keywordPlanKeyword_.Clone() : null; + label_ = other.label_ != null ? other.label_.Clone() : null; + landingPageView_ = other.landingPageView_ != null ? other.landingPageView_.Clone() : null; + languageConstant_ = other.languageConstant_ != null ? other.languageConstant_.Clone() : null; + locationView_ = other.locationView_ != null ? other.locationView_.Clone() : null; + managedPlacementView_ = other.managedPlacementView_ != null ? other.managedPlacementView_.Clone() : null; + mediaFile_ = other.mediaFile_ != null ? other.mediaFile_.Clone() : null; + mobileAppCategoryConstant_ = other.mobileAppCategoryConstant_ != null ? other.mobileAppCategoryConstant_.Clone() : null; + mobileDeviceConstant_ = other.mobileDeviceConstant_ != null ? other.mobileDeviceConstant_.Clone() : null; + mutateJob_ = other.mutateJob_ != null ? other.mutateJob_.Clone() : null; + operatingSystemVersionConstant_ = other.operatingSystemVersionConstant_ != null ? other.operatingSystemVersionConstant_.Clone() : null; + paidOrganicSearchTermView_ = other.paidOrganicSearchTermView_ != null ? other.paidOrganicSearchTermView_.Clone() : null; + parentalStatusView_ = other.parentalStatusView_ != null ? other.parentalStatusView_.Clone() : null; + productBiddingCategoryConstant_ = other.productBiddingCategoryConstant_ != null ? other.productBiddingCategoryConstant_.Clone() : null; + productGroupView_ = other.productGroupView_ != null ? other.productGroupView_.Clone() : null; + recommendation_ = other.recommendation_ != null ? other.recommendation_.Clone() : null; + searchTermView_ = other.searchTermView_ != null ? other.searchTermView_.Clone() : null; + sharedCriterion_ = other.sharedCriterion_ != null ? other.sharedCriterion_.Clone() : null; + sharedSet_ = other.sharedSet_ != null ? other.sharedSet_.Clone() : null; + shoppingPerformanceView_ = other.shoppingPerformanceView_ != null ? other.shoppingPerformanceView_.Clone() : null; + topicView_ = other.topicView_ != null ? other.topicView_.Clone() : null; + userInterest_ = other.userInterest_ != null ? other.userInterest_.Clone() : null; + userList_ = other.userList_ != null ? other.userList_.Clone() : null; + userLocationView_ = other.userLocationView_ != null ? other.userLocationView_.Clone() : null; + remarketingAction_ = other.remarketingAction_ != null ? other.remarketingAction_.Clone() : null; + topicConstant_ = other.topicConstant_ != null ? other.topicConstant_.Clone() : null; + video_ = other.video_ != null ? other.video_.Clone() : null; + metrics_ = other.metrics_ != null ? other.metrics_.Clone() : null; + segments_ = other.segments_ != null ? other.segments_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GoogleAdsRow Clone() { + return new GoogleAdsRow(this); + } + + /// Field number for the "account_budget" field. + public const int AccountBudgetFieldNumber = 42; + private global::Google.Ads.GoogleAds.V3.Resources.AccountBudget accountBudget_; + /// + /// The account budget in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AccountBudget AccountBudget { + get { return accountBudget_; } + set { + accountBudget_ = value; + } + } + + /// Field number for the "account_budget_proposal" field. + public const int AccountBudgetProposalFieldNumber = 43; + private global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal accountBudgetProposal_; + /// + /// The account budget proposal referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal AccountBudgetProposal { + get { return accountBudgetProposal_; } + set { + accountBudgetProposal_ = value; + } + } + + /// Field number for the "ad_group" field. + public const int AdGroupFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroup adGroup_; + /// + /// The ad group referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroup AdGroup { + get { return adGroup_; } + set { + adGroup_ = value; + } + } + + /// Field number for the "ad_group_ad" field. + public const int AdGroupAdFieldNumber = 16; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd adGroupAd_; + /// + /// The ad referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd AdGroupAd { + get { return adGroupAd_; } + set { + adGroupAd_ = value; + } + } + + /// Field number for the "ad_group_ad_asset_view" field. + public const int AdGroupAdAssetViewFieldNumber = 131; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView adGroupAdAssetView_; + /// + /// The ad group ad asset view in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView AdGroupAdAssetView { + get { return adGroupAdAssetView_; } + set { + adGroupAdAssetView_ = value; + } + } + + /// Field number for the "ad_group_ad_label" field. + public const int AdGroupAdLabelFieldNumber = 120; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel adGroupAdLabel_; + /// + /// The ad group ad label referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel AdGroupAdLabel { + get { return adGroupAdLabel_; } + set { + adGroupAdLabel_ = value; + } + } + + /// Field number for the "ad_group_audience_view" field. + public const int AdGroupAudienceViewFieldNumber = 57; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView adGroupAudienceView_; + /// + /// The ad group audience view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView AdGroupAudienceView { + get { return adGroupAudienceView_; } + set { + adGroupAudienceView_ = value; + } + } + + /// Field number for the "ad_group_bid_modifier" field. + public const int AdGroupBidModifierFieldNumber = 24; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier adGroupBidModifier_; + /// + /// The bid modifier referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier AdGroupBidModifier { + get { return adGroupBidModifier_; } + set { + adGroupBidModifier_ = value; + } + } + + /// Field number for the "ad_group_criterion" field. + public const int AdGroupCriterionFieldNumber = 17; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion adGroupCriterion_; + /// + /// The criterion referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion AdGroupCriterion { + get { return adGroupCriterion_; } + set { + adGroupCriterion_ = value; + } + } + + /// Field number for the "ad_group_criterion_label" field. + public const int AdGroupCriterionLabelFieldNumber = 121; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel adGroupCriterionLabel_; + /// + /// The ad group criterion label referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel AdGroupCriterionLabel { + get { return adGroupCriterionLabel_; } + set { + adGroupCriterionLabel_ = value; + } + } + + /// Field number for the "ad_group_criterion_simulation" field. + public const int AdGroupCriterionSimulationFieldNumber = 110; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation adGroupCriterionSimulation_; + /// + /// The ad group criterion simulation referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation AdGroupCriterionSimulation { + get { return adGroupCriterionSimulation_; } + set { + adGroupCriterionSimulation_ = value; + } + } + + /// Field number for the "ad_group_extension_setting" field. + public const int AdGroupExtensionSettingFieldNumber = 112; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting adGroupExtensionSetting_; + /// + /// The ad group extension setting referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting AdGroupExtensionSetting { + get { return adGroupExtensionSetting_; } + set { + adGroupExtensionSetting_ = value; + } + } + + /// Field number for the "ad_group_feed" field. + public const int AdGroupFeedFieldNumber = 67; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed adGroupFeed_; + /// + /// The ad group feed referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed AdGroupFeed { + get { return adGroupFeed_; } + set { + adGroupFeed_ = value; + } + } + + /// Field number for the "ad_group_label" field. + public const int AdGroupLabelFieldNumber = 115; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel adGroupLabel_; + /// + /// The ad group label referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel AdGroupLabel { + get { return adGroupLabel_; } + set { + adGroupLabel_ = value; + } + } + + /// Field number for the "ad_group_simulation" field. + public const int AdGroupSimulationFieldNumber = 107; + private global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation adGroupSimulation_; + /// + /// The ad group simulation referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation AdGroupSimulation { + get { return adGroupSimulation_; } + set { + adGroupSimulation_ = value; + } + } + + /// Field number for the "ad_parameter" field. + public const int AdParameterFieldNumber = 130; + private global::Google.Ads.GoogleAds.V3.Resources.AdParameter adParameter_; + /// + /// The ad parameter referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdParameter AdParameter { + get { return adParameter_; } + set { + adParameter_ = value; + } + } + + /// Field number for the "age_range_view" field. + public const int AgeRangeViewFieldNumber = 48; + private global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView ageRangeView_; + /// + /// The age range view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView AgeRangeView { + get { return ageRangeView_; } + set { + ageRangeView_ = value; + } + } + + /// Field number for the "ad_schedule_view" field. + public const int AdScheduleViewFieldNumber = 89; + private global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView adScheduleView_; + /// + /// The ad schedule view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView AdScheduleView { + get { return adScheduleView_; } + set { + adScheduleView_ = value; + } + } + + /// Field number for the "domain_category" field. + public const int DomainCategoryFieldNumber = 91; + private global::Google.Ads.GoogleAds.V3.Resources.DomainCategory domainCategory_; + /// + /// The domain category referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.DomainCategory DomainCategory { + get { return domainCategory_; } + set { + domainCategory_ = value; + } + } + + /// Field number for the "asset" field. + public const int AssetFieldNumber = 105; + private global::Google.Ads.GoogleAds.V3.Resources.Asset asset_; + /// + /// The asset referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Asset Asset { + get { return asset_; } + set { + asset_ = value; + } + } + + /// Field number for the "bidding_strategy" field. + public const int BiddingStrategyFieldNumber = 18; + private global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy biddingStrategy_; + /// + /// The bidding strategy referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy BiddingStrategy { + get { return biddingStrategy_; } + set { + biddingStrategy_ = value; + } + } + + /// Field number for the "billing_setup" field. + public const int BillingSetupFieldNumber = 41; + private global::Google.Ads.GoogleAds.V3.Resources.BillingSetup billingSetup_; + /// + /// The billing setup referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.BillingSetup BillingSetup { + get { return billingSetup_; } + set { + billingSetup_ = value; + } + } + + /// Field number for the "campaign_budget" field. + public const int CampaignBudgetFieldNumber = 19; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget campaignBudget_; + /// + /// The campaign budget referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget CampaignBudget { + get { return campaignBudget_; } + set { + campaignBudget_ = value; + } + } + + /// Field number for the "campaign" field. + public const int CampaignFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Resources.Campaign campaign_; + /// + /// The campaign referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Campaign Campaign { + get { return campaign_; } + set { + campaign_ = value; + } + } + + /// Field number for the "campaign_audience_view" field. + public const int CampaignAudienceViewFieldNumber = 69; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView campaignAudienceView_; + /// + /// The campaign audience view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView CampaignAudienceView { + get { return campaignAudienceView_; } + set { + campaignAudienceView_ = value; + } + } + + /// Field number for the "campaign_bid_modifier" field. + public const int CampaignBidModifierFieldNumber = 26; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier campaignBidModifier_; + /// + /// The campaign bid modifier referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier CampaignBidModifier { + get { return campaignBidModifier_; } + set { + campaignBidModifier_ = value; + } + } + + /// Field number for the "campaign_criterion" field. + public const int CampaignCriterionFieldNumber = 20; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion campaignCriterion_; + /// + /// The campaign criterion referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion CampaignCriterion { + get { return campaignCriterion_; } + set { + campaignCriterion_ = value; + } + } + + /// Field number for the "campaign_criterion_simulation" field. + public const int CampaignCriterionSimulationFieldNumber = 111; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation campaignCriterionSimulation_; + /// + /// The campaign criterion simulation referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation CampaignCriterionSimulation { + get { return campaignCriterionSimulation_; } + set { + campaignCriterionSimulation_ = value; + } + } + + /// Field number for the "campaign_draft" field. + public const int CampaignDraftFieldNumber = 49; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft campaignDraft_; + /// + /// The campaign draft referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft CampaignDraft { + get { return campaignDraft_; } + set { + campaignDraft_ = value; + } + } + + /// Field number for the "campaign_experiment" field. + public const int CampaignExperimentFieldNumber = 84; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment campaignExperiment_; + /// + /// The campaign experiment referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment CampaignExperiment { + get { return campaignExperiment_; } + set { + campaignExperiment_ = value; + } + } + + /// Field number for the "campaign_extension_setting" field. + public const int CampaignExtensionSettingFieldNumber = 113; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting campaignExtensionSetting_; + /// + /// The campaign extension setting referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting CampaignExtensionSetting { + get { return campaignExtensionSetting_; } + set { + campaignExtensionSetting_ = value; + } + } + + /// Field number for the "campaign_feed" field. + public const int CampaignFeedFieldNumber = 63; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed campaignFeed_; + /// + /// The campaign feed referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed CampaignFeed { + get { return campaignFeed_; } + set { + campaignFeed_ = value; + } + } + + /// Field number for the "campaign_label" field. + public const int CampaignLabelFieldNumber = 108; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel campaignLabel_; + /// + /// The campaign label referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel CampaignLabel { + get { return campaignLabel_; } + set { + campaignLabel_ = value; + } + } + + /// Field number for the "campaign_shared_set" field. + public const int CampaignSharedSetFieldNumber = 30; + private global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet campaignSharedSet_; + /// + /// Campaign Shared Set referenced in AWQL query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet CampaignSharedSet { + get { return campaignSharedSet_; } + set { + campaignSharedSet_ = value; + } + } + + /// Field number for the "carrier_constant" field. + public const int CarrierConstantFieldNumber = 66; + private global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant carrierConstant_; + /// + /// The carrier constant referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant CarrierConstant { + get { return carrierConstant_; } + set { + carrierConstant_ = value; + } + } + + /// Field number for the "change_status" field. + public const int ChangeStatusFieldNumber = 37; + private global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus changeStatus_; + /// + /// The ChangeStatus referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus ChangeStatus { + get { return changeStatus_; } + set { + changeStatus_ = value; + } + } + + /// Field number for the "conversion_action" field. + public const int ConversionActionFieldNumber = 103; + private global::Google.Ads.GoogleAds.V3.Resources.ConversionAction conversionAction_; + /// + /// The conversion action referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ConversionAction ConversionAction { + get { return conversionAction_; } + set { + conversionAction_ = value; + } + } + + /// Field number for the "click_view" field. + public const int ClickViewFieldNumber = 122; + private global::Google.Ads.GoogleAds.V3.Resources.ClickView clickView_; + /// + /// The ClickView referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ClickView ClickView { + get { return clickView_; } + set { + clickView_ = value; + } + } + + /// Field number for the "currency_constant" field. + public const int CurrencyConstantFieldNumber = 134; + private global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant currencyConstant_; + /// + /// The currency constant referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant CurrencyConstant { + get { return currencyConstant_; } + set { + currencyConstant_ = value; + } + } + + /// Field number for the "custom_interest" field. + public const int CustomInterestFieldNumber = 104; + private global::Google.Ads.GoogleAds.V3.Resources.CustomInterest customInterest_; + /// + /// The CustomInterest referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomInterest CustomInterest { + get { return customInterest_; } + set { + customInterest_ = value; + } + } + + /// Field number for the "customer" field. + public const int CustomerFieldNumber = 1; + private global::Google.Ads.GoogleAds.V3.Resources.Customer customer_; + /// + /// The customer referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Customer Customer { + get { return customer_; } + set { + customer_ = value; + } + } + + /// Field number for the "customer_manager_link" field. + public const int CustomerManagerLinkFieldNumber = 61; + private global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink customerManagerLink_; + /// + /// The CustomerManagerLink referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink CustomerManagerLink { + get { return customerManagerLink_; } + set { + customerManagerLink_ = value; + } + } + + /// Field number for the "customer_client_link" field. + public const int CustomerClientLinkFieldNumber = 62; + private global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink customerClientLink_; + /// + /// The CustomerClientLink referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink CustomerClientLink { + get { return customerClientLink_; } + set { + customerClientLink_ = value; + } + } + + /// Field number for the "customer_client" field. + public const int CustomerClientFieldNumber = 70; + private global::Google.Ads.GoogleAds.V3.Resources.CustomerClient customerClient_; + /// + /// The CustomerClient referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerClient CustomerClient { + get { return customerClient_; } + set { + customerClient_ = value; + } + } + + /// Field number for the "customer_extension_setting" field. + public const int CustomerExtensionSettingFieldNumber = 114; + private global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting customerExtensionSetting_; + /// + /// The customer extension setting referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting CustomerExtensionSetting { + get { return customerExtensionSetting_; } + set { + customerExtensionSetting_ = value; + } + } + + /// Field number for the "customer_feed" field. + public const int CustomerFeedFieldNumber = 64; + private global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed customerFeed_; + /// + /// The customer feed referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed CustomerFeed { + get { return customerFeed_; } + set { + customerFeed_ = value; + } + } + + /// Field number for the "customer_label" field. + public const int CustomerLabelFieldNumber = 124; + private global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel customerLabel_; + /// + /// The customer label referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel CustomerLabel { + get { return customerLabel_; } + set { + customerLabel_ = value; + } + } + + /// Field number for the "customer_negative_criterion" field. + public const int CustomerNegativeCriterionFieldNumber = 88; + private global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion customerNegativeCriterion_; + /// + /// The customer negative criterion referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion CustomerNegativeCriterion { + get { return customerNegativeCriterion_; } + set { + customerNegativeCriterion_ = value; + } + } + + /// Field number for the "detail_placement_view" field. + public const int DetailPlacementViewFieldNumber = 118; + private global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView detailPlacementView_; + /// + /// The detail placement view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView DetailPlacementView { + get { return detailPlacementView_; } + set { + detailPlacementView_ = value; + } + } + + /// Field number for the "display_keyword_view" field. + public const int DisplayKeywordViewFieldNumber = 47; + private global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView displayKeywordView_; + /// + /// The display keyword view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView DisplayKeywordView { + get { return displayKeywordView_; } + set { + displayKeywordView_ = value; + } + } + + /// Field number for the "distance_view" field. + public const int DistanceViewFieldNumber = 132; + private global::Google.Ads.GoogleAds.V3.Resources.DistanceView distanceView_; + /// + /// The distance view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.DistanceView DistanceView { + get { return distanceView_; } + set { + distanceView_ = value; + } + } + + /// Field number for the "dynamic_search_ads_search_term_view" field. + public const int DynamicSearchAdsSearchTermViewFieldNumber = 106; + private global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView dynamicSearchAdsSearchTermView_; + /// + /// The dynamic search ads search term view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView DynamicSearchAdsSearchTermView { + get { return dynamicSearchAdsSearchTermView_; } + set { + dynamicSearchAdsSearchTermView_ = value; + } + } + + /// Field number for the "expanded_landing_page_view" field. + public const int ExpandedLandingPageViewFieldNumber = 128; + private global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView expandedLandingPageView_; + /// + /// The expanded landing page view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView ExpandedLandingPageView { + get { return expandedLandingPageView_; } + set { + expandedLandingPageView_ = value; + } + } + + /// Field number for the "extension_feed_item" field. + public const int ExtensionFeedItemFieldNumber = 85; + private global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem extensionFeedItem_; + /// + /// The extension feed item referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem ExtensionFeedItem { + get { return extensionFeedItem_; } + set { + extensionFeedItem_ = value; + } + } + + /// Field number for the "feed" field. + public const int FeedFieldNumber = 46; + private global::Google.Ads.GoogleAds.V3.Resources.Feed feed_; + /// + /// The feed referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Feed Feed { + get { return feed_; } + set { + feed_ = value; + } + } + + /// Field number for the "feed_item" field. + public const int FeedItemFieldNumber = 50; + private global::Google.Ads.GoogleAds.V3.Resources.FeedItem feedItem_; + /// + /// The feed item referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedItem FeedItem { + get { return feedItem_; } + set { + feedItem_ = value; + } + } + + /// Field number for the "feed_item_target" field. + public const int FeedItemTargetFieldNumber = 116; + private global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget feedItemTarget_; + /// + /// The feed item target referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget FeedItemTarget { + get { return feedItemTarget_; } + set { + feedItemTarget_ = value; + } + } + + /// Field number for the "feed_mapping" field. + public const int FeedMappingFieldNumber = 58; + private global::Google.Ads.GoogleAds.V3.Resources.FeedMapping feedMapping_; + /// + /// The feed mapping referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedMapping FeedMapping { + get { return feedMapping_; } + set { + feedMapping_ = value; + } + } + + /// Field number for the "feed_placeholder_view" field. + public const int FeedPlaceholderViewFieldNumber = 97; + private global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView feedPlaceholderView_; + /// + /// The feed placeholder view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView FeedPlaceholderView { + get { return feedPlaceholderView_; } + set { + feedPlaceholderView_ = value; + } + } + + /// Field number for the "gender_view" field. + public const int GenderViewFieldNumber = 40; + private global::Google.Ads.GoogleAds.V3.Resources.GenderView genderView_; + /// + /// The gender view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.GenderView GenderView { + get { return genderView_; } + set { + genderView_ = value; + } + } + + /// Field number for the "geo_target_constant" field. + public const int GeoTargetConstantFieldNumber = 23; + private global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant geoTargetConstant_; + /// + /// The geo target constant referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant GeoTargetConstant { + get { return geoTargetConstant_; } + set { + geoTargetConstant_ = value; + } + } + + /// Field number for the "geographic_view" field. + public const int GeographicViewFieldNumber = 125; + private global::Google.Ads.GoogleAds.V3.Resources.GeographicView geographicView_; + /// + /// The geographic view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.GeographicView GeographicView { + get { return geographicView_; } + set { + geographicView_ = value; + } + } + + /// Field number for the "group_placement_view" field. + public const int GroupPlacementViewFieldNumber = 119; + private global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView groupPlacementView_; + /// + /// The group placement view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView GroupPlacementView { + get { return groupPlacementView_; } + set { + groupPlacementView_ = value; + } + } + + /// Field number for the "hotel_group_view" field. + public const int HotelGroupViewFieldNumber = 51; + private global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView hotelGroupView_; + /// + /// The hotel group view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView HotelGroupView { + get { return hotelGroupView_; } + set { + hotelGroupView_ = value; + } + } + + /// Field number for the "hotel_performance_view" field. + public const int HotelPerformanceViewFieldNumber = 71; + private global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView hotelPerformanceView_; + /// + /// The hotel performance view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView HotelPerformanceView { + get { return hotelPerformanceView_; } + set { + hotelPerformanceView_ = value; + } + } + + /// Field number for the "keyword_view" field. + public const int KeywordViewFieldNumber = 21; + private global::Google.Ads.GoogleAds.V3.Resources.KeywordView keywordView_; + /// + /// The keyword view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordView KeywordView { + get { return keywordView_; } + set { + keywordView_ = value; + } + } + + /// Field number for the "keyword_plan" field. + public const int KeywordPlanFieldNumber = 32; + private global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan keywordPlan_; + /// + /// The keyword plan referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan KeywordPlan { + get { return keywordPlan_; } + set { + keywordPlan_ = value; + } + } + + /// Field number for the "keyword_plan_campaign" field. + public const int KeywordPlanCampaignFieldNumber = 33; + private global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign keywordPlanCampaign_; + /// + /// The keyword plan campaign referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign KeywordPlanCampaign { + get { return keywordPlanCampaign_; } + set { + keywordPlanCampaign_ = value; + } + } + + /// Field number for the "keyword_plan_negative_keyword" field. + public const int KeywordPlanNegativeKeywordFieldNumber = 34; + private global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword keywordPlanNegativeKeyword_; + /// + /// The keyword plan negative keyword referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword KeywordPlanNegativeKeyword { + get { return keywordPlanNegativeKeyword_; } + set { + keywordPlanNegativeKeyword_ = value; + } + } + + /// Field number for the "keyword_plan_ad_group" field. + public const int KeywordPlanAdGroupFieldNumber = 35; + private global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup keywordPlanAdGroup_; + /// + /// The keyword plan ad group referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup KeywordPlanAdGroup { + get { return keywordPlanAdGroup_; } + set { + keywordPlanAdGroup_ = value; + } + } + + /// Field number for the "keyword_plan_keyword" field. + public const int KeywordPlanKeywordFieldNumber = 36; + private global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword keywordPlanKeyword_; + /// + /// The keyword plan keyword referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword KeywordPlanKeyword { + get { return keywordPlanKeyword_; } + set { + keywordPlanKeyword_ = value; + } + } + + /// Field number for the "label" field. + public const int LabelFieldNumber = 52; + private global::Google.Ads.GoogleAds.V3.Resources.Label label_; + /// + /// The label referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Label Label { + get { return label_; } + set { + label_ = value; + } + } + + /// Field number for the "landing_page_view" field. + public const int LandingPageViewFieldNumber = 126; + private global::Google.Ads.GoogleAds.V3.Resources.LandingPageView landingPageView_; + /// + /// The landing page view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.LandingPageView LandingPageView { + get { return landingPageView_; } + set { + landingPageView_ = value; + } + } + + /// Field number for the "language_constant" field. + public const int LanguageConstantFieldNumber = 55; + private global::Google.Ads.GoogleAds.V3.Resources.LanguageConstant languageConstant_; + /// + /// The language constant referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.LanguageConstant LanguageConstant { + get { return languageConstant_; } + set { + languageConstant_ = value; + } + } + + /// Field number for the "location_view" field. + public const int LocationViewFieldNumber = 123; + private global::Google.Ads.GoogleAds.V3.Resources.LocationView locationView_; + /// + /// The location view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.LocationView LocationView { + get { return locationView_; } + set { + locationView_ = value; + } + } + + /// Field number for the "managed_placement_view" field. + public const int ManagedPlacementViewFieldNumber = 53; + private global::Google.Ads.GoogleAds.V3.Resources.ManagedPlacementView managedPlacementView_; + /// + /// The managed placement view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ManagedPlacementView ManagedPlacementView { + get { return managedPlacementView_; } + set { + managedPlacementView_ = value; + } + } + + /// Field number for the "media_file" field. + public const int MediaFileFieldNumber = 90; + private global::Google.Ads.GoogleAds.V3.Resources.MediaFile mediaFile_; + /// + /// The media file referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.MediaFile MediaFile { + get { return mediaFile_; } + set { + mediaFile_ = value; + } + } + + /// Field number for the "mobile_app_category_constant" field. + public const int MobileAppCategoryConstantFieldNumber = 87; + private global::Google.Ads.GoogleAds.V3.Resources.MobileAppCategoryConstant mobileAppCategoryConstant_; + /// + /// The mobile app category constant referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.MobileAppCategoryConstant MobileAppCategoryConstant { + get { return mobileAppCategoryConstant_; } + set { + mobileAppCategoryConstant_ = value; + } + } + + /// Field number for the "mobile_device_constant" field. + public const int MobileDeviceConstantFieldNumber = 98; + private global::Google.Ads.GoogleAds.V3.Resources.MobileDeviceConstant mobileDeviceConstant_; + /// + /// The mobile device constant referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.MobileDeviceConstant MobileDeviceConstant { + get { return mobileDeviceConstant_; } + set { + mobileDeviceConstant_ = value; + } + } + + /// Field number for the "mutate_job" field. + public const int MutateJobFieldNumber = 127; + private global::Google.Ads.GoogleAds.V3.Resources.MutateJob mutateJob_; + /// + /// The mutate job referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.MutateJob MutateJob { + get { return mutateJob_; } + set { + mutateJob_ = value; + } + } + + /// Field number for the "operating_system_version_constant" field. + public const int OperatingSystemVersionConstantFieldNumber = 86; + private global::Google.Ads.GoogleAds.V3.Resources.OperatingSystemVersionConstant operatingSystemVersionConstant_; + /// + /// The operating system version constant referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.OperatingSystemVersionConstant OperatingSystemVersionConstant { + get { return operatingSystemVersionConstant_; } + set { + operatingSystemVersionConstant_ = value; + } + } + + /// Field number for the "paid_organic_search_term_view" field. + public const int PaidOrganicSearchTermViewFieldNumber = 129; + private global::Google.Ads.GoogleAds.V3.Resources.PaidOrganicSearchTermView paidOrganicSearchTermView_; + /// + /// The paid organic search term view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.PaidOrganicSearchTermView PaidOrganicSearchTermView { + get { return paidOrganicSearchTermView_; } + set { + paidOrganicSearchTermView_ = value; + } + } + + /// Field number for the "parental_status_view" field. + public const int ParentalStatusViewFieldNumber = 45; + private global::Google.Ads.GoogleAds.V3.Resources.ParentalStatusView parentalStatusView_; + /// + /// The parental status view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ParentalStatusView ParentalStatusView { + get { return parentalStatusView_; } + set { + parentalStatusView_ = value; + } + } + + /// Field number for the "product_bidding_category_constant" field. + public const int ProductBiddingCategoryConstantFieldNumber = 109; + private global::Google.Ads.GoogleAds.V3.Resources.ProductBiddingCategoryConstant productBiddingCategoryConstant_; + /// + /// The Product Bidding Category referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ProductBiddingCategoryConstant ProductBiddingCategoryConstant { + get { return productBiddingCategoryConstant_; } + set { + productBiddingCategoryConstant_ = value; + } + } + + /// Field number for the "product_group_view" field. + public const int ProductGroupViewFieldNumber = 54; + private global::Google.Ads.GoogleAds.V3.Resources.ProductGroupView productGroupView_; + /// + /// The product group view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ProductGroupView ProductGroupView { + get { return productGroupView_; } + set { + productGroupView_ = value; + } + } + + /// Field number for the "recommendation" field. + public const int RecommendationFieldNumber = 22; + private global::Google.Ads.GoogleAds.V3.Resources.Recommendation recommendation_; + /// + /// The recommendation referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Recommendation Recommendation { + get { return recommendation_; } + set { + recommendation_ = value; + } + } + + /// Field number for the "search_term_view" field. + public const int SearchTermViewFieldNumber = 68; + private global::Google.Ads.GoogleAds.V3.Resources.SearchTermView searchTermView_; + /// + /// The search term view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.SearchTermView SearchTermView { + get { return searchTermView_; } + set { + searchTermView_ = value; + } + } + + /// Field number for the "shared_criterion" field. + public const int SharedCriterionFieldNumber = 29; + private global::Google.Ads.GoogleAds.V3.Resources.SharedCriterion sharedCriterion_; + /// + /// The shared set referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.SharedCriterion SharedCriterion { + get { return sharedCriterion_; } + set { + sharedCriterion_ = value; + } + } + + /// Field number for the "shared_set" field. + public const int SharedSetFieldNumber = 27; + private global::Google.Ads.GoogleAds.V3.Resources.SharedSet sharedSet_; + /// + /// The shared set referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.SharedSet SharedSet { + get { return sharedSet_; } + set { + sharedSet_ = value; + } + } + + /// Field number for the "shopping_performance_view" field. + public const int ShoppingPerformanceViewFieldNumber = 117; + private global::Google.Ads.GoogleAds.V3.Resources.ShoppingPerformanceView shoppingPerformanceView_; + /// + /// The shopping performance view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.ShoppingPerformanceView ShoppingPerformanceView { + get { return shoppingPerformanceView_; } + set { + shoppingPerformanceView_ = value; + } + } + + /// Field number for the "topic_view" field. + public const int TopicViewFieldNumber = 44; + private global::Google.Ads.GoogleAds.V3.Resources.TopicView topicView_; + /// + /// The topic view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.TopicView TopicView { + get { return topicView_; } + set { + topicView_ = value; + } + } + + /// Field number for the "user_interest" field. + public const int UserInterestFieldNumber = 59; + private global::Google.Ads.GoogleAds.V3.Resources.UserInterest userInterest_; + /// + /// The user interest referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.UserInterest UserInterest { + get { return userInterest_; } + set { + userInterest_ = value; + } + } + + /// Field number for the "user_list" field. + public const int UserListFieldNumber = 38; + private global::Google.Ads.GoogleAds.V3.Resources.UserList userList_; + /// + /// The user list referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.UserList UserList { + get { return userList_; } + set { + userList_ = value; + } + } + + /// Field number for the "user_location_view" field. + public const int UserLocationViewFieldNumber = 135; + private global::Google.Ads.GoogleAds.V3.Resources.UserLocationView userLocationView_; + /// + /// The user location view referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.UserLocationView UserLocationView { + get { return userLocationView_; } + set { + userLocationView_ = value; + } + } + + /// Field number for the "remarketing_action" field. + public const int RemarketingActionFieldNumber = 60; + private global::Google.Ads.GoogleAds.V3.Resources.RemarketingAction remarketingAction_; + /// + /// The remarketing action referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.RemarketingAction RemarketingAction { + get { return remarketingAction_; } + set { + remarketingAction_ = value; + } + } + + /// Field number for the "topic_constant" field. + public const int TopicConstantFieldNumber = 31; + private global::Google.Ads.GoogleAds.V3.Resources.TopicConstant topicConstant_; + /// + /// The topic constant referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.TopicConstant TopicConstant { + get { return topicConstant_; } + set { + topicConstant_ = value; + } + } + + /// Field number for the "video" field. + public const int VideoFieldNumber = 39; + private global::Google.Ads.GoogleAds.V3.Resources.Video video_; + /// + /// The video referenced in the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.Video Video { + get { return video_; } + set { + video_ = value; + } + } + + /// Field number for the "metrics" field. + public const int MetricsFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Common.Metrics metrics_; + /// + /// The metrics. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.Metrics Metrics { + get { return metrics_; } + set { + metrics_ = value; + } + } + + /// Field number for the "segments" field. + public const int SegmentsFieldNumber = 102; + private global::Google.Ads.GoogleAds.V3.Common.Segments segments_; + /// + /// The segments. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.Segments Segments { + get { return segments_; } + set { + segments_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GoogleAdsRow); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GoogleAdsRow other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(AccountBudget, other.AccountBudget)) return false; + if (!object.Equals(AccountBudgetProposal, other.AccountBudgetProposal)) return false; + if (!object.Equals(AdGroup, other.AdGroup)) return false; + if (!object.Equals(AdGroupAd, other.AdGroupAd)) return false; + if (!object.Equals(AdGroupAdAssetView, other.AdGroupAdAssetView)) return false; + if (!object.Equals(AdGroupAdLabel, other.AdGroupAdLabel)) return false; + if (!object.Equals(AdGroupAudienceView, other.AdGroupAudienceView)) return false; + if (!object.Equals(AdGroupBidModifier, other.AdGroupBidModifier)) return false; + if (!object.Equals(AdGroupCriterion, other.AdGroupCriterion)) return false; + if (!object.Equals(AdGroupCriterionLabel, other.AdGroupCriterionLabel)) return false; + if (!object.Equals(AdGroupCriterionSimulation, other.AdGroupCriterionSimulation)) return false; + if (!object.Equals(AdGroupExtensionSetting, other.AdGroupExtensionSetting)) return false; + if (!object.Equals(AdGroupFeed, other.AdGroupFeed)) return false; + if (!object.Equals(AdGroupLabel, other.AdGroupLabel)) return false; + if (!object.Equals(AdGroupSimulation, other.AdGroupSimulation)) return false; + if (!object.Equals(AdParameter, other.AdParameter)) return false; + if (!object.Equals(AgeRangeView, other.AgeRangeView)) return false; + if (!object.Equals(AdScheduleView, other.AdScheduleView)) return false; + if (!object.Equals(DomainCategory, other.DomainCategory)) return false; + if (!object.Equals(Asset, other.Asset)) return false; + if (!object.Equals(BiddingStrategy, other.BiddingStrategy)) return false; + if (!object.Equals(BillingSetup, other.BillingSetup)) return false; + if (!object.Equals(CampaignBudget, other.CampaignBudget)) return false; + if (!object.Equals(Campaign, other.Campaign)) return false; + if (!object.Equals(CampaignAudienceView, other.CampaignAudienceView)) return false; + if (!object.Equals(CampaignBidModifier, other.CampaignBidModifier)) return false; + if (!object.Equals(CampaignCriterion, other.CampaignCriterion)) return false; + if (!object.Equals(CampaignCriterionSimulation, other.CampaignCriterionSimulation)) return false; + if (!object.Equals(CampaignDraft, other.CampaignDraft)) return false; + if (!object.Equals(CampaignExperiment, other.CampaignExperiment)) return false; + if (!object.Equals(CampaignExtensionSetting, other.CampaignExtensionSetting)) return false; + if (!object.Equals(CampaignFeed, other.CampaignFeed)) return false; + if (!object.Equals(CampaignLabel, other.CampaignLabel)) return false; + if (!object.Equals(CampaignSharedSet, other.CampaignSharedSet)) return false; + if (!object.Equals(CarrierConstant, other.CarrierConstant)) return false; + if (!object.Equals(ChangeStatus, other.ChangeStatus)) return false; + if (!object.Equals(ConversionAction, other.ConversionAction)) return false; + if (!object.Equals(ClickView, other.ClickView)) return false; + if (!object.Equals(CurrencyConstant, other.CurrencyConstant)) return false; + if (!object.Equals(CustomInterest, other.CustomInterest)) return false; + if (!object.Equals(Customer, other.Customer)) return false; + if (!object.Equals(CustomerManagerLink, other.CustomerManagerLink)) return false; + if (!object.Equals(CustomerClientLink, other.CustomerClientLink)) return false; + if (!object.Equals(CustomerClient, other.CustomerClient)) return false; + if (!object.Equals(CustomerExtensionSetting, other.CustomerExtensionSetting)) return false; + if (!object.Equals(CustomerFeed, other.CustomerFeed)) return false; + if (!object.Equals(CustomerLabel, other.CustomerLabel)) return false; + if (!object.Equals(CustomerNegativeCriterion, other.CustomerNegativeCriterion)) return false; + if (!object.Equals(DetailPlacementView, other.DetailPlacementView)) return false; + if (!object.Equals(DisplayKeywordView, other.DisplayKeywordView)) return false; + if (!object.Equals(DistanceView, other.DistanceView)) return false; + if (!object.Equals(DynamicSearchAdsSearchTermView, other.DynamicSearchAdsSearchTermView)) return false; + if (!object.Equals(ExpandedLandingPageView, other.ExpandedLandingPageView)) return false; + if (!object.Equals(ExtensionFeedItem, other.ExtensionFeedItem)) return false; + if (!object.Equals(Feed, other.Feed)) return false; + if (!object.Equals(FeedItem, other.FeedItem)) return false; + if (!object.Equals(FeedItemTarget, other.FeedItemTarget)) return false; + if (!object.Equals(FeedMapping, other.FeedMapping)) return false; + if (!object.Equals(FeedPlaceholderView, other.FeedPlaceholderView)) return false; + if (!object.Equals(GenderView, other.GenderView)) return false; + if (!object.Equals(GeoTargetConstant, other.GeoTargetConstant)) return false; + if (!object.Equals(GeographicView, other.GeographicView)) return false; + if (!object.Equals(GroupPlacementView, other.GroupPlacementView)) return false; + if (!object.Equals(HotelGroupView, other.HotelGroupView)) return false; + if (!object.Equals(HotelPerformanceView, other.HotelPerformanceView)) return false; + if (!object.Equals(KeywordView, other.KeywordView)) return false; + if (!object.Equals(KeywordPlan, other.KeywordPlan)) return false; + if (!object.Equals(KeywordPlanCampaign, other.KeywordPlanCampaign)) return false; + if (!object.Equals(KeywordPlanNegativeKeyword, other.KeywordPlanNegativeKeyword)) return false; + if (!object.Equals(KeywordPlanAdGroup, other.KeywordPlanAdGroup)) return false; + if (!object.Equals(KeywordPlanKeyword, other.KeywordPlanKeyword)) return false; + if (!object.Equals(Label, other.Label)) return false; + if (!object.Equals(LandingPageView, other.LandingPageView)) return false; + if (!object.Equals(LanguageConstant, other.LanguageConstant)) return false; + if (!object.Equals(LocationView, other.LocationView)) return false; + if (!object.Equals(ManagedPlacementView, other.ManagedPlacementView)) return false; + if (!object.Equals(MediaFile, other.MediaFile)) return false; + if (!object.Equals(MobileAppCategoryConstant, other.MobileAppCategoryConstant)) return false; + if (!object.Equals(MobileDeviceConstant, other.MobileDeviceConstant)) return false; + if (!object.Equals(MutateJob, other.MutateJob)) return false; + if (!object.Equals(OperatingSystemVersionConstant, other.OperatingSystemVersionConstant)) return false; + if (!object.Equals(PaidOrganicSearchTermView, other.PaidOrganicSearchTermView)) return false; + if (!object.Equals(ParentalStatusView, other.ParentalStatusView)) return false; + if (!object.Equals(ProductBiddingCategoryConstant, other.ProductBiddingCategoryConstant)) return false; + if (!object.Equals(ProductGroupView, other.ProductGroupView)) return false; + if (!object.Equals(Recommendation, other.Recommendation)) return false; + if (!object.Equals(SearchTermView, other.SearchTermView)) return false; + if (!object.Equals(SharedCriterion, other.SharedCriterion)) return false; + if (!object.Equals(SharedSet, other.SharedSet)) return false; + if (!object.Equals(ShoppingPerformanceView, other.ShoppingPerformanceView)) return false; + if (!object.Equals(TopicView, other.TopicView)) return false; + if (!object.Equals(UserInterest, other.UserInterest)) return false; + if (!object.Equals(UserList, other.UserList)) return false; + if (!object.Equals(UserLocationView, other.UserLocationView)) return false; + if (!object.Equals(RemarketingAction, other.RemarketingAction)) return false; + if (!object.Equals(TopicConstant, other.TopicConstant)) return false; + if (!object.Equals(Video, other.Video)) return false; + if (!object.Equals(Metrics, other.Metrics)) return false; + if (!object.Equals(Segments, other.Segments)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (accountBudget_ != null) hash ^= AccountBudget.GetHashCode(); + if (accountBudgetProposal_ != null) hash ^= AccountBudgetProposal.GetHashCode(); + if (adGroup_ != null) hash ^= AdGroup.GetHashCode(); + if (adGroupAd_ != null) hash ^= AdGroupAd.GetHashCode(); + if (adGroupAdAssetView_ != null) hash ^= AdGroupAdAssetView.GetHashCode(); + if (adGroupAdLabel_ != null) hash ^= AdGroupAdLabel.GetHashCode(); + if (adGroupAudienceView_ != null) hash ^= AdGroupAudienceView.GetHashCode(); + if (adGroupBidModifier_ != null) hash ^= AdGroupBidModifier.GetHashCode(); + if (adGroupCriterion_ != null) hash ^= AdGroupCriterion.GetHashCode(); + if (adGroupCriterionLabel_ != null) hash ^= AdGroupCriterionLabel.GetHashCode(); + if (adGroupCriterionSimulation_ != null) hash ^= AdGroupCriterionSimulation.GetHashCode(); + if (adGroupExtensionSetting_ != null) hash ^= AdGroupExtensionSetting.GetHashCode(); + if (adGroupFeed_ != null) hash ^= AdGroupFeed.GetHashCode(); + if (adGroupLabel_ != null) hash ^= AdGroupLabel.GetHashCode(); + if (adGroupSimulation_ != null) hash ^= AdGroupSimulation.GetHashCode(); + if (adParameter_ != null) hash ^= AdParameter.GetHashCode(); + if (ageRangeView_ != null) hash ^= AgeRangeView.GetHashCode(); + if (adScheduleView_ != null) hash ^= AdScheduleView.GetHashCode(); + if (domainCategory_ != null) hash ^= DomainCategory.GetHashCode(); + if (asset_ != null) hash ^= Asset.GetHashCode(); + if (biddingStrategy_ != null) hash ^= BiddingStrategy.GetHashCode(); + if (billingSetup_ != null) hash ^= BillingSetup.GetHashCode(); + if (campaignBudget_ != null) hash ^= CampaignBudget.GetHashCode(); + if (campaign_ != null) hash ^= Campaign.GetHashCode(); + if (campaignAudienceView_ != null) hash ^= CampaignAudienceView.GetHashCode(); + if (campaignBidModifier_ != null) hash ^= CampaignBidModifier.GetHashCode(); + if (campaignCriterion_ != null) hash ^= CampaignCriterion.GetHashCode(); + if (campaignCriterionSimulation_ != null) hash ^= CampaignCriterionSimulation.GetHashCode(); + if (campaignDraft_ != null) hash ^= CampaignDraft.GetHashCode(); + if (campaignExperiment_ != null) hash ^= CampaignExperiment.GetHashCode(); + if (campaignExtensionSetting_ != null) hash ^= CampaignExtensionSetting.GetHashCode(); + if (campaignFeed_ != null) hash ^= CampaignFeed.GetHashCode(); + if (campaignLabel_ != null) hash ^= CampaignLabel.GetHashCode(); + if (campaignSharedSet_ != null) hash ^= CampaignSharedSet.GetHashCode(); + if (carrierConstant_ != null) hash ^= CarrierConstant.GetHashCode(); + if (changeStatus_ != null) hash ^= ChangeStatus.GetHashCode(); + if (conversionAction_ != null) hash ^= ConversionAction.GetHashCode(); + if (clickView_ != null) hash ^= ClickView.GetHashCode(); + if (currencyConstant_ != null) hash ^= CurrencyConstant.GetHashCode(); + if (customInterest_ != null) hash ^= CustomInterest.GetHashCode(); + if (customer_ != null) hash ^= Customer.GetHashCode(); + if (customerManagerLink_ != null) hash ^= CustomerManagerLink.GetHashCode(); + if (customerClientLink_ != null) hash ^= CustomerClientLink.GetHashCode(); + if (customerClient_ != null) hash ^= CustomerClient.GetHashCode(); + if (customerExtensionSetting_ != null) hash ^= CustomerExtensionSetting.GetHashCode(); + if (customerFeed_ != null) hash ^= CustomerFeed.GetHashCode(); + if (customerLabel_ != null) hash ^= CustomerLabel.GetHashCode(); + if (customerNegativeCriterion_ != null) hash ^= CustomerNegativeCriterion.GetHashCode(); + if (detailPlacementView_ != null) hash ^= DetailPlacementView.GetHashCode(); + if (displayKeywordView_ != null) hash ^= DisplayKeywordView.GetHashCode(); + if (distanceView_ != null) hash ^= DistanceView.GetHashCode(); + if (dynamicSearchAdsSearchTermView_ != null) hash ^= DynamicSearchAdsSearchTermView.GetHashCode(); + if (expandedLandingPageView_ != null) hash ^= ExpandedLandingPageView.GetHashCode(); + if (extensionFeedItem_ != null) hash ^= ExtensionFeedItem.GetHashCode(); + if (feed_ != null) hash ^= Feed.GetHashCode(); + if (feedItem_ != null) hash ^= FeedItem.GetHashCode(); + if (feedItemTarget_ != null) hash ^= FeedItemTarget.GetHashCode(); + if (feedMapping_ != null) hash ^= FeedMapping.GetHashCode(); + if (feedPlaceholderView_ != null) hash ^= FeedPlaceholderView.GetHashCode(); + if (genderView_ != null) hash ^= GenderView.GetHashCode(); + if (geoTargetConstant_ != null) hash ^= GeoTargetConstant.GetHashCode(); + if (geographicView_ != null) hash ^= GeographicView.GetHashCode(); + if (groupPlacementView_ != null) hash ^= GroupPlacementView.GetHashCode(); + if (hotelGroupView_ != null) hash ^= HotelGroupView.GetHashCode(); + if (hotelPerformanceView_ != null) hash ^= HotelPerformanceView.GetHashCode(); + if (keywordView_ != null) hash ^= KeywordView.GetHashCode(); + if (keywordPlan_ != null) hash ^= KeywordPlan.GetHashCode(); + if (keywordPlanCampaign_ != null) hash ^= KeywordPlanCampaign.GetHashCode(); + if (keywordPlanNegativeKeyword_ != null) hash ^= KeywordPlanNegativeKeyword.GetHashCode(); + if (keywordPlanAdGroup_ != null) hash ^= KeywordPlanAdGroup.GetHashCode(); + if (keywordPlanKeyword_ != null) hash ^= KeywordPlanKeyword.GetHashCode(); + if (label_ != null) hash ^= Label.GetHashCode(); + if (landingPageView_ != null) hash ^= LandingPageView.GetHashCode(); + if (languageConstant_ != null) hash ^= LanguageConstant.GetHashCode(); + if (locationView_ != null) hash ^= LocationView.GetHashCode(); + if (managedPlacementView_ != null) hash ^= ManagedPlacementView.GetHashCode(); + if (mediaFile_ != null) hash ^= MediaFile.GetHashCode(); + if (mobileAppCategoryConstant_ != null) hash ^= MobileAppCategoryConstant.GetHashCode(); + if (mobileDeviceConstant_ != null) hash ^= MobileDeviceConstant.GetHashCode(); + if (mutateJob_ != null) hash ^= MutateJob.GetHashCode(); + if (operatingSystemVersionConstant_ != null) hash ^= OperatingSystemVersionConstant.GetHashCode(); + if (paidOrganicSearchTermView_ != null) hash ^= PaidOrganicSearchTermView.GetHashCode(); + if (parentalStatusView_ != null) hash ^= ParentalStatusView.GetHashCode(); + if (productBiddingCategoryConstant_ != null) hash ^= ProductBiddingCategoryConstant.GetHashCode(); + if (productGroupView_ != null) hash ^= ProductGroupView.GetHashCode(); + if (recommendation_ != null) hash ^= Recommendation.GetHashCode(); + if (searchTermView_ != null) hash ^= SearchTermView.GetHashCode(); + if (sharedCriterion_ != null) hash ^= SharedCriterion.GetHashCode(); + if (sharedSet_ != null) hash ^= SharedSet.GetHashCode(); + if (shoppingPerformanceView_ != null) hash ^= ShoppingPerformanceView.GetHashCode(); + if (topicView_ != null) hash ^= TopicView.GetHashCode(); + if (userInterest_ != null) hash ^= UserInterest.GetHashCode(); + if (userList_ != null) hash ^= UserList.GetHashCode(); + if (userLocationView_ != null) hash ^= UserLocationView.GetHashCode(); + if (remarketingAction_ != null) hash ^= RemarketingAction.GetHashCode(); + if (topicConstant_ != null) hash ^= TopicConstant.GetHashCode(); + if (video_ != null) hash ^= Video.GetHashCode(); + if (metrics_ != null) hash ^= Metrics.GetHashCode(); + if (segments_ != null) hash ^= Segments.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (customer_ != null) { + output.WriteRawTag(10); + output.WriteMessage(Customer); + } + if (campaign_ != null) { + output.WriteRawTag(18); + output.WriteMessage(Campaign); + } + if (adGroup_ != null) { + output.WriteRawTag(26); + output.WriteMessage(AdGroup); + } + if (metrics_ != null) { + output.WriteRawTag(34); + output.WriteMessage(Metrics); + } + if (adGroupAd_ != null) { + output.WriteRawTag(130, 1); + output.WriteMessage(AdGroupAd); + } + if (adGroupCriterion_ != null) { + output.WriteRawTag(138, 1); + output.WriteMessage(AdGroupCriterion); + } + if (biddingStrategy_ != null) { + output.WriteRawTag(146, 1); + output.WriteMessage(BiddingStrategy); + } + if (campaignBudget_ != null) { + output.WriteRawTag(154, 1); + output.WriteMessage(CampaignBudget); + } + if (campaignCriterion_ != null) { + output.WriteRawTag(162, 1); + output.WriteMessage(CampaignCriterion); + } + if (keywordView_ != null) { + output.WriteRawTag(170, 1); + output.WriteMessage(KeywordView); + } + if (recommendation_ != null) { + output.WriteRawTag(178, 1); + output.WriteMessage(Recommendation); + } + if (geoTargetConstant_ != null) { + output.WriteRawTag(186, 1); + output.WriteMessage(GeoTargetConstant); + } + if (adGroupBidModifier_ != null) { + output.WriteRawTag(194, 1); + output.WriteMessage(AdGroupBidModifier); + } + if (campaignBidModifier_ != null) { + output.WriteRawTag(210, 1); + output.WriteMessage(CampaignBidModifier); + } + if (sharedSet_ != null) { + output.WriteRawTag(218, 1); + output.WriteMessage(SharedSet); + } + if (sharedCriterion_ != null) { + output.WriteRawTag(234, 1); + output.WriteMessage(SharedCriterion); + } + if (campaignSharedSet_ != null) { + output.WriteRawTag(242, 1); + output.WriteMessage(CampaignSharedSet); + } + if (topicConstant_ != null) { + output.WriteRawTag(250, 1); + output.WriteMessage(TopicConstant); + } + if (keywordPlan_ != null) { + output.WriteRawTag(130, 2); + output.WriteMessage(KeywordPlan); + } + if (keywordPlanCampaign_ != null) { + output.WriteRawTag(138, 2); + output.WriteMessage(KeywordPlanCampaign); + } + if (keywordPlanNegativeKeyword_ != null) { + output.WriteRawTag(146, 2); + output.WriteMessage(KeywordPlanNegativeKeyword); + } + if (keywordPlanAdGroup_ != null) { + output.WriteRawTag(154, 2); + output.WriteMessage(KeywordPlanAdGroup); + } + if (keywordPlanKeyword_ != null) { + output.WriteRawTag(162, 2); + output.WriteMessage(KeywordPlanKeyword); + } + if (changeStatus_ != null) { + output.WriteRawTag(170, 2); + output.WriteMessage(ChangeStatus); + } + if (userList_ != null) { + output.WriteRawTag(178, 2); + output.WriteMessage(UserList); + } + if (video_ != null) { + output.WriteRawTag(186, 2); + output.WriteMessage(Video); + } + if (genderView_ != null) { + output.WriteRawTag(194, 2); + output.WriteMessage(GenderView); + } + if (billingSetup_ != null) { + output.WriteRawTag(202, 2); + output.WriteMessage(BillingSetup); + } + if (accountBudget_ != null) { + output.WriteRawTag(210, 2); + output.WriteMessage(AccountBudget); + } + if (accountBudgetProposal_ != null) { + output.WriteRawTag(218, 2); + output.WriteMessage(AccountBudgetProposal); + } + if (topicView_ != null) { + output.WriteRawTag(226, 2); + output.WriteMessage(TopicView); + } + if (parentalStatusView_ != null) { + output.WriteRawTag(234, 2); + output.WriteMessage(ParentalStatusView); + } + if (feed_ != null) { + output.WriteRawTag(242, 2); + output.WriteMessage(Feed); + } + if (displayKeywordView_ != null) { + output.WriteRawTag(250, 2); + output.WriteMessage(DisplayKeywordView); + } + if (ageRangeView_ != null) { + output.WriteRawTag(130, 3); + output.WriteMessage(AgeRangeView); + } + if (campaignDraft_ != null) { + output.WriteRawTag(138, 3); + output.WriteMessage(CampaignDraft); + } + if (feedItem_ != null) { + output.WriteRawTag(146, 3); + output.WriteMessage(FeedItem); + } + if (hotelGroupView_ != null) { + output.WriteRawTag(154, 3); + output.WriteMessage(HotelGroupView); + } + if (label_ != null) { + output.WriteRawTag(162, 3); + output.WriteMessage(Label); + } + if (managedPlacementView_ != null) { + output.WriteRawTag(170, 3); + output.WriteMessage(ManagedPlacementView); + } + if (productGroupView_ != null) { + output.WriteRawTag(178, 3); + output.WriteMessage(ProductGroupView); + } + if (languageConstant_ != null) { + output.WriteRawTag(186, 3); + output.WriteMessage(LanguageConstant); + } + if (adGroupAudienceView_ != null) { + output.WriteRawTag(202, 3); + output.WriteMessage(AdGroupAudienceView); + } + if (feedMapping_ != null) { + output.WriteRawTag(210, 3); + output.WriteMessage(FeedMapping); + } + if (userInterest_ != null) { + output.WriteRawTag(218, 3); + output.WriteMessage(UserInterest); + } + if (remarketingAction_ != null) { + output.WriteRawTag(226, 3); + output.WriteMessage(RemarketingAction); + } + if (customerManagerLink_ != null) { + output.WriteRawTag(234, 3); + output.WriteMessage(CustomerManagerLink); + } + if (customerClientLink_ != null) { + output.WriteRawTag(242, 3); + output.WriteMessage(CustomerClientLink); + } + if (campaignFeed_ != null) { + output.WriteRawTag(250, 3); + output.WriteMessage(CampaignFeed); + } + if (customerFeed_ != null) { + output.WriteRawTag(130, 4); + output.WriteMessage(CustomerFeed); + } + if (carrierConstant_ != null) { + output.WriteRawTag(146, 4); + output.WriteMessage(CarrierConstant); + } + if (adGroupFeed_ != null) { + output.WriteRawTag(154, 4); + output.WriteMessage(AdGroupFeed); + } + if (searchTermView_ != null) { + output.WriteRawTag(162, 4); + output.WriteMessage(SearchTermView); + } + if (campaignAudienceView_ != null) { + output.WriteRawTag(170, 4); + output.WriteMessage(CampaignAudienceView); + } + if (customerClient_ != null) { + output.WriteRawTag(178, 4); + output.WriteMessage(CustomerClient); + } + if (hotelPerformanceView_ != null) { + output.WriteRawTag(186, 4); + output.WriteMessage(HotelPerformanceView); + } + if (campaignExperiment_ != null) { + output.WriteRawTag(162, 5); + output.WriteMessage(CampaignExperiment); + } + if (extensionFeedItem_ != null) { + output.WriteRawTag(170, 5); + output.WriteMessage(ExtensionFeedItem); + } + if (operatingSystemVersionConstant_ != null) { + output.WriteRawTag(178, 5); + output.WriteMessage(OperatingSystemVersionConstant); + } + if (mobileAppCategoryConstant_ != null) { + output.WriteRawTag(186, 5); + output.WriteMessage(MobileAppCategoryConstant); + } + if (customerNegativeCriterion_ != null) { + output.WriteRawTag(194, 5); + output.WriteMessage(CustomerNegativeCriterion); + } + if (adScheduleView_ != null) { + output.WriteRawTag(202, 5); + output.WriteMessage(AdScheduleView); + } + if (mediaFile_ != null) { + output.WriteRawTag(210, 5); + output.WriteMessage(MediaFile); + } + if (domainCategory_ != null) { + output.WriteRawTag(218, 5); + output.WriteMessage(DomainCategory); + } + if (feedPlaceholderView_ != null) { + output.WriteRawTag(138, 6); + output.WriteMessage(FeedPlaceholderView); + } + if (mobileDeviceConstant_ != null) { + output.WriteRawTag(146, 6); + output.WriteMessage(MobileDeviceConstant); + } + if (segments_ != null) { + output.WriteRawTag(178, 6); + output.WriteMessage(Segments); + } + if (conversionAction_ != null) { + output.WriteRawTag(186, 6); + output.WriteMessage(ConversionAction); + } + if (customInterest_ != null) { + output.WriteRawTag(194, 6); + output.WriteMessage(CustomInterest); + } + if (asset_ != null) { + output.WriteRawTag(202, 6); + output.WriteMessage(Asset); + } + if (dynamicSearchAdsSearchTermView_ != null) { + output.WriteRawTag(210, 6); + output.WriteMessage(DynamicSearchAdsSearchTermView); + } + if (adGroupSimulation_ != null) { + output.WriteRawTag(218, 6); + output.WriteMessage(AdGroupSimulation); + } + if (campaignLabel_ != null) { + output.WriteRawTag(226, 6); + output.WriteMessage(CampaignLabel); + } + if (productBiddingCategoryConstant_ != null) { + output.WriteRawTag(234, 6); + output.WriteMessage(ProductBiddingCategoryConstant); + } + if (adGroupCriterionSimulation_ != null) { + output.WriteRawTag(242, 6); + output.WriteMessage(AdGroupCriterionSimulation); + } + if (campaignCriterionSimulation_ != null) { + output.WriteRawTag(250, 6); + output.WriteMessage(CampaignCriterionSimulation); + } + if (adGroupExtensionSetting_ != null) { + output.WriteRawTag(130, 7); + output.WriteMessage(AdGroupExtensionSetting); + } + if (campaignExtensionSetting_ != null) { + output.WriteRawTag(138, 7); + output.WriteMessage(CampaignExtensionSetting); + } + if (customerExtensionSetting_ != null) { + output.WriteRawTag(146, 7); + output.WriteMessage(CustomerExtensionSetting); + } + if (adGroupLabel_ != null) { + output.WriteRawTag(154, 7); + output.WriteMessage(AdGroupLabel); + } + if (feedItemTarget_ != null) { + output.WriteRawTag(162, 7); + output.WriteMessage(FeedItemTarget); + } + if (shoppingPerformanceView_ != null) { + output.WriteRawTag(170, 7); + output.WriteMessage(ShoppingPerformanceView); + } + if (detailPlacementView_ != null) { + output.WriteRawTag(178, 7); + output.WriteMessage(DetailPlacementView); + } + if (groupPlacementView_ != null) { + output.WriteRawTag(186, 7); + output.WriteMessage(GroupPlacementView); + } + if (adGroupAdLabel_ != null) { + output.WriteRawTag(194, 7); + output.WriteMessage(AdGroupAdLabel); + } + if (adGroupCriterionLabel_ != null) { + output.WriteRawTag(202, 7); + output.WriteMessage(AdGroupCriterionLabel); + } + if (clickView_ != null) { + output.WriteRawTag(210, 7); + output.WriteMessage(ClickView); + } + if (locationView_ != null) { + output.WriteRawTag(218, 7); + output.WriteMessage(LocationView); + } + if (customerLabel_ != null) { + output.WriteRawTag(226, 7); + output.WriteMessage(CustomerLabel); + } + if (geographicView_ != null) { + output.WriteRawTag(234, 7); + output.WriteMessage(GeographicView); + } + if (landingPageView_ != null) { + output.WriteRawTag(242, 7); + output.WriteMessage(LandingPageView); + } + if (mutateJob_ != null) { + output.WriteRawTag(250, 7); + output.WriteMessage(MutateJob); + } + if (expandedLandingPageView_ != null) { + output.WriteRawTag(130, 8); + output.WriteMessage(ExpandedLandingPageView); + } + if (paidOrganicSearchTermView_ != null) { + output.WriteRawTag(138, 8); + output.WriteMessage(PaidOrganicSearchTermView); + } + if (adParameter_ != null) { + output.WriteRawTag(146, 8); + output.WriteMessage(AdParameter); + } + if (adGroupAdAssetView_ != null) { + output.WriteRawTag(154, 8); + output.WriteMessage(AdGroupAdAssetView); + } + if (distanceView_ != null) { + output.WriteRawTag(162, 8); + output.WriteMessage(DistanceView); + } + if (currencyConstant_ != null) { + output.WriteRawTag(178, 8); + output.WriteMessage(CurrencyConstant); + } + if (userLocationView_ != null) { + output.WriteRawTag(186, 8); + output.WriteMessage(UserLocationView); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (accountBudget_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AccountBudget); + } + if (accountBudgetProposal_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AccountBudgetProposal); + } + if (adGroup_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroup); + } + if (adGroupAd_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupAd); + } + if (adGroupAdAssetView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupAdAssetView); + } + if (adGroupAdLabel_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupAdLabel); + } + if (adGroupAudienceView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupAudienceView); + } + if (adGroupBidModifier_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupBidModifier); + } + if (adGroupCriterion_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupCriterion); + } + if (adGroupCriterionLabel_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupCriterionLabel); + } + if (adGroupCriterionSimulation_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupCriterionSimulation); + } + if (adGroupExtensionSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupExtensionSetting); + } + if (adGroupFeed_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupFeed); + } + if (adGroupLabel_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupLabel); + } + if (adGroupSimulation_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupSimulation); + } + if (adParameter_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdParameter); + } + if (ageRangeView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AgeRangeView); + } + if (adScheduleView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdScheduleView); + } + if (domainCategory_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(DomainCategory); + } + if (asset_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Asset); + } + if (biddingStrategy_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(BiddingStrategy); + } + if (billingSetup_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(BillingSetup); + } + if (campaignBudget_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignBudget); + } + if (campaign_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Campaign); + } + if (campaignAudienceView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignAudienceView); + } + if (campaignBidModifier_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignBidModifier); + } + if (campaignCriterion_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignCriterion); + } + if (campaignCriterionSimulation_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignCriterionSimulation); + } + if (campaignDraft_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignDraft); + } + if (campaignExperiment_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignExperiment); + } + if (campaignExtensionSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignExtensionSetting); + } + if (campaignFeed_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignFeed); + } + if (campaignLabel_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignLabel); + } + if (campaignSharedSet_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignSharedSet); + } + if (carrierConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CarrierConstant); + } + if (changeStatus_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ChangeStatus); + } + if (conversionAction_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ConversionAction); + } + if (clickView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ClickView); + } + if (currencyConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CurrencyConstant); + } + if (customInterest_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomInterest); + } + if (customer_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Customer); + } + if (customerManagerLink_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerManagerLink); + } + if (customerClientLink_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerClientLink); + } + if (customerClient_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerClient); + } + if (customerExtensionSetting_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerExtensionSetting); + } + if (customerFeed_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerFeed); + } + if (customerLabel_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerLabel); + } + if (customerNegativeCriterion_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerNegativeCriterion); + } + if (detailPlacementView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(DetailPlacementView); + } + if (displayKeywordView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(DisplayKeywordView); + } + if (distanceView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(DistanceView); + } + if (dynamicSearchAdsSearchTermView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(DynamicSearchAdsSearchTermView); + } + if (expandedLandingPageView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ExpandedLandingPageView); + } + if (extensionFeedItem_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ExtensionFeedItem); + } + if (feed_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Feed); + } + if (feedItem_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedItem); + } + if (feedItemTarget_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedItemTarget); + } + if (feedMapping_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedMapping); + } + if (feedPlaceholderView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedPlaceholderView); + } + if (genderView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(GenderView); + } + if (geoTargetConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(GeoTargetConstant); + } + if (geographicView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(GeographicView); + } + if (groupPlacementView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(GroupPlacementView); + } + if (hotelGroupView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(HotelGroupView); + } + if (hotelPerformanceView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(HotelPerformanceView); + } + if (keywordView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(KeywordView); + } + if (keywordPlan_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(KeywordPlan); + } + if (keywordPlanCampaign_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(KeywordPlanCampaign); + } + if (keywordPlanNegativeKeyword_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(KeywordPlanNegativeKeyword); + } + if (keywordPlanAdGroup_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(KeywordPlanAdGroup); + } + if (keywordPlanKeyword_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(KeywordPlanKeyword); + } + if (label_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Label); + } + if (landingPageView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(LandingPageView); + } + if (languageConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(LanguageConstant); + } + if (locationView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(LocationView); + } + if (managedPlacementView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ManagedPlacementView); + } + if (mediaFile_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MediaFile); + } + if (mobileAppCategoryConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MobileAppCategoryConstant); + } + if (mobileDeviceConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MobileDeviceConstant); + } + if (mutateJob_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MutateJob); + } + if (operatingSystemVersionConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(OperatingSystemVersionConstant); + } + if (paidOrganicSearchTermView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(PaidOrganicSearchTermView); + } + if (parentalStatusView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ParentalStatusView); + } + if (productBiddingCategoryConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ProductBiddingCategoryConstant); + } + if (productGroupView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ProductGroupView); + } + if (recommendation_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Recommendation); + } + if (searchTermView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(SearchTermView); + } + if (sharedCriterion_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(SharedCriterion); + } + if (sharedSet_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(SharedSet); + } + if (shoppingPerformanceView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ShoppingPerformanceView); + } + if (topicView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TopicView); + } + if (userInterest_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserInterest); + } + if (userList_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserList); + } + if (userLocationView_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserLocationView); + } + if (remarketingAction_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(RemarketingAction); + } + if (topicConstant_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(TopicConstant); + } + if (video_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Video); + } + if (metrics_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Metrics); + } + if (segments_ != null) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(Segments); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GoogleAdsRow other) { + if (other == null) { + return; + } + if (other.accountBudget_ != null) { + if (accountBudget_ == null) { + AccountBudget = new global::Google.Ads.GoogleAds.V3.Resources.AccountBudget(); + } + AccountBudget.MergeFrom(other.AccountBudget); + } + if (other.accountBudgetProposal_ != null) { + if (accountBudgetProposal_ == null) { + AccountBudgetProposal = new global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal(); + } + AccountBudgetProposal.MergeFrom(other.AccountBudgetProposal); + } + if (other.adGroup_ != null) { + if (adGroup_ == null) { + AdGroup = new global::Google.Ads.GoogleAds.V3.Resources.AdGroup(); + } + AdGroup.MergeFrom(other.AdGroup); + } + if (other.adGroupAd_ != null) { + if (adGroupAd_ == null) { + AdGroupAd = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd(); + } + AdGroupAd.MergeFrom(other.AdGroupAd); + } + if (other.adGroupAdAssetView_ != null) { + if (adGroupAdAssetView_ == null) { + AdGroupAdAssetView = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView(); + } + AdGroupAdAssetView.MergeFrom(other.AdGroupAdAssetView); + } + if (other.adGroupAdLabel_ != null) { + if (adGroupAdLabel_ == null) { + AdGroupAdLabel = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel(); + } + AdGroupAdLabel.MergeFrom(other.AdGroupAdLabel); + } + if (other.adGroupAudienceView_ != null) { + if (adGroupAudienceView_ == null) { + AdGroupAudienceView = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView(); + } + AdGroupAudienceView.MergeFrom(other.AdGroupAudienceView); + } + if (other.adGroupBidModifier_ != null) { + if (adGroupBidModifier_ == null) { + AdGroupBidModifier = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier(); + } + AdGroupBidModifier.MergeFrom(other.AdGroupBidModifier); + } + if (other.adGroupCriterion_ != null) { + if (adGroupCriterion_ == null) { + AdGroupCriterion = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion(); + } + AdGroupCriterion.MergeFrom(other.AdGroupCriterion); + } + if (other.adGroupCriterionLabel_ != null) { + if (adGroupCriterionLabel_ == null) { + AdGroupCriterionLabel = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel(); + } + AdGroupCriterionLabel.MergeFrom(other.AdGroupCriterionLabel); + } + if (other.adGroupCriterionSimulation_ != null) { + if (adGroupCriterionSimulation_ == null) { + AdGroupCriterionSimulation = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation(); + } + AdGroupCriterionSimulation.MergeFrom(other.AdGroupCriterionSimulation); + } + if (other.adGroupExtensionSetting_ != null) { + if (adGroupExtensionSetting_ == null) { + AdGroupExtensionSetting = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting(); + } + AdGroupExtensionSetting.MergeFrom(other.AdGroupExtensionSetting); + } + if (other.adGroupFeed_ != null) { + if (adGroupFeed_ == null) { + AdGroupFeed = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed(); + } + AdGroupFeed.MergeFrom(other.AdGroupFeed); + } + if (other.adGroupLabel_ != null) { + if (adGroupLabel_ == null) { + AdGroupLabel = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel(); + } + AdGroupLabel.MergeFrom(other.AdGroupLabel); + } + if (other.adGroupSimulation_ != null) { + if (adGroupSimulation_ == null) { + AdGroupSimulation = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation(); + } + AdGroupSimulation.MergeFrom(other.AdGroupSimulation); + } + if (other.adParameter_ != null) { + if (adParameter_ == null) { + AdParameter = new global::Google.Ads.GoogleAds.V3.Resources.AdParameter(); + } + AdParameter.MergeFrom(other.AdParameter); + } + if (other.ageRangeView_ != null) { + if (ageRangeView_ == null) { + AgeRangeView = new global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView(); + } + AgeRangeView.MergeFrom(other.AgeRangeView); + } + if (other.adScheduleView_ != null) { + if (adScheduleView_ == null) { + AdScheduleView = new global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView(); + } + AdScheduleView.MergeFrom(other.AdScheduleView); + } + if (other.domainCategory_ != null) { + if (domainCategory_ == null) { + DomainCategory = new global::Google.Ads.GoogleAds.V3.Resources.DomainCategory(); + } + DomainCategory.MergeFrom(other.DomainCategory); + } + if (other.asset_ != null) { + if (asset_ == null) { + Asset = new global::Google.Ads.GoogleAds.V3.Resources.Asset(); + } + Asset.MergeFrom(other.Asset); + } + if (other.biddingStrategy_ != null) { + if (biddingStrategy_ == null) { + BiddingStrategy = new global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy(); + } + BiddingStrategy.MergeFrom(other.BiddingStrategy); + } + if (other.billingSetup_ != null) { + if (billingSetup_ == null) { + BillingSetup = new global::Google.Ads.GoogleAds.V3.Resources.BillingSetup(); + } + BillingSetup.MergeFrom(other.BillingSetup); + } + if (other.campaignBudget_ != null) { + if (campaignBudget_ == null) { + CampaignBudget = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget(); + } + CampaignBudget.MergeFrom(other.CampaignBudget); + } + if (other.campaign_ != null) { + if (campaign_ == null) { + Campaign = new global::Google.Ads.GoogleAds.V3.Resources.Campaign(); + } + Campaign.MergeFrom(other.Campaign); + } + if (other.campaignAudienceView_ != null) { + if (campaignAudienceView_ == null) { + CampaignAudienceView = new global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView(); + } + CampaignAudienceView.MergeFrom(other.CampaignAudienceView); + } + if (other.campaignBidModifier_ != null) { + if (campaignBidModifier_ == null) { + CampaignBidModifier = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier(); + } + CampaignBidModifier.MergeFrom(other.CampaignBidModifier); + } + if (other.campaignCriterion_ != null) { + if (campaignCriterion_ == null) { + CampaignCriterion = new global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion(); + } + CampaignCriterion.MergeFrom(other.CampaignCriterion); + } + if (other.campaignCriterionSimulation_ != null) { + if (campaignCriterionSimulation_ == null) { + CampaignCriterionSimulation = new global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation(); + } + CampaignCriterionSimulation.MergeFrom(other.CampaignCriterionSimulation); + } + if (other.campaignDraft_ != null) { + if (campaignDraft_ == null) { + CampaignDraft = new global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft(); + } + CampaignDraft.MergeFrom(other.CampaignDraft); + } + if (other.campaignExperiment_ != null) { + if (campaignExperiment_ == null) { + CampaignExperiment = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment(); + } + CampaignExperiment.MergeFrom(other.CampaignExperiment); + } + if (other.campaignExtensionSetting_ != null) { + if (campaignExtensionSetting_ == null) { + CampaignExtensionSetting = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting(); + } + CampaignExtensionSetting.MergeFrom(other.CampaignExtensionSetting); + } + if (other.campaignFeed_ != null) { + if (campaignFeed_ == null) { + CampaignFeed = new global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed(); + } + CampaignFeed.MergeFrom(other.CampaignFeed); + } + if (other.campaignLabel_ != null) { + if (campaignLabel_ == null) { + CampaignLabel = new global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel(); + } + CampaignLabel.MergeFrom(other.CampaignLabel); + } + if (other.campaignSharedSet_ != null) { + if (campaignSharedSet_ == null) { + CampaignSharedSet = new global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet(); + } + CampaignSharedSet.MergeFrom(other.CampaignSharedSet); + } + if (other.carrierConstant_ != null) { + if (carrierConstant_ == null) { + CarrierConstant = new global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant(); + } + CarrierConstant.MergeFrom(other.CarrierConstant); + } + if (other.changeStatus_ != null) { + if (changeStatus_ == null) { + ChangeStatus = new global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus(); + } + ChangeStatus.MergeFrom(other.ChangeStatus); + } + if (other.conversionAction_ != null) { + if (conversionAction_ == null) { + ConversionAction = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction(); + } + ConversionAction.MergeFrom(other.ConversionAction); + } + if (other.clickView_ != null) { + if (clickView_ == null) { + ClickView = new global::Google.Ads.GoogleAds.V3.Resources.ClickView(); + } + ClickView.MergeFrom(other.ClickView); + } + if (other.currencyConstant_ != null) { + if (currencyConstant_ == null) { + CurrencyConstant = new global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant(); + } + CurrencyConstant.MergeFrom(other.CurrencyConstant); + } + if (other.customInterest_ != null) { + if (customInterest_ == null) { + CustomInterest = new global::Google.Ads.GoogleAds.V3.Resources.CustomInterest(); + } + CustomInterest.MergeFrom(other.CustomInterest); + } + if (other.customer_ != null) { + if (customer_ == null) { + Customer = new global::Google.Ads.GoogleAds.V3.Resources.Customer(); + } + Customer.MergeFrom(other.Customer); + } + if (other.customerManagerLink_ != null) { + if (customerManagerLink_ == null) { + CustomerManagerLink = new global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink(); + } + CustomerManagerLink.MergeFrom(other.CustomerManagerLink); + } + if (other.customerClientLink_ != null) { + if (customerClientLink_ == null) { + CustomerClientLink = new global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink(); + } + CustomerClientLink.MergeFrom(other.CustomerClientLink); + } + if (other.customerClient_ != null) { + if (customerClient_ == null) { + CustomerClient = new global::Google.Ads.GoogleAds.V3.Resources.CustomerClient(); + } + CustomerClient.MergeFrom(other.CustomerClient); + } + if (other.customerExtensionSetting_ != null) { + if (customerExtensionSetting_ == null) { + CustomerExtensionSetting = new global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting(); + } + CustomerExtensionSetting.MergeFrom(other.CustomerExtensionSetting); + } + if (other.customerFeed_ != null) { + if (customerFeed_ == null) { + CustomerFeed = new global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed(); + } + CustomerFeed.MergeFrom(other.CustomerFeed); + } + if (other.customerLabel_ != null) { + if (customerLabel_ == null) { + CustomerLabel = new global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel(); + } + CustomerLabel.MergeFrom(other.CustomerLabel); + } + if (other.customerNegativeCriterion_ != null) { + if (customerNegativeCriterion_ == null) { + CustomerNegativeCriterion = new global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion(); + } + CustomerNegativeCriterion.MergeFrom(other.CustomerNegativeCriterion); + } + if (other.detailPlacementView_ != null) { + if (detailPlacementView_ == null) { + DetailPlacementView = new global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView(); + } + DetailPlacementView.MergeFrom(other.DetailPlacementView); + } + if (other.displayKeywordView_ != null) { + if (displayKeywordView_ == null) { + DisplayKeywordView = new global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView(); + } + DisplayKeywordView.MergeFrom(other.DisplayKeywordView); + } + if (other.distanceView_ != null) { + if (distanceView_ == null) { + DistanceView = new global::Google.Ads.GoogleAds.V3.Resources.DistanceView(); + } + DistanceView.MergeFrom(other.DistanceView); + } + if (other.dynamicSearchAdsSearchTermView_ != null) { + if (dynamicSearchAdsSearchTermView_ == null) { + DynamicSearchAdsSearchTermView = new global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView(); + } + DynamicSearchAdsSearchTermView.MergeFrom(other.DynamicSearchAdsSearchTermView); + } + if (other.expandedLandingPageView_ != null) { + if (expandedLandingPageView_ == null) { + ExpandedLandingPageView = new global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView(); + } + ExpandedLandingPageView.MergeFrom(other.ExpandedLandingPageView); + } + if (other.extensionFeedItem_ != null) { + if (extensionFeedItem_ == null) { + ExtensionFeedItem = new global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem(); + } + ExtensionFeedItem.MergeFrom(other.ExtensionFeedItem); + } + if (other.feed_ != null) { + if (feed_ == null) { + Feed = new global::Google.Ads.GoogleAds.V3.Resources.Feed(); + } + Feed.MergeFrom(other.Feed); + } + if (other.feedItem_ != null) { + if (feedItem_ == null) { + FeedItem = new global::Google.Ads.GoogleAds.V3.Resources.FeedItem(); + } + FeedItem.MergeFrom(other.FeedItem); + } + if (other.feedItemTarget_ != null) { + if (feedItemTarget_ == null) { + FeedItemTarget = new global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget(); + } + FeedItemTarget.MergeFrom(other.FeedItemTarget); + } + if (other.feedMapping_ != null) { + if (feedMapping_ == null) { + FeedMapping = new global::Google.Ads.GoogleAds.V3.Resources.FeedMapping(); + } + FeedMapping.MergeFrom(other.FeedMapping); + } + if (other.feedPlaceholderView_ != null) { + if (feedPlaceholderView_ == null) { + FeedPlaceholderView = new global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView(); + } + FeedPlaceholderView.MergeFrom(other.FeedPlaceholderView); + } + if (other.genderView_ != null) { + if (genderView_ == null) { + GenderView = new global::Google.Ads.GoogleAds.V3.Resources.GenderView(); + } + GenderView.MergeFrom(other.GenderView); + } + if (other.geoTargetConstant_ != null) { + if (geoTargetConstant_ == null) { + GeoTargetConstant = new global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant(); + } + GeoTargetConstant.MergeFrom(other.GeoTargetConstant); + } + if (other.geographicView_ != null) { + if (geographicView_ == null) { + GeographicView = new global::Google.Ads.GoogleAds.V3.Resources.GeographicView(); + } + GeographicView.MergeFrom(other.GeographicView); + } + if (other.groupPlacementView_ != null) { + if (groupPlacementView_ == null) { + GroupPlacementView = new global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView(); + } + GroupPlacementView.MergeFrom(other.GroupPlacementView); + } + if (other.hotelGroupView_ != null) { + if (hotelGroupView_ == null) { + HotelGroupView = new global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView(); + } + HotelGroupView.MergeFrom(other.HotelGroupView); + } + if (other.hotelPerformanceView_ != null) { + if (hotelPerformanceView_ == null) { + HotelPerformanceView = new global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView(); + } + HotelPerformanceView.MergeFrom(other.HotelPerformanceView); + } + if (other.keywordView_ != null) { + if (keywordView_ == null) { + KeywordView = new global::Google.Ads.GoogleAds.V3.Resources.KeywordView(); + } + KeywordView.MergeFrom(other.KeywordView); + } + if (other.keywordPlan_ != null) { + if (keywordPlan_ == null) { + KeywordPlan = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan(); + } + KeywordPlan.MergeFrom(other.KeywordPlan); + } + if (other.keywordPlanCampaign_ != null) { + if (keywordPlanCampaign_ == null) { + KeywordPlanCampaign = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign(); + } + KeywordPlanCampaign.MergeFrom(other.KeywordPlanCampaign); + } + if (other.keywordPlanNegativeKeyword_ != null) { + if (keywordPlanNegativeKeyword_ == null) { + KeywordPlanNegativeKeyword = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword(); + } + KeywordPlanNegativeKeyword.MergeFrom(other.KeywordPlanNegativeKeyword); + } + if (other.keywordPlanAdGroup_ != null) { + if (keywordPlanAdGroup_ == null) { + KeywordPlanAdGroup = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup(); + } + KeywordPlanAdGroup.MergeFrom(other.KeywordPlanAdGroup); + } + if (other.keywordPlanKeyword_ != null) { + if (keywordPlanKeyword_ == null) { + KeywordPlanKeyword = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword(); + } + KeywordPlanKeyword.MergeFrom(other.KeywordPlanKeyword); + } + if (other.label_ != null) { + if (label_ == null) { + Label = new global::Google.Ads.GoogleAds.V3.Resources.Label(); + } + Label.MergeFrom(other.Label); + } + if (other.landingPageView_ != null) { + if (landingPageView_ == null) { + LandingPageView = new global::Google.Ads.GoogleAds.V3.Resources.LandingPageView(); + } + LandingPageView.MergeFrom(other.LandingPageView); + } + if (other.languageConstant_ != null) { + if (languageConstant_ == null) { + LanguageConstant = new global::Google.Ads.GoogleAds.V3.Resources.LanguageConstant(); + } + LanguageConstant.MergeFrom(other.LanguageConstant); + } + if (other.locationView_ != null) { + if (locationView_ == null) { + LocationView = new global::Google.Ads.GoogleAds.V3.Resources.LocationView(); + } + LocationView.MergeFrom(other.LocationView); + } + if (other.managedPlacementView_ != null) { + if (managedPlacementView_ == null) { + ManagedPlacementView = new global::Google.Ads.GoogleAds.V3.Resources.ManagedPlacementView(); + } + ManagedPlacementView.MergeFrom(other.ManagedPlacementView); + } + if (other.mediaFile_ != null) { + if (mediaFile_ == null) { + MediaFile = new global::Google.Ads.GoogleAds.V3.Resources.MediaFile(); + } + MediaFile.MergeFrom(other.MediaFile); + } + if (other.mobileAppCategoryConstant_ != null) { + if (mobileAppCategoryConstant_ == null) { + MobileAppCategoryConstant = new global::Google.Ads.GoogleAds.V3.Resources.MobileAppCategoryConstant(); + } + MobileAppCategoryConstant.MergeFrom(other.MobileAppCategoryConstant); + } + if (other.mobileDeviceConstant_ != null) { + if (mobileDeviceConstant_ == null) { + MobileDeviceConstant = new global::Google.Ads.GoogleAds.V3.Resources.MobileDeviceConstant(); + } + MobileDeviceConstant.MergeFrom(other.MobileDeviceConstant); + } + if (other.mutateJob_ != null) { + if (mutateJob_ == null) { + MutateJob = new global::Google.Ads.GoogleAds.V3.Resources.MutateJob(); + } + MutateJob.MergeFrom(other.MutateJob); + } + if (other.operatingSystemVersionConstant_ != null) { + if (operatingSystemVersionConstant_ == null) { + OperatingSystemVersionConstant = new global::Google.Ads.GoogleAds.V3.Resources.OperatingSystemVersionConstant(); + } + OperatingSystemVersionConstant.MergeFrom(other.OperatingSystemVersionConstant); + } + if (other.paidOrganicSearchTermView_ != null) { + if (paidOrganicSearchTermView_ == null) { + PaidOrganicSearchTermView = new global::Google.Ads.GoogleAds.V3.Resources.PaidOrganicSearchTermView(); + } + PaidOrganicSearchTermView.MergeFrom(other.PaidOrganicSearchTermView); + } + if (other.parentalStatusView_ != null) { + if (parentalStatusView_ == null) { + ParentalStatusView = new global::Google.Ads.GoogleAds.V3.Resources.ParentalStatusView(); + } + ParentalStatusView.MergeFrom(other.ParentalStatusView); + } + if (other.productBiddingCategoryConstant_ != null) { + if (productBiddingCategoryConstant_ == null) { + ProductBiddingCategoryConstant = new global::Google.Ads.GoogleAds.V3.Resources.ProductBiddingCategoryConstant(); + } + ProductBiddingCategoryConstant.MergeFrom(other.ProductBiddingCategoryConstant); + } + if (other.productGroupView_ != null) { + if (productGroupView_ == null) { + ProductGroupView = new global::Google.Ads.GoogleAds.V3.Resources.ProductGroupView(); + } + ProductGroupView.MergeFrom(other.ProductGroupView); + } + if (other.recommendation_ != null) { + if (recommendation_ == null) { + Recommendation = new global::Google.Ads.GoogleAds.V3.Resources.Recommendation(); + } + Recommendation.MergeFrom(other.Recommendation); + } + if (other.searchTermView_ != null) { + if (searchTermView_ == null) { + SearchTermView = new global::Google.Ads.GoogleAds.V3.Resources.SearchTermView(); + } + SearchTermView.MergeFrom(other.SearchTermView); + } + if (other.sharedCriterion_ != null) { + if (sharedCriterion_ == null) { + SharedCriterion = new global::Google.Ads.GoogleAds.V3.Resources.SharedCriterion(); + } + SharedCriterion.MergeFrom(other.SharedCriterion); + } + if (other.sharedSet_ != null) { + if (sharedSet_ == null) { + SharedSet = new global::Google.Ads.GoogleAds.V3.Resources.SharedSet(); + } + SharedSet.MergeFrom(other.SharedSet); + } + if (other.shoppingPerformanceView_ != null) { + if (shoppingPerformanceView_ == null) { + ShoppingPerformanceView = new global::Google.Ads.GoogleAds.V3.Resources.ShoppingPerformanceView(); + } + ShoppingPerformanceView.MergeFrom(other.ShoppingPerformanceView); + } + if (other.topicView_ != null) { + if (topicView_ == null) { + TopicView = new global::Google.Ads.GoogleAds.V3.Resources.TopicView(); + } + TopicView.MergeFrom(other.TopicView); + } + if (other.userInterest_ != null) { + if (userInterest_ == null) { + UserInterest = new global::Google.Ads.GoogleAds.V3.Resources.UserInterest(); + } + UserInterest.MergeFrom(other.UserInterest); + } + if (other.userList_ != null) { + if (userList_ == null) { + UserList = new global::Google.Ads.GoogleAds.V3.Resources.UserList(); + } + UserList.MergeFrom(other.UserList); + } + if (other.userLocationView_ != null) { + if (userLocationView_ == null) { + UserLocationView = new global::Google.Ads.GoogleAds.V3.Resources.UserLocationView(); + } + UserLocationView.MergeFrom(other.UserLocationView); + } + if (other.remarketingAction_ != null) { + if (remarketingAction_ == null) { + RemarketingAction = new global::Google.Ads.GoogleAds.V3.Resources.RemarketingAction(); + } + RemarketingAction.MergeFrom(other.RemarketingAction); + } + if (other.topicConstant_ != null) { + if (topicConstant_ == null) { + TopicConstant = new global::Google.Ads.GoogleAds.V3.Resources.TopicConstant(); + } + TopicConstant.MergeFrom(other.TopicConstant); + } + if (other.video_ != null) { + if (video_ == null) { + Video = new global::Google.Ads.GoogleAds.V3.Resources.Video(); + } + Video.MergeFrom(other.Video); + } + if (other.metrics_ != null) { + if (metrics_ == null) { + Metrics = new global::Google.Ads.GoogleAds.V3.Common.Metrics(); + } + Metrics.MergeFrom(other.Metrics); + } + if (other.segments_ != null) { + if (segments_ == null) { + Segments = new global::Google.Ads.GoogleAds.V3.Common.Segments(); + } + Segments.MergeFrom(other.Segments); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + if (customer_ == null) { + Customer = new global::Google.Ads.GoogleAds.V3.Resources.Customer(); + } + input.ReadMessage(Customer); + break; + } + case 18: { + if (campaign_ == null) { + Campaign = new global::Google.Ads.GoogleAds.V3.Resources.Campaign(); + } + input.ReadMessage(Campaign); + break; + } + case 26: { + if (adGroup_ == null) { + AdGroup = new global::Google.Ads.GoogleAds.V3.Resources.AdGroup(); + } + input.ReadMessage(AdGroup); + break; + } + case 34: { + if (metrics_ == null) { + Metrics = new global::Google.Ads.GoogleAds.V3.Common.Metrics(); + } + input.ReadMessage(Metrics); + break; + } + case 130: { + if (adGroupAd_ == null) { + AdGroupAd = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAd(); + } + input.ReadMessage(AdGroupAd); + break; + } + case 138: { + if (adGroupCriterion_ == null) { + AdGroupCriterion = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterion(); + } + input.ReadMessage(AdGroupCriterion); + break; + } + case 146: { + if (biddingStrategy_ == null) { + BiddingStrategy = new global::Google.Ads.GoogleAds.V3.Resources.BiddingStrategy(); + } + input.ReadMessage(BiddingStrategy); + break; + } + case 154: { + if (campaignBudget_ == null) { + CampaignBudget = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBudget(); + } + input.ReadMessage(CampaignBudget); + break; + } + case 162: { + if (campaignCriterion_ == null) { + CampaignCriterion = new global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterion(); + } + input.ReadMessage(CampaignCriterion); + break; + } + case 170: { + if (keywordView_ == null) { + KeywordView = new global::Google.Ads.GoogleAds.V3.Resources.KeywordView(); + } + input.ReadMessage(KeywordView); + break; + } + case 178: { + if (recommendation_ == null) { + Recommendation = new global::Google.Ads.GoogleAds.V3.Resources.Recommendation(); + } + input.ReadMessage(Recommendation); + break; + } + case 186: { + if (geoTargetConstant_ == null) { + GeoTargetConstant = new global::Google.Ads.GoogleAds.V3.Resources.GeoTargetConstant(); + } + input.ReadMessage(GeoTargetConstant); + break; + } + case 194: { + if (adGroupBidModifier_ == null) { + AdGroupBidModifier = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupBidModifier(); + } + input.ReadMessage(AdGroupBidModifier); + break; + } + case 210: { + if (campaignBidModifier_ == null) { + CampaignBidModifier = new global::Google.Ads.GoogleAds.V3.Resources.CampaignBidModifier(); + } + input.ReadMessage(CampaignBidModifier); + break; + } + case 218: { + if (sharedSet_ == null) { + SharedSet = new global::Google.Ads.GoogleAds.V3.Resources.SharedSet(); + } + input.ReadMessage(SharedSet); + break; + } + case 234: { + if (sharedCriterion_ == null) { + SharedCriterion = new global::Google.Ads.GoogleAds.V3.Resources.SharedCriterion(); + } + input.ReadMessage(SharedCriterion); + break; + } + case 242: { + if (campaignSharedSet_ == null) { + CampaignSharedSet = new global::Google.Ads.GoogleAds.V3.Resources.CampaignSharedSet(); + } + input.ReadMessage(CampaignSharedSet); + break; + } + case 250: { + if (topicConstant_ == null) { + TopicConstant = new global::Google.Ads.GoogleAds.V3.Resources.TopicConstant(); + } + input.ReadMessage(TopicConstant); + break; + } + case 258: { + if (keywordPlan_ == null) { + KeywordPlan = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan(); + } + input.ReadMessage(KeywordPlan); + break; + } + case 266: { + if (keywordPlanCampaign_ == null) { + KeywordPlanCampaign = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign(); + } + input.ReadMessage(KeywordPlanCampaign); + break; + } + case 274: { + if (keywordPlanNegativeKeyword_ == null) { + KeywordPlanNegativeKeyword = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword(); + } + input.ReadMessage(KeywordPlanNegativeKeyword); + break; + } + case 282: { + if (keywordPlanAdGroup_ == null) { + KeywordPlanAdGroup = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup(); + } + input.ReadMessage(KeywordPlanAdGroup); + break; + } + case 290: { + if (keywordPlanKeyword_ == null) { + KeywordPlanKeyword = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword(); + } + input.ReadMessage(KeywordPlanKeyword); + break; + } + case 298: { + if (changeStatus_ == null) { + ChangeStatus = new global::Google.Ads.GoogleAds.V3.Resources.ChangeStatus(); + } + input.ReadMessage(ChangeStatus); + break; + } + case 306: { + if (userList_ == null) { + UserList = new global::Google.Ads.GoogleAds.V3.Resources.UserList(); + } + input.ReadMessage(UserList); + break; + } + case 314: { + if (video_ == null) { + Video = new global::Google.Ads.GoogleAds.V3.Resources.Video(); + } + input.ReadMessage(Video); + break; + } + case 322: { + if (genderView_ == null) { + GenderView = new global::Google.Ads.GoogleAds.V3.Resources.GenderView(); + } + input.ReadMessage(GenderView); + break; + } + case 330: { + if (billingSetup_ == null) { + BillingSetup = new global::Google.Ads.GoogleAds.V3.Resources.BillingSetup(); + } + input.ReadMessage(BillingSetup); + break; + } + case 338: { + if (accountBudget_ == null) { + AccountBudget = new global::Google.Ads.GoogleAds.V3.Resources.AccountBudget(); + } + input.ReadMessage(AccountBudget); + break; + } + case 346: { + if (accountBudgetProposal_ == null) { + AccountBudgetProposal = new global::Google.Ads.GoogleAds.V3.Resources.AccountBudgetProposal(); + } + input.ReadMessage(AccountBudgetProposal); + break; + } + case 354: { + if (topicView_ == null) { + TopicView = new global::Google.Ads.GoogleAds.V3.Resources.TopicView(); + } + input.ReadMessage(TopicView); + break; + } + case 362: { + if (parentalStatusView_ == null) { + ParentalStatusView = new global::Google.Ads.GoogleAds.V3.Resources.ParentalStatusView(); + } + input.ReadMessage(ParentalStatusView); + break; + } + case 370: { + if (feed_ == null) { + Feed = new global::Google.Ads.GoogleAds.V3.Resources.Feed(); + } + input.ReadMessage(Feed); + break; + } + case 378: { + if (displayKeywordView_ == null) { + DisplayKeywordView = new global::Google.Ads.GoogleAds.V3.Resources.DisplayKeywordView(); + } + input.ReadMessage(DisplayKeywordView); + break; + } + case 386: { + if (ageRangeView_ == null) { + AgeRangeView = new global::Google.Ads.GoogleAds.V3.Resources.AgeRangeView(); + } + input.ReadMessage(AgeRangeView); + break; + } + case 394: { + if (campaignDraft_ == null) { + CampaignDraft = new global::Google.Ads.GoogleAds.V3.Resources.CampaignDraft(); + } + input.ReadMessage(CampaignDraft); + break; + } + case 402: { + if (feedItem_ == null) { + FeedItem = new global::Google.Ads.GoogleAds.V3.Resources.FeedItem(); + } + input.ReadMessage(FeedItem); + break; + } + case 410: { + if (hotelGroupView_ == null) { + HotelGroupView = new global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView(); + } + input.ReadMessage(HotelGroupView); + break; + } + case 418: { + if (label_ == null) { + Label = new global::Google.Ads.GoogleAds.V3.Resources.Label(); + } + input.ReadMessage(Label); + break; + } + case 426: { + if (managedPlacementView_ == null) { + ManagedPlacementView = new global::Google.Ads.GoogleAds.V3.Resources.ManagedPlacementView(); + } + input.ReadMessage(ManagedPlacementView); + break; + } + case 434: { + if (productGroupView_ == null) { + ProductGroupView = new global::Google.Ads.GoogleAds.V3.Resources.ProductGroupView(); + } + input.ReadMessage(ProductGroupView); + break; + } + case 442: { + if (languageConstant_ == null) { + LanguageConstant = new global::Google.Ads.GoogleAds.V3.Resources.LanguageConstant(); + } + input.ReadMessage(LanguageConstant); + break; + } + case 458: { + if (adGroupAudienceView_ == null) { + AdGroupAudienceView = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAudienceView(); + } + input.ReadMessage(AdGroupAudienceView); + break; + } + case 466: { + if (feedMapping_ == null) { + FeedMapping = new global::Google.Ads.GoogleAds.V3.Resources.FeedMapping(); + } + input.ReadMessage(FeedMapping); + break; + } + case 474: { + if (userInterest_ == null) { + UserInterest = new global::Google.Ads.GoogleAds.V3.Resources.UserInterest(); + } + input.ReadMessage(UserInterest); + break; + } + case 482: { + if (remarketingAction_ == null) { + RemarketingAction = new global::Google.Ads.GoogleAds.V3.Resources.RemarketingAction(); + } + input.ReadMessage(RemarketingAction); + break; + } + case 490: { + if (customerManagerLink_ == null) { + CustomerManagerLink = new global::Google.Ads.GoogleAds.V3.Resources.CustomerManagerLink(); + } + input.ReadMessage(CustomerManagerLink); + break; + } + case 498: { + if (customerClientLink_ == null) { + CustomerClientLink = new global::Google.Ads.GoogleAds.V3.Resources.CustomerClientLink(); + } + input.ReadMessage(CustomerClientLink); + break; + } + case 506: { + if (campaignFeed_ == null) { + CampaignFeed = new global::Google.Ads.GoogleAds.V3.Resources.CampaignFeed(); + } + input.ReadMessage(CampaignFeed); + break; + } + case 514: { + if (customerFeed_ == null) { + CustomerFeed = new global::Google.Ads.GoogleAds.V3.Resources.CustomerFeed(); + } + input.ReadMessage(CustomerFeed); + break; + } + case 530: { + if (carrierConstant_ == null) { + CarrierConstant = new global::Google.Ads.GoogleAds.V3.Resources.CarrierConstant(); + } + input.ReadMessage(CarrierConstant); + break; + } + case 538: { + if (adGroupFeed_ == null) { + AdGroupFeed = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupFeed(); + } + input.ReadMessage(AdGroupFeed); + break; + } + case 546: { + if (searchTermView_ == null) { + SearchTermView = new global::Google.Ads.GoogleAds.V3.Resources.SearchTermView(); + } + input.ReadMessage(SearchTermView); + break; + } + case 554: { + if (campaignAudienceView_ == null) { + CampaignAudienceView = new global::Google.Ads.GoogleAds.V3.Resources.CampaignAudienceView(); + } + input.ReadMessage(CampaignAudienceView); + break; + } + case 562: { + if (customerClient_ == null) { + CustomerClient = new global::Google.Ads.GoogleAds.V3.Resources.CustomerClient(); + } + input.ReadMessage(CustomerClient); + break; + } + case 570: { + if (hotelPerformanceView_ == null) { + HotelPerformanceView = new global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView(); + } + input.ReadMessage(HotelPerformanceView); + break; + } + case 674: { + if (campaignExperiment_ == null) { + CampaignExperiment = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExperiment(); + } + input.ReadMessage(CampaignExperiment); + break; + } + case 682: { + if (extensionFeedItem_ == null) { + ExtensionFeedItem = new global::Google.Ads.GoogleAds.V3.Resources.ExtensionFeedItem(); + } + input.ReadMessage(ExtensionFeedItem); + break; + } + case 690: { + if (operatingSystemVersionConstant_ == null) { + OperatingSystemVersionConstant = new global::Google.Ads.GoogleAds.V3.Resources.OperatingSystemVersionConstant(); + } + input.ReadMessage(OperatingSystemVersionConstant); + break; + } + case 698: { + if (mobileAppCategoryConstant_ == null) { + MobileAppCategoryConstant = new global::Google.Ads.GoogleAds.V3.Resources.MobileAppCategoryConstant(); + } + input.ReadMessage(MobileAppCategoryConstant); + break; + } + case 706: { + if (customerNegativeCriterion_ == null) { + CustomerNegativeCriterion = new global::Google.Ads.GoogleAds.V3.Resources.CustomerNegativeCriterion(); + } + input.ReadMessage(CustomerNegativeCriterion); + break; + } + case 714: { + if (adScheduleView_ == null) { + AdScheduleView = new global::Google.Ads.GoogleAds.V3.Resources.AdScheduleView(); + } + input.ReadMessage(AdScheduleView); + break; + } + case 722: { + if (mediaFile_ == null) { + MediaFile = new global::Google.Ads.GoogleAds.V3.Resources.MediaFile(); + } + input.ReadMessage(MediaFile); + break; + } + case 730: { + if (domainCategory_ == null) { + DomainCategory = new global::Google.Ads.GoogleAds.V3.Resources.DomainCategory(); + } + input.ReadMessage(DomainCategory); + break; + } + case 778: { + if (feedPlaceholderView_ == null) { + FeedPlaceholderView = new global::Google.Ads.GoogleAds.V3.Resources.FeedPlaceholderView(); + } + input.ReadMessage(FeedPlaceholderView); + break; + } + case 786: { + if (mobileDeviceConstant_ == null) { + MobileDeviceConstant = new global::Google.Ads.GoogleAds.V3.Resources.MobileDeviceConstant(); + } + input.ReadMessage(MobileDeviceConstant); + break; + } + case 818: { + if (segments_ == null) { + Segments = new global::Google.Ads.GoogleAds.V3.Common.Segments(); + } + input.ReadMessage(Segments); + break; + } + case 826: { + if (conversionAction_ == null) { + ConversionAction = new global::Google.Ads.GoogleAds.V3.Resources.ConversionAction(); + } + input.ReadMessage(ConversionAction); + break; + } + case 834: { + if (customInterest_ == null) { + CustomInterest = new global::Google.Ads.GoogleAds.V3.Resources.CustomInterest(); + } + input.ReadMessage(CustomInterest); + break; + } + case 842: { + if (asset_ == null) { + Asset = new global::Google.Ads.GoogleAds.V3.Resources.Asset(); + } + input.ReadMessage(Asset); + break; + } + case 850: { + if (dynamicSearchAdsSearchTermView_ == null) { + DynamicSearchAdsSearchTermView = new global::Google.Ads.GoogleAds.V3.Resources.DynamicSearchAdsSearchTermView(); + } + input.ReadMessage(DynamicSearchAdsSearchTermView); + break; + } + case 858: { + if (adGroupSimulation_ == null) { + AdGroupSimulation = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupSimulation(); + } + input.ReadMessage(AdGroupSimulation); + break; + } + case 866: { + if (campaignLabel_ == null) { + CampaignLabel = new global::Google.Ads.GoogleAds.V3.Resources.CampaignLabel(); + } + input.ReadMessage(CampaignLabel); + break; + } + case 874: { + if (productBiddingCategoryConstant_ == null) { + ProductBiddingCategoryConstant = new global::Google.Ads.GoogleAds.V3.Resources.ProductBiddingCategoryConstant(); + } + input.ReadMessage(ProductBiddingCategoryConstant); + break; + } + case 882: { + if (adGroupCriterionSimulation_ == null) { + AdGroupCriterionSimulation = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionSimulation(); + } + input.ReadMessage(AdGroupCriterionSimulation); + break; + } + case 890: { + if (campaignCriterionSimulation_ == null) { + CampaignCriterionSimulation = new global::Google.Ads.GoogleAds.V3.Resources.CampaignCriterionSimulation(); + } + input.ReadMessage(CampaignCriterionSimulation); + break; + } + case 898: { + if (adGroupExtensionSetting_ == null) { + AdGroupExtensionSetting = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupExtensionSetting(); + } + input.ReadMessage(AdGroupExtensionSetting); + break; + } + case 906: { + if (campaignExtensionSetting_ == null) { + CampaignExtensionSetting = new global::Google.Ads.GoogleAds.V3.Resources.CampaignExtensionSetting(); + } + input.ReadMessage(CampaignExtensionSetting); + break; + } + case 914: { + if (customerExtensionSetting_ == null) { + CustomerExtensionSetting = new global::Google.Ads.GoogleAds.V3.Resources.CustomerExtensionSetting(); + } + input.ReadMessage(CustomerExtensionSetting); + break; + } + case 922: { + if (adGroupLabel_ == null) { + AdGroupLabel = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupLabel(); + } + input.ReadMessage(AdGroupLabel); + break; + } + case 930: { + if (feedItemTarget_ == null) { + FeedItemTarget = new global::Google.Ads.GoogleAds.V3.Resources.FeedItemTarget(); + } + input.ReadMessage(FeedItemTarget); + break; + } + case 938: { + if (shoppingPerformanceView_ == null) { + ShoppingPerformanceView = new global::Google.Ads.GoogleAds.V3.Resources.ShoppingPerformanceView(); + } + input.ReadMessage(ShoppingPerformanceView); + break; + } + case 946: { + if (detailPlacementView_ == null) { + DetailPlacementView = new global::Google.Ads.GoogleAds.V3.Resources.DetailPlacementView(); + } + input.ReadMessage(DetailPlacementView); + break; + } + case 954: { + if (groupPlacementView_ == null) { + GroupPlacementView = new global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView(); + } + input.ReadMessage(GroupPlacementView); + break; + } + case 962: { + if (adGroupAdLabel_ == null) { + AdGroupAdLabel = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdLabel(); + } + input.ReadMessage(AdGroupAdLabel); + break; + } + case 970: { + if (adGroupCriterionLabel_ == null) { + AdGroupCriterionLabel = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupCriterionLabel(); + } + input.ReadMessage(AdGroupCriterionLabel); + break; + } + case 978: { + if (clickView_ == null) { + ClickView = new global::Google.Ads.GoogleAds.V3.Resources.ClickView(); + } + input.ReadMessage(ClickView); + break; + } + case 986: { + if (locationView_ == null) { + LocationView = new global::Google.Ads.GoogleAds.V3.Resources.LocationView(); + } + input.ReadMessage(LocationView); + break; + } + case 994: { + if (customerLabel_ == null) { + CustomerLabel = new global::Google.Ads.GoogleAds.V3.Resources.CustomerLabel(); + } + input.ReadMessage(CustomerLabel); + break; + } + case 1002: { + if (geographicView_ == null) { + GeographicView = new global::Google.Ads.GoogleAds.V3.Resources.GeographicView(); + } + input.ReadMessage(GeographicView); + break; + } + case 1010: { + if (landingPageView_ == null) { + LandingPageView = new global::Google.Ads.GoogleAds.V3.Resources.LandingPageView(); + } + input.ReadMessage(LandingPageView); + break; + } + case 1018: { + if (mutateJob_ == null) { + MutateJob = new global::Google.Ads.GoogleAds.V3.Resources.MutateJob(); + } + input.ReadMessage(MutateJob); + break; + } + case 1026: { + if (expandedLandingPageView_ == null) { + ExpandedLandingPageView = new global::Google.Ads.GoogleAds.V3.Resources.ExpandedLandingPageView(); + } + input.ReadMessage(ExpandedLandingPageView); + break; + } + case 1034: { + if (paidOrganicSearchTermView_ == null) { + PaidOrganicSearchTermView = new global::Google.Ads.GoogleAds.V3.Resources.PaidOrganicSearchTermView(); + } + input.ReadMessage(PaidOrganicSearchTermView); + break; + } + case 1042: { + if (adParameter_ == null) { + AdParameter = new global::Google.Ads.GoogleAds.V3.Resources.AdParameter(); + } + input.ReadMessage(AdParameter); + break; + } + case 1050: { + if (adGroupAdAssetView_ == null) { + AdGroupAdAssetView = new global::Google.Ads.GoogleAds.V3.Resources.AdGroupAdAssetView(); + } + input.ReadMessage(AdGroupAdAssetView); + break; + } + case 1058: { + if (distanceView_ == null) { + DistanceView = new global::Google.Ads.GoogleAds.V3.Resources.DistanceView(); + } + input.ReadMessage(DistanceView); + break; + } + case 1074: { + if (currencyConstant_ == null) { + CurrencyConstant = new global::Google.Ads.GoogleAds.V3.Resources.CurrencyConstant(); + } + input.ReadMessage(CurrencyConstant); + break; + } + case 1082: { + if (userLocationView_ == null) { + UserLocationView = new global::Google.Ads.GoogleAds.V3.Resources.UserLocationView(); + } + input.ReadMessage(UserLocationView); + break; + } + } + } + } + + } + + /// + /// Request message for [GoogleAdsService.Mutate][google.ads.googleads.v3.services.GoogleAdsService.Mutate]. + /// + public sealed partial class MutateGoogleAdsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateGoogleAdsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateGoogleAdsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateGoogleAdsRequest(MutateGoogleAdsRequest other) : this() { + customerId_ = other.customerId_; + mutateOperations_ = other.mutateOperations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateGoogleAdsRequest Clone() { + return new MutateGoogleAdsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose resources are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "mutate_operations" field. + public const int MutateOperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_mutateOperations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateOperation.Parser); + private readonly pbc::RepeatedField mutateOperations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual resources. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField MutateOperations { + get { return mutateOperations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateGoogleAdsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateGoogleAdsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!mutateOperations_.Equals(other.mutateOperations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= mutateOperations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + mutateOperations_.WriteTo(output, _repeated_mutateOperations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += mutateOperations_.CalculateSize(_repeated_mutateOperations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateGoogleAdsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + mutateOperations_.Add(other.mutateOperations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + mutateOperations_.AddEntriesFrom(input, _repeated_mutateOperations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// Response message for [GoogleAdsService.Mutate][google.ads.googleads.v3.services.GoogleAdsService.Mutate]. + /// + public sealed partial class MutateGoogleAdsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateGoogleAdsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateGoogleAdsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateGoogleAdsResponse(MutateGoogleAdsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + mutateOperationResponses_ = other.mutateOperationResponses_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateGoogleAdsResponse Clone() { + return new MutateGoogleAdsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g., auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "mutate_operation_responses" field. + public const int MutateOperationResponsesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_mutateOperationResponses_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Services.MutateOperationResponse.Parser); + private readonly pbc::RepeatedField mutateOperationResponses_ = new pbc::RepeatedField(); + /// + /// All responses for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField MutateOperationResponses { + get { return mutateOperationResponses_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateGoogleAdsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateGoogleAdsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!mutateOperationResponses_.Equals(other.mutateOperationResponses_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= mutateOperationResponses_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + mutateOperationResponses_.WriteTo(output, _repeated_mutateOperationResponses_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += mutateOperationResponses_.CalculateSize(_repeated_mutateOperationResponses_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateGoogleAdsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + mutateOperationResponses_.Add(other.mutateOperationResponses_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + mutateOperationResponses_.AddEntriesFrom(input, _repeated_mutateOperationResponses_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a resource. + /// + public sealed partial class MutateOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateOperation(MutateOperation other) : this() { + switch (other.OperationCase) { + case OperationOneofCase.AdGroupAdLabelOperation: + AdGroupAdLabelOperation = other.AdGroupAdLabelOperation.Clone(); + break; + case OperationOneofCase.AdGroupAdOperation: + AdGroupAdOperation = other.AdGroupAdOperation.Clone(); + break; + case OperationOneofCase.AdGroupBidModifierOperation: + AdGroupBidModifierOperation = other.AdGroupBidModifierOperation.Clone(); + break; + case OperationOneofCase.AdGroupCriterionLabelOperation: + AdGroupCriterionLabelOperation = other.AdGroupCriterionLabelOperation.Clone(); + break; + case OperationOneofCase.AdGroupCriterionOperation: + AdGroupCriterionOperation = other.AdGroupCriterionOperation.Clone(); + break; + case OperationOneofCase.AdGroupExtensionSettingOperation: + AdGroupExtensionSettingOperation = other.AdGroupExtensionSettingOperation.Clone(); + break; + case OperationOneofCase.AdGroupFeedOperation: + AdGroupFeedOperation = other.AdGroupFeedOperation.Clone(); + break; + case OperationOneofCase.AdGroupLabelOperation: + AdGroupLabelOperation = other.AdGroupLabelOperation.Clone(); + break; + case OperationOneofCase.AdGroupOperation: + AdGroupOperation = other.AdGroupOperation.Clone(); + break; + case OperationOneofCase.AdParameterOperation: + AdParameterOperation = other.AdParameterOperation.Clone(); + break; + case OperationOneofCase.AssetOperation: + AssetOperation = other.AssetOperation.Clone(); + break; + case OperationOneofCase.BiddingStrategyOperation: + BiddingStrategyOperation = other.BiddingStrategyOperation.Clone(); + break; + case OperationOneofCase.CampaignBidModifierOperation: + CampaignBidModifierOperation = other.CampaignBidModifierOperation.Clone(); + break; + case OperationOneofCase.CampaignBudgetOperation: + CampaignBudgetOperation = other.CampaignBudgetOperation.Clone(); + break; + case OperationOneofCase.CampaignCriterionOperation: + CampaignCriterionOperation = other.CampaignCriterionOperation.Clone(); + break; + case OperationOneofCase.CampaignDraftOperation: + CampaignDraftOperation = other.CampaignDraftOperation.Clone(); + break; + case OperationOneofCase.CampaignExperimentOperation: + CampaignExperimentOperation = other.CampaignExperimentOperation.Clone(); + break; + case OperationOneofCase.CampaignExtensionSettingOperation: + CampaignExtensionSettingOperation = other.CampaignExtensionSettingOperation.Clone(); + break; + case OperationOneofCase.CampaignFeedOperation: + CampaignFeedOperation = other.CampaignFeedOperation.Clone(); + break; + case OperationOneofCase.CampaignLabelOperation: + CampaignLabelOperation = other.CampaignLabelOperation.Clone(); + break; + case OperationOneofCase.CampaignOperation: + CampaignOperation = other.CampaignOperation.Clone(); + break; + case OperationOneofCase.CampaignSharedSetOperation: + CampaignSharedSetOperation = other.CampaignSharedSetOperation.Clone(); + break; + case OperationOneofCase.ConversionActionOperation: + ConversionActionOperation = other.ConversionActionOperation.Clone(); + break; + case OperationOneofCase.CustomerExtensionSettingOperation: + CustomerExtensionSettingOperation = other.CustomerExtensionSettingOperation.Clone(); + break; + case OperationOneofCase.CustomerFeedOperation: + CustomerFeedOperation = other.CustomerFeedOperation.Clone(); + break; + case OperationOneofCase.CustomerLabelOperation: + CustomerLabelOperation = other.CustomerLabelOperation.Clone(); + break; + case OperationOneofCase.CustomerNegativeCriterionOperation: + CustomerNegativeCriterionOperation = other.CustomerNegativeCriterionOperation.Clone(); + break; + case OperationOneofCase.CustomerOperation: + CustomerOperation = other.CustomerOperation.Clone(); + break; + case OperationOneofCase.ExtensionFeedItemOperation: + ExtensionFeedItemOperation = other.ExtensionFeedItemOperation.Clone(); + break; + case OperationOneofCase.FeedItemOperation: + FeedItemOperation = other.FeedItemOperation.Clone(); + break; + case OperationOneofCase.FeedItemTargetOperation: + FeedItemTargetOperation = other.FeedItemTargetOperation.Clone(); + break; + case OperationOneofCase.FeedMappingOperation: + FeedMappingOperation = other.FeedMappingOperation.Clone(); + break; + case OperationOneofCase.FeedOperation: + FeedOperation = other.FeedOperation.Clone(); + break; + case OperationOneofCase.LabelOperation: + LabelOperation = other.LabelOperation.Clone(); + break; + case OperationOneofCase.MediaFileOperation: + MediaFileOperation = other.MediaFileOperation.Clone(); + break; + case OperationOneofCase.RemarketingActionOperation: + RemarketingActionOperation = other.RemarketingActionOperation.Clone(); + break; + case OperationOneofCase.SharedCriterionOperation: + SharedCriterionOperation = other.SharedCriterionOperation.Clone(); + break; + case OperationOneofCase.SharedSetOperation: + SharedSetOperation = other.SharedSetOperation.Clone(); + break; + case OperationOneofCase.UserListOperation: + UserListOperation = other.UserListOperation.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateOperation Clone() { + return new MutateOperation(this); + } + + /// Field number for the "ad_group_ad_label_operation" field. + public const int AdGroupAdLabelOperationFieldNumber = 17; + /// + /// An ad group ad label mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelOperation AdGroupAdLabelOperation { + get { return operationCase_ == OperationOneofCase.AdGroupAdLabelOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupAdLabelOperation; + } + } + + /// Field number for the "ad_group_ad_operation" field. + public const int AdGroupAdOperationFieldNumber = 1; + /// + /// An ad group ad mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupAdOperation AdGroupAdOperation { + get { return operationCase_ == OperationOneofCase.AdGroupAdOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupAdOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupAdOperation; + } + } + + /// Field number for the "ad_group_bid_modifier_operation" field. + public const int AdGroupBidModifierOperationFieldNumber = 2; + /// + /// An ad group bid modifier mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierOperation AdGroupBidModifierOperation { + get { return operationCase_ == OperationOneofCase.AdGroupBidModifierOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupBidModifierOperation; + } + } + + /// Field number for the "ad_group_criterion_label_operation" field. + public const int AdGroupCriterionLabelOperationFieldNumber = 18; + /// + /// An ad group criterion label mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelOperation AdGroupCriterionLabelOperation { + get { return operationCase_ == OperationOneofCase.AdGroupCriterionLabelOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupCriterionLabelOperation; + } + } + + /// Field number for the "ad_group_criterion_operation" field. + public const int AdGroupCriterionOperationFieldNumber = 3; + /// + /// An ad group criterion mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionOperation AdGroupCriterionOperation { + get { return operationCase_ == OperationOneofCase.AdGroupCriterionOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupCriterionOperation; + } + } + + /// Field number for the "ad_group_extension_setting_operation" field. + public const int AdGroupExtensionSettingOperationFieldNumber = 19; + /// + /// An ad group extension setting mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingOperation AdGroupExtensionSettingOperation { + get { return operationCase_ == OperationOneofCase.AdGroupExtensionSettingOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupExtensionSettingOperation; + } + } + + /// Field number for the "ad_group_feed_operation" field. + public const int AdGroupFeedOperationFieldNumber = 20; + /// + /// An ad group feed mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedOperation AdGroupFeedOperation { + get { return operationCase_ == OperationOneofCase.AdGroupFeedOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupFeedOperation; + } + } + + /// Field number for the "ad_group_label_operation" field. + public const int AdGroupLabelOperationFieldNumber = 21; + /// + /// An ad group label mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelOperation AdGroupLabelOperation { + get { return operationCase_ == OperationOneofCase.AdGroupLabelOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupLabelOperation; + } + } + + /// Field number for the "ad_group_operation" field. + public const int AdGroupOperationFieldNumber = 5; + /// + /// An ad group mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdGroupOperation AdGroupOperation { + get { return operationCase_ == OperationOneofCase.AdGroupOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdGroupOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdGroupOperation; + } + } + + /// Field number for the "ad_parameter_operation" field. + public const int AdParameterOperationFieldNumber = 22; + /// + /// An ad parameter mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AdParameterOperation AdParameterOperation { + get { return operationCase_ == OperationOneofCase.AdParameterOperation ? (global::Google.Ads.GoogleAds.V3.Services.AdParameterOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AdParameterOperation; + } + } + + /// Field number for the "asset_operation" field. + public const int AssetOperationFieldNumber = 23; + /// + /// An asset mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.AssetOperation AssetOperation { + get { return operationCase_ == OperationOneofCase.AssetOperation ? (global::Google.Ads.GoogleAds.V3.Services.AssetOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.AssetOperation; + } + } + + /// Field number for the "bidding_strategy_operation" field. + public const int BiddingStrategyOperationFieldNumber = 6; + /// + /// A bidding strategy mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyOperation BiddingStrategyOperation { + get { return operationCase_ == OperationOneofCase.BiddingStrategyOperation ? (global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.BiddingStrategyOperation; + } + } + + /// Field number for the "campaign_bid_modifier_operation" field. + public const int CampaignBidModifierOperationFieldNumber = 7; + /// + /// A campaign bid modifier mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierOperation CampaignBidModifierOperation { + get { return operationCase_ == OperationOneofCase.CampaignBidModifierOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignBidModifierOperation; + } + } + + /// Field number for the "campaign_budget_operation" field. + public const int CampaignBudgetOperationFieldNumber = 8; + /// + /// A campaign budget mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetOperation CampaignBudgetOperation { + get { return operationCase_ == OperationOneofCase.CampaignBudgetOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignBudgetOperation; + } + } + + /// Field number for the "campaign_criterion_operation" field. + public const int CampaignCriterionOperationFieldNumber = 13; + /// + /// A campaign criterion mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionOperation CampaignCriterionOperation { + get { return operationCase_ == OperationOneofCase.CampaignCriterionOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignCriterionOperation; + } + } + + /// Field number for the "campaign_draft_operation" field. + public const int CampaignDraftOperationFieldNumber = 24; + /// + /// A campaign draft mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignDraftOperation CampaignDraftOperation { + get { return operationCase_ == OperationOneofCase.CampaignDraftOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignDraftOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignDraftOperation; + } + } + + /// Field number for the "campaign_experiment_operation" field. + public const int CampaignExperimentOperationFieldNumber = 25; + /// + /// A campaign experiment mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentOperation CampaignExperimentOperation { + get { return operationCase_ == OperationOneofCase.CampaignExperimentOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignExperimentOperation; + } + } + + /// Field number for the "campaign_extension_setting_operation" field. + public const int CampaignExtensionSettingOperationFieldNumber = 26; + /// + /// A campaign extension setting mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingOperation CampaignExtensionSettingOperation { + get { return operationCase_ == OperationOneofCase.CampaignExtensionSettingOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignExtensionSettingOperation; + } + } + + /// Field number for the "campaign_feed_operation" field. + public const int CampaignFeedOperationFieldNumber = 27; + /// + /// A campaign feed mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignFeedOperation CampaignFeedOperation { + get { return operationCase_ == OperationOneofCase.CampaignFeedOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignFeedOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignFeedOperation; + } + } + + /// Field number for the "campaign_label_operation" field. + public const int CampaignLabelOperationFieldNumber = 28; + /// + /// A campaign label mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignLabelOperation CampaignLabelOperation { + get { return operationCase_ == OperationOneofCase.CampaignLabelOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignLabelOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignLabelOperation; + } + } + + /// Field number for the "campaign_operation" field. + public const int CampaignOperationFieldNumber = 10; + /// + /// A campaign mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignOperation CampaignOperation { + get { return operationCase_ == OperationOneofCase.CampaignOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignOperation; + } + } + + /// Field number for the "campaign_shared_set_operation" field. + public const int CampaignSharedSetOperationFieldNumber = 11; + /// + /// A campaign shared set mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetOperation CampaignSharedSetOperation { + get { return operationCase_ == OperationOneofCase.CampaignSharedSetOperation ? (global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CampaignSharedSetOperation; + } + } + + /// Field number for the "conversion_action_operation" field. + public const int ConversionActionOperationFieldNumber = 12; + /// + /// A conversion action mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.ConversionActionOperation ConversionActionOperation { + get { return operationCase_ == OperationOneofCase.ConversionActionOperation ? (global::Google.Ads.GoogleAds.V3.Services.ConversionActionOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.ConversionActionOperation; + } + } + + /// Field number for the "customer_extension_setting_operation" field. + public const int CustomerExtensionSettingOperationFieldNumber = 30; + /// + /// A customer extension setting mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingOperation CustomerExtensionSettingOperation { + get { return operationCase_ == OperationOneofCase.CustomerExtensionSettingOperation ? (global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CustomerExtensionSettingOperation; + } + } + + /// Field number for the "customer_feed_operation" field. + public const int CustomerFeedOperationFieldNumber = 31; + /// + /// A customer feed mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CustomerFeedOperation CustomerFeedOperation { + get { return operationCase_ == OperationOneofCase.CustomerFeedOperation ? (global::Google.Ads.GoogleAds.V3.Services.CustomerFeedOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CustomerFeedOperation; + } + } + + /// Field number for the "customer_label_operation" field. + public const int CustomerLabelOperationFieldNumber = 32; + /// + /// A customer label mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CustomerLabelOperation CustomerLabelOperation { + get { return operationCase_ == OperationOneofCase.CustomerLabelOperation ? (global::Google.Ads.GoogleAds.V3.Services.CustomerLabelOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CustomerLabelOperation; + } + } + + /// Field number for the "customer_negative_criterion_operation" field. + public const int CustomerNegativeCriterionOperationFieldNumber = 34; + /// + /// A customer negative criterion mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionOperation CustomerNegativeCriterionOperation { + get { return operationCase_ == OperationOneofCase.CustomerNegativeCriterionOperation ? (global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CustomerNegativeCriterionOperation; + } + } + + /// Field number for the "customer_operation" field. + public const int CustomerOperationFieldNumber = 35; + /// + /// A customer mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.CustomerOperation CustomerOperation { + get { return operationCase_ == OperationOneofCase.CustomerOperation ? (global::Google.Ads.GoogleAds.V3.Services.CustomerOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.CustomerOperation; + } + } + + /// Field number for the "extension_feed_item_operation" field. + public const int ExtensionFeedItemOperationFieldNumber = 36; + /// + /// An extension feed item mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemOperation ExtensionFeedItemOperation { + get { return operationCase_ == OperationOneofCase.ExtensionFeedItemOperation ? (global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.ExtensionFeedItemOperation; + } + } + + /// Field number for the "feed_item_operation" field. + public const int FeedItemOperationFieldNumber = 37; + /// + /// A feed item mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.FeedItemOperation FeedItemOperation { + get { return operationCase_ == OperationOneofCase.FeedItemOperation ? (global::Google.Ads.GoogleAds.V3.Services.FeedItemOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.FeedItemOperation; + } + } + + /// Field number for the "feed_item_target_operation" field. + public const int FeedItemTargetOperationFieldNumber = 38; + /// + /// A feed item target mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetOperation FeedItemTargetOperation { + get { return operationCase_ == OperationOneofCase.FeedItemTargetOperation ? (global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.FeedItemTargetOperation; + } + } + + /// Field number for the "feed_mapping_operation" field. + public const int FeedMappingOperationFieldNumber = 39; + /// + /// A feed mapping mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.FeedMappingOperation FeedMappingOperation { + get { return operationCase_ == OperationOneofCase.FeedMappingOperation ? (global::Google.Ads.GoogleAds.V3.Services.FeedMappingOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.FeedMappingOperation; + } + } + + /// Field number for the "feed_operation" field. + public const int FeedOperationFieldNumber = 40; + /// + /// A feed mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.FeedOperation FeedOperation { + get { return operationCase_ == OperationOneofCase.FeedOperation ? (global::Google.Ads.GoogleAds.V3.Services.FeedOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.FeedOperation; + } + } + + /// Field number for the "label_operation" field. + public const int LabelOperationFieldNumber = 41; + /// + /// A label mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.LabelOperation LabelOperation { + get { return operationCase_ == OperationOneofCase.LabelOperation ? (global::Google.Ads.GoogleAds.V3.Services.LabelOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.LabelOperation; + } + } + + /// Field number for the "media_file_operation" field. + public const int MediaFileOperationFieldNumber = 42; + /// + /// A media file mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MediaFileOperation MediaFileOperation { + get { return operationCase_ == OperationOneofCase.MediaFileOperation ? (global::Google.Ads.GoogleAds.V3.Services.MediaFileOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.MediaFileOperation; + } + } + + /// Field number for the "remarketing_action_operation" field. + public const int RemarketingActionOperationFieldNumber = 43; + /// + /// A remarketing action mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.RemarketingActionOperation RemarketingActionOperation { + get { return operationCase_ == OperationOneofCase.RemarketingActionOperation ? (global::Google.Ads.GoogleAds.V3.Services.RemarketingActionOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.RemarketingActionOperation; + } + } + + /// Field number for the "shared_criterion_operation" field. + public const int SharedCriterionOperationFieldNumber = 14; + /// + /// A shared criterion mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.SharedCriterionOperation SharedCriterionOperation { + get { return operationCase_ == OperationOneofCase.SharedCriterionOperation ? (global::Google.Ads.GoogleAds.V3.Services.SharedCriterionOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.SharedCriterionOperation; + } + } + + /// Field number for the "shared_set_operation" field. + public const int SharedSetOperationFieldNumber = 15; + /// + /// A shared set mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.SharedSetOperation SharedSetOperation { + get { return operationCase_ == OperationOneofCase.SharedSetOperation ? (global::Google.Ads.GoogleAds.V3.Services.SharedSetOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.SharedSetOperation; + } + } + + /// Field number for the "user_list_operation" field. + public const int UserListOperationFieldNumber = 16; + /// + /// A user list mutate operation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.UserListOperation UserListOperation { + get { return operationCase_ == OperationOneofCase.UserListOperation ? (global::Google.Ads.GoogleAds.V3.Services.UserListOperation) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.UserListOperation; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + AdGroupAdLabelOperation = 17, + AdGroupAdOperation = 1, + AdGroupBidModifierOperation = 2, + AdGroupCriterionLabelOperation = 18, + AdGroupCriterionOperation = 3, + AdGroupExtensionSettingOperation = 19, + AdGroupFeedOperation = 20, + AdGroupLabelOperation = 21, + AdGroupOperation = 5, + AdParameterOperation = 22, + AssetOperation = 23, + BiddingStrategyOperation = 6, + CampaignBidModifierOperation = 7, + CampaignBudgetOperation = 8, + CampaignCriterionOperation = 13, + CampaignDraftOperation = 24, + CampaignExperimentOperation = 25, + CampaignExtensionSettingOperation = 26, + CampaignFeedOperation = 27, + CampaignLabelOperation = 28, + CampaignOperation = 10, + CampaignSharedSetOperation = 11, + ConversionActionOperation = 12, + CustomerExtensionSettingOperation = 30, + CustomerFeedOperation = 31, + CustomerLabelOperation = 32, + CustomerNegativeCriterionOperation = 34, + CustomerOperation = 35, + ExtensionFeedItemOperation = 36, + FeedItemOperation = 37, + FeedItemTargetOperation = 38, + FeedMappingOperation = 39, + FeedOperation = 40, + LabelOperation = 41, + MediaFileOperation = 42, + RemarketingActionOperation = 43, + SharedCriterionOperation = 14, + SharedSetOperation = 15, + UserListOperation = 16, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(AdGroupAdLabelOperation, other.AdGroupAdLabelOperation)) return false; + if (!object.Equals(AdGroupAdOperation, other.AdGroupAdOperation)) return false; + if (!object.Equals(AdGroupBidModifierOperation, other.AdGroupBidModifierOperation)) return false; + if (!object.Equals(AdGroupCriterionLabelOperation, other.AdGroupCriterionLabelOperation)) return false; + if (!object.Equals(AdGroupCriterionOperation, other.AdGroupCriterionOperation)) return false; + if (!object.Equals(AdGroupExtensionSettingOperation, other.AdGroupExtensionSettingOperation)) return false; + if (!object.Equals(AdGroupFeedOperation, other.AdGroupFeedOperation)) return false; + if (!object.Equals(AdGroupLabelOperation, other.AdGroupLabelOperation)) return false; + if (!object.Equals(AdGroupOperation, other.AdGroupOperation)) return false; + if (!object.Equals(AdParameterOperation, other.AdParameterOperation)) return false; + if (!object.Equals(AssetOperation, other.AssetOperation)) return false; + if (!object.Equals(BiddingStrategyOperation, other.BiddingStrategyOperation)) return false; + if (!object.Equals(CampaignBidModifierOperation, other.CampaignBidModifierOperation)) return false; + if (!object.Equals(CampaignBudgetOperation, other.CampaignBudgetOperation)) return false; + if (!object.Equals(CampaignCriterionOperation, other.CampaignCriterionOperation)) return false; + if (!object.Equals(CampaignDraftOperation, other.CampaignDraftOperation)) return false; + if (!object.Equals(CampaignExperimentOperation, other.CampaignExperimentOperation)) return false; + if (!object.Equals(CampaignExtensionSettingOperation, other.CampaignExtensionSettingOperation)) return false; + if (!object.Equals(CampaignFeedOperation, other.CampaignFeedOperation)) return false; + if (!object.Equals(CampaignLabelOperation, other.CampaignLabelOperation)) return false; + if (!object.Equals(CampaignOperation, other.CampaignOperation)) return false; + if (!object.Equals(CampaignSharedSetOperation, other.CampaignSharedSetOperation)) return false; + if (!object.Equals(ConversionActionOperation, other.ConversionActionOperation)) return false; + if (!object.Equals(CustomerExtensionSettingOperation, other.CustomerExtensionSettingOperation)) return false; + if (!object.Equals(CustomerFeedOperation, other.CustomerFeedOperation)) return false; + if (!object.Equals(CustomerLabelOperation, other.CustomerLabelOperation)) return false; + if (!object.Equals(CustomerNegativeCriterionOperation, other.CustomerNegativeCriterionOperation)) return false; + if (!object.Equals(CustomerOperation, other.CustomerOperation)) return false; + if (!object.Equals(ExtensionFeedItemOperation, other.ExtensionFeedItemOperation)) return false; + if (!object.Equals(FeedItemOperation, other.FeedItemOperation)) return false; + if (!object.Equals(FeedItemTargetOperation, other.FeedItemTargetOperation)) return false; + if (!object.Equals(FeedMappingOperation, other.FeedMappingOperation)) return false; + if (!object.Equals(FeedOperation, other.FeedOperation)) return false; + if (!object.Equals(LabelOperation, other.LabelOperation)) return false; + if (!object.Equals(MediaFileOperation, other.MediaFileOperation)) return false; + if (!object.Equals(RemarketingActionOperation, other.RemarketingActionOperation)) return false; + if (!object.Equals(SharedCriterionOperation, other.SharedCriterionOperation)) return false; + if (!object.Equals(SharedSetOperation, other.SharedSetOperation)) return false; + if (!object.Equals(UserListOperation, other.UserListOperation)) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (operationCase_ == OperationOneofCase.AdGroupAdLabelOperation) hash ^= AdGroupAdLabelOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdGroupAdOperation) hash ^= AdGroupAdOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdGroupBidModifierOperation) hash ^= AdGroupBidModifierOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdGroupCriterionLabelOperation) hash ^= AdGroupCriterionLabelOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdGroupCriterionOperation) hash ^= AdGroupCriterionOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdGroupExtensionSettingOperation) hash ^= AdGroupExtensionSettingOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdGroupFeedOperation) hash ^= AdGroupFeedOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdGroupLabelOperation) hash ^= AdGroupLabelOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdGroupOperation) hash ^= AdGroupOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AdParameterOperation) hash ^= AdParameterOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.AssetOperation) hash ^= AssetOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.BiddingStrategyOperation) hash ^= BiddingStrategyOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignBidModifierOperation) hash ^= CampaignBidModifierOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignBudgetOperation) hash ^= CampaignBudgetOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignCriterionOperation) hash ^= CampaignCriterionOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignDraftOperation) hash ^= CampaignDraftOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignExperimentOperation) hash ^= CampaignExperimentOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignExtensionSettingOperation) hash ^= CampaignExtensionSettingOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignFeedOperation) hash ^= CampaignFeedOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignLabelOperation) hash ^= CampaignLabelOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignOperation) hash ^= CampaignOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CampaignSharedSetOperation) hash ^= CampaignSharedSetOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.ConversionActionOperation) hash ^= ConversionActionOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CustomerExtensionSettingOperation) hash ^= CustomerExtensionSettingOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CustomerFeedOperation) hash ^= CustomerFeedOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CustomerLabelOperation) hash ^= CustomerLabelOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CustomerNegativeCriterionOperation) hash ^= CustomerNegativeCriterionOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.CustomerOperation) hash ^= CustomerOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.ExtensionFeedItemOperation) hash ^= ExtensionFeedItemOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.FeedItemOperation) hash ^= FeedItemOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.FeedItemTargetOperation) hash ^= FeedItemTargetOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.FeedMappingOperation) hash ^= FeedMappingOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.FeedOperation) hash ^= FeedOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.LabelOperation) hash ^= LabelOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.MediaFileOperation) hash ^= MediaFileOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.RemarketingActionOperation) hash ^= RemarketingActionOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.SharedCriterionOperation) hash ^= SharedCriterionOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.SharedSetOperation) hash ^= SharedSetOperation.GetHashCode(); + if (operationCase_ == OperationOneofCase.UserListOperation) hash ^= UserListOperation.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.AdGroupAdOperation) { + output.WriteRawTag(10); + output.WriteMessage(AdGroupAdOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupBidModifierOperation) { + output.WriteRawTag(18); + output.WriteMessage(AdGroupBidModifierOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupCriterionOperation) { + output.WriteRawTag(26); + output.WriteMessage(AdGroupCriterionOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupOperation) { + output.WriteRawTag(42); + output.WriteMessage(AdGroupOperation); + } + if (operationCase_ == OperationOneofCase.BiddingStrategyOperation) { + output.WriteRawTag(50); + output.WriteMessage(BiddingStrategyOperation); + } + if (operationCase_ == OperationOneofCase.CampaignBidModifierOperation) { + output.WriteRawTag(58); + output.WriteMessage(CampaignBidModifierOperation); + } + if (operationCase_ == OperationOneofCase.CampaignBudgetOperation) { + output.WriteRawTag(66); + output.WriteMessage(CampaignBudgetOperation); + } + if (operationCase_ == OperationOneofCase.CampaignOperation) { + output.WriteRawTag(82); + output.WriteMessage(CampaignOperation); + } + if (operationCase_ == OperationOneofCase.CampaignSharedSetOperation) { + output.WriteRawTag(90); + output.WriteMessage(CampaignSharedSetOperation); + } + if (operationCase_ == OperationOneofCase.ConversionActionOperation) { + output.WriteRawTag(98); + output.WriteMessage(ConversionActionOperation); + } + if (operationCase_ == OperationOneofCase.CampaignCriterionOperation) { + output.WriteRawTag(106); + output.WriteMessage(CampaignCriterionOperation); + } + if (operationCase_ == OperationOneofCase.SharedCriterionOperation) { + output.WriteRawTag(114); + output.WriteMessage(SharedCriterionOperation); + } + if (operationCase_ == OperationOneofCase.SharedSetOperation) { + output.WriteRawTag(122); + output.WriteMessage(SharedSetOperation); + } + if (operationCase_ == OperationOneofCase.UserListOperation) { + output.WriteRawTag(130, 1); + output.WriteMessage(UserListOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupAdLabelOperation) { + output.WriteRawTag(138, 1); + output.WriteMessage(AdGroupAdLabelOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupCriterionLabelOperation) { + output.WriteRawTag(146, 1); + output.WriteMessage(AdGroupCriterionLabelOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupExtensionSettingOperation) { + output.WriteRawTag(154, 1); + output.WriteMessage(AdGroupExtensionSettingOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupFeedOperation) { + output.WriteRawTag(162, 1); + output.WriteMessage(AdGroupFeedOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupLabelOperation) { + output.WriteRawTag(170, 1); + output.WriteMessage(AdGroupLabelOperation); + } + if (operationCase_ == OperationOneofCase.AdParameterOperation) { + output.WriteRawTag(178, 1); + output.WriteMessage(AdParameterOperation); + } + if (operationCase_ == OperationOneofCase.AssetOperation) { + output.WriteRawTag(186, 1); + output.WriteMessage(AssetOperation); + } + if (operationCase_ == OperationOneofCase.CampaignDraftOperation) { + output.WriteRawTag(194, 1); + output.WriteMessage(CampaignDraftOperation); + } + if (operationCase_ == OperationOneofCase.CampaignExperimentOperation) { + output.WriteRawTag(202, 1); + output.WriteMessage(CampaignExperimentOperation); + } + if (operationCase_ == OperationOneofCase.CampaignExtensionSettingOperation) { + output.WriteRawTag(210, 1); + output.WriteMessage(CampaignExtensionSettingOperation); + } + if (operationCase_ == OperationOneofCase.CampaignFeedOperation) { + output.WriteRawTag(218, 1); + output.WriteMessage(CampaignFeedOperation); + } + if (operationCase_ == OperationOneofCase.CampaignLabelOperation) { + output.WriteRawTag(226, 1); + output.WriteMessage(CampaignLabelOperation); + } + if (operationCase_ == OperationOneofCase.CustomerExtensionSettingOperation) { + output.WriteRawTag(242, 1); + output.WriteMessage(CustomerExtensionSettingOperation); + } + if (operationCase_ == OperationOneofCase.CustomerFeedOperation) { + output.WriteRawTag(250, 1); + output.WriteMessage(CustomerFeedOperation); + } + if (operationCase_ == OperationOneofCase.CustomerLabelOperation) { + output.WriteRawTag(130, 2); + output.WriteMessage(CustomerLabelOperation); + } + if (operationCase_ == OperationOneofCase.CustomerNegativeCriterionOperation) { + output.WriteRawTag(146, 2); + output.WriteMessage(CustomerNegativeCriterionOperation); + } + if (operationCase_ == OperationOneofCase.CustomerOperation) { + output.WriteRawTag(154, 2); + output.WriteMessage(CustomerOperation); + } + if (operationCase_ == OperationOneofCase.ExtensionFeedItemOperation) { + output.WriteRawTag(162, 2); + output.WriteMessage(ExtensionFeedItemOperation); + } + if (operationCase_ == OperationOneofCase.FeedItemOperation) { + output.WriteRawTag(170, 2); + output.WriteMessage(FeedItemOperation); + } + if (operationCase_ == OperationOneofCase.FeedItemTargetOperation) { + output.WriteRawTag(178, 2); + output.WriteMessage(FeedItemTargetOperation); + } + if (operationCase_ == OperationOneofCase.FeedMappingOperation) { + output.WriteRawTag(186, 2); + output.WriteMessage(FeedMappingOperation); + } + if (operationCase_ == OperationOneofCase.FeedOperation) { + output.WriteRawTag(194, 2); + output.WriteMessage(FeedOperation); + } + if (operationCase_ == OperationOneofCase.LabelOperation) { + output.WriteRawTag(202, 2); + output.WriteMessage(LabelOperation); + } + if (operationCase_ == OperationOneofCase.MediaFileOperation) { + output.WriteRawTag(210, 2); + output.WriteMessage(MediaFileOperation); + } + if (operationCase_ == OperationOneofCase.RemarketingActionOperation) { + output.WriteRawTag(218, 2); + output.WriteMessage(RemarketingActionOperation); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (operationCase_ == OperationOneofCase.AdGroupAdLabelOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupAdLabelOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupAdOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupAdOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupBidModifierOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupBidModifierOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupCriterionLabelOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupCriterionLabelOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupCriterionOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupCriterionOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupExtensionSettingOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupExtensionSettingOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupFeedOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupFeedOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupLabelOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupLabelOperation); + } + if (operationCase_ == OperationOneofCase.AdGroupOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupOperation); + } + if (operationCase_ == OperationOneofCase.AdParameterOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdParameterOperation); + } + if (operationCase_ == OperationOneofCase.AssetOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AssetOperation); + } + if (operationCase_ == OperationOneofCase.BiddingStrategyOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(BiddingStrategyOperation); + } + if (operationCase_ == OperationOneofCase.CampaignBidModifierOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignBidModifierOperation); + } + if (operationCase_ == OperationOneofCase.CampaignBudgetOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignBudgetOperation); + } + if (operationCase_ == OperationOneofCase.CampaignCriterionOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignCriterionOperation); + } + if (operationCase_ == OperationOneofCase.CampaignDraftOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignDraftOperation); + } + if (operationCase_ == OperationOneofCase.CampaignExperimentOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignExperimentOperation); + } + if (operationCase_ == OperationOneofCase.CampaignExtensionSettingOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignExtensionSettingOperation); + } + if (operationCase_ == OperationOneofCase.CampaignFeedOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignFeedOperation); + } + if (operationCase_ == OperationOneofCase.CampaignLabelOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignLabelOperation); + } + if (operationCase_ == OperationOneofCase.CampaignOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignOperation); + } + if (operationCase_ == OperationOneofCase.CampaignSharedSetOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignSharedSetOperation); + } + if (operationCase_ == OperationOneofCase.ConversionActionOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ConversionActionOperation); + } + if (operationCase_ == OperationOneofCase.CustomerExtensionSettingOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerExtensionSettingOperation); + } + if (operationCase_ == OperationOneofCase.CustomerFeedOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerFeedOperation); + } + if (operationCase_ == OperationOneofCase.CustomerLabelOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerLabelOperation); + } + if (operationCase_ == OperationOneofCase.CustomerNegativeCriterionOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerNegativeCriterionOperation); + } + if (operationCase_ == OperationOneofCase.CustomerOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerOperation); + } + if (operationCase_ == OperationOneofCase.ExtensionFeedItemOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ExtensionFeedItemOperation); + } + if (operationCase_ == OperationOneofCase.FeedItemOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedItemOperation); + } + if (operationCase_ == OperationOneofCase.FeedItemTargetOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedItemTargetOperation); + } + if (operationCase_ == OperationOneofCase.FeedMappingOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedMappingOperation); + } + if (operationCase_ == OperationOneofCase.FeedOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedOperation); + } + if (operationCase_ == OperationOneofCase.LabelOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(LabelOperation); + } + if (operationCase_ == OperationOneofCase.MediaFileOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MediaFileOperation); + } + if (operationCase_ == OperationOneofCase.RemarketingActionOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(RemarketingActionOperation); + } + if (operationCase_ == OperationOneofCase.SharedCriterionOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(SharedCriterionOperation); + } + if (operationCase_ == OperationOneofCase.SharedSetOperation) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(SharedSetOperation); + } + if (operationCase_ == OperationOneofCase.UserListOperation) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserListOperation); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateOperation other) { + if (other == null) { + return; + } + switch (other.OperationCase) { + case OperationOneofCase.AdGroupAdLabelOperation: + if (AdGroupAdLabelOperation == null) { + AdGroupAdLabelOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelOperation(); + } + AdGroupAdLabelOperation.MergeFrom(other.AdGroupAdLabelOperation); + break; + case OperationOneofCase.AdGroupAdOperation: + if (AdGroupAdOperation == null) { + AdGroupAdOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupAdOperation(); + } + AdGroupAdOperation.MergeFrom(other.AdGroupAdOperation); + break; + case OperationOneofCase.AdGroupBidModifierOperation: + if (AdGroupBidModifierOperation == null) { + AdGroupBidModifierOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierOperation(); + } + AdGroupBidModifierOperation.MergeFrom(other.AdGroupBidModifierOperation); + break; + case OperationOneofCase.AdGroupCriterionLabelOperation: + if (AdGroupCriterionLabelOperation == null) { + AdGroupCriterionLabelOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelOperation(); + } + AdGroupCriterionLabelOperation.MergeFrom(other.AdGroupCriterionLabelOperation); + break; + case OperationOneofCase.AdGroupCriterionOperation: + if (AdGroupCriterionOperation == null) { + AdGroupCriterionOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionOperation(); + } + AdGroupCriterionOperation.MergeFrom(other.AdGroupCriterionOperation); + break; + case OperationOneofCase.AdGroupExtensionSettingOperation: + if (AdGroupExtensionSettingOperation == null) { + AdGroupExtensionSettingOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingOperation(); + } + AdGroupExtensionSettingOperation.MergeFrom(other.AdGroupExtensionSettingOperation); + break; + case OperationOneofCase.AdGroupFeedOperation: + if (AdGroupFeedOperation == null) { + AdGroupFeedOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedOperation(); + } + AdGroupFeedOperation.MergeFrom(other.AdGroupFeedOperation); + break; + case OperationOneofCase.AdGroupLabelOperation: + if (AdGroupLabelOperation == null) { + AdGroupLabelOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelOperation(); + } + AdGroupLabelOperation.MergeFrom(other.AdGroupLabelOperation); + break; + case OperationOneofCase.AdGroupOperation: + if (AdGroupOperation == null) { + AdGroupOperation = new global::Google.Ads.GoogleAds.V3.Services.AdGroupOperation(); + } + AdGroupOperation.MergeFrom(other.AdGroupOperation); + break; + case OperationOneofCase.AdParameterOperation: + if (AdParameterOperation == null) { + AdParameterOperation = new global::Google.Ads.GoogleAds.V3.Services.AdParameterOperation(); + } + AdParameterOperation.MergeFrom(other.AdParameterOperation); + break; + case OperationOneofCase.AssetOperation: + if (AssetOperation == null) { + AssetOperation = new global::Google.Ads.GoogleAds.V3.Services.AssetOperation(); + } + AssetOperation.MergeFrom(other.AssetOperation); + break; + case OperationOneofCase.BiddingStrategyOperation: + if (BiddingStrategyOperation == null) { + BiddingStrategyOperation = new global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyOperation(); + } + BiddingStrategyOperation.MergeFrom(other.BiddingStrategyOperation); + break; + case OperationOneofCase.CampaignBidModifierOperation: + if (CampaignBidModifierOperation == null) { + CampaignBidModifierOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierOperation(); + } + CampaignBidModifierOperation.MergeFrom(other.CampaignBidModifierOperation); + break; + case OperationOneofCase.CampaignBudgetOperation: + if (CampaignBudgetOperation == null) { + CampaignBudgetOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetOperation(); + } + CampaignBudgetOperation.MergeFrom(other.CampaignBudgetOperation); + break; + case OperationOneofCase.CampaignCriterionOperation: + if (CampaignCriterionOperation == null) { + CampaignCriterionOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionOperation(); + } + CampaignCriterionOperation.MergeFrom(other.CampaignCriterionOperation); + break; + case OperationOneofCase.CampaignDraftOperation: + if (CampaignDraftOperation == null) { + CampaignDraftOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignDraftOperation(); + } + CampaignDraftOperation.MergeFrom(other.CampaignDraftOperation); + break; + case OperationOneofCase.CampaignExperimentOperation: + if (CampaignExperimentOperation == null) { + CampaignExperimentOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentOperation(); + } + CampaignExperimentOperation.MergeFrom(other.CampaignExperimentOperation); + break; + case OperationOneofCase.CampaignExtensionSettingOperation: + if (CampaignExtensionSettingOperation == null) { + CampaignExtensionSettingOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingOperation(); + } + CampaignExtensionSettingOperation.MergeFrom(other.CampaignExtensionSettingOperation); + break; + case OperationOneofCase.CampaignFeedOperation: + if (CampaignFeedOperation == null) { + CampaignFeedOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignFeedOperation(); + } + CampaignFeedOperation.MergeFrom(other.CampaignFeedOperation); + break; + case OperationOneofCase.CampaignLabelOperation: + if (CampaignLabelOperation == null) { + CampaignLabelOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignLabelOperation(); + } + CampaignLabelOperation.MergeFrom(other.CampaignLabelOperation); + break; + case OperationOneofCase.CampaignOperation: + if (CampaignOperation == null) { + CampaignOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignOperation(); + } + CampaignOperation.MergeFrom(other.CampaignOperation); + break; + case OperationOneofCase.CampaignSharedSetOperation: + if (CampaignSharedSetOperation == null) { + CampaignSharedSetOperation = new global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetOperation(); + } + CampaignSharedSetOperation.MergeFrom(other.CampaignSharedSetOperation); + break; + case OperationOneofCase.ConversionActionOperation: + if (ConversionActionOperation == null) { + ConversionActionOperation = new global::Google.Ads.GoogleAds.V3.Services.ConversionActionOperation(); + } + ConversionActionOperation.MergeFrom(other.ConversionActionOperation); + break; + case OperationOneofCase.CustomerExtensionSettingOperation: + if (CustomerExtensionSettingOperation == null) { + CustomerExtensionSettingOperation = new global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingOperation(); + } + CustomerExtensionSettingOperation.MergeFrom(other.CustomerExtensionSettingOperation); + break; + case OperationOneofCase.CustomerFeedOperation: + if (CustomerFeedOperation == null) { + CustomerFeedOperation = new global::Google.Ads.GoogleAds.V3.Services.CustomerFeedOperation(); + } + CustomerFeedOperation.MergeFrom(other.CustomerFeedOperation); + break; + case OperationOneofCase.CustomerLabelOperation: + if (CustomerLabelOperation == null) { + CustomerLabelOperation = new global::Google.Ads.GoogleAds.V3.Services.CustomerLabelOperation(); + } + CustomerLabelOperation.MergeFrom(other.CustomerLabelOperation); + break; + case OperationOneofCase.CustomerNegativeCriterionOperation: + if (CustomerNegativeCriterionOperation == null) { + CustomerNegativeCriterionOperation = new global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionOperation(); + } + CustomerNegativeCriterionOperation.MergeFrom(other.CustomerNegativeCriterionOperation); + break; + case OperationOneofCase.CustomerOperation: + if (CustomerOperation == null) { + CustomerOperation = new global::Google.Ads.GoogleAds.V3.Services.CustomerOperation(); + } + CustomerOperation.MergeFrom(other.CustomerOperation); + break; + case OperationOneofCase.ExtensionFeedItemOperation: + if (ExtensionFeedItemOperation == null) { + ExtensionFeedItemOperation = new global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemOperation(); + } + ExtensionFeedItemOperation.MergeFrom(other.ExtensionFeedItemOperation); + break; + case OperationOneofCase.FeedItemOperation: + if (FeedItemOperation == null) { + FeedItemOperation = new global::Google.Ads.GoogleAds.V3.Services.FeedItemOperation(); + } + FeedItemOperation.MergeFrom(other.FeedItemOperation); + break; + case OperationOneofCase.FeedItemTargetOperation: + if (FeedItemTargetOperation == null) { + FeedItemTargetOperation = new global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetOperation(); + } + FeedItemTargetOperation.MergeFrom(other.FeedItemTargetOperation); + break; + case OperationOneofCase.FeedMappingOperation: + if (FeedMappingOperation == null) { + FeedMappingOperation = new global::Google.Ads.GoogleAds.V3.Services.FeedMappingOperation(); + } + FeedMappingOperation.MergeFrom(other.FeedMappingOperation); + break; + case OperationOneofCase.FeedOperation: + if (FeedOperation == null) { + FeedOperation = new global::Google.Ads.GoogleAds.V3.Services.FeedOperation(); + } + FeedOperation.MergeFrom(other.FeedOperation); + break; + case OperationOneofCase.LabelOperation: + if (LabelOperation == null) { + LabelOperation = new global::Google.Ads.GoogleAds.V3.Services.LabelOperation(); + } + LabelOperation.MergeFrom(other.LabelOperation); + break; + case OperationOneofCase.MediaFileOperation: + if (MediaFileOperation == null) { + MediaFileOperation = new global::Google.Ads.GoogleAds.V3.Services.MediaFileOperation(); + } + MediaFileOperation.MergeFrom(other.MediaFileOperation); + break; + case OperationOneofCase.RemarketingActionOperation: + if (RemarketingActionOperation == null) { + RemarketingActionOperation = new global::Google.Ads.GoogleAds.V3.Services.RemarketingActionOperation(); + } + RemarketingActionOperation.MergeFrom(other.RemarketingActionOperation); + break; + case OperationOneofCase.SharedCriterionOperation: + if (SharedCriterionOperation == null) { + SharedCriterionOperation = new global::Google.Ads.GoogleAds.V3.Services.SharedCriterionOperation(); + } + SharedCriterionOperation.MergeFrom(other.SharedCriterionOperation); + break; + case OperationOneofCase.SharedSetOperation: + if (SharedSetOperation == null) { + SharedSetOperation = new global::Google.Ads.GoogleAds.V3.Services.SharedSetOperation(); + } + SharedSetOperation.MergeFrom(other.SharedSetOperation); + break; + case OperationOneofCase.UserListOperation: + if (UserListOperation == null) { + UserListOperation = new global::Google.Ads.GoogleAds.V3.Services.UserListOperation(); + } + UserListOperation.MergeFrom(other.UserListOperation); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupAdOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupAdOperation(); + if (operationCase_ == OperationOneofCase.AdGroupAdOperation) { + subBuilder.MergeFrom(AdGroupAdOperation); + } + input.ReadMessage(subBuilder); + AdGroupAdOperation = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupBidModifierOperation(); + if (operationCase_ == OperationOneofCase.AdGroupBidModifierOperation) { + subBuilder.MergeFrom(AdGroupBidModifierOperation); + } + input.ReadMessage(subBuilder); + AdGroupBidModifierOperation = subBuilder; + break; + } + case 26: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionOperation(); + if (operationCase_ == OperationOneofCase.AdGroupCriterionOperation) { + subBuilder.MergeFrom(AdGroupCriterionOperation); + } + input.ReadMessage(subBuilder); + AdGroupCriterionOperation = subBuilder; + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupOperation(); + if (operationCase_ == OperationOneofCase.AdGroupOperation) { + subBuilder.MergeFrom(AdGroupOperation); + } + input.ReadMessage(subBuilder); + AdGroupOperation = subBuilder; + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.BiddingStrategyOperation(); + if (operationCase_ == OperationOneofCase.BiddingStrategyOperation) { + subBuilder.MergeFrom(BiddingStrategyOperation); + } + input.ReadMessage(subBuilder); + BiddingStrategyOperation = subBuilder; + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignBidModifierOperation(); + if (operationCase_ == OperationOneofCase.CampaignBidModifierOperation) { + subBuilder.MergeFrom(CampaignBidModifierOperation); + } + input.ReadMessage(subBuilder); + CampaignBidModifierOperation = subBuilder; + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignBudgetOperation(); + if (operationCase_ == OperationOneofCase.CampaignBudgetOperation) { + subBuilder.MergeFrom(CampaignBudgetOperation); + } + input.ReadMessage(subBuilder); + CampaignBudgetOperation = subBuilder; + break; + } + case 82: { + global::Google.Ads.GoogleAds.V3.Services.CampaignOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignOperation(); + if (operationCase_ == OperationOneofCase.CampaignOperation) { + subBuilder.MergeFrom(CampaignOperation); + } + input.ReadMessage(subBuilder); + CampaignOperation = subBuilder; + break; + } + case 90: { + global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignSharedSetOperation(); + if (operationCase_ == OperationOneofCase.CampaignSharedSetOperation) { + subBuilder.MergeFrom(CampaignSharedSetOperation); + } + input.ReadMessage(subBuilder); + CampaignSharedSetOperation = subBuilder; + break; + } + case 98: { + global::Google.Ads.GoogleAds.V3.Services.ConversionActionOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.ConversionActionOperation(); + if (operationCase_ == OperationOneofCase.ConversionActionOperation) { + subBuilder.MergeFrom(ConversionActionOperation); + } + input.ReadMessage(subBuilder); + ConversionActionOperation = subBuilder; + break; + } + case 106: { + global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignCriterionOperation(); + if (operationCase_ == OperationOneofCase.CampaignCriterionOperation) { + subBuilder.MergeFrom(CampaignCriterionOperation); + } + input.ReadMessage(subBuilder); + CampaignCriterionOperation = subBuilder; + break; + } + case 114: { + global::Google.Ads.GoogleAds.V3.Services.SharedCriterionOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.SharedCriterionOperation(); + if (operationCase_ == OperationOneofCase.SharedCriterionOperation) { + subBuilder.MergeFrom(SharedCriterionOperation); + } + input.ReadMessage(subBuilder); + SharedCriterionOperation = subBuilder; + break; + } + case 122: { + global::Google.Ads.GoogleAds.V3.Services.SharedSetOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.SharedSetOperation(); + if (operationCase_ == OperationOneofCase.SharedSetOperation) { + subBuilder.MergeFrom(SharedSetOperation); + } + input.ReadMessage(subBuilder); + SharedSetOperation = subBuilder; + break; + } + case 130: { + global::Google.Ads.GoogleAds.V3.Services.UserListOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.UserListOperation(); + if (operationCase_ == OperationOneofCase.UserListOperation) { + subBuilder.MergeFrom(UserListOperation); + } + input.ReadMessage(subBuilder); + UserListOperation = subBuilder; + break; + } + case 138: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupAdLabelOperation(); + if (operationCase_ == OperationOneofCase.AdGroupAdLabelOperation) { + subBuilder.MergeFrom(AdGroupAdLabelOperation); + } + input.ReadMessage(subBuilder); + AdGroupAdLabelOperation = subBuilder; + break; + } + case 146: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupCriterionLabelOperation(); + if (operationCase_ == OperationOneofCase.AdGroupCriterionLabelOperation) { + subBuilder.MergeFrom(AdGroupCriterionLabelOperation); + } + input.ReadMessage(subBuilder); + AdGroupCriterionLabelOperation = subBuilder; + break; + } + case 154: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupExtensionSettingOperation(); + if (operationCase_ == OperationOneofCase.AdGroupExtensionSettingOperation) { + subBuilder.MergeFrom(AdGroupExtensionSettingOperation); + } + input.ReadMessage(subBuilder); + AdGroupExtensionSettingOperation = subBuilder; + break; + } + case 162: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupFeedOperation(); + if (operationCase_ == OperationOneofCase.AdGroupFeedOperation) { + subBuilder.MergeFrom(AdGroupFeedOperation); + } + input.ReadMessage(subBuilder); + AdGroupFeedOperation = subBuilder; + break; + } + case 170: { + global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdGroupLabelOperation(); + if (operationCase_ == OperationOneofCase.AdGroupLabelOperation) { + subBuilder.MergeFrom(AdGroupLabelOperation); + } + input.ReadMessage(subBuilder); + AdGroupLabelOperation = subBuilder; + break; + } + case 178: { + global::Google.Ads.GoogleAds.V3.Services.AdParameterOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AdParameterOperation(); + if (operationCase_ == OperationOneofCase.AdParameterOperation) { + subBuilder.MergeFrom(AdParameterOperation); + } + input.ReadMessage(subBuilder); + AdParameterOperation = subBuilder; + break; + } + case 186: { + global::Google.Ads.GoogleAds.V3.Services.AssetOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.AssetOperation(); + if (operationCase_ == OperationOneofCase.AssetOperation) { + subBuilder.MergeFrom(AssetOperation); + } + input.ReadMessage(subBuilder); + AssetOperation = subBuilder; + break; + } + case 194: { + global::Google.Ads.GoogleAds.V3.Services.CampaignDraftOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignDraftOperation(); + if (operationCase_ == OperationOneofCase.CampaignDraftOperation) { + subBuilder.MergeFrom(CampaignDraftOperation); + } + input.ReadMessage(subBuilder); + CampaignDraftOperation = subBuilder; + break; + } + case 202: { + global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignExperimentOperation(); + if (operationCase_ == OperationOneofCase.CampaignExperimentOperation) { + subBuilder.MergeFrom(CampaignExperimentOperation); + } + input.ReadMessage(subBuilder); + CampaignExperimentOperation = subBuilder; + break; + } + case 210: { + global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignExtensionSettingOperation(); + if (operationCase_ == OperationOneofCase.CampaignExtensionSettingOperation) { + subBuilder.MergeFrom(CampaignExtensionSettingOperation); + } + input.ReadMessage(subBuilder); + CampaignExtensionSettingOperation = subBuilder; + break; + } + case 218: { + global::Google.Ads.GoogleAds.V3.Services.CampaignFeedOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignFeedOperation(); + if (operationCase_ == OperationOneofCase.CampaignFeedOperation) { + subBuilder.MergeFrom(CampaignFeedOperation); + } + input.ReadMessage(subBuilder); + CampaignFeedOperation = subBuilder; + break; + } + case 226: { + global::Google.Ads.GoogleAds.V3.Services.CampaignLabelOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CampaignLabelOperation(); + if (operationCase_ == OperationOneofCase.CampaignLabelOperation) { + subBuilder.MergeFrom(CampaignLabelOperation); + } + input.ReadMessage(subBuilder); + CampaignLabelOperation = subBuilder; + break; + } + case 242: { + global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CustomerExtensionSettingOperation(); + if (operationCase_ == OperationOneofCase.CustomerExtensionSettingOperation) { + subBuilder.MergeFrom(CustomerExtensionSettingOperation); + } + input.ReadMessage(subBuilder); + CustomerExtensionSettingOperation = subBuilder; + break; + } + case 250: { + global::Google.Ads.GoogleAds.V3.Services.CustomerFeedOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CustomerFeedOperation(); + if (operationCase_ == OperationOneofCase.CustomerFeedOperation) { + subBuilder.MergeFrom(CustomerFeedOperation); + } + input.ReadMessage(subBuilder); + CustomerFeedOperation = subBuilder; + break; + } + case 258: { + global::Google.Ads.GoogleAds.V3.Services.CustomerLabelOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CustomerLabelOperation(); + if (operationCase_ == OperationOneofCase.CustomerLabelOperation) { + subBuilder.MergeFrom(CustomerLabelOperation); + } + input.ReadMessage(subBuilder); + CustomerLabelOperation = subBuilder; + break; + } + case 274: { + global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CustomerNegativeCriterionOperation(); + if (operationCase_ == OperationOneofCase.CustomerNegativeCriterionOperation) { + subBuilder.MergeFrom(CustomerNegativeCriterionOperation); + } + input.ReadMessage(subBuilder); + CustomerNegativeCriterionOperation = subBuilder; + break; + } + case 282: { + global::Google.Ads.GoogleAds.V3.Services.CustomerOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.CustomerOperation(); + if (operationCase_ == OperationOneofCase.CustomerOperation) { + subBuilder.MergeFrom(CustomerOperation); + } + input.ReadMessage(subBuilder); + CustomerOperation = subBuilder; + break; + } + case 290: { + global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.ExtensionFeedItemOperation(); + if (operationCase_ == OperationOneofCase.ExtensionFeedItemOperation) { + subBuilder.MergeFrom(ExtensionFeedItemOperation); + } + input.ReadMessage(subBuilder); + ExtensionFeedItemOperation = subBuilder; + break; + } + case 298: { + global::Google.Ads.GoogleAds.V3.Services.FeedItemOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.FeedItemOperation(); + if (operationCase_ == OperationOneofCase.FeedItemOperation) { + subBuilder.MergeFrom(FeedItemOperation); + } + input.ReadMessage(subBuilder); + FeedItemOperation = subBuilder; + break; + } + case 306: { + global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.FeedItemTargetOperation(); + if (operationCase_ == OperationOneofCase.FeedItemTargetOperation) { + subBuilder.MergeFrom(FeedItemTargetOperation); + } + input.ReadMessage(subBuilder); + FeedItemTargetOperation = subBuilder; + break; + } + case 314: { + global::Google.Ads.GoogleAds.V3.Services.FeedMappingOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.FeedMappingOperation(); + if (operationCase_ == OperationOneofCase.FeedMappingOperation) { + subBuilder.MergeFrom(FeedMappingOperation); + } + input.ReadMessage(subBuilder); + FeedMappingOperation = subBuilder; + break; + } + case 322: { + global::Google.Ads.GoogleAds.V3.Services.FeedOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.FeedOperation(); + if (operationCase_ == OperationOneofCase.FeedOperation) { + subBuilder.MergeFrom(FeedOperation); + } + input.ReadMessage(subBuilder); + FeedOperation = subBuilder; + break; + } + case 330: { + global::Google.Ads.GoogleAds.V3.Services.LabelOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.LabelOperation(); + if (operationCase_ == OperationOneofCase.LabelOperation) { + subBuilder.MergeFrom(LabelOperation); + } + input.ReadMessage(subBuilder); + LabelOperation = subBuilder; + break; + } + case 338: { + global::Google.Ads.GoogleAds.V3.Services.MediaFileOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MediaFileOperation(); + if (operationCase_ == OperationOneofCase.MediaFileOperation) { + subBuilder.MergeFrom(MediaFileOperation); + } + input.ReadMessage(subBuilder); + MediaFileOperation = subBuilder; + break; + } + case 346: { + global::Google.Ads.GoogleAds.V3.Services.RemarketingActionOperation subBuilder = new global::Google.Ads.GoogleAds.V3.Services.RemarketingActionOperation(); + if (operationCase_ == OperationOneofCase.RemarketingActionOperation) { + subBuilder.MergeFrom(RemarketingActionOperation); + } + input.ReadMessage(subBuilder); + RemarketingActionOperation = subBuilder; + break; + } + } + } + } + + } + + /// + /// Response message for the resource mutate. + /// + public sealed partial class MutateOperationResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateOperationResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateOperationResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateOperationResponse(MutateOperationResponse other) : this() { + switch (other.ResponseCase) { + case ResponseOneofCase.AdGroupAdLabelResult: + AdGroupAdLabelResult = other.AdGroupAdLabelResult.Clone(); + break; + case ResponseOneofCase.AdGroupAdResult: + AdGroupAdResult = other.AdGroupAdResult.Clone(); + break; + case ResponseOneofCase.AdGroupBidModifierResult: + AdGroupBidModifierResult = other.AdGroupBidModifierResult.Clone(); + break; + case ResponseOneofCase.AdGroupCriterionLabelResult: + AdGroupCriterionLabelResult = other.AdGroupCriterionLabelResult.Clone(); + break; + case ResponseOneofCase.AdGroupCriterionResult: + AdGroupCriterionResult = other.AdGroupCriterionResult.Clone(); + break; + case ResponseOneofCase.AdGroupExtensionSettingResult: + AdGroupExtensionSettingResult = other.AdGroupExtensionSettingResult.Clone(); + break; + case ResponseOneofCase.AdGroupFeedResult: + AdGroupFeedResult = other.AdGroupFeedResult.Clone(); + break; + case ResponseOneofCase.AdGroupLabelResult: + AdGroupLabelResult = other.AdGroupLabelResult.Clone(); + break; + case ResponseOneofCase.AdGroupResult: + AdGroupResult = other.AdGroupResult.Clone(); + break; + case ResponseOneofCase.AdParameterResult: + AdParameterResult = other.AdParameterResult.Clone(); + break; + case ResponseOneofCase.AssetResult: + AssetResult = other.AssetResult.Clone(); + break; + case ResponseOneofCase.BiddingStrategyResult: + BiddingStrategyResult = other.BiddingStrategyResult.Clone(); + break; + case ResponseOneofCase.CampaignBidModifierResult: + CampaignBidModifierResult = other.CampaignBidModifierResult.Clone(); + break; + case ResponseOneofCase.CampaignBudgetResult: + CampaignBudgetResult = other.CampaignBudgetResult.Clone(); + break; + case ResponseOneofCase.CampaignCriterionResult: + CampaignCriterionResult = other.CampaignCriterionResult.Clone(); + break; + case ResponseOneofCase.CampaignDraftResult: + CampaignDraftResult = other.CampaignDraftResult.Clone(); + break; + case ResponseOneofCase.CampaignExperimentResult: + CampaignExperimentResult = other.CampaignExperimentResult.Clone(); + break; + case ResponseOneofCase.CampaignExtensionSettingResult: + CampaignExtensionSettingResult = other.CampaignExtensionSettingResult.Clone(); + break; + case ResponseOneofCase.CampaignFeedResult: + CampaignFeedResult = other.CampaignFeedResult.Clone(); + break; + case ResponseOneofCase.CampaignLabelResult: + CampaignLabelResult = other.CampaignLabelResult.Clone(); + break; + case ResponseOneofCase.CampaignResult: + CampaignResult = other.CampaignResult.Clone(); + break; + case ResponseOneofCase.CampaignSharedSetResult: + CampaignSharedSetResult = other.CampaignSharedSetResult.Clone(); + break; + case ResponseOneofCase.ConversionActionResult: + ConversionActionResult = other.ConversionActionResult.Clone(); + break; + case ResponseOneofCase.CustomerExtensionSettingResult: + CustomerExtensionSettingResult = other.CustomerExtensionSettingResult.Clone(); + break; + case ResponseOneofCase.CustomerFeedResult: + CustomerFeedResult = other.CustomerFeedResult.Clone(); + break; + case ResponseOneofCase.CustomerLabelResult: + CustomerLabelResult = other.CustomerLabelResult.Clone(); + break; + case ResponseOneofCase.CustomerNegativeCriterionResult: + CustomerNegativeCriterionResult = other.CustomerNegativeCriterionResult.Clone(); + break; + case ResponseOneofCase.CustomerResult: + CustomerResult = other.CustomerResult.Clone(); + break; + case ResponseOneofCase.ExtensionFeedItemResult: + ExtensionFeedItemResult = other.ExtensionFeedItemResult.Clone(); + break; + case ResponseOneofCase.FeedItemResult: + FeedItemResult = other.FeedItemResult.Clone(); + break; + case ResponseOneofCase.FeedItemTargetResult: + FeedItemTargetResult = other.FeedItemTargetResult.Clone(); + break; + case ResponseOneofCase.FeedMappingResult: + FeedMappingResult = other.FeedMappingResult.Clone(); + break; + case ResponseOneofCase.FeedResult: + FeedResult = other.FeedResult.Clone(); + break; + case ResponseOneofCase.LabelResult: + LabelResult = other.LabelResult.Clone(); + break; + case ResponseOneofCase.MediaFileResult: + MediaFileResult = other.MediaFileResult.Clone(); + break; + case ResponseOneofCase.RemarketingActionResult: + RemarketingActionResult = other.RemarketingActionResult.Clone(); + break; + case ResponseOneofCase.SharedCriterionResult: + SharedCriterionResult = other.SharedCriterionResult.Clone(); + break; + case ResponseOneofCase.SharedSetResult: + SharedSetResult = other.SharedSetResult.Clone(); + break; + case ResponseOneofCase.UserListResult: + UserListResult = other.UserListResult.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateOperationResponse Clone() { + return new MutateOperationResponse(this); + } + + /// Field number for the "ad_group_ad_label_result" field. + public const int AdGroupAdLabelResultFieldNumber = 17; + /// + /// The result for the ad group ad label mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelResult AdGroupAdLabelResult { + get { return responseCase_ == ResponseOneofCase.AdGroupAdLabelResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupAdLabelResult; + } + } + + /// Field number for the "ad_group_ad_result" field. + public const int AdGroupAdResultFieldNumber = 1; + /// + /// The result for the ad group ad mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdResult AdGroupAdResult { + get { return responseCase_ == ResponseOneofCase.AdGroupAdResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupAdResult; + } + } + + /// Field number for the "ad_group_bid_modifier_result" field. + public const int AdGroupBidModifierResultFieldNumber = 2; + /// + /// The result for the ad group bid modifier mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifierResult AdGroupBidModifierResult { + get { return responseCase_ == ResponseOneofCase.AdGroupBidModifierResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifierResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupBidModifierResult; + } + } + + /// Field number for the "ad_group_criterion_label_result" field. + public const int AdGroupCriterionLabelResultFieldNumber = 18; + /// + /// The result for the ad group criterion label mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelResult AdGroupCriterionLabelResult { + get { return responseCase_ == ResponseOneofCase.AdGroupCriterionLabelResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupCriterionLabelResult; + } + } + + /// Field number for the "ad_group_criterion_result" field. + public const int AdGroupCriterionResultFieldNumber = 3; + /// + /// The result for the ad group criterion mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionResult AdGroupCriterionResult { + get { return responseCase_ == ResponseOneofCase.AdGroupCriterionResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupCriterionResult; + } + } + + /// Field number for the "ad_group_extension_setting_result" field. + public const int AdGroupExtensionSettingResultFieldNumber = 19; + /// + /// The result for the ad group extension setting mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingResult AdGroupExtensionSettingResult { + get { return responseCase_ == ResponseOneofCase.AdGroupExtensionSettingResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupExtensionSettingResult; + } + } + + /// Field number for the "ad_group_feed_result" field. + public const int AdGroupFeedResultFieldNumber = 20; + /// + /// The result for the ad group feed mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedResult AdGroupFeedResult { + get { return responseCase_ == ResponseOneofCase.AdGroupFeedResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupFeedResult; + } + } + + /// Field number for the "ad_group_label_result" field. + public const int AdGroupLabelResultFieldNumber = 21; + /// + /// The result for the ad group label mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelResult AdGroupLabelResult { + get { return responseCase_ == ResponseOneofCase.AdGroupLabelResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupLabelResult; + } + } + + /// Field number for the "ad_group_result" field. + public const int AdGroupResultFieldNumber = 5; + /// + /// The result for the ad group mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupResult AdGroupResult { + get { return responseCase_ == ResponseOneofCase.AdGroupResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdGroupResult; + } + } + + /// Field number for the "ad_parameter_result" field. + public const int AdParameterResultFieldNumber = 22; + /// + /// The result for the ad parameter mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAdParameterResult AdParameterResult { + get { return responseCase_ == ResponseOneofCase.AdParameterResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAdParameterResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AdParameterResult; + } + } + + /// Field number for the "asset_result" field. + public const int AssetResultFieldNumber = 23; + /// + /// The result for the asset mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateAssetResult AssetResult { + get { return responseCase_ == ResponseOneofCase.AssetResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateAssetResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.AssetResult; + } + } + + /// Field number for the "bidding_strategy_result" field. + public const int BiddingStrategyResultFieldNumber = 6; + /// + /// The result for the bidding strategy mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategyResult BiddingStrategyResult { + get { return responseCase_ == ResponseOneofCase.BiddingStrategyResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategyResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.BiddingStrategyResult; + } + } + + /// Field number for the "campaign_bid_modifier_result" field. + public const int CampaignBidModifierResultFieldNumber = 7; + /// + /// The result for the campaign bid modifier mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifierResult CampaignBidModifierResult { + get { return responseCase_ == ResponseOneofCase.CampaignBidModifierResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifierResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignBidModifierResult; + } + } + + /// Field number for the "campaign_budget_result" field. + public const int CampaignBudgetResultFieldNumber = 8; + /// + /// The result for the campaign budget mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetResult CampaignBudgetResult { + get { return responseCase_ == ResponseOneofCase.CampaignBudgetResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignBudgetResult; + } + } + + /// Field number for the "campaign_criterion_result" field. + public const int CampaignCriterionResultFieldNumber = 13; + /// + /// The result for the campaign criterion mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriterionResult CampaignCriterionResult { + get { return responseCase_ == ResponseOneofCase.CampaignCriterionResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriterionResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignCriterionResult; + } + } + + /// Field number for the "campaign_draft_result" field. + public const int CampaignDraftResultFieldNumber = 24; + /// + /// The result for the campaign draft mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftResult CampaignDraftResult { + get { return responseCase_ == ResponseOneofCase.CampaignDraftResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignDraftResult; + } + } + + /// Field number for the "campaign_experiment_result" field. + public const int CampaignExperimentResultFieldNumber = 25; + /// + /// The result for the campaign experiment mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentResult CampaignExperimentResult { + get { return responseCase_ == ResponseOneofCase.CampaignExperimentResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignExperimentResult; + } + } + + /// Field number for the "campaign_extension_setting_result" field. + public const int CampaignExtensionSettingResultFieldNumber = 26; + /// + /// The result for the campaign extension setting mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingResult CampaignExtensionSettingResult { + get { return responseCase_ == ResponseOneofCase.CampaignExtensionSettingResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignExtensionSettingResult; + } + } + + /// Field number for the "campaign_feed_result" field. + public const int CampaignFeedResultFieldNumber = 27; + /// + /// The result for the campaign feed mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedResult CampaignFeedResult { + get { return responseCase_ == ResponseOneofCase.CampaignFeedResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignFeedResult; + } + } + + /// Field number for the "campaign_label_result" field. + public const int CampaignLabelResultFieldNumber = 28; + /// + /// The result for the campaign label mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelResult CampaignLabelResult { + get { return responseCase_ == ResponseOneofCase.CampaignLabelResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignLabelResult; + } + } + + /// Field number for the "campaign_result" field. + public const int CampaignResultFieldNumber = 10; + /// + /// The result for the campaign mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignResult CampaignResult { + get { return responseCase_ == ResponseOneofCase.CampaignResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignResult; + } + } + + /// Field number for the "campaign_shared_set_result" field. + public const int CampaignSharedSetResultFieldNumber = 11; + /// + /// The result for the campaign shared set mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetResult CampaignSharedSetResult { + get { return responseCase_ == ResponseOneofCase.CampaignSharedSetResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CampaignSharedSetResult; + } + } + + /// Field number for the "conversion_action_result" field. + public const int ConversionActionResultFieldNumber = 12; + /// + /// The result for the conversion action mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionResult ConversionActionResult { + get { return responseCase_ == ResponseOneofCase.ConversionActionResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.ConversionActionResult; + } + } + + /// Field number for the "customer_extension_setting_result" field. + public const int CustomerExtensionSettingResultFieldNumber = 30; + /// + /// The result for the customer extension setting mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingResult CustomerExtensionSettingResult { + get { return responseCase_ == ResponseOneofCase.CustomerExtensionSettingResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CustomerExtensionSettingResult; + } + } + + /// Field number for the "customer_feed_result" field. + public const int CustomerFeedResultFieldNumber = 31; + /// + /// The result for the customer feed mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedResult CustomerFeedResult { + get { return responseCase_ == ResponseOneofCase.CustomerFeedResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CustomerFeedResult; + } + } + + /// Field number for the "customer_label_result" field. + public const int CustomerLabelResultFieldNumber = 32; + /// + /// The result for the customer label mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelResult CustomerLabelResult { + get { return responseCase_ == ResponseOneofCase.CustomerLabelResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CustomerLabelResult; + } + } + + /// Field number for the "customer_negative_criterion_result" field. + public const int CustomerNegativeCriterionResultFieldNumber = 34; + /// + /// The result for the customer negative criterion mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResult CustomerNegativeCriterionResult { + get { return responseCase_ == ResponseOneofCase.CustomerNegativeCriterionResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CustomerNegativeCriterionResult; + } + } + + /// Field number for the "customer_result" field. + public const int CustomerResultFieldNumber = 35; + /// + /// The result for the customer mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult CustomerResult { + get { return responseCase_ == ResponseOneofCase.CustomerResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.CustomerResult; + } + } + + /// Field number for the "extension_feed_item_result" field. + public const int ExtensionFeedItemResultFieldNumber = 36; + /// + /// The result for the extension feed item mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemResult ExtensionFeedItemResult { + get { return responseCase_ == ResponseOneofCase.ExtensionFeedItemResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.ExtensionFeedItemResult; + } + } + + /// Field number for the "feed_item_result" field. + public const int FeedItemResultFieldNumber = 37; + /// + /// The result for the feed item mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemResult FeedItemResult { + get { return responseCase_ == ResponseOneofCase.FeedItemResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.FeedItemResult; + } + } + + /// Field number for the "feed_item_target_result" field. + public const int FeedItemTargetResultFieldNumber = 38; + /// + /// The result for the feed item target mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetResult FeedItemTargetResult { + get { return responseCase_ == ResponseOneofCase.FeedItemTargetResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.FeedItemTargetResult; + } + } + + /// Field number for the "feed_mapping_result" field. + public const int FeedMappingResultFieldNumber = 39; + /// + /// The result for the feed mapping mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingResult FeedMappingResult { + get { return responseCase_ == ResponseOneofCase.FeedMappingResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.FeedMappingResult; + } + } + + /// Field number for the "feed_result" field. + public const int FeedResultFieldNumber = 40; + /// + /// The result for the feed mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateFeedResult FeedResult { + get { return responseCase_ == ResponseOneofCase.FeedResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateFeedResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.FeedResult; + } + } + + /// Field number for the "label_result" field. + public const int LabelResultFieldNumber = 41; + /// + /// The result for the label mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateLabelResult LabelResult { + get { return responseCase_ == ResponseOneofCase.LabelResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateLabelResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.LabelResult; + } + } + + /// Field number for the "media_file_result" field. + public const int MediaFileResultFieldNumber = 42; + /// + /// The result for the media file mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateMediaFileResult MediaFileResult { + get { return responseCase_ == ResponseOneofCase.MediaFileResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateMediaFileResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.MediaFileResult; + } + } + + /// Field number for the "remarketing_action_result" field. + public const int RemarketingActionResultFieldNumber = 43; + /// + /// The result for the remarketing action mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateRemarketingActionResult RemarketingActionResult { + get { return responseCase_ == ResponseOneofCase.RemarketingActionResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateRemarketingActionResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.RemarketingActionResult; + } + } + + /// Field number for the "shared_criterion_result" field. + public const int SharedCriterionResultFieldNumber = 14; + /// + /// The result for the shared criterion mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateSharedCriterionResult SharedCriterionResult { + get { return responseCase_ == ResponseOneofCase.SharedCriterionResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateSharedCriterionResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.SharedCriterionResult; + } + } + + /// Field number for the "shared_set_result" field. + public const int SharedSetResultFieldNumber = 15; + /// + /// The result for the shared set mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateSharedSetResult SharedSetResult { + get { return responseCase_ == ResponseOneofCase.SharedSetResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateSharedSetResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.SharedSetResult; + } + } + + /// Field number for the "user_list_result" field. + public const int UserListResultFieldNumber = 16; + /// + /// The result for the user list mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.MutateUserListResult UserListResult { + get { return responseCase_ == ResponseOneofCase.UserListResult ? (global::Google.Ads.GoogleAds.V3.Services.MutateUserListResult) response_ : null; } + set { + response_ = value; + responseCase_ = value == null ? ResponseOneofCase.None : ResponseOneofCase.UserListResult; + } + } + + private object response_; + /// Enum of possible cases for the "response" oneof. + public enum ResponseOneofCase { + None = 0, + AdGroupAdLabelResult = 17, + AdGroupAdResult = 1, + AdGroupBidModifierResult = 2, + AdGroupCriterionLabelResult = 18, + AdGroupCriterionResult = 3, + AdGroupExtensionSettingResult = 19, + AdGroupFeedResult = 20, + AdGroupLabelResult = 21, + AdGroupResult = 5, + AdParameterResult = 22, + AssetResult = 23, + BiddingStrategyResult = 6, + CampaignBidModifierResult = 7, + CampaignBudgetResult = 8, + CampaignCriterionResult = 13, + CampaignDraftResult = 24, + CampaignExperimentResult = 25, + CampaignExtensionSettingResult = 26, + CampaignFeedResult = 27, + CampaignLabelResult = 28, + CampaignResult = 10, + CampaignSharedSetResult = 11, + ConversionActionResult = 12, + CustomerExtensionSettingResult = 30, + CustomerFeedResult = 31, + CustomerLabelResult = 32, + CustomerNegativeCriterionResult = 34, + CustomerResult = 35, + ExtensionFeedItemResult = 36, + FeedItemResult = 37, + FeedItemTargetResult = 38, + FeedMappingResult = 39, + FeedResult = 40, + LabelResult = 41, + MediaFileResult = 42, + RemarketingActionResult = 43, + SharedCriterionResult = 14, + SharedSetResult = 15, + UserListResult = 16, + } + private ResponseOneofCase responseCase_ = ResponseOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ResponseOneofCase ResponseCase { + get { return responseCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearResponse() { + responseCase_ = ResponseOneofCase.None; + response_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateOperationResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateOperationResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(AdGroupAdLabelResult, other.AdGroupAdLabelResult)) return false; + if (!object.Equals(AdGroupAdResult, other.AdGroupAdResult)) return false; + if (!object.Equals(AdGroupBidModifierResult, other.AdGroupBidModifierResult)) return false; + if (!object.Equals(AdGroupCriterionLabelResult, other.AdGroupCriterionLabelResult)) return false; + if (!object.Equals(AdGroupCriterionResult, other.AdGroupCriterionResult)) return false; + if (!object.Equals(AdGroupExtensionSettingResult, other.AdGroupExtensionSettingResult)) return false; + if (!object.Equals(AdGroupFeedResult, other.AdGroupFeedResult)) return false; + if (!object.Equals(AdGroupLabelResult, other.AdGroupLabelResult)) return false; + if (!object.Equals(AdGroupResult, other.AdGroupResult)) return false; + if (!object.Equals(AdParameterResult, other.AdParameterResult)) return false; + if (!object.Equals(AssetResult, other.AssetResult)) return false; + if (!object.Equals(BiddingStrategyResult, other.BiddingStrategyResult)) return false; + if (!object.Equals(CampaignBidModifierResult, other.CampaignBidModifierResult)) return false; + if (!object.Equals(CampaignBudgetResult, other.CampaignBudgetResult)) return false; + if (!object.Equals(CampaignCriterionResult, other.CampaignCriterionResult)) return false; + if (!object.Equals(CampaignDraftResult, other.CampaignDraftResult)) return false; + if (!object.Equals(CampaignExperimentResult, other.CampaignExperimentResult)) return false; + if (!object.Equals(CampaignExtensionSettingResult, other.CampaignExtensionSettingResult)) return false; + if (!object.Equals(CampaignFeedResult, other.CampaignFeedResult)) return false; + if (!object.Equals(CampaignLabelResult, other.CampaignLabelResult)) return false; + if (!object.Equals(CampaignResult, other.CampaignResult)) return false; + if (!object.Equals(CampaignSharedSetResult, other.CampaignSharedSetResult)) return false; + if (!object.Equals(ConversionActionResult, other.ConversionActionResult)) return false; + if (!object.Equals(CustomerExtensionSettingResult, other.CustomerExtensionSettingResult)) return false; + if (!object.Equals(CustomerFeedResult, other.CustomerFeedResult)) return false; + if (!object.Equals(CustomerLabelResult, other.CustomerLabelResult)) return false; + if (!object.Equals(CustomerNegativeCriterionResult, other.CustomerNegativeCriterionResult)) return false; + if (!object.Equals(CustomerResult, other.CustomerResult)) return false; + if (!object.Equals(ExtensionFeedItemResult, other.ExtensionFeedItemResult)) return false; + if (!object.Equals(FeedItemResult, other.FeedItemResult)) return false; + if (!object.Equals(FeedItemTargetResult, other.FeedItemTargetResult)) return false; + if (!object.Equals(FeedMappingResult, other.FeedMappingResult)) return false; + if (!object.Equals(FeedResult, other.FeedResult)) return false; + if (!object.Equals(LabelResult, other.LabelResult)) return false; + if (!object.Equals(MediaFileResult, other.MediaFileResult)) return false; + if (!object.Equals(RemarketingActionResult, other.RemarketingActionResult)) return false; + if (!object.Equals(SharedCriterionResult, other.SharedCriterionResult)) return false; + if (!object.Equals(SharedSetResult, other.SharedSetResult)) return false; + if (!object.Equals(UserListResult, other.UserListResult)) return false; + if (ResponseCase != other.ResponseCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (responseCase_ == ResponseOneofCase.AdGroupAdLabelResult) hash ^= AdGroupAdLabelResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdGroupAdResult) hash ^= AdGroupAdResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdGroupBidModifierResult) hash ^= AdGroupBidModifierResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdGroupCriterionLabelResult) hash ^= AdGroupCriterionLabelResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdGroupCriterionResult) hash ^= AdGroupCriterionResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdGroupExtensionSettingResult) hash ^= AdGroupExtensionSettingResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdGroupFeedResult) hash ^= AdGroupFeedResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdGroupLabelResult) hash ^= AdGroupLabelResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdGroupResult) hash ^= AdGroupResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AdParameterResult) hash ^= AdParameterResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.AssetResult) hash ^= AssetResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.BiddingStrategyResult) hash ^= BiddingStrategyResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignBidModifierResult) hash ^= CampaignBidModifierResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignBudgetResult) hash ^= CampaignBudgetResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignCriterionResult) hash ^= CampaignCriterionResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignDraftResult) hash ^= CampaignDraftResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignExperimentResult) hash ^= CampaignExperimentResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignExtensionSettingResult) hash ^= CampaignExtensionSettingResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignFeedResult) hash ^= CampaignFeedResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignLabelResult) hash ^= CampaignLabelResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignResult) hash ^= CampaignResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CampaignSharedSetResult) hash ^= CampaignSharedSetResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.ConversionActionResult) hash ^= ConversionActionResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CustomerExtensionSettingResult) hash ^= CustomerExtensionSettingResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CustomerFeedResult) hash ^= CustomerFeedResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CustomerLabelResult) hash ^= CustomerLabelResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CustomerNegativeCriterionResult) hash ^= CustomerNegativeCriterionResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.CustomerResult) hash ^= CustomerResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.ExtensionFeedItemResult) hash ^= ExtensionFeedItemResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.FeedItemResult) hash ^= FeedItemResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.FeedItemTargetResult) hash ^= FeedItemTargetResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.FeedMappingResult) hash ^= FeedMappingResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.FeedResult) hash ^= FeedResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.LabelResult) hash ^= LabelResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.MediaFileResult) hash ^= MediaFileResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.RemarketingActionResult) hash ^= RemarketingActionResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.SharedCriterionResult) hash ^= SharedCriterionResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.SharedSetResult) hash ^= SharedSetResult.GetHashCode(); + if (responseCase_ == ResponseOneofCase.UserListResult) hash ^= UserListResult.GetHashCode(); + hash ^= (int) responseCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (responseCase_ == ResponseOneofCase.AdGroupAdResult) { + output.WriteRawTag(10); + output.WriteMessage(AdGroupAdResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupBidModifierResult) { + output.WriteRawTag(18); + output.WriteMessage(AdGroupBidModifierResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupCriterionResult) { + output.WriteRawTag(26); + output.WriteMessage(AdGroupCriterionResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupResult) { + output.WriteRawTag(42); + output.WriteMessage(AdGroupResult); + } + if (responseCase_ == ResponseOneofCase.BiddingStrategyResult) { + output.WriteRawTag(50); + output.WriteMessage(BiddingStrategyResult); + } + if (responseCase_ == ResponseOneofCase.CampaignBidModifierResult) { + output.WriteRawTag(58); + output.WriteMessage(CampaignBidModifierResult); + } + if (responseCase_ == ResponseOneofCase.CampaignBudgetResult) { + output.WriteRawTag(66); + output.WriteMessage(CampaignBudgetResult); + } + if (responseCase_ == ResponseOneofCase.CampaignResult) { + output.WriteRawTag(82); + output.WriteMessage(CampaignResult); + } + if (responseCase_ == ResponseOneofCase.CampaignSharedSetResult) { + output.WriteRawTag(90); + output.WriteMessage(CampaignSharedSetResult); + } + if (responseCase_ == ResponseOneofCase.ConversionActionResult) { + output.WriteRawTag(98); + output.WriteMessage(ConversionActionResult); + } + if (responseCase_ == ResponseOneofCase.CampaignCriterionResult) { + output.WriteRawTag(106); + output.WriteMessage(CampaignCriterionResult); + } + if (responseCase_ == ResponseOneofCase.SharedCriterionResult) { + output.WriteRawTag(114); + output.WriteMessage(SharedCriterionResult); + } + if (responseCase_ == ResponseOneofCase.SharedSetResult) { + output.WriteRawTag(122); + output.WriteMessage(SharedSetResult); + } + if (responseCase_ == ResponseOneofCase.UserListResult) { + output.WriteRawTag(130, 1); + output.WriteMessage(UserListResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupAdLabelResult) { + output.WriteRawTag(138, 1); + output.WriteMessage(AdGroupAdLabelResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupCriterionLabelResult) { + output.WriteRawTag(146, 1); + output.WriteMessage(AdGroupCriterionLabelResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupExtensionSettingResult) { + output.WriteRawTag(154, 1); + output.WriteMessage(AdGroupExtensionSettingResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupFeedResult) { + output.WriteRawTag(162, 1); + output.WriteMessage(AdGroupFeedResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupLabelResult) { + output.WriteRawTag(170, 1); + output.WriteMessage(AdGroupLabelResult); + } + if (responseCase_ == ResponseOneofCase.AdParameterResult) { + output.WriteRawTag(178, 1); + output.WriteMessage(AdParameterResult); + } + if (responseCase_ == ResponseOneofCase.AssetResult) { + output.WriteRawTag(186, 1); + output.WriteMessage(AssetResult); + } + if (responseCase_ == ResponseOneofCase.CampaignDraftResult) { + output.WriteRawTag(194, 1); + output.WriteMessage(CampaignDraftResult); + } + if (responseCase_ == ResponseOneofCase.CampaignExperimentResult) { + output.WriteRawTag(202, 1); + output.WriteMessage(CampaignExperimentResult); + } + if (responseCase_ == ResponseOneofCase.CampaignExtensionSettingResult) { + output.WriteRawTag(210, 1); + output.WriteMessage(CampaignExtensionSettingResult); + } + if (responseCase_ == ResponseOneofCase.CampaignFeedResult) { + output.WriteRawTag(218, 1); + output.WriteMessage(CampaignFeedResult); + } + if (responseCase_ == ResponseOneofCase.CampaignLabelResult) { + output.WriteRawTag(226, 1); + output.WriteMessage(CampaignLabelResult); + } + if (responseCase_ == ResponseOneofCase.CustomerExtensionSettingResult) { + output.WriteRawTag(242, 1); + output.WriteMessage(CustomerExtensionSettingResult); + } + if (responseCase_ == ResponseOneofCase.CustomerFeedResult) { + output.WriteRawTag(250, 1); + output.WriteMessage(CustomerFeedResult); + } + if (responseCase_ == ResponseOneofCase.CustomerLabelResult) { + output.WriteRawTag(130, 2); + output.WriteMessage(CustomerLabelResult); + } + if (responseCase_ == ResponseOneofCase.CustomerNegativeCriterionResult) { + output.WriteRawTag(146, 2); + output.WriteMessage(CustomerNegativeCriterionResult); + } + if (responseCase_ == ResponseOneofCase.CustomerResult) { + output.WriteRawTag(154, 2); + output.WriteMessage(CustomerResult); + } + if (responseCase_ == ResponseOneofCase.ExtensionFeedItemResult) { + output.WriteRawTag(162, 2); + output.WriteMessage(ExtensionFeedItemResult); + } + if (responseCase_ == ResponseOneofCase.FeedItemResult) { + output.WriteRawTag(170, 2); + output.WriteMessage(FeedItemResult); + } + if (responseCase_ == ResponseOneofCase.FeedItemTargetResult) { + output.WriteRawTag(178, 2); + output.WriteMessage(FeedItemTargetResult); + } + if (responseCase_ == ResponseOneofCase.FeedMappingResult) { + output.WriteRawTag(186, 2); + output.WriteMessage(FeedMappingResult); + } + if (responseCase_ == ResponseOneofCase.FeedResult) { + output.WriteRawTag(194, 2); + output.WriteMessage(FeedResult); + } + if (responseCase_ == ResponseOneofCase.LabelResult) { + output.WriteRawTag(202, 2); + output.WriteMessage(LabelResult); + } + if (responseCase_ == ResponseOneofCase.MediaFileResult) { + output.WriteRawTag(210, 2); + output.WriteMessage(MediaFileResult); + } + if (responseCase_ == ResponseOneofCase.RemarketingActionResult) { + output.WriteRawTag(218, 2); + output.WriteMessage(RemarketingActionResult); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (responseCase_ == ResponseOneofCase.AdGroupAdLabelResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupAdLabelResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupAdResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupAdResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupBidModifierResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupBidModifierResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupCriterionLabelResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupCriterionLabelResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupCriterionResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupCriterionResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupExtensionSettingResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupExtensionSettingResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupFeedResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupFeedResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupLabelResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdGroupLabelResult); + } + if (responseCase_ == ResponseOneofCase.AdGroupResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupResult); + } + if (responseCase_ == ResponseOneofCase.AdParameterResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AdParameterResult); + } + if (responseCase_ == ResponseOneofCase.AssetResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(AssetResult); + } + if (responseCase_ == ResponseOneofCase.BiddingStrategyResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(BiddingStrategyResult); + } + if (responseCase_ == ResponseOneofCase.CampaignBidModifierResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignBidModifierResult); + } + if (responseCase_ == ResponseOneofCase.CampaignBudgetResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignBudgetResult); + } + if (responseCase_ == ResponseOneofCase.CampaignCriterionResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignCriterionResult); + } + if (responseCase_ == ResponseOneofCase.CampaignDraftResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignDraftResult); + } + if (responseCase_ == ResponseOneofCase.CampaignExperimentResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignExperimentResult); + } + if (responseCase_ == ResponseOneofCase.CampaignExtensionSettingResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignExtensionSettingResult); + } + if (responseCase_ == ResponseOneofCase.CampaignFeedResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignFeedResult); + } + if (responseCase_ == ResponseOneofCase.CampaignLabelResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CampaignLabelResult); + } + if (responseCase_ == ResponseOneofCase.CampaignResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignResult); + } + if (responseCase_ == ResponseOneofCase.CampaignSharedSetResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignSharedSetResult); + } + if (responseCase_ == ResponseOneofCase.ConversionActionResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ConversionActionResult); + } + if (responseCase_ == ResponseOneofCase.CustomerExtensionSettingResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerExtensionSettingResult); + } + if (responseCase_ == ResponseOneofCase.CustomerFeedResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerFeedResult); + } + if (responseCase_ == ResponseOneofCase.CustomerLabelResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerLabelResult); + } + if (responseCase_ == ResponseOneofCase.CustomerNegativeCriterionResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerNegativeCriterionResult); + } + if (responseCase_ == ResponseOneofCase.CustomerResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(CustomerResult); + } + if (responseCase_ == ResponseOneofCase.ExtensionFeedItemResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(ExtensionFeedItemResult); + } + if (responseCase_ == ResponseOneofCase.FeedItemResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedItemResult); + } + if (responseCase_ == ResponseOneofCase.FeedItemTargetResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedItemTargetResult); + } + if (responseCase_ == ResponseOneofCase.FeedMappingResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedMappingResult); + } + if (responseCase_ == ResponseOneofCase.FeedResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(FeedResult); + } + if (responseCase_ == ResponseOneofCase.LabelResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(LabelResult); + } + if (responseCase_ == ResponseOneofCase.MediaFileResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(MediaFileResult); + } + if (responseCase_ == ResponseOneofCase.RemarketingActionResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(RemarketingActionResult); + } + if (responseCase_ == ResponseOneofCase.SharedCriterionResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(SharedCriterionResult); + } + if (responseCase_ == ResponseOneofCase.SharedSetResult) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(SharedSetResult); + } + if (responseCase_ == ResponseOneofCase.UserListResult) { + size += 2 + pb::CodedOutputStream.ComputeMessageSize(UserListResult); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateOperationResponse other) { + if (other == null) { + return; + } + switch (other.ResponseCase) { + case ResponseOneofCase.AdGroupAdLabelResult: + if (AdGroupAdLabelResult == null) { + AdGroupAdLabelResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelResult(); + } + AdGroupAdLabelResult.MergeFrom(other.AdGroupAdLabelResult); + break; + case ResponseOneofCase.AdGroupAdResult: + if (AdGroupAdResult == null) { + AdGroupAdResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdResult(); + } + AdGroupAdResult.MergeFrom(other.AdGroupAdResult); + break; + case ResponseOneofCase.AdGroupBidModifierResult: + if (AdGroupBidModifierResult == null) { + AdGroupBidModifierResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifierResult(); + } + AdGroupBidModifierResult.MergeFrom(other.AdGroupBidModifierResult); + break; + case ResponseOneofCase.AdGroupCriterionLabelResult: + if (AdGroupCriterionLabelResult == null) { + AdGroupCriterionLabelResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelResult(); + } + AdGroupCriterionLabelResult.MergeFrom(other.AdGroupCriterionLabelResult); + break; + case ResponseOneofCase.AdGroupCriterionResult: + if (AdGroupCriterionResult == null) { + AdGroupCriterionResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionResult(); + } + AdGroupCriterionResult.MergeFrom(other.AdGroupCriterionResult); + break; + case ResponseOneofCase.AdGroupExtensionSettingResult: + if (AdGroupExtensionSettingResult == null) { + AdGroupExtensionSettingResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingResult(); + } + AdGroupExtensionSettingResult.MergeFrom(other.AdGroupExtensionSettingResult); + break; + case ResponseOneofCase.AdGroupFeedResult: + if (AdGroupFeedResult == null) { + AdGroupFeedResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedResult(); + } + AdGroupFeedResult.MergeFrom(other.AdGroupFeedResult); + break; + case ResponseOneofCase.AdGroupLabelResult: + if (AdGroupLabelResult == null) { + AdGroupLabelResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelResult(); + } + AdGroupLabelResult.MergeFrom(other.AdGroupLabelResult); + break; + case ResponseOneofCase.AdGroupResult: + if (AdGroupResult == null) { + AdGroupResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupResult(); + } + AdGroupResult.MergeFrom(other.AdGroupResult); + break; + case ResponseOneofCase.AdParameterResult: + if (AdParameterResult == null) { + AdParameterResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAdParameterResult(); + } + AdParameterResult.MergeFrom(other.AdParameterResult); + break; + case ResponseOneofCase.AssetResult: + if (AssetResult == null) { + AssetResult = new global::Google.Ads.GoogleAds.V3.Services.MutateAssetResult(); + } + AssetResult.MergeFrom(other.AssetResult); + break; + case ResponseOneofCase.BiddingStrategyResult: + if (BiddingStrategyResult == null) { + BiddingStrategyResult = new global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategyResult(); + } + BiddingStrategyResult.MergeFrom(other.BiddingStrategyResult); + break; + case ResponseOneofCase.CampaignBidModifierResult: + if (CampaignBidModifierResult == null) { + CampaignBidModifierResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifierResult(); + } + CampaignBidModifierResult.MergeFrom(other.CampaignBidModifierResult); + break; + case ResponseOneofCase.CampaignBudgetResult: + if (CampaignBudgetResult == null) { + CampaignBudgetResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetResult(); + } + CampaignBudgetResult.MergeFrom(other.CampaignBudgetResult); + break; + case ResponseOneofCase.CampaignCriterionResult: + if (CampaignCriterionResult == null) { + CampaignCriterionResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriterionResult(); + } + CampaignCriterionResult.MergeFrom(other.CampaignCriterionResult); + break; + case ResponseOneofCase.CampaignDraftResult: + if (CampaignDraftResult == null) { + CampaignDraftResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftResult(); + } + CampaignDraftResult.MergeFrom(other.CampaignDraftResult); + break; + case ResponseOneofCase.CampaignExperimentResult: + if (CampaignExperimentResult == null) { + CampaignExperimentResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentResult(); + } + CampaignExperimentResult.MergeFrom(other.CampaignExperimentResult); + break; + case ResponseOneofCase.CampaignExtensionSettingResult: + if (CampaignExtensionSettingResult == null) { + CampaignExtensionSettingResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingResult(); + } + CampaignExtensionSettingResult.MergeFrom(other.CampaignExtensionSettingResult); + break; + case ResponseOneofCase.CampaignFeedResult: + if (CampaignFeedResult == null) { + CampaignFeedResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedResult(); + } + CampaignFeedResult.MergeFrom(other.CampaignFeedResult); + break; + case ResponseOneofCase.CampaignLabelResult: + if (CampaignLabelResult == null) { + CampaignLabelResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelResult(); + } + CampaignLabelResult.MergeFrom(other.CampaignLabelResult); + break; + case ResponseOneofCase.CampaignResult: + if (CampaignResult == null) { + CampaignResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignResult(); + } + CampaignResult.MergeFrom(other.CampaignResult); + break; + case ResponseOneofCase.CampaignSharedSetResult: + if (CampaignSharedSetResult == null) { + CampaignSharedSetResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetResult(); + } + CampaignSharedSetResult.MergeFrom(other.CampaignSharedSetResult); + break; + case ResponseOneofCase.ConversionActionResult: + if (ConversionActionResult == null) { + ConversionActionResult = new global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionResult(); + } + ConversionActionResult.MergeFrom(other.ConversionActionResult); + break; + case ResponseOneofCase.CustomerExtensionSettingResult: + if (CustomerExtensionSettingResult == null) { + CustomerExtensionSettingResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingResult(); + } + CustomerExtensionSettingResult.MergeFrom(other.CustomerExtensionSettingResult); + break; + case ResponseOneofCase.CustomerFeedResult: + if (CustomerFeedResult == null) { + CustomerFeedResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedResult(); + } + CustomerFeedResult.MergeFrom(other.CustomerFeedResult); + break; + case ResponseOneofCase.CustomerLabelResult: + if (CustomerLabelResult == null) { + CustomerLabelResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelResult(); + } + CustomerLabelResult.MergeFrom(other.CustomerLabelResult); + break; + case ResponseOneofCase.CustomerNegativeCriterionResult: + if (CustomerNegativeCriterionResult == null) { + CustomerNegativeCriterionResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResult(); + } + CustomerNegativeCriterionResult.MergeFrom(other.CustomerNegativeCriterionResult); + break; + case ResponseOneofCase.CustomerResult: + if (CustomerResult == null) { + CustomerResult = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult(); + } + CustomerResult.MergeFrom(other.CustomerResult); + break; + case ResponseOneofCase.ExtensionFeedItemResult: + if (ExtensionFeedItemResult == null) { + ExtensionFeedItemResult = new global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemResult(); + } + ExtensionFeedItemResult.MergeFrom(other.ExtensionFeedItemResult); + break; + case ResponseOneofCase.FeedItemResult: + if (FeedItemResult == null) { + FeedItemResult = new global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemResult(); + } + FeedItemResult.MergeFrom(other.FeedItemResult); + break; + case ResponseOneofCase.FeedItemTargetResult: + if (FeedItemTargetResult == null) { + FeedItemTargetResult = new global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetResult(); + } + FeedItemTargetResult.MergeFrom(other.FeedItemTargetResult); + break; + case ResponseOneofCase.FeedMappingResult: + if (FeedMappingResult == null) { + FeedMappingResult = new global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingResult(); + } + FeedMappingResult.MergeFrom(other.FeedMappingResult); + break; + case ResponseOneofCase.FeedResult: + if (FeedResult == null) { + FeedResult = new global::Google.Ads.GoogleAds.V3.Services.MutateFeedResult(); + } + FeedResult.MergeFrom(other.FeedResult); + break; + case ResponseOneofCase.LabelResult: + if (LabelResult == null) { + LabelResult = new global::Google.Ads.GoogleAds.V3.Services.MutateLabelResult(); + } + LabelResult.MergeFrom(other.LabelResult); + break; + case ResponseOneofCase.MediaFileResult: + if (MediaFileResult == null) { + MediaFileResult = new global::Google.Ads.GoogleAds.V3.Services.MutateMediaFileResult(); + } + MediaFileResult.MergeFrom(other.MediaFileResult); + break; + case ResponseOneofCase.RemarketingActionResult: + if (RemarketingActionResult == null) { + RemarketingActionResult = new global::Google.Ads.GoogleAds.V3.Services.MutateRemarketingActionResult(); + } + RemarketingActionResult.MergeFrom(other.RemarketingActionResult); + break; + case ResponseOneofCase.SharedCriterionResult: + if (SharedCriterionResult == null) { + SharedCriterionResult = new global::Google.Ads.GoogleAds.V3.Services.MutateSharedCriterionResult(); + } + SharedCriterionResult.MergeFrom(other.SharedCriterionResult); + break; + case ResponseOneofCase.SharedSetResult: + if (SharedSetResult == null) { + SharedSetResult = new global::Google.Ads.GoogleAds.V3.Services.MutateSharedSetResult(); + } + SharedSetResult.MergeFrom(other.SharedSetResult); + break; + case ResponseOneofCase.UserListResult: + if (UserListResult == null) { + UserListResult = new global::Google.Ads.GoogleAds.V3.Services.MutateUserListResult(); + } + UserListResult.MergeFrom(other.UserListResult); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdResult(); + if (responseCase_ == ResponseOneofCase.AdGroupAdResult) { + subBuilder.MergeFrom(AdGroupAdResult); + } + input.ReadMessage(subBuilder); + AdGroupAdResult = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifierResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupBidModifierResult(); + if (responseCase_ == ResponseOneofCase.AdGroupBidModifierResult) { + subBuilder.MergeFrom(AdGroupBidModifierResult); + } + input.ReadMessage(subBuilder); + AdGroupBidModifierResult = subBuilder; + break; + } + case 26: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionResult(); + if (responseCase_ == ResponseOneofCase.AdGroupCriterionResult) { + subBuilder.MergeFrom(AdGroupCriterionResult); + } + input.ReadMessage(subBuilder); + AdGroupCriterionResult = subBuilder; + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupResult(); + if (responseCase_ == ResponseOneofCase.AdGroupResult) { + subBuilder.MergeFrom(AdGroupResult); + } + input.ReadMessage(subBuilder); + AdGroupResult = subBuilder; + break; + } + case 50: { + global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategyResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateBiddingStrategyResult(); + if (responseCase_ == ResponseOneofCase.BiddingStrategyResult) { + subBuilder.MergeFrom(BiddingStrategyResult); + } + input.ReadMessage(subBuilder); + BiddingStrategyResult = subBuilder; + break; + } + case 58: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifierResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBidModifierResult(); + if (responseCase_ == ResponseOneofCase.CampaignBidModifierResult) { + subBuilder.MergeFrom(CampaignBidModifierResult); + } + input.ReadMessage(subBuilder); + CampaignBidModifierResult = subBuilder; + break; + } + case 66: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignBudgetResult(); + if (responseCase_ == ResponseOneofCase.CampaignBudgetResult) { + subBuilder.MergeFrom(CampaignBudgetResult); + } + input.ReadMessage(subBuilder); + CampaignBudgetResult = subBuilder; + break; + } + case 82: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignResult(); + if (responseCase_ == ResponseOneofCase.CampaignResult) { + subBuilder.MergeFrom(CampaignResult); + } + input.ReadMessage(subBuilder); + CampaignResult = subBuilder; + break; + } + case 90: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignSharedSetResult(); + if (responseCase_ == ResponseOneofCase.CampaignSharedSetResult) { + subBuilder.MergeFrom(CampaignSharedSetResult); + } + input.ReadMessage(subBuilder); + CampaignSharedSetResult = subBuilder; + break; + } + case 98: { + global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateConversionActionResult(); + if (responseCase_ == ResponseOneofCase.ConversionActionResult) { + subBuilder.MergeFrom(ConversionActionResult); + } + input.ReadMessage(subBuilder); + ConversionActionResult = subBuilder; + break; + } + case 106: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriterionResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignCriterionResult(); + if (responseCase_ == ResponseOneofCase.CampaignCriterionResult) { + subBuilder.MergeFrom(CampaignCriterionResult); + } + input.ReadMessage(subBuilder); + CampaignCriterionResult = subBuilder; + break; + } + case 114: { + global::Google.Ads.GoogleAds.V3.Services.MutateSharedCriterionResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateSharedCriterionResult(); + if (responseCase_ == ResponseOneofCase.SharedCriterionResult) { + subBuilder.MergeFrom(SharedCriterionResult); + } + input.ReadMessage(subBuilder); + SharedCriterionResult = subBuilder; + break; + } + case 122: { + global::Google.Ads.GoogleAds.V3.Services.MutateSharedSetResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateSharedSetResult(); + if (responseCase_ == ResponseOneofCase.SharedSetResult) { + subBuilder.MergeFrom(SharedSetResult); + } + input.ReadMessage(subBuilder); + SharedSetResult = subBuilder; + break; + } + case 130: { + global::Google.Ads.GoogleAds.V3.Services.MutateUserListResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateUserListResult(); + if (responseCase_ == ResponseOneofCase.UserListResult) { + subBuilder.MergeFrom(UserListResult); + } + input.ReadMessage(subBuilder); + UserListResult = subBuilder; + break; + } + case 138: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupAdLabelResult(); + if (responseCase_ == ResponseOneofCase.AdGroupAdLabelResult) { + subBuilder.MergeFrom(AdGroupAdLabelResult); + } + input.ReadMessage(subBuilder); + AdGroupAdLabelResult = subBuilder; + break; + } + case 146: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupCriterionLabelResult(); + if (responseCase_ == ResponseOneofCase.AdGroupCriterionLabelResult) { + subBuilder.MergeFrom(AdGroupCriterionLabelResult); + } + input.ReadMessage(subBuilder); + AdGroupCriterionLabelResult = subBuilder; + break; + } + case 154: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupExtensionSettingResult(); + if (responseCase_ == ResponseOneofCase.AdGroupExtensionSettingResult) { + subBuilder.MergeFrom(AdGroupExtensionSettingResult); + } + input.ReadMessage(subBuilder); + AdGroupExtensionSettingResult = subBuilder; + break; + } + case 162: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupFeedResult(); + if (responseCase_ == ResponseOneofCase.AdGroupFeedResult) { + subBuilder.MergeFrom(AdGroupFeedResult); + } + input.ReadMessage(subBuilder); + AdGroupFeedResult = subBuilder; + break; + } + case 170: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdGroupLabelResult(); + if (responseCase_ == ResponseOneofCase.AdGroupLabelResult) { + subBuilder.MergeFrom(AdGroupLabelResult); + } + input.ReadMessage(subBuilder); + AdGroupLabelResult = subBuilder; + break; + } + case 178: { + global::Google.Ads.GoogleAds.V3.Services.MutateAdParameterResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAdParameterResult(); + if (responseCase_ == ResponseOneofCase.AdParameterResult) { + subBuilder.MergeFrom(AdParameterResult); + } + input.ReadMessage(subBuilder); + AdParameterResult = subBuilder; + break; + } + case 186: { + global::Google.Ads.GoogleAds.V3.Services.MutateAssetResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateAssetResult(); + if (responseCase_ == ResponseOneofCase.AssetResult) { + subBuilder.MergeFrom(AssetResult); + } + input.ReadMessage(subBuilder); + AssetResult = subBuilder; + break; + } + case 194: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignDraftResult(); + if (responseCase_ == ResponseOneofCase.CampaignDraftResult) { + subBuilder.MergeFrom(CampaignDraftResult); + } + input.ReadMessage(subBuilder); + CampaignDraftResult = subBuilder; + break; + } + case 202: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExperimentResult(); + if (responseCase_ == ResponseOneofCase.CampaignExperimentResult) { + subBuilder.MergeFrom(CampaignExperimentResult); + } + input.ReadMessage(subBuilder); + CampaignExperimentResult = subBuilder; + break; + } + case 210: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignExtensionSettingResult(); + if (responseCase_ == ResponseOneofCase.CampaignExtensionSettingResult) { + subBuilder.MergeFrom(CampaignExtensionSettingResult); + } + input.ReadMessage(subBuilder); + CampaignExtensionSettingResult = subBuilder; + break; + } + case 218: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignFeedResult(); + if (responseCase_ == ResponseOneofCase.CampaignFeedResult) { + subBuilder.MergeFrom(CampaignFeedResult); + } + input.ReadMessage(subBuilder); + CampaignFeedResult = subBuilder; + break; + } + case 226: { + global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCampaignLabelResult(); + if (responseCase_ == ResponseOneofCase.CampaignLabelResult) { + subBuilder.MergeFrom(CampaignLabelResult); + } + input.ReadMessage(subBuilder); + CampaignLabelResult = subBuilder; + break; + } + case 242: { + global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerExtensionSettingResult(); + if (responseCase_ == ResponseOneofCase.CustomerExtensionSettingResult) { + subBuilder.MergeFrom(CustomerExtensionSettingResult); + } + input.ReadMessage(subBuilder); + CustomerExtensionSettingResult = subBuilder; + break; + } + case 250: { + global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerFeedResult(); + if (responseCase_ == ResponseOneofCase.CustomerFeedResult) { + subBuilder.MergeFrom(CustomerFeedResult); + } + input.ReadMessage(subBuilder); + CustomerFeedResult = subBuilder; + break; + } + case 258: { + global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerLabelResult(); + if (responseCase_ == ResponseOneofCase.CustomerLabelResult) { + subBuilder.MergeFrom(CustomerLabelResult); + } + input.ReadMessage(subBuilder); + CustomerLabelResult = subBuilder; + break; + } + case 274: { + global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerNegativeCriteriaResult(); + if (responseCase_ == ResponseOneofCase.CustomerNegativeCriterionResult) { + subBuilder.MergeFrom(CustomerNegativeCriterionResult); + } + input.ReadMessage(subBuilder); + CustomerNegativeCriterionResult = subBuilder; + break; + } + case 282: { + global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateCustomerResult(); + if (responseCase_ == ResponseOneofCase.CustomerResult) { + subBuilder.MergeFrom(CustomerResult); + } + input.ReadMessage(subBuilder); + CustomerResult = subBuilder; + break; + } + case 290: { + global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateExtensionFeedItemResult(); + if (responseCase_ == ResponseOneofCase.ExtensionFeedItemResult) { + subBuilder.MergeFrom(ExtensionFeedItemResult); + } + input.ReadMessage(subBuilder); + ExtensionFeedItemResult = subBuilder; + break; + } + case 298: { + global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemResult(); + if (responseCase_ == ResponseOneofCase.FeedItemResult) { + subBuilder.MergeFrom(FeedItemResult); + } + input.ReadMessage(subBuilder); + FeedItemResult = subBuilder; + break; + } + case 306: { + global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateFeedItemTargetResult(); + if (responseCase_ == ResponseOneofCase.FeedItemTargetResult) { + subBuilder.MergeFrom(FeedItemTargetResult); + } + input.ReadMessage(subBuilder); + FeedItemTargetResult = subBuilder; + break; + } + case 314: { + global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateFeedMappingResult(); + if (responseCase_ == ResponseOneofCase.FeedMappingResult) { + subBuilder.MergeFrom(FeedMappingResult); + } + input.ReadMessage(subBuilder); + FeedMappingResult = subBuilder; + break; + } + case 322: { + global::Google.Ads.GoogleAds.V3.Services.MutateFeedResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateFeedResult(); + if (responseCase_ == ResponseOneofCase.FeedResult) { + subBuilder.MergeFrom(FeedResult); + } + input.ReadMessage(subBuilder); + FeedResult = subBuilder; + break; + } + case 330: { + global::Google.Ads.GoogleAds.V3.Services.MutateLabelResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateLabelResult(); + if (responseCase_ == ResponseOneofCase.LabelResult) { + subBuilder.MergeFrom(LabelResult); + } + input.ReadMessage(subBuilder); + LabelResult = subBuilder; + break; + } + case 338: { + global::Google.Ads.GoogleAds.V3.Services.MutateMediaFileResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateMediaFileResult(); + if (responseCase_ == ResponseOneofCase.MediaFileResult) { + subBuilder.MergeFrom(MediaFileResult); + } + input.ReadMessage(subBuilder); + MediaFileResult = subBuilder; + break; + } + case 346: { + global::Google.Ads.GoogleAds.V3.Services.MutateRemarketingActionResult subBuilder = new global::Google.Ads.GoogleAds.V3.Services.MutateRemarketingActionResult(); + if (responseCase_ == ResponseOneofCase.RemarketingActionResult) { + subBuilder.MergeFrom(RemarketingActionResult); + } + input.ReadMessage(subBuilder); + RemarketingActionResult = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GoogleAdsServiceClient.cs b/src/V3/Stubs/GoogleAdsServiceClient.cs new file mode 100644 index 000000000..de261c2d6 --- /dev/null +++ b/src/V3/Stubs/GoogleAdsServiceClient.cs @@ -0,0 +1,1515 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagve = Google.Ads.GoogleAds.V3.Enums; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class GoogleAdsServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static GoogleAdsServiceSettings GetDefault() => new GoogleAdsServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public GoogleAdsServiceSettings() { } + + private GoogleAdsServiceSettings(GoogleAdsServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + SearchSettings = existing.SearchSettings; + SearchStreamSettings = existing.SearchStreamSettings; + MutateSettings = existing.MutateSettings; + OnCopy(existing); + } + + partial void OnCopy(GoogleAdsServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// GoogleAdsServiceClient.Search and GoogleAdsServiceClient.SearchAsync. + /// + /// + /// The default GoogleAdsServiceClient.Search and + /// GoogleAdsServiceClient.SearchAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings SearchSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for calls to GoogleAdsServiceClient.SearchStream. + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings SearchStreamSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000))); + + /// + /// for synchronous and asynchronous calls to + /// GoogleAdsServiceClient.Mutate and GoogleAdsServiceClient.MutateAsync. + /// + /// + /// The default GoogleAdsServiceClient.Mutate and + /// GoogleAdsServiceClient.MutateAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public GoogleAdsServiceSettings Clone() => new GoogleAdsServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class GoogleAdsServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public GoogleAdsServiceSettings Settings { get; set; } + + /// + public override GoogleAdsServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return GoogleAdsServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return GoogleAdsServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => GoogleAdsServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => GoogleAdsServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => GoogleAdsServiceClient.ChannelPool; + } + + /// + /// GoogleAdsService client wrapper, for convenient use. + /// + public abstract partial class GoogleAdsServiceClient + { + /// + /// The default endpoint for the GoogleAdsService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default GoogleAdsService scopes. + /// + /// + /// The default GoogleAdsService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GoogleAdsServiceClient client = await GoogleAdsServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GoogleAdsServiceClient.DefaultEndpoint.Host, GoogleAdsServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GoogleAdsServiceClient client = GoogleAdsServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, GoogleAdsServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GoogleAdsServiceClient client = GoogleAdsServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GoogleAdsServiceClient.DefaultEndpoint.Host, GoogleAdsServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GoogleAdsServiceClient client = GoogleAdsServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static GoogleAdsServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, GoogleAdsServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GoogleAdsServiceClient Create(grpccore::Channel channel, GoogleAdsServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GoogleAdsServiceClient Create(grpccore::CallInvoker callInvoker, GoogleAdsServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + GoogleAdsService.GoogleAdsServiceClient grpcClient = new GoogleAdsService.GoogleAdsServiceClient(callInvoker); + return new GoogleAdsServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC GoogleAdsService client. + /// + public virtual GoogleAdsService.GoogleAdsServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns all rows that match the search query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public virtual gax::PagedAsyncEnumerable SearchAsync( + SearchGoogleAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns all rows that match the search query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public virtual gax::PagedEnumerable Search( + SearchGoogleAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns all rows that match the search stream query. + /// + /// + /// Required. The ID of the customer being queried. + /// + /// + /// Required. The query string. + /// + /// + /// Determines whether a summary row will be returned. By default, summary row + /// is not returned. If requested, the summary row will be sent in a response + /// by itself after all other query results are returned. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The server stream. + /// + public virtual SearchStreamStream SearchStream( + string customerId, + string query, + gagve::SummaryRowSettingEnum.Types.SummaryRowSetting? summaryRowSetting, + gaxgrpc::CallSettings callSettings = null) => SearchStream( + new SearchGoogleAdsStreamRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Query = gax::GaxPreconditions.CheckNotNullOrEmpty(query, nameof(query)), + SummaryRowSetting = summaryRowSetting ?? gagve::SummaryRowSettingEnum.Types.SummaryRowSetting.Unspecified, // Optional + }, + callSettings); + + /// + /// Returns all rows that match the search stream query. + /// + /// + /// Required. The ID of the customer being queried. + /// + /// + /// Required. The query string. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The server stream. + /// + public virtual SearchStreamStream SearchStream( + string customerId, + string query, + gaxgrpc::CallSettings callSettings = null) => SearchStream( + new SearchGoogleAdsStreamRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Query = gax::GaxPreconditions.CheckNotNullOrEmpty(query, nameof(query)), + }, + callSettings); + + /// + /// Returns all rows that match the search stream query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The server stream. + /// + public virtual SearchStreamStream SearchStream( + SearchGoogleAdsStreamRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Server streaming methods for SearchStream. + /// + public abstract partial class SearchStreamStream : gaxgrpc::ServerStreamingBase + { + } + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// Required. The ID of the customer whose resources are being modified. + /// + /// + /// Required. The list of operations to perform on individual resources. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAsync( + string customerId, + scg::IEnumerable mutateOperations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateAsync( + new MutateGoogleAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + MutateOperations = { gax::GaxPreconditions.CheckNotNull(mutateOperations, nameof(mutateOperations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// Required. The ID of the customer whose resources are being modified. + /// + /// + /// Required. The list of operations to perform on individual resources. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAsync( + string customerId, + scg::IEnumerable mutateOperations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateAsync( + customerId, + mutateOperations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// Required. The ID of the customer whose resources are being modified. + /// + /// + /// Required. The list of operations to perform on individual resources. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateGoogleAdsResponse Mutate( + string customerId, + scg::IEnumerable mutateOperations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => Mutate( + new MutateGoogleAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + MutateOperations = { gax::GaxPreconditions.CheckNotNull(mutateOperations, nameof(mutateOperations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// Required. The ID of the customer whose resources are being modified. + /// + /// + /// Required. The list of operations to perform on individual resources. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAsync( + string customerId, + scg::IEnumerable mutateOperations, + gaxgrpc::CallSettings callSettings = null) => MutateAsync( + new MutateGoogleAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + MutateOperations = { gax::GaxPreconditions.CheckNotNull(mutateOperations, nameof(mutateOperations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// Required. The ID of the customer whose resources are being modified. + /// + /// + /// Required. The list of operations to perform on individual resources. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAsync( + string customerId, + scg::IEnumerable mutateOperations, + st::CancellationToken cancellationToken) => MutateAsync( + customerId, + mutateOperations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// Required. The ID of the customer whose resources are being modified. + /// + /// + /// Required. The list of operations to perform on individual resources. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateGoogleAdsResponse Mutate( + string customerId, + scg::IEnumerable mutateOperations, + gaxgrpc::CallSettings callSettings = null) => Mutate( + new MutateGoogleAdsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + MutateOperations = { gax::GaxPreconditions.CheckNotNull(mutateOperations, nameof(mutateOperations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAsync( + MutateGoogleAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateAsync( + MutateGoogleAdsRequest request, + st::CancellationToken cancellationToken) => MutateAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateGoogleAdsResponse Mutate( + MutateGoogleAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// GoogleAdsService client wrapper implementation, for convenient use. + /// + public sealed partial class GoogleAdsServiceClientImpl : GoogleAdsServiceClient + { + private readonly gaxgrpc::ApiCall _callSearch; + private readonly gaxgrpc::ApiServerStreamingCall _callSearchStream; + private readonly gaxgrpc::ApiCall _callMutate; + + /// + /// Constructs a client wrapper for the GoogleAdsService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public GoogleAdsServiceClientImpl(GoogleAdsService.GoogleAdsServiceClient grpcClient, GoogleAdsServiceSettings settings) + { + GrpcClient = grpcClient; + GoogleAdsServiceSettings effectiveSettings = settings ?? GoogleAdsServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callSearch = clientHelper.BuildApiCall( + GrpcClient.SearchAsync, GrpcClient.Search, effectiveSettings.SearchSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callSearchStream = clientHelper.BuildApiCall( + GrpcClient.SearchStream, effectiveSettings.SearchStreamSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callMutate = clientHelper.BuildApiCall( + GrpcClient.MutateAsync, GrpcClient.Mutate, effectiveSettings.MutateSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callSearch); + Modify_SearchApiCall(ref _callSearch); + Modify_ApiCall(ref _callSearchStream); + Modify_SearchStreamApiCall(ref _callSearchStream); + Modify_ApiCall(ref _callMutate); + Modify_MutateApiCall(ref _callMutate); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + partial void Modify_ApiCall(ref gaxgrpc::ApiServerStreamingCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_SearchApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_SearchStreamApiCall(ref gaxgrpc::ApiServerStreamingCall call); + partial void Modify_MutateApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(GoogleAdsService.GoogleAdsServiceClient grpcClient, GoogleAdsServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC GoogleAdsService client. + /// + public override GoogleAdsService.GoogleAdsServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_SearchGoogleAdsRequest(ref SearchGoogleAdsRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_SearchGoogleAdsStreamRequest(ref SearchGoogleAdsStreamRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateGoogleAdsRequest(ref MutateGoogleAdsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns all rows that match the search query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable asynchronous sequence of resources. + /// + public override gax::PagedAsyncEnumerable SearchAsync( + SearchGoogleAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_SearchGoogleAdsRequest(ref request, ref callSettings); + return new gaxgrpc::GrpcPagedAsyncEnumerable(_callSearch, request, callSettings); + } + + /// + /// Returns all rows that match the search query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A pageable sequence of resources. + /// + public override gax::PagedEnumerable Search( + SearchGoogleAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_SearchGoogleAdsRequest(ref request, ref callSettings); + return new gaxgrpc::GrpcPagedEnumerable(_callSearch, request, callSettings); + } + + /// + /// Returns all rows that match the search stream query. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The server stream. + /// + public override SearchStreamStream SearchStream( + SearchGoogleAdsStreamRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_SearchGoogleAdsStreamRequest(ref request, ref callSettings); + return new SearchStreamStreamImpl(_callSearchStream.Call(request, callSettings)); + } + + internal sealed partial class SearchStreamStreamImpl : SearchStreamStream + { + /// + /// Construct the server-streaming method for SearchStream. + /// + /// The underlying gRPC server-streaming call. + internal SearchStreamStreamImpl(grpccore::AsyncServerStreamingCall call) + { + GrpcCall = call; + } + + /// + public override grpccore::AsyncServerStreamingCall GrpcCall { get; } + + /// + public override scg::IAsyncEnumerator ResponseStream => GrpcCall.ResponseStream; + } + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateAsync( + MutateGoogleAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateGoogleAdsRequest(ref request, ref callSettings); + return _callMutate.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateGoogleAdsResponse Mutate( + MutateGoogleAdsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateGoogleAdsRequest(ref request, ref callSettings); + return _callMutate.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + public partial class SearchGoogleAdsRequest : gaxgrpc::IPageRequest { } + public partial class SearchGoogleAdsResponse : gaxgrpc::IPageResponse + { + /// + /// Returns an enumerator that iterates through the resources in this response. + /// + public scg::IEnumerator GetEnumerator() => Results.GetEnumerator(); + + /// + sc::IEnumerator sc::IEnumerable.GetEnumerator() => GetEnumerator(); + } + + +} diff --git a/src/V3/Stubs/GoogleAdsServiceGrpc.cs b/src/V3/Stubs/GoogleAdsServiceGrpc.cs new file mode 100644 index 000000000..bffc74fab --- /dev/null +++ b/src/V3/Stubs/GoogleAdsServiceGrpc.cs @@ -0,0 +1,519 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/google_ads_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch data and metrics across resources. + /// + public static partial class GoogleAdsService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.GoogleAdsService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsStreamRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsStreamResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateGoogleAdsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateGoogleAdsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_Search = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "Search", + __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsRequest, + __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsResponse); + + static readonly grpc::Method __Method_SearchStream = new grpc::Method( + grpc::MethodType.ServerStreaming, + __ServiceName, + "SearchStream", + __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsStreamRequest, + __Marshaller_google_ads_googleads_v3_services_SearchGoogleAdsStreamResponse); + + static readonly grpc::Method __Method_Mutate = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "Mutate", + __Marshaller_google_ads_googleads_v3_services_MutateGoogleAdsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateGoogleAdsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.GoogleAdsServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of GoogleAdsService + public abstract partial class GoogleAdsServiceBase + { + /// + /// Returns all rows that match the search query. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task Search(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Returns all rows that match the search stream query. + /// + /// The request received from the client. + /// Used for sending responses back to the client. + /// The context of the server-side call handler being invoked. + /// A task indicating completion of the handler. + public virtual global::System.Threading.Tasks.Task SearchStream(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamRequest request, grpc::IServerStreamWriter responseStream, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task Mutate(global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for GoogleAdsService + public partial class GoogleAdsServiceClient : grpc::ClientBase + { + /// Creates a new client for GoogleAdsService + /// The channel to use to make remote calls. + public GoogleAdsServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for GoogleAdsService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public GoogleAdsServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected GoogleAdsServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected GoogleAdsServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns all rows that match the search query. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsResponse Search(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return Search(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all rows that match the search query. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsResponse Search(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_Search, null, options, request); + } + /// + /// Returns all rows that match the search query. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall SearchAsync(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return SearchAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all rows that match the search query. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall SearchAsync(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_Search, null, options, request); + } + /// + /// Returns all rows that match the search stream query. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncServerStreamingCall SearchStream(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return SearchStream(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all rows that match the search stream query. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncServerStreamingCall SearchStream(global::Google.Ads.GoogleAds.V3.Services.SearchGoogleAdsStreamRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncServerStreamingCall(__Method_SearchStream, null, options, request); + } + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsResponse Mutate(global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return Mutate(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsResponse Mutate(global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_Mutate, null, options, request); + } + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAsync(global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes resources. This method supports atomic + /// transactions with multiple types of resources. For example, you can + /// atomically create a campaign and a campaign budget, or perform up to + /// thousands of mutates atomically. + /// + /// This method is essentially a wrapper around a series of mutate methods. The + /// only features it offers over calling those methods directly are: + /// + /// - Atomic transactions + /// - Temp resource names (described below) + /// - Somewhat reduced latency over making a series of mutate calls + /// + /// Note: Only resources that support atomic transactions are included, so this + /// method can't replace all calls to individual services. + /// + /// ## Atomic Transaction Benefits + /// + /// Atomicity makes error handling much easier. If you're making a series of + /// changes and one fails, it can leave your account in an inconsistent state. + /// With atomicity, you either reach the desired state directly, or the request + /// fails and you can retry. + /// + /// ## Temp Resource Names + /// + /// Temp resource names are a special type of resource name used to create a + /// resource and reference that resource in the same request. For example, if a + /// campaign budget is created with `resource_name` equal to + /// `customers/123/campaignBudgets/-1`, that resource name can be reused in + /// the `Campaign.budget` field in the same request. That way, the two + /// resources are created and linked atomically. + /// + /// To create a temp resource name, put a negative number in the part of the + /// name that the server would normally allocate. + /// + /// Note: + /// + /// - Resources must be created with a temp name before the name can be reused. + /// For example, the previous CampaignBudget+Campaign example would fail if + /// the mutate order was reversed. + /// - Temp names are not remembered across requests. + /// - There's no limit to the number of temp names in a request. + /// - Each temp name must use a unique negative number, even if the resource + /// types differ. + /// + /// ## Latency + /// + /// It's important to group mutates by resource type or the request may time + /// out and fail. Latency is roughly equal to a series of calls to individual + /// mutate methods, where each change in resource type is a new call. For + /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while + /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateAsync(global::Google.Ads.GoogleAds.V3.Services.MutateGoogleAdsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_Mutate, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override GoogleAdsServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new GoogleAdsServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(GoogleAdsServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_Search, serviceImpl.Search) + .AddMethod(__Method_SearchStream, serviceImpl.SearchStream) + .AddMethod(__Method_Mutate, serviceImpl.Mutate).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, GoogleAdsServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_Search, serviceImpl.Search); + serviceBinder.AddMethod(__Method_SearchStream, serviceImpl.SearchStream); + serviceBinder.AddMethod(__Method_Mutate, serviceImpl.Mutate); + } + + } +} +#endregion diff --git a/src/V3/Stubs/GroupPlacementView.cs b/src/V3/Stubs/GroupPlacementView.cs new file mode 100644 index 000000000..b9f4f1565 --- /dev/null +++ b/src/V3/Stubs/GroupPlacementView.cs @@ -0,0 +1,346 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/group_placement_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/group_placement_view.proto + public static partial class GroupPlacementViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/group_placement_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GroupPlacementViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvZ3JvdXBfcGxh", + "Y2VtZW50X3ZpZXcucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlcxoyZ29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMvcGxhY2Vt", + "ZW50X3R5cGUucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJv", + "dG8aGWdvb2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1", + "Zi93cmFwcGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "byLWAwoSR3JvdXBQbGFjZW1lbnRWaWV3EkoKDXJlc291cmNlX25hbWUYASAB", + "KAlCM+BBBfpBLQorZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0dyb3VwUGxh", + "Y2VtZW50VmlldxI0CglwbGFjZW1lbnQYAiABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWVCA+BBAxI3CgxkaXNwbGF5X25hbWUYAyABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxI1Cgp0YXJnZXRfdXJs", + "GAQgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMSWwoO", + "cGxhY2VtZW50X3R5cGUYBSABKA4yPi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lbnVtcy5QbGFjZW1lbnRUeXBlRW51bS5QbGFjZW1lbnRUeXBlQgPgQQM6", + "cepBbgorZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0dyb3VwUGxhY2VtZW50", + "VmlldxI/Y3VzdG9tZXJzL3tjdXN0b21lcn0vZ3JvdXBQbGFjZW1lbnRWaWV3", + "cy97Z3JvdXBfcGxhY2VtZW50X3ZpZXd9QoQCCiVjb20uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMucmVzb3VyY2VzQhdHcm91cFBsYWNlbWVudFZpZXdQcm90", + "b1ABWkpnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fk", + "cy9nb29nbGVhZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNc", + "R29vZ2xlQWRzXFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVB", + "ZHM6OlYzOjpSZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.PlacementTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView), global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView.Parser, new[]{ "ResourceName", "Placement", "DisplayName", "TargetUrl", "PlacementType" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A group placement view. + /// + public sealed partial class GroupPlacementView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GroupPlacementView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GroupPlacementView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GroupPlacementView(GroupPlacementView other) : this() { + resourceName_ = other.resourceName_; + Placement = other.Placement; + DisplayName = other.DisplayName; + TargetUrl = other.TargetUrl; + placementType_ = other.placementType_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GroupPlacementView Clone() { + return new GroupPlacementView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the group placement view. + /// Group placement view resource names have the form: + /// + /// `customers/{customer_id}/groupPlacementViews/{ad_group_id}~{base64_placement}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "placement" field. + public const int PlacementFieldNumber = 2; + private static readonly pb::FieldCodec _single_placement_codec = pb::FieldCodec.ForClassWrapper(18); + private string placement_; + /// + /// Output only. The automatic placement string at group level, e. g. web domain, mobile + /// app ID, or a YouTube channel ID. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Placement { + get { return placement_; } + set { + placement_ = value; + } + } + + + /// Field number for the "display_name" field. + public const int DisplayNameFieldNumber = 3; + private static readonly pb::FieldCodec _single_displayName_codec = pb::FieldCodec.ForClassWrapper(26); + private string displayName_; + /// + /// Output only. Domain name for websites and YouTube channel name for YouTube channels. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DisplayName { + get { return displayName_; } + set { + displayName_ = value; + } + } + + + /// Field number for the "target_url" field. + public const int TargetUrlFieldNumber = 4; + private static readonly pb::FieldCodec _single_targetUrl_codec = pb::FieldCodec.ForClassWrapper(34); + private string targetUrl_; + /// + /// Output only. URL of the group placement, e.g. domain, link to the mobile application in + /// app store, or a YouTube channel URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string TargetUrl { + get { return targetUrl_; } + set { + targetUrl_ = value; + } + } + + + /// Field number for the "placement_type" field. + public const int PlacementTypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.PlacementTypeEnum.Types.PlacementType placementType_ = 0; + /// + /// Output only. Type of the placement, e.g. Website, YouTube Channel, Mobile Application. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.PlacementTypeEnum.Types.PlacementType PlacementType { + get { return placementType_; } + set { + placementType_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GroupPlacementView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GroupPlacementView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Placement != other.Placement) return false; + if (DisplayName != other.DisplayName) return false; + if (TargetUrl != other.TargetUrl) return false; + if (PlacementType != other.PlacementType) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (placement_ != null) hash ^= Placement.GetHashCode(); + if (displayName_ != null) hash ^= DisplayName.GetHashCode(); + if (targetUrl_ != null) hash ^= TargetUrl.GetHashCode(); + if (PlacementType != 0) hash ^= PlacementType.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (placement_ != null) { + _single_placement_codec.WriteTagAndValue(output, Placement); + } + if (displayName_ != null) { + _single_displayName_codec.WriteTagAndValue(output, DisplayName); + } + if (targetUrl_ != null) { + _single_targetUrl_codec.WriteTagAndValue(output, TargetUrl); + } + if (PlacementType != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) PlacementType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (placement_ != null) { + size += _single_placement_codec.CalculateSizeWithTag(Placement); + } + if (displayName_ != null) { + size += _single_displayName_codec.CalculateSizeWithTag(DisplayName); + } + if (targetUrl_ != null) { + size += _single_targetUrl_codec.CalculateSizeWithTag(TargetUrl); + } + if (PlacementType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) PlacementType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GroupPlacementView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.placement_ != null) { + if (placement_ == null || other.Placement != "") { + Placement = other.Placement; + } + } + if (other.displayName_ != null) { + if (displayName_ == null || other.DisplayName != "") { + DisplayName = other.DisplayName; + } + } + if (other.targetUrl_ != null) { + if (targetUrl_ == null || other.TargetUrl != "") { + TargetUrl = other.TargetUrl; + } + } + if (other.PlacementType != 0) { + PlacementType = other.PlacementType; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_placement_codec.Read(input); + if (placement_ == null || value != "") { + Placement = value; + } + break; + } + case 26: { + string value = _single_displayName_codec.Read(input); + if (displayName_ == null || value != "") { + DisplayName = value; + } + break; + } + case 34: { + string value = _single_targetUrl_codec.Read(input); + if (targetUrl_ == null || value != "") { + TargetUrl = value; + } + break; + } + case 40: { + PlacementType = (global::Google.Ads.GoogleAds.V3.Enums.PlacementTypeEnum.Types.PlacementType) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GroupPlacementViewService.cs b/src/V3/Stubs/GroupPlacementViewService.cs new file mode 100644 index 000000000..c11e0b14b --- /dev/null +++ b/src/V3/Stubs/GroupPlacementViewService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/group_placement_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/group_placement_view_service.proto + public static partial class GroupPlacementViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/group_placement_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static GroupPlacementViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9ncm91cF9wbGFj", + "ZW1lbnRfdmlld19zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzL2dyb3VwX3BsYWNlbWVudF92aWV3LnByb3RvGhxnb29nbGUvYXBpL2Fu", + "bm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29v", + "Z2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90byI6ChxHZXRHcm91cFBsYWNl", + "bWVudFZpZXdSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAjKY", + "AgoZR3JvdXBQbGFjZW1lbnRWaWV3U2VydmljZRLdAQoVR2V0R3JvdXBQbGFj", + "ZW1lbnRWaWV3Ej4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "R2V0R3JvdXBQbGFjZW1lbnRWaWV3UmVxdWVzdBo1Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5Hcm91cFBsYWNlbWVudFZpZXciTYLT5JMC", + "NxI1L3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2dyb3VwUGxhY2Vt", + "ZW50Vmlld3MvKn3aQQ1yZXNvdXJjZV9uYW1lGhvKQRhnb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb21ChQIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlc0IeR3JvdXBQbGFjZW1lbnRWaWV3U2VydmljZVByb3RvUAFaSGdv", + "b2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2ds", + "ZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29nbGVBZHNc", + "VjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6U2Vy", + "dmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetGroupPlacementViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetGroupPlacementViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [GroupPlacementViewService.GetGroupPlacementView][google.ads.googleads.v3.services.GroupPlacementViewService.GetGroupPlacementView]. + /// + public sealed partial class GetGroupPlacementViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetGroupPlacementViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.GroupPlacementViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGroupPlacementViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGroupPlacementViewRequest(GetGroupPlacementViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetGroupPlacementViewRequest Clone() { + return new GetGroupPlacementViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the Group Placement view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetGroupPlacementViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetGroupPlacementViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetGroupPlacementViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/GroupPlacementViewServiceClient.cs b/src/V3/Stubs/GroupPlacementViewServiceClient.cs new file mode 100644 index 000000000..b3539f95e --- /dev/null +++ b/src/V3/Stubs/GroupPlacementViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class GroupPlacementViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static GroupPlacementViewServiceSettings GetDefault() => new GroupPlacementViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public GroupPlacementViewServiceSettings() { } + + private GroupPlacementViewServiceSettings(GroupPlacementViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetGroupPlacementViewSettings = existing.GetGroupPlacementViewSettings; + OnCopy(existing); + } + + partial void OnCopy(GroupPlacementViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// GroupPlacementViewServiceClient.GetGroupPlacementView and GroupPlacementViewServiceClient.GetGroupPlacementViewAsync. + /// + /// + /// The default GroupPlacementViewServiceClient.GetGroupPlacementView and + /// GroupPlacementViewServiceClient.GetGroupPlacementViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetGroupPlacementViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public GroupPlacementViewServiceSettings Clone() => new GroupPlacementViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class GroupPlacementViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public GroupPlacementViewServiceSettings Settings { get; set; } + + /// + public override GroupPlacementViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return GroupPlacementViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return GroupPlacementViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => GroupPlacementViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => GroupPlacementViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => GroupPlacementViewServiceClient.ChannelPool; + } + + /// + /// GroupPlacementViewService client wrapper, for convenient use. + /// + public abstract partial class GroupPlacementViewServiceClient + { + /// + /// The default endpoint for the GroupPlacementViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default GroupPlacementViewService scopes. + /// + /// + /// The default GroupPlacementViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GroupPlacementViewServiceClient client = await GroupPlacementViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GroupPlacementViewServiceClient.DefaultEndpoint.Host, GroupPlacementViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GroupPlacementViewServiceClient client = GroupPlacementViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, GroupPlacementViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// GroupPlacementViewServiceClient client = GroupPlacementViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// GroupPlacementViewServiceClient.DefaultEndpoint.Host, GroupPlacementViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// GroupPlacementViewServiceClient client = GroupPlacementViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static GroupPlacementViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, GroupPlacementViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GroupPlacementViewServiceClient Create(grpccore::Channel channel, GroupPlacementViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static GroupPlacementViewServiceClient Create(grpccore::CallInvoker callInvoker, GroupPlacementViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + GroupPlacementViewService.GroupPlacementViewServiceClient grpcClient = new GroupPlacementViewService.GroupPlacementViewServiceClient(callInvoker); + return new GroupPlacementViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC GroupPlacementViewService client. + /// + public virtual GroupPlacementViewService.GroupPlacementViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// + /// Required. The resource name of the Group Placement view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGroupPlacementViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGroupPlacementViewAsync( + new GetGroupPlacementViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// + /// Required. The resource name of the Group Placement view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGroupPlacementViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetGroupPlacementViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// + /// Required. The resource name of the Group Placement view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GroupPlacementView GetGroupPlacementView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetGroupPlacementView( + new GetGroupPlacementViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGroupPlacementViewAsync( + GetGroupPlacementViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetGroupPlacementViewAsync( + GetGroupPlacementViewRequest request, + st::CancellationToken cancellationToken) => GetGroupPlacementViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::GroupPlacementView GetGroupPlacementView( + GetGroupPlacementViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// GroupPlacementViewService client wrapper implementation, for convenient use. + /// + public sealed partial class GroupPlacementViewServiceClientImpl : GroupPlacementViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetGroupPlacementView; + + /// + /// Constructs a client wrapper for the GroupPlacementViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public GroupPlacementViewServiceClientImpl(GroupPlacementViewService.GroupPlacementViewServiceClient grpcClient, GroupPlacementViewServiceSettings settings) + { + GrpcClient = grpcClient; + GroupPlacementViewServiceSettings effectiveSettings = settings ?? GroupPlacementViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetGroupPlacementView = clientHelper.BuildApiCall( + GrpcClient.GetGroupPlacementViewAsync, GrpcClient.GetGroupPlacementView, effectiveSettings.GetGroupPlacementViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetGroupPlacementView); + Modify_GetGroupPlacementViewApiCall(ref _callGetGroupPlacementView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetGroupPlacementViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(GroupPlacementViewService.GroupPlacementViewServiceClient grpcClient, GroupPlacementViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC GroupPlacementViewService client. + /// + public override GroupPlacementViewService.GroupPlacementViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetGroupPlacementViewRequest(ref GetGroupPlacementViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetGroupPlacementViewAsync( + GetGroupPlacementViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGroupPlacementViewRequest(ref request, ref callSettings); + return _callGetGroupPlacementView.Async(request, callSettings); + } + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::GroupPlacementView GetGroupPlacementView( + GetGroupPlacementViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetGroupPlacementViewRequest(ref request, ref callSettings); + return _callGetGroupPlacementView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/GroupPlacementViewServiceGrpc.cs b/src/V3/Stubs/GroupPlacementViewServiceGrpc.cs new file mode 100644 index 000000000..29f4c65b6 --- /dev/null +++ b/src/V3/Stubs/GroupPlacementViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/group_placement_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to fetch Group Placement views. + /// + public static partial class GroupPlacementViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.GroupPlacementViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetGroupPlacementViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetGroupPlacementViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_GroupPlacementView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetGroupPlacementView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetGroupPlacementView", + __Marshaller_google_ads_googleads_v3_services_GetGroupPlacementViewRequest, + __Marshaller_google_ads_googleads_v3_resources_GroupPlacementView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.GroupPlacementViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of GroupPlacementViewService + public abstract partial class GroupPlacementViewServiceBase + { + /// + /// Returns the requested Group Placement view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetGroupPlacementView(global::Google.Ads.GoogleAds.V3.Services.GetGroupPlacementViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for GroupPlacementViewService + public partial class GroupPlacementViewServiceClient : grpc::ClientBase + { + /// Creates a new client for GroupPlacementViewService + /// The channel to use to make remote calls. + public GroupPlacementViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for GroupPlacementViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public GroupPlacementViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected GroupPlacementViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected GroupPlacementViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested Group Placement view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView GetGroupPlacementView(global::Google.Ads.GoogleAds.V3.Services.GetGroupPlacementViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGroupPlacementView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Group Placement view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.GroupPlacementView GetGroupPlacementView(global::Google.Ads.GoogleAds.V3.Services.GetGroupPlacementViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetGroupPlacementView, null, options, request); + } + /// + /// Returns the requested Group Placement view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGroupPlacementViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetGroupPlacementViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetGroupPlacementViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Group Placement view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetGroupPlacementViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetGroupPlacementViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetGroupPlacementView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override GroupPlacementViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new GroupPlacementViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(GroupPlacementViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetGroupPlacementView, serviceImpl.GetGroupPlacementView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, GroupPlacementViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetGroupPlacementView, serviceImpl.GetGroupPlacementView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/HeaderError.cs b/src/V3/Stubs/HeaderError.cs new file mode 100644 index 000000000..8b1346a6d --- /dev/null +++ b/src/V3/Stubs/HeaderError.cs @@ -0,0 +1,181 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/header_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/header_error.proto + public static partial class HeaderErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/header_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HeaderErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvaGVhZGVyX2Vycm9y", + "LnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMaHGdvb2ds", + "ZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iXQoPSGVhZGVyRXJyb3JFbnVtIkoK", + "C0hlYWRlckVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEh0K", + "GUlOVkFMSURfTE9HSU5fQ1VTVE9NRVJfSUQQA0LrAQoiY29tLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IQSGVhZGVyRXJyb3JQcm90b1ABWkRn", + "b29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29n", + "bGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29v", + "Z2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVy", + "cm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnBy", + "b3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.HeaderErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.HeaderErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.HeaderErrorEnum.Types.HeaderError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible header errors. + /// + public sealed partial class HeaderErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HeaderErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.HeaderErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HeaderErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HeaderErrorEnum(HeaderErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HeaderErrorEnum Clone() { + return new HeaderErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HeaderErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HeaderErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HeaderErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the HeaderErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible header errors. + /// + public enum HeaderError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The login customer id could not be validated. + /// + [pbr::OriginalName("INVALID_LOGIN_CUSTOMER_ID")] InvalidLoginCustomerId = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/HotelDateSelectionType.cs b/src/V3/Stubs/HotelDateSelectionType.cs new file mode 100644 index 000000000..3735252b5 --- /dev/null +++ b/src/V3/Stubs/HotelDateSelectionType.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/hotel_date_selection_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/hotel_date_selection_type.proto + public static partial class HotelDateSelectionTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/hotel_date_selection_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HotelDateSelectionTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9ob3RlbF9kYXRlX3Nl", + "bGVjdGlvbl90eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "bnVtcxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJ+ChpIb3RlbERh", + "dGVTZWxlY3Rpb25UeXBlRW51bSJgChZIb3RlbERhdGVTZWxlY3Rpb25UeXBl", + "Eg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhUKEURFRkFVTFRfU0VM", + "RUNUSU9OEDISEQoNVVNFUl9TRUxFQ1RFRBAzQvABCiFjb20uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXNCG0hvdGVsRGF0ZVNlbGVjdGlvblR5cGVQ", + "cm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlz", + "L2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRz", + "XFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1z", + "YgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.HotelDateSelectionTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.HotelDateSelectionTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.HotelDateSelectionTypeEnum.Types.HotelDateSelectionType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible hotel date selection types + /// + public sealed partial class HotelDateSelectionTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelDateSelectionTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.HotelDateSelectionTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelDateSelectionTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelDateSelectionTypeEnum(HotelDateSelectionTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelDateSelectionTypeEnum Clone() { + return new HotelDateSelectionTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelDateSelectionTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelDateSelectionTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelDateSelectionTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the HotelDateSelectionTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible hotel date selection types. + /// + public enum HotelDateSelectionType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Dates selected by default. + /// + [pbr::OriginalName("DEFAULT_SELECTION")] DefaultSelection = 50, + /// + /// Dates selected by the user. + /// + [pbr::OriginalName("USER_SELECTED")] UserSelected = 51, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/HotelGroupView.cs b/src/V3/Stubs/HotelGroupView.cs new file mode 100644 index 000000000..5fc5c1cd6 --- /dev/null +++ b/src/V3/Stubs/HotelGroupView.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/hotel_group_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/hotel_group_view.proto + public static partial class HotelGroupViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/hotel_group_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HotelGroupViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvaG90ZWxfZ3Jv", + "dXBfdmlldy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhlnb29nbGUv", + "YXBpL3Jlc291cmNlLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnBy", + "b3RvIr8BCg5Ib3RlbEdyb3VwVmlldxJGCg1yZXNvdXJjZV9uYW1lGAEgASgJ", + "Qi/gQQX6QSkKJ2dvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9Ib3RlbEdyb3Vw", + "Vmlldzpl6kFiCidnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vSG90ZWxHcm91", + "cFZpZXcSN2N1c3RvbWVycy97Y3VzdG9tZXJ9L2hvdGVsR3JvdXBWaWV3cy97", + "aG90ZWxfZ3JvdXBfdmlld31CgAIKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXNCE0hvdGVsR3JvdXBWaWV3UHJvdG9QAVpKZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xW", + "M1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVz", + "b3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView), global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A hotel group view. + /// + public sealed partial class HotelGroupView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelGroupView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.HotelGroupViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelGroupView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelGroupView(HotelGroupView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelGroupView Clone() { + return new HotelGroupView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the hotel group view. + /// Hotel Group view resource names have the form: + /// + /// `customers/{customer_id}/hotelGroupViews/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelGroupView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelGroupView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelGroupView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/HotelGroupViewService.cs b/src/V3/Stubs/HotelGroupViewService.cs new file mode 100644 index 000000000..d6f23e2b1 --- /dev/null +++ b/src/V3/Stubs/HotelGroupViewService.cs @@ -0,0 +1,195 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/hotel_group_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/hotel_group_view_service.proto + public static partial class HotelGroupViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/hotel_group_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HotelGroupViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9ob3RlbF9ncm91", + "cF92aWV3X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzGjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMv", + "aG90ZWxfZ3JvdXBfdmlldy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9u", + "cy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkv", + "ZmllbGRfYmVoYXZpb3IucHJvdG8iNgoYR2V0SG90ZWxHcm91cFZpZXdSZXF1", + "ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAjKEAgoVSG90ZWxHcm91", + "cFZpZXdTZXJ2aWNlEs0BChFHZXRIb3RlbEdyb3VwVmlldxI6Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEhvdGVsR3JvdXBWaWV3UmVx", + "dWVzdBoxLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5Ib3Rl", + "bEdyb3VwVmlldyJJgtPkkwIzEjEvdjMve3Jlc291cmNlX25hbWU9Y3VzdG9t", + "ZXJzLyovaG90ZWxHcm91cFZpZXdzLyp92kENcmVzb3VyY2VfbmFtZRobykEY", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQoECCiRjb20uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXNCGkhvdGVsR3JvdXBWaWV3U2VydmljZVBy", + "b3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMv", + "YWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.HotelGroupViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetHotelGroupViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetHotelGroupViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [HotelGroupViewService.GetHotelGroupView][google.ads.googleads.v3.services.HotelGroupViewService.GetHotelGroupView]. + /// + public sealed partial class GetHotelGroupViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetHotelGroupViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.HotelGroupViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetHotelGroupViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetHotelGroupViewRequest(GetHotelGroupViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetHotelGroupViewRequest Clone() { + return new GetHotelGroupViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. Resource name of the Hotel Group View to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetHotelGroupViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetHotelGroupViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetHotelGroupViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/HotelGroupViewServiceClient.cs b/src/V3/Stubs/HotelGroupViewServiceClient.cs new file mode 100644 index 000000000..e47dcc233 --- /dev/null +++ b/src/V3/Stubs/HotelGroupViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class HotelGroupViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static HotelGroupViewServiceSettings GetDefault() => new HotelGroupViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public HotelGroupViewServiceSettings() { } + + private HotelGroupViewServiceSettings(HotelGroupViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetHotelGroupViewSettings = existing.GetHotelGroupViewSettings; + OnCopy(existing); + } + + partial void OnCopy(HotelGroupViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// HotelGroupViewServiceClient.GetHotelGroupView and HotelGroupViewServiceClient.GetHotelGroupViewAsync. + /// + /// + /// The default HotelGroupViewServiceClient.GetHotelGroupView and + /// HotelGroupViewServiceClient.GetHotelGroupViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetHotelGroupViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public HotelGroupViewServiceSettings Clone() => new HotelGroupViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class HotelGroupViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public HotelGroupViewServiceSettings Settings { get; set; } + + /// + public override HotelGroupViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return HotelGroupViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return HotelGroupViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => HotelGroupViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => HotelGroupViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => HotelGroupViewServiceClient.ChannelPool; + } + + /// + /// HotelGroupViewService client wrapper, for convenient use. + /// + public abstract partial class HotelGroupViewServiceClient + { + /// + /// The default endpoint for the HotelGroupViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default HotelGroupViewService scopes. + /// + /// + /// The default HotelGroupViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// HotelGroupViewServiceClient client = await HotelGroupViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// HotelGroupViewServiceClient.DefaultEndpoint.Host, HotelGroupViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// HotelGroupViewServiceClient client = HotelGroupViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, HotelGroupViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// HotelGroupViewServiceClient client = HotelGroupViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// HotelGroupViewServiceClient.DefaultEndpoint.Host, HotelGroupViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// HotelGroupViewServiceClient client = HotelGroupViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static HotelGroupViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, HotelGroupViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static HotelGroupViewServiceClient Create(grpccore::Channel channel, HotelGroupViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static HotelGroupViewServiceClient Create(grpccore::CallInvoker callInvoker, HotelGroupViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + HotelGroupViewService.HotelGroupViewServiceClient grpcClient = new HotelGroupViewService.HotelGroupViewServiceClient(callInvoker); + return new HotelGroupViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC HotelGroupViewService client. + /// + public virtual HotelGroupViewService.HotelGroupViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// + /// Required. Resource name of the Hotel Group View to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetHotelGroupViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetHotelGroupViewAsync( + new GetHotelGroupViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// + /// Required. Resource name of the Hotel Group View to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetHotelGroupViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetHotelGroupViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// + /// Required. Resource name of the Hotel Group View to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::HotelGroupView GetHotelGroupView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetHotelGroupView( + new GetHotelGroupViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetHotelGroupViewAsync( + GetHotelGroupViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetHotelGroupViewAsync( + GetHotelGroupViewRequest request, + st::CancellationToken cancellationToken) => GetHotelGroupViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::HotelGroupView GetHotelGroupView( + GetHotelGroupViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// HotelGroupViewService client wrapper implementation, for convenient use. + /// + public sealed partial class HotelGroupViewServiceClientImpl : HotelGroupViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetHotelGroupView; + + /// + /// Constructs a client wrapper for the HotelGroupViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public HotelGroupViewServiceClientImpl(HotelGroupViewService.HotelGroupViewServiceClient grpcClient, HotelGroupViewServiceSettings settings) + { + GrpcClient = grpcClient; + HotelGroupViewServiceSettings effectiveSettings = settings ?? HotelGroupViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetHotelGroupView = clientHelper.BuildApiCall( + GrpcClient.GetHotelGroupViewAsync, GrpcClient.GetHotelGroupView, effectiveSettings.GetHotelGroupViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetHotelGroupView); + Modify_GetHotelGroupViewApiCall(ref _callGetHotelGroupView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetHotelGroupViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(HotelGroupViewService.HotelGroupViewServiceClient grpcClient, HotelGroupViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC HotelGroupViewService client. + /// + public override HotelGroupViewService.HotelGroupViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetHotelGroupViewRequest(ref GetHotelGroupViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetHotelGroupViewAsync( + GetHotelGroupViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetHotelGroupViewRequest(ref request, ref callSettings); + return _callGetHotelGroupView.Async(request, callSettings); + } + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::HotelGroupView GetHotelGroupView( + GetHotelGroupViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetHotelGroupViewRequest(ref request, ref callSettings); + return _callGetHotelGroupView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/HotelGroupViewServiceGrpc.cs b/src/V3/Stubs/HotelGroupViewServiceGrpc.cs new file mode 100644 index 000000000..05abec61a --- /dev/null +++ b/src/V3/Stubs/HotelGroupViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/hotel_group_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage Hotel Group Views. + /// + public static partial class HotelGroupViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.HotelGroupViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetHotelGroupViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetHotelGroupViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_HotelGroupView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetHotelGroupView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetHotelGroupView", + __Marshaller_google_ads_googleads_v3_services_GetHotelGroupViewRequest, + __Marshaller_google_ads_googleads_v3_resources_HotelGroupView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.HotelGroupViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of HotelGroupViewService + public abstract partial class HotelGroupViewServiceBase + { + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetHotelGroupView(global::Google.Ads.GoogleAds.V3.Services.GetHotelGroupViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for HotelGroupViewService + public partial class HotelGroupViewServiceClient : grpc::ClientBase + { + /// Creates a new client for HotelGroupViewService + /// The channel to use to make remote calls. + public HotelGroupViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for HotelGroupViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public HotelGroupViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected HotelGroupViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected HotelGroupViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView GetHotelGroupView(global::Google.Ads.GoogleAds.V3.Services.GetHotelGroupViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetHotelGroupView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.HotelGroupView GetHotelGroupView(global::Google.Ads.GoogleAds.V3.Services.GetHotelGroupViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetHotelGroupView, null, options, request); + } + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetHotelGroupViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetHotelGroupViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetHotelGroupViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Hotel Group View in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetHotelGroupViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetHotelGroupViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetHotelGroupView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override HotelGroupViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new HotelGroupViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(HotelGroupViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetHotelGroupView, serviceImpl.GetHotelGroupView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, HotelGroupViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetHotelGroupView, serviceImpl.GetHotelGroupView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/HotelPerformanceView.cs b/src/V3/Stubs/HotelPerformanceView.cs new file mode 100644 index 000000000..7b0b6f1d9 --- /dev/null +++ b/src/V3/Stubs/HotelPerformanceView.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/hotel_performance_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/hotel_performance_view.proto + public static partial class HotelPerformanceViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/hotel_performance_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HotelPerformanceViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvaG90ZWxfcGVy", + "Zm9ybWFuY2Vfdmlldy5wcm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "cmVzb3VyY2VzGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGhln", + "b29nbGUvYXBpL3Jlc291cmNlLnByb3RvGhxnb29nbGUvYXBpL2Fubm90YXRp", + "b25zLnByb3RvIsMBChRIb3RlbFBlcmZvcm1hbmNlVmlldxJMCg1yZXNvdXJj", + "ZV9uYW1lGAEgASgJQjXgQQX6QS8KLWdvb2dsZWFkcy5nb29nbGVhcGlzLmNv", + "bS9Ib3RlbFBlcmZvcm1hbmNlVmlldzpd6kFaCi1nb29nbGVhZHMuZ29vZ2xl", + "YXBpcy5jb20vSG90ZWxQZXJmb3JtYW5jZVZpZXcSKWN1c3RvbWVycy97Y3Vz", + "dG9tZXJ9L2hvdGVsUGVyZm9ybWFuY2VWaWV3QoYCCiVjb20uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMucmVzb3VyY2VzQhlIb3RlbFBlcmZvcm1hbmNlVmll", + "d1Byb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFw", + "aXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FB", + "qgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xl", + "XEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdv", + "b2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView), global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A hotel performance view. + /// + public sealed partial class HotelPerformanceView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelPerformanceView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPerformanceView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPerformanceView(HotelPerformanceView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPerformanceView Clone() { + return new HotelPerformanceView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the hotel performance view. + /// Hotel performance view resource names have the form: + /// + /// `customers/{customer_id}/hotelPerformanceView` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelPerformanceView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelPerformanceView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelPerformanceView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/HotelPerformanceViewService.cs b/src/V3/Stubs/HotelPerformanceViewService.cs new file mode 100644 index 000000000..6e4f7c55f --- /dev/null +++ b/src/V3/Stubs/HotelPerformanceViewService.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/hotel_performance_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/hotel_performance_view_service.proto + public static partial class HotelPerformanceViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/hotel_performance_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HotelPerformanceViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9ob3RlbF9wZXJm", + "b3JtYW5jZV92aWV3X3NlcnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnNlcnZpY2VzGj5nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNv", + "dXJjZXMvaG90ZWxfcGVyZm9ybWFuY2Vfdmlldy5wcm90bxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90bxoXZ29vZ2xlL2FwaS9jbGllbnQucHJvdG8a", + "H2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8iPAoeR2V0SG90ZWxQ", + "ZXJmb3JtYW5jZVZpZXdSZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlC", + "A+BBAjKfAgobSG90ZWxQZXJmb3JtYW5jZVZpZXdTZXJ2aWNlEuIBChdHZXRI", + "b3RlbFBlcmZvcm1hbmNlVmlldxJALmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLkdldEhvdGVsUGVyZm9ybWFuY2VWaWV3UmVxdWVzdBo3Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5Ib3RlbFBlcmZvcm1h", + "bmNlVmlldyJMgtPkkwI2EjQvdjMve3Jlc291cmNlX25hbWU9Y3VzdG9tZXJz", + "LyovaG90ZWxQZXJmb3JtYW5jZVZpZXd92kENcmVzb3VyY2VfbmFtZRobykEY", + "Z29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQocCCiRjb20uZ29vZ2xlLmFkcy5n", + "b29nbGVhZHMudjMuc2VydmljZXNCIEhvdGVsUGVyZm9ybWFuY2VWaWV3U2Vy", + "dmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dB", + "QaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xl", + "XEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetHotelPerformanceViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetHotelPerformanceViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [HotelPerformanceViewService.GetHotelPerformanceView][google.ads.googleads.v3.services.HotelPerformanceViewService.GetHotelPerformanceView]. + /// + public sealed partial class GetHotelPerformanceViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetHotelPerformanceViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.HotelPerformanceViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetHotelPerformanceViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetHotelPerformanceViewRequest(GetHotelPerformanceViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetHotelPerformanceViewRequest Clone() { + return new GetHotelPerformanceViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. Resource name of the Hotel Performance View to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetHotelPerformanceViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetHotelPerformanceViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetHotelPerformanceViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/HotelPerformanceViewServiceClient.cs b/src/V3/Stubs/HotelPerformanceViewServiceClient.cs new file mode 100644 index 000000000..6bf435398 --- /dev/null +++ b/src/V3/Stubs/HotelPerformanceViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class HotelPerformanceViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static HotelPerformanceViewServiceSettings GetDefault() => new HotelPerformanceViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public HotelPerformanceViewServiceSettings() { } + + private HotelPerformanceViewServiceSettings(HotelPerformanceViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetHotelPerformanceViewSettings = existing.GetHotelPerformanceViewSettings; + OnCopy(existing); + } + + partial void OnCopy(HotelPerformanceViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// HotelPerformanceViewServiceClient.GetHotelPerformanceView and HotelPerformanceViewServiceClient.GetHotelPerformanceViewAsync. + /// + /// + /// The default HotelPerformanceViewServiceClient.GetHotelPerformanceView and + /// HotelPerformanceViewServiceClient.GetHotelPerformanceViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetHotelPerformanceViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public HotelPerformanceViewServiceSettings Clone() => new HotelPerformanceViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class HotelPerformanceViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public HotelPerformanceViewServiceSettings Settings { get; set; } + + /// + public override HotelPerformanceViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return HotelPerformanceViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return HotelPerformanceViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => HotelPerformanceViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => HotelPerformanceViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => HotelPerformanceViewServiceClient.ChannelPool; + } + + /// + /// HotelPerformanceViewService client wrapper, for convenient use. + /// + public abstract partial class HotelPerformanceViewServiceClient + { + /// + /// The default endpoint for the HotelPerformanceViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default HotelPerformanceViewService scopes. + /// + /// + /// The default HotelPerformanceViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// HotelPerformanceViewServiceClient client = await HotelPerformanceViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// HotelPerformanceViewServiceClient.DefaultEndpoint.Host, HotelPerformanceViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// HotelPerformanceViewServiceClient client = HotelPerformanceViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, HotelPerformanceViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// HotelPerformanceViewServiceClient client = HotelPerformanceViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// HotelPerformanceViewServiceClient.DefaultEndpoint.Host, HotelPerformanceViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// HotelPerformanceViewServiceClient client = HotelPerformanceViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static HotelPerformanceViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, HotelPerformanceViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static HotelPerformanceViewServiceClient Create(grpccore::Channel channel, HotelPerformanceViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static HotelPerformanceViewServiceClient Create(grpccore::CallInvoker callInvoker, HotelPerformanceViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + HotelPerformanceViewService.HotelPerformanceViewServiceClient grpcClient = new HotelPerformanceViewService.HotelPerformanceViewServiceClient(callInvoker); + return new HotelPerformanceViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC HotelPerformanceViewService client. + /// + public virtual HotelPerformanceViewService.HotelPerformanceViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// + /// Required. Resource name of the Hotel Performance View to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetHotelPerformanceViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetHotelPerformanceViewAsync( + new GetHotelPerformanceViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// + /// Required. Resource name of the Hotel Performance View to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetHotelPerformanceViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetHotelPerformanceViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// + /// Required. Resource name of the Hotel Performance View to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::HotelPerformanceView GetHotelPerformanceView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetHotelPerformanceView( + new GetHotelPerformanceViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetHotelPerformanceViewAsync( + GetHotelPerformanceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetHotelPerformanceViewAsync( + GetHotelPerformanceViewRequest request, + st::CancellationToken cancellationToken) => GetHotelPerformanceViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::HotelPerformanceView GetHotelPerformanceView( + GetHotelPerformanceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// HotelPerformanceViewService client wrapper implementation, for convenient use. + /// + public sealed partial class HotelPerformanceViewServiceClientImpl : HotelPerformanceViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetHotelPerformanceView; + + /// + /// Constructs a client wrapper for the HotelPerformanceViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public HotelPerformanceViewServiceClientImpl(HotelPerformanceViewService.HotelPerformanceViewServiceClient grpcClient, HotelPerformanceViewServiceSettings settings) + { + GrpcClient = grpcClient; + HotelPerformanceViewServiceSettings effectiveSettings = settings ?? HotelPerformanceViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetHotelPerformanceView = clientHelper.BuildApiCall( + GrpcClient.GetHotelPerformanceViewAsync, GrpcClient.GetHotelPerformanceView, effectiveSettings.GetHotelPerformanceViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetHotelPerformanceView); + Modify_GetHotelPerformanceViewApiCall(ref _callGetHotelPerformanceView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetHotelPerformanceViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(HotelPerformanceViewService.HotelPerformanceViewServiceClient grpcClient, HotelPerformanceViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC HotelPerformanceViewService client. + /// + public override HotelPerformanceViewService.HotelPerformanceViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetHotelPerformanceViewRequest(ref GetHotelPerformanceViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetHotelPerformanceViewAsync( + GetHotelPerformanceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetHotelPerformanceViewRequest(ref request, ref callSettings); + return _callGetHotelPerformanceView.Async(request, callSettings); + } + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::HotelPerformanceView GetHotelPerformanceView( + GetHotelPerformanceViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetHotelPerformanceViewRequest(ref request, ref callSettings); + return _callGetHotelPerformanceView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/HotelPerformanceViewServiceGrpc.cs b/src/V3/Stubs/HotelPerformanceViewServiceGrpc.cs new file mode 100644 index 000000000..ebe057a27 --- /dev/null +++ b/src/V3/Stubs/HotelPerformanceViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/hotel_performance_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage Hotel Performance Views. + /// + public static partial class HotelPerformanceViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.HotelPerformanceViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetHotelPerformanceViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetHotelPerformanceViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_HotelPerformanceView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetHotelPerformanceView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetHotelPerformanceView", + __Marshaller_google_ads_googleads_v3_services_GetHotelPerformanceViewRequest, + __Marshaller_google_ads_googleads_v3_resources_HotelPerformanceView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.HotelPerformanceViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of HotelPerformanceViewService + public abstract partial class HotelPerformanceViewServiceBase + { + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetHotelPerformanceView(global::Google.Ads.GoogleAds.V3.Services.GetHotelPerformanceViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for HotelPerformanceViewService + public partial class HotelPerformanceViewServiceClient : grpc::ClientBase + { + /// Creates a new client for HotelPerformanceViewService + /// The channel to use to make remote calls. + public HotelPerformanceViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for HotelPerformanceViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public HotelPerformanceViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected HotelPerformanceViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected HotelPerformanceViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView GetHotelPerformanceView(global::Google.Ads.GoogleAds.V3.Services.GetHotelPerformanceViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetHotelPerformanceView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.HotelPerformanceView GetHotelPerformanceView(global::Google.Ads.GoogleAds.V3.Services.GetHotelPerformanceViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetHotelPerformanceView, null, options, request); + } + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetHotelPerformanceViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetHotelPerformanceViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetHotelPerformanceViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Hotel Performance View in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetHotelPerformanceViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetHotelPerformanceViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetHotelPerformanceView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override HotelPerformanceViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new HotelPerformanceViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(HotelPerformanceViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetHotelPerformanceView, serviceImpl.GetHotelPerformanceView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, HotelPerformanceViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetHotelPerformanceView, serviceImpl.GetHotelPerformanceView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/HotelPlaceholderField.cs b/src/V3/Stubs/HotelPlaceholderField.cs new file mode 100644 index 000000000..57901e37d --- /dev/null +++ b/src/V3/Stubs/HotelPlaceholderField.cs @@ -0,0 +1,285 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/hotel_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/hotel_placeholder_field.proto + public static partial class HotelPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/hotel_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HotelPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9ob3RlbF9wbGFjZWhv", + "bGRlcl9maWVsZC5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51", + "bXMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8izQMKGUhvdGVsUGxh", + "Y2Vob2xkZXJGaWVsZEVudW0irwMKFUhvdGVsUGxhY2Vob2xkZXJGaWVsZBIP", + "CgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIPCgtQUk9QRVJUWV9JRBAC", + "EhEKDVBST1BFUlRZX05BTUUQAxIUChBERVNUSU5BVElPTl9OQU1FEAQSDwoL", + "REVTQ1JJUFRJT04QBRILCgdBRERSRVNTEAYSCQoFUFJJQ0UQBxITCg9GT1JN", + "QVRURURfUFJJQ0UQCBIOCgpTQUxFX1BSSUNFEAkSGAoURk9STUFUVEVEX1NB", + "TEVfUFJJQ0UQChINCglJTUFHRV9VUkwQCxIMCghDQVRFR09SWRAMEg8KC1NU", + "QVJfUkFUSU5HEA0SFwoTQ09OVEVYVFVBTF9LRVlXT1JEUxAOEg4KCkZJTkFM", + "X1VSTFMQDxIVChFGSU5BTF9NT0JJTEVfVVJMUxAQEhAKDFRSQUNLSU5HX1VS", + "TBAREhQKEEFORFJPSURfQVBQX0xJTksQEhIYChRTSU1JTEFSX1BST1BFUlRZ", + "X0lEUxATEhAKDElPU19BUFBfTElOSxAUEhQKEElPU19BUFBfU1RPUkVfSUQQ", + "FULwAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQhtIb3Rl", + "bHNQbGFjZWhvbGRlckZpZWxkUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2Vu", + "dW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1H", + "b29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.HotelPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.HotelPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.HotelPlaceholderFieldEnum.Types.HotelPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Hotel placeholder fields. + /// For more information about dynamic remarketing feeds, see + /// https://support.google.com/google-ads/answer/6053288. + /// + public sealed partial class HotelPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.HotelPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPlaceholderFieldEnum(HotelPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPlaceholderFieldEnum Clone() { + return new HotelPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the HotelPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Hotel placeholder fields. + /// + public enum HotelPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: STRING. Required. Unique ID. + /// + [pbr::OriginalName("PROPERTY_ID")] PropertyId = 2, + /// + /// Data Type: STRING. Required. Main headline with property name to be shown + /// in dynamic ad. + /// + [pbr::OriginalName("PROPERTY_NAME")] PropertyName = 3, + /// + /// Data Type: STRING. Name of destination to be shown in dynamic ad. + /// + [pbr::OriginalName("DESTINATION_NAME")] DestinationName = 4, + /// + /// Data Type: STRING. Description of destination to be shown in dynamic ad. + /// + [pbr::OriginalName("DESCRIPTION")] Description = 5, + /// + /// Data Type: STRING. Complete property address, including postal code. + /// + [pbr::OriginalName("ADDRESS")] Address = 6, + /// + /// Data Type: STRING. Price to be shown in the ad. + /// Example: "100.00 USD" + /// + [pbr::OriginalName("PRICE")] Price = 7, + /// + /// Data Type: STRING. Formatted price to be shown in the ad. + /// Example: "Starting at $100.00 USD", "$80 - $100" + /// + [pbr::OriginalName("FORMATTED_PRICE")] FormattedPrice = 8, + /// + /// Data Type: STRING. Sale price to be shown in the ad. + /// Example: "80.00 USD" + /// + [pbr::OriginalName("SALE_PRICE")] SalePrice = 9, + /// + /// Data Type: STRING. Formatted sale price to be shown in the ad. + /// Example: "On sale for $80.00", "$60 - $80" + /// + [pbr::OriginalName("FORMATTED_SALE_PRICE")] FormattedSalePrice = 10, + /// + /// Data Type: URL. Image to be displayed in the ad. + /// + [pbr::OriginalName("IMAGE_URL")] ImageUrl = 11, + /// + /// Data Type: STRING. Category of property used to group like items together + /// for recommendation engine. + /// + [pbr::OriginalName("CATEGORY")] Category = 12, + /// + /// Data Type: INT64. Star rating (1 to 5) used to group like items + /// together for recommendation engine. + /// + [pbr::OriginalName("STAR_RATING")] StarRating = 13, + /// + /// Data Type: STRING_LIST. Keywords used for product retrieval. + /// + [pbr::OriginalName("CONTEXTUAL_KEYWORDS")] ContextualKeywords = 14, + /// + /// Data Type: URL_LIST. Required. Final URLs for the ad when using Upgraded + /// URLs. User will be redirected to these URLs when they click on an ad, or + /// when they click on a specific flight for ads that show multiple + /// flights. + /// + [pbr::OriginalName("FINAL_URLS")] FinalUrls = 15, + /// + /// Data Type: URL_LIST. Final mobile URLs for the ad when using Upgraded + /// URLs. + /// + [pbr::OriginalName("FINAL_MOBILE_URLS")] FinalMobileUrls = 16, + /// + /// Data Type: URL. Tracking template for the ad when using Upgraded URLs. + /// + [pbr::OriginalName("TRACKING_URL")] TrackingUrl = 17, + /// + /// Data Type: STRING. Android app link. Must be formatted as: + /// android-app://{package_id}/{scheme}/{host_path}. + /// The components are defined as follows: + /// package_id: app ID as specified in Google Play. + /// scheme: the scheme to pass to the application. Can be HTTP, or a custom + /// scheme. + /// host_path: identifies the specific content within your application. + /// + [pbr::OriginalName("ANDROID_APP_LINK")] AndroidAppLink = 18, + /// + /// Data Type: STRING_LIST. List of recommended property IDs to show together + /// with this item. + /// + [pbr::OriginalName("SIMILAR_PROPERTY_IDS")] SimilarPropertyIds = 19, + /// + /// Data Type: STRING. iOS app link. + /// + [pbr::OriginalName("IOS_APP_LINK")] IosAppLink = 20, + /// + /// Data Type: INT64. iOS app store ID. + /// + [pbr::OriginalName("IOS_APP_STORE_ID")] IosAppStoreId = 21, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/HotelPriceBucket.cs b/src/V3/Stubs/HotelPriceBucket.cs new file mode 100644 index 000000000..0985b36f6 --- /dev/null +++ b/src/V3/Stubs/HotelPriceBucket.cs @@ -0,0 +1,187 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/hotel_price_bucket.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/hotel_price_bucket.proto + public static partial class HotelPriceBucketReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/hotel_price_bucket.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HotelPriceBucketReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9ob3RlbF9wcmljZV9i", + "dWNrZXQucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvImkKFEhvdGVsUHJpY2VCdWNr", + "ZXRFbnVtIlEKEEhvdGVsUHJpY2VCdWNrZXQSDwoLVU5TUEVDSUZJRUQQABIL", + "CgdVTktOT1dOEAESDwoLTE9XRVNUX1RJRUQQAxIOCgpOT1RfTE9XRVNUEARC", + "6gEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IVSG90ZWxQ", + "cmljZUJ1Y2tldFByb3RvUAFaQmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3Rv", + "L2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9lbnVtcztlbnVtc6ICA0dB", + "QaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVudW1zygIdR29vZ2xlXEFk", + "c1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29nbGU6OkFkczo6R29vZ2xlQWRz", + "OjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.HotelPriceBucketEnum), global::Google.Ads.GoogleAds.V3.Enums.HotelPriceBucketEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.HotelPriceBucketEnum.Types.HotelPriceBucket) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing hotel price bucket for a hotel itinerary. + /// + public sealed partial class HotelPriceBucketEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelPriceBucketEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.HotelPriceBucketReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPriceBucketEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPriceBucketEnum(HotelPriceBucketEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelPriceBucketEnum Clone() { + return new HotelPriceBucketEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelPriceBucketEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelPriceBucketEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelPriceBucketEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the HotelPriceBucketEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible hotel price buckets. + /// + public enum HotelPriceBucket { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Tied for lowest price. Partner is within a small variance of the lowest + /// price. + /// + [pbr::OriginalName("LOWEST_TIED")] LowestTied = 3, + /// + /// Not lowest price. Partner is not within a small variance of the lowest + /// price. + /// + [pbr::OriginalName("NOT_LOWEST")] NotLowest = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/HotelRateType.cs b/src/V3/Stubs/HotelRateType.cs new file mode 100644 index 000000000..c8240d6d0 --- /dev/null +++ b/src/V3/Stubs/HotelRateType.cs @@ -0,0 +1,200 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/hotel_rate_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/hotel_rate_type.proto + public static partial class HotelRateTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/hotel_rate_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static HotelRateTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9ob3RlbF9yYXRlX3R5", + "cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvIooBChFIb3RlbFJhdGVUeXBlRW51", + "bSJ1Cg1Ib3RlbFJhdGVUeXBlEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9X", + "ThABEg8KC1VOQVZBSUxBQkxFEAISDwoLUFVCTElDX1JBVEUQAxISCg5RVUFM", + "SUZJRURfUkFURRAEEhAKDFBSSVZBVEVfUkFURRAFQucBCiFjb20uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXNCEkhvdGVsUmF0ZVR5cGVQcm90b1AB", + "WkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9n", + "b29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdv", + "b2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVu", + "dW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.HotelRateTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.HotelRateTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.HotelRateTypeEnum.Types.HotelRateType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible hotel rate types. + /// + public sealed partial class HotelRateTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new HotelRateTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.HotelRateTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelRateTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelRateTypeEnum(HotelRateTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public HotelRateTypeEnum Clone() { + return new HotelRateTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as HotelRateTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(HotelRateTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(HotelRateTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the HotelRateTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible hotel rate types. + /// + public enum HotelRateType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Rate type information is unavailable. + /// + [pbr::OriginalName("UNAVAILABLE")] Unavailable = 2, + /// + /// Rates available to everyone. + /// + [pbr::OriginalName("PUBLIC_RATE")] PublicRate = 3, + /// + /// A membership program rate is available and satisfies basic requirements + /// like having a public rate available. UI treatment will strikethrough the + /// public rate and indicate that a discount is available to the user. For + /// more on Qualified Rates, visit + /// https://developers.google.com/hotels/hotel-ads/dev-guide/qualified-rates + /// + [pbr::OriginalName("QUALIFIED_RATE")] QualifiedRate = 4, + /// + /// Rates available to users that satisfy some eligibility criteria. e.g. + /// all signed-in users, 20% of mobile users, all mobile users in Canada, + /// etc. + /// + [pbr::OriginalName("PRIVATE_RATE")] PrivateRate = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/IdError.cs b/src/V3/Stubs/IdError.cs new file mode 100644 index 000000000..3c22b47a7 --- /dev/null +++ b/src/V3/Stubs/IdError.cs @@ -0,0 +1,180 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/id_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/id_error.proto + public static partial class IdErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/id_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static IdErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvaWRfZXJyb3IucHJv", + "dG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29vZ2xlL2Fw", + "aS9hbm5vdGF0aW9ucy5wcm90byJFCgtJZEVycm9yRW51bSI2CgdJZEVycm9y", + "Eg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEg0KCU5PVF9GT1VORBAC", + "QucBCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzQgxJZEVy", + "cm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5H", + "b29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.IdErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.IdErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.IdErrorEnum.Types.IdError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible id errors. + /// + public sealed partial class IdErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new IdErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.IdErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IdErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IdErrorEnum(IdErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IdErrorEnum Clone() { + return new IdErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as IdErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(IdErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(IdErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the IdErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible id errors. + /// + public enum IdError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Id not found + /// + [pbr::OriginalName("NOT_FOUND")] NotFound = 2, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/ImageError.cs b/src/V3/Stubs/ImageError.cs new file mode 100644 index 000000000..839ce8c4d --- /dev/null +++ b/src/V3/Stubs/ImageError.cs @@ -0,0 +1,353 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/image_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/image_error.proto + public static partial class ImageErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/image_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static ImageErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvaW1hZ2VfZXJyb3Iu", + "cHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29vZ2xl", + "L2FwaS9hbm5vdGF0aW9ucy5wcm90byKqCAoOSW1hZ2VFcnJvckVudW0ilwgK", + "CkltYWdlRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESEQoN", + "SU5WQUxJRF9JTUFHRRACEhEKDVNUT1JBR0VfRVJST1IQAxIPCgtCQURfUkVR", + "VUVTVBAEEhMKD1VORVhQRUNURURfU0laRRAFEhgKFEFOSU1BVEVEX05PVF9B", + "TExPV0VEEAYSFgoSQU5JTUFUSU9OX1RPT19MT05HEAcSEAoMU0VSVkVSX0VS", + "Uk9SEAgSGQoVQ01ZS19KUEVHX05PVF9BTExPV0VEEAkSFQoRRkxBU0hfTk9U", + "X0FMTE9XRUQQChIaChZGTEFTSF9XSVRIT1VUX0NMSUNLVEFHEAsSJgoiRkxB", + "U0hfRVJST1JfQUZURVJfRklYSU5HX0NMSUNLX1RBRxAMEhoKFkFOSU1BVEVE", + "X1ZJU1VBTF9FRkZFQ1QQDRIPCgtGTEFTSF9FUlJPUhAOEhIKDkxBWU9VVF9Q", + "Uk9CTEVNEA8SHgoaUFJPQkxFTV9SRUFESU5HX0lNQUdFX0ZJTEUQEBIXChNF", + "UlJPUl9TVE9SSU5HX0lNQUdFEBESHAoYQVNQRUNUX1JBVElPX05PVF9BTExP", + "V0VEEBISHQoZRkxBU0hfSEFTX05FVFdPUktfT0JKRUNUUxATEh0KGUZMQVNI", + "X0hBU19ORVRXT1JLX01FVEhPRFMQFBIRCg1GTEFTSF9IQVNfVVJMEBUSHAoY", + "RkxBU0hfSEFTX01PVVNFX1RSQUNLSU5HEBYSGAoURkxBU0hfSEFTX1JBTkRP", + "TV9OVU0QFxIWChJGTEFTSF9TRUxGX1RBUkdFVFMQGBIbChdGTEFTSF9CQURf", + "R0VUVVJMX1RBUkdFVBAZEh8KG0ZMQVNIX1ZFUlNJT05fTk9UX1NVUFBPUlRF", + "RBAaEiYKIkZMQVNIX1dJVEhPVVRfSEFSRF9DT0RFRF9DTElDS19VUkwQGxIW", + "ChJJTlZBTElEX0ZMQVNIX0ZJTEUQHBIkCiBGQUlMRURfVE9fRklYX0NMSUNL", + "X1RBR19JTl9GTEFTSBAdEiQKIEZMQVNIX0FDQ0VTU0VTX05FVFdPUktfUkVT", + "T1VSQ0VTEB4SGgoWRkxBU0hfRVhURVJOQUxfSlNfQ0FMTBAfEhoKFkZMQVNI", + "X0VYVEVSTkFMX0ZTX0NBTEwQIBISCg5GSUxFX1RPT19MQVJHRRAhEhgKFElN", + "QUdFX0RBVEFfVE9PX0xBUkdFECISGgoWSU1BR0VfUFJPQ0VTU0lOR19FUlJP", + "UhAjEhMKD0lNQUdFX1RPT19TTUFMTBAkEhEKDUlOVkFMSURfSU5QVVQQJRIY", + "ChRQUk9CTEVNX1JFQURJTkdfRklMRRAmEh4KGklNQUdFX0NPTlNUUkFJTlRT", + "X1ZJT0xBVEVEECdC6gEKImNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5l", + "cnJvcnNCD0ltYWdlRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9n", + "ZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vy", + "cm9yc6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oC", + "Hkdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRz", + "OjpHb29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.ImageErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.ImageErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.ImageErrorEnum.Types.ImageError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible image errors. + /// + public sealed partial class ImageErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ImageErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.ImageErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageErrorEnum(ImageErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ImageErrorEnum Clone() { + return new ImageErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ImageErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ImageErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ImageErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the ImageErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible image errors. + /// + public enum ImageError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The image is not valid. + /// + [pbr::OriginalName("INVALID_IMAGE")] InvalidImage = 2, + /// + /// The image could not be stored. + /// + [pbr::OriginalName("STORAGE_ERROR")] StorageError = 3, + /// + /// There was a problem with the request. + /// + [pbr::OriginalName("BAD_REQUEST")] BadRequest = 4, + /// + /// The image is not of legal dimensions. + /// + [pbr::OriginalName("UNEXPECTED_SIZE")] UnexpectedSize = 5, + /// + /// Animated image are not permitted. + /// + [pbr::OriginalName("ANIMATED_NOT_ALLOWED")] AnimatedNotAllowed = 6, + /// + /// Animation is too long. + /// + [pbr::OriginalName("ANIMATION_TOO_LONG")] AnimationTooLong = 7, + /// + /// There was an error on the server. + /// + [pbr::OriginalName("SERVER_ERROR")] ServerError = 8, + /// + /// Image cannot be in CMYK color format. + /// + [pbr::OriginalName("CMYK_JPEG_NOT_ALLOWED")] CmykJpegNotAllowed = 9, + /// + /// Flash images are not permitted. + /// + [pbr::OriginalName("FLASH_NOT_ALLOWED")] FlashNotAllowed = 10, + /// + /// Flash images must support clickTag. + /// + [pbr::OriginalName("FLASH_WITHOUT_CLICKTAG")] FlashWithoutClicktag = 11, + /// + /// A flash error has occurred after fixing the click tag. + /// + [pbr::OriginalName("FLASH_ERROR_AFTER_FIXING_CLICK_TAG")] FlashErrorAfterFixingClickTag = 12, + /// + /// Unacceptable visual effects. + /// + [pbr::OriginalName("ANIMATED_VISUAL_EFFECT")] AnimatedVisualEffect = 13, + /// + /// There was a problem with the flash image. + /// + [pbr::OriginalName("FLASH_ERROR")] FlashError = 14, + /// + /// Incorrect image layout. + /// + [pbr::OriginalName("LAYOUT_PROBLEM")] LayoutProblem = 15, + /// + /// There was a problem reading the image file. + /// + [pbr::OriginalName("PROBLEM_READING_IMAGE_FILE")] ProblemReadingImageFile = 16, + /// + /// There was an error storing the image. + /// + [pbr::OriginalName("ERROR_STORING_IMAGE")] ErrorStoringImage = 17, + /// + /// The aspect ratio of the image is not allowed. + /// + [pbr::OriginalName("ASPECT_RATIO_NOT_ALLOWED")] AspectRatioNotAllowed = 18, + /// + /// Flash cannot have network objects. + /// + [pbr::OriginalName("FLASH_HAS_NETWORK_OBJECTS")] FlashHasNetworkObjects = 19, + /// + /// Flash cannot have network methods. + /// + [pbr::OriginalName("FLASH_HAS_NETWORK_METHODS")] FlashHasNetworkMethods = 20, + /// + /// Flash cannot have a Url. + /// + [pbr::OriginalName("FLASH_HAS_URL")] FlashHasUrl = 21, + /// + /// Flash cannot use mouse tracking. + /// + [pbr::OriginalName("FLASH_HAS_MOUSE_TRACKING")] FlashHasMouseTracking = 22, + /// + /// Flash cannot have a random number. + /// + [pbr::OriginalName("FLASH_HAS_RANDOM_NUM")] FlashHasRandomNum = 23, + /// + /// Ad click target cannot be '_self'. + /// + [pbr::OriginalName("FLASH_SELF_TARGETS")] FlashSelfTargets = 24, + /// + /// GetUrl method should only use '_blank'. + /// + [pbr::OriginalName("FLASH_BAD_GETURL_TARGET")] FlashBadGeturlTarget = 25, + /// + /// Flash version is not supported. + /// + [pbr::OriginalName("FLASH_VERSION_NOT_SUPPORTED")] FlashVersionNotSupported = 26, + /// + /// Flash movies need to have hard coded click URL or clickTAG + /// + [pbr::OriginalName("FLASH_WITHOUT_HARD_CODED_CLICK_URL")] FlashWithoutHardCodedClickUrl = 27, + /// + /// Uploaded flash file is corrupted. + /// + [pbr::OriginalName("INVALID_FLASH_FILE")] InvalidFlashFile = 28, + /// + /// Uploaded flash file can be parsed, but the click tag can not be fixed + /// properly. + /// + [pbr::OriginalName("FAILED_TO_FIX_CLICK_TAG_IN_FLASH")] FailedToFixClickTagInFlash = 29, + /// + /// Flash movie accesses network resources + /// + [pbr::OriginalName("FLASH_ACCESSES_NETWORK_RESOURCES")] FlashAccessesNetworkResources = 30, + /// + /// Flash movie attempts to call external javascript code + /// + [pbr::OriginalName("FLASH_EXTERNAL_JS_CALL")] FlashExternalJsCall = 31, + /// + /// Flash movie attempts to call flash system commands + /// + [pbr::OriginalName("FLASH_EXTERNAL_FS_CALL")] FlashExternalFsCall = 32, + /// + /// Image file is too large. + /// + [pbr::OriginalName("FILE_TOO_LARGE")] FileTooLarge = 33, + /// + /// Image data is too large. + /// + [pbr::OriginalName("IMAGE_DATA_TOO_LARGE")] ImageDataTooLarge = 34, + /// + /// Error while processing the image. + /// + [pbr::OriginalName("IMAGE_PROCESSING_ERROR")] ImageProcessingError = 35, + /// + /// Image is too small. + /// + [pbr::OriginalName("IMAGE_TOO_SMALL")] ImageTooSmall = 36, + /// + /// Input was invalid. + /// + [pbr::OriginalName("INVALID_INPUT")] InvalidInput = 37, + /// + /// There was a problem reading the image file. + /// + [pbr::OriginalName("PROBLEM_READING_FILE")] ProblemReadingFile = 38, + /// + /// Image constraints are violated, but details like ASPECT_RATIO_NOT_ALLOWED + /// can't be provided. This happens when asset spec contains more than one + /// constraint and different criteria of different constraints are violated. + /// + [pbr::OriginalName("IMAGE_CONSTRAINTS_VIOLATED")] ImageConstraintsViolated = 39, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/IncomeRangeType.cs b/src/V3/Stubs/IncomeRangeType.cs new file mode 100644 index 000000000..b80b015fc --- /dev/null +++ b/src/V3/Stubs/IncomeRangeType.cs @@ -0,0 +1,208 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/income_range_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/income_range_type.proto + public static partial class IncomeRangeTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/income_range_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static IncomeRangeTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9pbmNvbWVfcmFuZ2Vf", + "dHlwZS5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMaHGdv", + "b2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8igwIKE0luY29tZVJhbmdlVHlw", + "ZUVudW0i6wEKD0luY29tZVJhbmdlVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsK", + "B1VOS05PV04QARIXChFJTkNPTUVfUkFOR0VfMF81MBCxkB8SGAoSSU5DT01F", + "X1JBTkdFXzUwXzYwELKQHxIYChJJTkNPTUVfUkFOR0VfNjBfNzAQs5AfEhgK", + "EklOQ09NRV9SQU5HRV83MF84MBC0kB8SGAoSSU5DT01FX1JBTkdFXzgwXzkw", + "ELWQHxIYChJJTkNPTUVfUkFOR0VfOTBfVVAQtpAfEh8KGUlOQ09NRV9SQU5H", + "RV9VTkRFVEVSTUlORUQQsJAfQukBCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuZW51bXNCFEluY29tZVJhbmdlVHlwZVByb3RvUAFaQmdvb2dsZS5n", + "b2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92", + "My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRzLlYz", + "LkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.IncomeRangeTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.IncomeRangeTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.IncomeRangeTypeEnum.Types.IncomeRangeType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the type of demographic income ranges. + /// + public sealed partial class IncomeRangeTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new IncomeRangeTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.IncomeRangeTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IncomeRangeTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IncomeRangeTypeEnum(IncomeRangeTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IncomeRangeTypeEnum Clone() { + return new IncomeRangeTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as IncomeRangeTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(IncomeRangeTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(IncomeRangeTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the IncomeRangeTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The type of demographic income ranges (e.g. between 0% to 50%). + /// + public enum IncomeRangeType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// 0%-50%. + /// + [pbr::OriginalName("INCOME_RANGE_0_50")] IncomeRange050 = 510001, + /// + /// 50% to 60%. + /// + [pbr::OriginalName("INCOME_RANGE_50_60")] IncomeRange5060 = 510002, + /// + /// 60% to 70%. + /// + [pbr::OriginalName("INCOME_RANGE_60_70")] IncomeRange6070 = 510003, + /// + /// 70% to 80%. + /// + [pbr::OriginalName("INCOME_RANGE_70_80")] IncomeRange7080 = 510004, + /// + /// 80% to 90%. + /// + [pbr::OriginalName("INCOME_RANGE_80_90")] IncomeRange8090 = 510005, + /// + /// Greater than 90%. + /// + [pbr::OriginalName("INCOME_RANGE_90_UP")] IncomeRange90Up = 510006, + /// + /// Undetermined income range. + /// + [pbr::OriginalName("INCOME_RANGE_UNDETERMINED")] IncomeRangeUndetermined = 510000, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/InteractionEventType.cs b/src/V3/Stubs/InteractionEventType.cs new file mode 100644 index 000000000..62eab763d --- /dev/null +++ b/src/V3/Stubs/InteractionEventType.cs @@ -0,0 +1,200 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/interaction_event_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/interaction_event_type.proto + public static partial class InteractionEventTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/interaction_event_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static InteractionEventTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjpnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9pbnRlcmFjdGlvbl9l", + "dmVudF90eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVt", + "cxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKFAQoYSW50ZXJhY3Rp", + "b25FdmVudFR5cGVFbnVtImkKFEludGVyYWN0aW9uRXZlbnRUeXBlEg8KC1VO", + "U1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEgkKBUNMSUNLEAISDgoKRU5HQUdF", + "TUVOVBADEg4KClZJREVPX1ZJRVcQBBIICgROT05FEAVC7gEKIWNvbS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0IZSW50ZXJhY3Rpb25FdmVudFR5", + "cGVQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29n", + "bGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xl", + "QWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVu", + "dW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.InteractionEventTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.InteractionEventTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.InteractionEventTypeEnum.Types.InteractionEventType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing types of payable and free interactions. + /// + public sealed partial class InteractionEventTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new InteractionEventTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.InteractionEventTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionEventTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionEventTypeEnum(InteractionEventTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionEventTypeEnum Clone() { + return new InteractionEventTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as InteractionEventTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(InteractionEventTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(InteractionEventTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the InteractionEventTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible types of payable and free interactions. + /// + public enum InteractionEventType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Click to site. In most cases, this interaction navigates to an external + /// location, usually the advertiser's landing page. This is also the default + /// InteractionEventType for click events. + /// + [pbr::OriginalName("CLICK")] Click = 2, + /// + /// The user's expressed intent to engage with the ad in-place. + /// + [pbr::OriginalName("ENGAGEMENT")] Engagement = 3, + /// + /// User viewed a video ad. + /// + [pbr::OriginalName("VIDEO_VIEW")] VideoView = 4, + /// + /// The default InteractionEventType for ad conversion events. + /// This is used when an ad conversion row does NOT indicate + /// that the free interactions (i.e., the ad conversions) + /// should be 'promoted' and reported as part of the core metrics. + /// These are simply other (ad) conversions. + /// + [pbr::OriginalName("NONE")] None = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/InteractionType.cs b/src/V3/Stubs/InteractionType.cs new file mode 100644 index 000000000..5505f2f49 --- /dev/null +++ b/src/V3/Stubs/InteractionType.cs @@ -0,0 +1,180 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/interaction_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/interaction_type.proto + public static partial class InteractionTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/interaction_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static InteractionTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9pbnRlcmFjdGlvbl90", + "eXBlLnByb3RvEh1nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJSChNJbnRlcmFjdGlvblR5cGVF", + "bnVtIjsKD0ludGVyYWN0aW9uVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VO", + "S05PV04QARIKCgVDQUxMUxDAPkLpAQohY29tLmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zQhRJbnRlcmFjdGlvblR5cGVQcm90b1ABWkJnb29nbGUu", + "Z29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMv", + "djMvZW51bXM7ZW51bXOiAgNHQUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5W", + "My5FbnVtc8oCHUdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29v", + "Z2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.InteractionTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.InteractionTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.InteractionTypeEnum.Types.InteractionType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible interaction types. + /// + public sealed partial class InteractionTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new InteractionTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.InteractionTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionTypeEnum(InteractionTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InteractionTypeEnum Clone() { + return new InteractionTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as InteractionTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(InteractionTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(InteractionTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the InteractionTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible interaction types. + /// + public enum InteractionType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Calls. + /// + [pbr::OriginalName("CALLS")] Calls = 8000, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/InternalError.cs b/src/V3/Stubs/InternalError.cs new file mode 100644 index 000000000..0769e6c8b --- /dev/null +++ b/src/V3/Stubs/InternalError.cs @@ -0,0 +1,196 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/internal_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/internal_error.proto + public static partial class InternalErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/internal_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static InternalErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvaW50ZXJuYWxfZXJy", + "b3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9ycxocZ29v", + "Z2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKhAQoRSW50ZXJuYWxFcnJvckVu", + "dW0iiwEKDUludGVybmFsRXJyb3ISDwoLVU5TUEVDSUZJRUQQABILCgdVTktO", + "T1dOEAESEgoOSU5URVJOQUxfRVJST1IQAhIcChhFUlJPUl9DT0RFX05PVF9Q", + "VUJMSVNIRUQQAxITCg9UUkFOU0lFTlRfRVJST1IQBBIVChFERUFETElORV9F", + "WENFRURFRBAFQu0BCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJy", + "b3JzQhJJbnRlcm5hbEVycm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcv", + "Z2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztl", + "cnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPK", + "Ah5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFk", + "czo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.InternalErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.InternalErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.InternalErrorEnum.Types.InternalError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible internal errors. + /// + public sealed partial class InternalErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new InternalErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.InternalErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InternalErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InternalErrorEnum(InternalErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InternalErrorEnum Clone() { + return new InternalErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as InternalErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(InternalErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(InternalErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the InternalErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible internal errors. + /// + public enum InternalError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Google Ads API encountered unexpected internal error. + /// + [pbr::OriginalName("INTERNAL_ERROR")] InternalError = 2, + /// + /// The intended error code doesn't exist in specified API version. It will + /// be released in a future API version. + /// + [pbr::OriginalName("ERROR_CODE_NOT_PUBLISHED")] ErrorCodeNotPublished = 3, + /// + /// Google Ads API encountered an unexpected transient error. The user + /// should retry their request in these cases. + /// + [pbr::OriginalName("TRANSIENT_ERROR")] TransientError = 4, + /// + /// The request took longer than a deadline. + /// + [pbr::OriginalName("DEADLINE_EXCEEDED")] DeadlineExceeded = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/Invoice.cs b/src/V3/Stubs/Invoice.cs new file mode 100644 index 000000000..86f48c9a8 --- /dev/null +++ b/src/V3/Stubs/Invoice.cs @@ -0,0 +1,1321 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/invoice.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/invoice.proto + public static partial class InvoiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/invoice.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static InvoiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvaW52b2ljZS5w", + "cm90bxIhZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzGipnb29n", + "bGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24vZGF0ZXMucHJvdG8aMGdvb2ds", + "ZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2ludm9pY2VfdHlwZS5wcm90bxof", + "Z29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2FwaS9y", + "ZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnByb3Rv", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIssOCgdJbnZvaWNlEj8K", + "DXJlc291cmNlX25hbWUYASABKAlCKOBBBfpBIgogZ29vZ2xlYWRzLmdvb2ds", + "ZWFwaXMuY29tL0ludm9pY2USLQoCaWQYAiABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWVCA+BBAxJNCgR0eXBlGAMgASgOMjouZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuZW51bXMuSW52b2ljZVR5cGVFbnVtLkludm9pY2VU", + "eXBlQgPgQQMSOAoNYmlsbGluZ19zZXR1cBgEIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEj4KE3BheW1lbnRzX2FjY291bnRfaWQY", + "BSABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxI+ChNw", + "YXltZW50c19wcm9maWxlX2lkGAYgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlQgPgQQMSNQoKaXNzdWVfZGF0ZRgHIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5TdHJpbmdWYWx1ZUID4EEDEjMKCGR1ZV9kYXRlGAggASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMSSgoSc2VydmljZV9k", + "YXRlX3JhbmdlGAkgASgLMikuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29t", + "bW9uLkRhdGVSYW5nZUID4EEDEjgKDWN1cnJlbmN5X2NvZGUYCiABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxJKCiBpbnZvaWNlX2xl", + "dmVsX2FkanVzdG1lbnRzX21pY3JvcxgLIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQ2NFZhbHVlQgPgQQMSQAoWc3VidG90YWxfYW1vdW50X21pY3JvcxgM", + "IAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSOwoRdGF4", + "X2Ftb3VudF9taWNyb3MYDSABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRW", + "YWx1ZUID4EEDEj0KE3RvdGFsX2Ftb3VudF9taWNyb3MYDiABKAsyGy5nb29n", + "bGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEjwKEWNvcnJlY3RlZF9pbnZv", + "aWNlGA8gASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMS", + "PAoRcmVwbGFjZWRfaW52b2ljZXMYECADKAsyHC5nb29nbGUucHJvdG9idWYu", + "U3RyaW5nVmFsdWVCA+BBAxIyCgdwZGZfdXJsGBEgASgLMhwuZ29vZ2xlLnBy", + "b3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMSZgoYYWNjb3VudF9idWRnZXRfc3Vt", + "bWFyaWVzGBIgAygLMj8uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3Vy", + "Y2VzLkludm9pY2UuQWNjb3VudEJ1ZGdldFN1bW1hcnlCA+BBAxriBAoUQWNj", + "b3VudEJ1ZGdldFN1bW1hcnkSMwoIY3VzdG9tZXIYASABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWVCA+BBAxJEChljdXN0b21lcl9kZXNjcmlw", + "dGl2ZV9uYW1lGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVl", + "QgPgQQMSOQoOYWNjb3VudF9idWRnZXQYAyABKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWVCA+BBAxI+ChNhY2NvdW50X2J1ZGdldF9uYW1lGAQg", + "ASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQgPgQQMSQAoVcHVy", + "Y2hhc2Vfb3JkZXJfbnVtYmVyGAUgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0", + "cmluZ1ZhbHVlQgPgQQMSQAoWc3VidG90YWxfYW1vdW50X21pY3JvcxgGIAEo", + "CzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlQgPgQQMSOwoRdGF4X2Ft", + "b3VudF9taWNyb3MYByABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1", + "ZUID4EEDEj0KE3RvdGFsX2Ftb3VudF9taWNyb3MYCCABKAsyGy5nb29nbGUu", + "cHJvdG9idWYuSW50NjRWYWx1ZUID4EEDElQKHGJpbGxhYmxlX2FjdGl2aXR5", + "X2RhdGVfcmFuZ2UYCSABKAsyKS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5j", + "b21tb24uRGF0ZVJhbmdlQgPgQQM6TupBSwogZ29vZ2xlYWRzLmdvb2dsZWFw", + "aXMuY29tL0ludm9pY2USJ2N1c3RvbWVycy97Y3VzdG9tZXJ9L2ludm9pY2Vz", + "L3tpbnZvaWNlfUL5AQolY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlc0IMSW52b2ljZVByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dl", + "bnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7", + "cmVzb3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVz", + "b3VyY2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIl", + "R29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.DatesReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.InvoiceTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Invoice), global::Google.Ads.GoogleAds.V3.Resources.Invoice.Parser, new[]{ "ResourceName", "Id", "Type", "BillingSetup", "PaymentsAccountId", "PaymentsProfileId", "IssueDate", "DueDate", "ServiceDateRange", "CurrencyCode", "InvoiceLevelAdjustmentsMicros", "SubtotalAmountMicros", "TaxAmountMicros", "TotalAmountMicros", "CorrectedInvoice", "ReplacedInvoices", "PdfUrl", "AccountBudgetSummaries" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Invoice.Types.AccountBudgetSummary), global::Google.Ads.GoogleAds.V3.Resources.Invoice.Types.AccountBudgetSummary.Parser, new[]{ "Customer", "CustomerDescriptiveName", "AccountBudget", "AccountBudgetName", "PurchaseOrderNumber", "SubtotalAmountMicros", "TaxAmountMicros", "TotalAmountMicros", "BillableActivityDateRange" }, null, null, null)}) + })); + } + #endregion + + } + #region Messages + /// + /// An invoice. All invoice information is snapshotted to match the PDF invoice. + /// For invoices older than the launch of InvoiceService, the snapshotted + /// information may not match the PDF invoice. + /// + public sealed partial class Invoice : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Invoice()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.InvoiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Invoice() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Invoice(Invoice other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + type_ = other.type_; + BillingSetup = other.BillingSetup; + PaymentsAccountId = other.PaymentsAccountId; + PaymentsProfileId = other.PaymentsProfileId; + IssueDate = other.IssueDate; + DueDate = other.DueDate; + serviceDateRange_ = other.serviceDateRange_ != null ? other.serviceDateRange_.Clone() : null; + CurrencyCode = other.CurrencyCode; + InvoiceLevelAdjustmentsMicros = other.InvoiceLevelAdjustmentsMicros; + SubtotalAmountMicros = other.SubtotalAmountMicros; + TaxAmountMicros = other.TaxAmountMicros; + TotalAmountMicros = other.TotalAmountMicros; + CorrectedInvoice = other.CorrectedInvoice; + replacedInvoices_ = other.replacedInvoices_.Clone(); + PdfUrl = other.PdfUrl; + accountBudgetSummaries_ = other.accountBudgetSummaries_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public Invoice Clone() { + return new Invoice(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the invoice. Multiple customers can share a given + /// invoice, so multiple resource names may point to the same invoice. + /// Invoice resource names have the form: + /// + /// `customers/{customer_id}/invoices/{invoice_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForClassWrapper(18); + private string id_; + /// + /// Output only. The ID of the invoice. It appears on the invoice PDF as "Invoice number". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "type" field. + public const int TypeFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Enums.InvoiceTypeEnum.Types.InvoiceType type_ = 0; + /// + /// Output only. The type of invoice. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.InvoiceTypeEnum.Types.InvoiceType Type { + get { return type_; } + set { + type_ = value; + } + } + + /// Field number for the "billing_setup" field. + public const int BillingSetupFieldNumber = 4; + private static readonly pb::FieldCodec _single_billingSetup_codec = pb::FieldCodec.ForClassWrapper(34); + private string billingSetup_; + /// + /// Output only. The resource name of this invoice’s billing setup. + /// + /// `customers/{customer_id}/billingSetups/{billing_setup_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BillingSetup { + get { return billingSetup_; } + set { + billingSetup_ = value; + } + } + + + /// Field number for the "payments_account_id" field. + public const int PaymentsAccountIdFieldNumber = 5; + private static readonly pb::FieldCodec _single_paymentsAccountId_codec = pb::FieldCodec.ForClassWrapper(42); + private string paymentsAccountId_; + /// + /// Output only. A 16 digit ID used to identify the payments account associated with the + /// billing setup, e.g. "1234-5678-9012-3456". It appears on the invoice PDF as + /// "Billing Account Number". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PaymentsAccountId { + get { return paymentsAccountId_; } + set { + paymentsAccountId_ = value; + } + } + + + /// Field number for the "payments_profile_id" field. + public const int PaymentsProfileIdFieldNumber = 6; + private static readonly pb::FieldCodec _single_paymentsProfileId_codec = pb::FieldCodec.ForClassWrapper(50); + private string paymentsProfileId_; + /// + /// Output only. A 12 digit ID used to identify the payments profile associated with the + /// billing setup, e.g. "1234-5678-9012". It appears on the invoice PDF as + /// "Billing ID". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PaymentsProfileId { + get { return paymentsProfileId_; } + set { + paymentsProfileId_ = value; + } + } + + + /// Field number for the "issue_date" field. + public const int IssueDateFieldNumber = 7; + private static readonly pb::FieldCodec _single_issueDate_codec = pb::FieldCodec.ForClassWrapper(58); + private string issueDate_; + /// + /// Output only. The issue date in yyyy-mm-dd format. It appears on the invoice PDF as + /// either "Issue date" or "Invoice date". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string IssueDate { + get { return issueDate_; } + set { + issueDate_ = value; + } + } + + + /// Field number for the "due_date" field. + public const int DueDateFieldNumber = 8; + private static readonly pb::FieldCodec _single_dueDate_codec = pb::FieldCodec.ForClassWrapper(66); + private string dueDate_; + /// + /// Output only. The due date in yyyy-mm-dd format. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string DueDate { + get { return dueDate_; } + set { + dueDate_ = value; + } + } + + + /// Field number for the "service_date_range" field. + public const int ServiceDateRangeFieldNumber = 9; + private global::Google.Ads.GoogleAds.V3.Common.DateRange serviceDateRange_; + /// + /// Output only. The service period date range of this invoice. The end date is inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.DateRange ServiceDateRange { + get { return serviceDateRange_; } + set { + serviceDateRange_ = value; + } + } + + /// Field number for the "currency_code" field. + public const int CurrencyCodeFieldNumber = 10; + private static readonly pb::FieldCodec _single_currencyCode_codec = pb::FieldCodec.ForClassWrapper(82); + private string currencyCode_; + /// + /// Output only. The currency code. All costs are returned in this currency. A subset of the + /// currency codes derived from the ISO 4217 standard is supported. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CurrencyCode { + get { return currencyCode_; } + set { + currencyCode_ = value; + } + } + + + /// Field number for the "invoice_level_adjustments_micros" field. + public const int InvoiceLevelAdjustmentsMicrosFieldNumber = 11; + private static readonly pb::FieldCodec _single_invoiceLevelAdjustmentsMicros_codec = pb::FieldCodec.ForStructWrapper(90); + private long? invoiceLevelAdjustmentsMicros_; + /// + /// Output only. The total amount of invoice level adjustments. These adjustments are made + /// on the invoice, not on a specific account budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? InvoiceLevelAdjustmentsMicros { + get { return invoiceLevelAdjustmentsMicros_; } + set { + invoiceLevelAdjustmentsMicros_ = value; + } + } + + + /// Field number for the "subtotal_amount_micros" field. + public const int SubtotalAmountMicrosFieldNumber = 12; + private static readonly pb::FieldCodec _single_subtotalAmountMicros_codec = pb::FieldCodec.ForStructWrapper(98); + private long? subtotalAmountMicros_; + /// + /// Output only. The pretax subtotal amount, in micros. This equals the sum of the + /// AccountBudgetSummary subtotal amounts, plus the invoice level adjustments. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? SubtotalAmountMicros { + get { return subtotalAmountMicros_; } + set { + subtotalAmountMicros_ = value; + } + } + + + /// Field number for the "tax_amount_micros" field. + public const int TaxAmountMicrosFieldNumber = 13; + private static readonly pb::FieldCodec _single_taxAmountMicros_codec = pb::FieldCodec.ForStructWrapper(106); + private long? taxAmountMicros_; + /// + /// Output only. The sum of all taxes on the invoice, in micros. This equals the sum of the + /// AccountBudgetSummary tax amounts, plus taxes not associated with a specific + /// account budget. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TaxAmountMicros { + get { return taxAmountMicros_; } + set { + taxAmountMicros_ = value; + } + } + + + /// Field number for the "total_amount_micros" field. + public const int TotalAmountMicrosFieldNumber = 14; + private static readonly pb::FieldCodec _single_totalAmountMicros_codec = pb::FieldCodec.ForStructWrapper(114); + private long? totalAmountMicros_; + /// + /// Output only. The total amount, in micros. This equals the sum of the invoice subtotal + /// amount and the invoice tax amount. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TotalAmountMicros { + get { return totalAmountMicros_; } + set { + totalAmountMicros_ = value; + } + } + + + /// Field number for the "corrected_invoice" field. + public const int CorrectedInvoiceFieldNumber = 15; + private static readonly pb::FieldCodec _single_correctedInvoice_codec = pb::FieldCodec.ForClassWrapper(122); + private string correctedInvoice_; + /// + /// Output only. The resource name of the original invoice corrected, wrote off, or canceled + /// by this invoice, if applicable. If `corrected_invoice` is set, + /// `replaced_invoices` will not be set. + /// + /// Invoice resource names have the form: + /// + /// `customers/{customer_id}/invoices/{invoice_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CorrectedInvoice { + get { return correctedInvoice_; } + set { + correctedInvoice_ = value; + } + } + + + /// Field number for the "replaced_invoices" field. + public const int ReplacedInvoicesFieldNumber = 16; + private static readonly pb::FieldCodec _repeated_replacedInvoices_codec + = pb::FieldCodec.ForClassWrapper(130); + private readonly pbc::RepeatedField replacedInvoices_ = new pbc::RepeatedField(); + /// + /// Output only. The resource name of the original invoice(s) being rebilled or replaced by + /// this invoice, if applicable. There might be multiple replaced invoices due + /// to invoice consolidation. The replaced invoices may not belong to the same + /// payments account. If `replaced_invoices` is set, `corrected_invoice` will + /// not be set. + /// Invoice resource names have the form: + /// + /// `customers/{customer_id}/invoices/{invoice_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField ReplacedInvoices { + get { return replacedInvoices_; } + } + + /// Field number for the "pdf_url" field. + public const int PdfUrlFieldNumber = 17; + private static readonly pb::FieldCodec _single_pdfUrl_codec = pb::FieldCodec.ForClassWrapper(138); + private string pdfUrl_; + /// + /// Output only. The URL to a PDF copy of the invoice. Users need to pass in their OAuth + /// token to request the PDF with this URL. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PdfUrl { + get { return pdfUrl_; } + set { + pdfUrl_ = value; + } + } + + + /// Field number for the "account_budget_summaries" field. + public const int AccountBudgetSummariesFieldNumber = 18; + private static readonly pb::FieldCodec _repeated_accountBudgetSummaries_codec + = pb::FieldCodec.ForMessage(146, global::Google.Ads.GoogleAds.V3.Resources.Invoice.Types.AccountBudgetSummary.Parser); + private readonly pbc::RepeatedField accountBudgetSummaries_ = new pbc::RepeatedField(); + /// + /// Output only. The list of summarized account budget information associated with this + /// invoice. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField AccountBudgetSummaries { + get { return accountBudgetSummaries_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as Invoice); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(Invoice other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Type != other.Type) return false; + if (BillingSetup != other.BillingSetup) return false; + if (PaymentsAccountId != other.PaymentsAccountId) return false; + if (PaymentsProfileId != other.PaymentsProfileId) return false; + if (IssueDate != other.IssueDate) return false; + if (DueDate != other.DueDate) return false; + if (!object.Equals(ServiceDateRange, other.ServiceDateRange)) return false; + if (CurrencyCode != other.CurrencyCode) return false; + if (InvoiceLevelAdjustmentsMicros != other.InvoiceLevelAdjustmentsMicros) return false; + if (SubtotalAmountMicros != other.SubtotalAmountMicros) return false; + if (TaxAmountMicros != other.TaxAmountMicros) return false; + if (TotalAmountMicros != other.TotalAmountMicros) return false; + if (CorrectedInvoice != other.CorrectedInvoice) return false; + if(!replacedInvoices_.Equals(other.replacedInvoices_)) return false; + if (PdfUrl != other.PdfUrl) return false; + if(!accountBudgetSummaries_.Equals(other.accountBudgetSummaries_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (Type != 0) hash ^= Type.GetHashCode(); + if (billingSetup_ != null) hash ^= BillingSetup.GetHashCode(); + if (paymentsAccountId_ != null) hash ^= PaymentsAccountId.GetHashCode(); + if (paymentsProfileId_ != null) hash ^= PaymentsProfileId.GetHashCode(); + if (issueDate_ != null) hash ^= IssueDate.GetHashCode(); + if (dueDate_ != null) hash ^= DueDate.GetHashCode(); + if (serviceDateRange_ != null) hash ^= ServiceDateRange.GetHashCode(); + if (currencyCode_ != null) hash ^= CurrencyCode.GetHashCode(); + if (invoiceLevelAdjustmentsMicros_ != null) hash ^= InvoiceLevelAdjustmentsMicros.GetHashCode(); + if (subtotalAmountMicros_ != null) hash ^= SubtotalAmountMicros.GetHashCode(); + if (taxAmountMicros_ != null) hash ^= TaxAmountMicros.GetHashCode(); + if (totalAmountMicros_ != null) hash ^= TotalAmountMicros.GetHashCode(); + if (correctedInvoice_ != null) hash ^= CorrectedInvoice.GetHashCode(); + hash ^= replacedInvoices_.GetHashCode(); + if (pdfUrl_ != null) hash ^= PdfUrl.GetHashCode(); + hash ^= accountBudgetSummaries_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (Type != 0) { + output.WriteRawTag(24); + output.WriteEnum((int) Type); + } + if (billingSetup_ != null) { + _single_billingSetup_codec.WriteTagAndValue(output, BillingSetup); + } + if (paymentsAccountId_ != null) { + _single_paymentsAccountId_codec.WriteTagAndValue(output, PaymentsAccountId); + } + if (paymentsProfileId_ != null) { + _single_paymentsProfileId_codec.WriteTagAndValue(output, PaymentsProfileId); + } + if (issueDate_ != null) { + _single_issueDate_codec.WriteTagAndValue(output, IssueDate); + } + if (dueDate_ != null) { + _single_dueDate_codec.WriteTagAndValue(output, DueDate); + } + if (serviceDateRange_ != null) { + output.WriteRawTag(74); + output.WriteMessage(ServiceDateRange); + } + if (currencyCode_ != null) { + _single_currencyCode_codec.WriteTagAndValue(output, CurrencyCode); + } + if (invoiceLevelAdjustmentsMicros_ != null) { + _single_invoiceLevelAdjustmentsMicros_codec.WriteTagAndValue(output, InvoiceLevelAdjustmentsMicros); + } + if (subtotalAmountMicros_ != null) { + _single_subtotalAmountMicros_codec.WriteTagAndValue(output, SubtotalAmountMicros); + } + if (taxAmountMicros_ != null) { + _single_taxAmountMicros_codec.WriteTagAndValue(output, TaxAmountMicros); + } + if (totalAmountMicros_ != null) { + _single_totalAmountMicros_codec.WriteTagAndValue(output, TotalAmountMicros); + } + if (correctedInvoice_ != null) { + _single_correctedInvoice_codec.WriteTagAndValue(output, CorrectedInvoice); + } + replacedInvoices_.WriteTo(output, _repeated_replacedInvoices_codec); + if (pdfUrl_ != null) { + _single_pdfUrl_codec.WriteTagAndValue(output, PdfUrl); + } + accountBudgetSummaries_.WriteTo(output, _repeated_accountBudgetSummaries_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (Type != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Type); + } + if (billingSetup_ != null) { + size += _single_billingSetup_codec.CalculateSizeWithTag(BillingSetup); + } + if (paymentsAccountId_ != null) { + size += _single_paymentsAccountId_codec.CalculateSizeWithTag(PaymentsAccountId); + } + if (paymentsProfileId_ != null) { + size += _single_paymentsProfileId_codec.CalculateSizeWithTag(PaymentsProfileId); + } + if (issueDate_ != null) { + size += _single_issueDate_codec.CalculateSizeWithTag(IssueDate); + } + if (dueDate_ != null) { + size += _single_dueDate_codec.CalculateSizeWithTag(DueDate); + } + if (serviceDateRange_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ServiceDateRange); + } + if (currencyCode_ != null) { + size += _single_currencyCode_codec.CalculateSizeWithTag(CurrencyCode); + } + if (invoiceLevelAdjustmentsMicros_ != null) { + size += _single_invoiceLevelAdjustmentsMicros_codec.CalculateSizeWithTag(InvoiceLevelAdjustmentsMicros); + } + if (subtotalAmountMicros_ != null) { + size += _single_subtotalAmountMicros_codec.CalculateSizeWithTag(SubtotalAmountMicros); + } + if (taxAmountMicros_ != null) { + size += _single_taxAmountMicros_codec.CalculateSizeWithTag(TaxAmountMicros); + } + if (totalAmountMicros_ != null) { + size += _single_totalAmountMicros_codec.CalculateSizeWithTag(TotalAmountMicros); + } + if (correctedInvoice_ != null) { + size += _single_correctedInvoice_codec.CalculateSizeWithTag(CorrectedInvoice); + } + size += replacedInvoices_.CalculateSize(_repeated_replacedInvoices_codec); + if (pdfUrl_ != null) { + size += _single_pdfUrl_codec.CalculateSizeWithTag(PdfUrl); + } + size += accountBudgetSummaries_.CalculateSize(_repeated_accountBudgetSummaries_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(Invoice other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != "") { + Id = other.Id; + } + } + if (other.Type != 0) { + Type = other.Type; + } + if (other.billingSetup_ != null) { + if (billingSetup_ == null || other.BillingSetup != "") { + BillingSetup = other.BillingSetup; + } + } + if (other.paymentsAccountId_ != null) { + if (paymentsAccountId_ == null || other.PaymentsAccountId != "") { + PaymentsAccountId = other.PaymentsAccountId; + } + } + if (other.paymentsProfileId_ != null) { + if (paymentsProfileId_ == null || other.PaymentsProfileId != "") { + PaymentsProfileId = other.PaymentsProfileId; + } + } + if (other.issueDate_ != null) { + if (issueDate_ == null || other.IssueDate != "") { + IssueDate = other.IssueDate; + } + } + if (other.dueDate_ != null) { + if (dueDate_ == null || other.DueDate != "") { + DueDate = other.DueDate; + } + } + if (other.serviceDateRange_ != null) { + if (serviceDateRange_ == null) { + ServiceDateRange = new global::Google.Ads.GoogleAds.V3.Common.DateRange(); + } + ServiceDateRange.MergeFrom(other.ServiceDateRange); + } + if (other.currencyCode_ != null) { + if (currencyCode_ == null || other.CurrencyCode != "") { + CurrencyCode = other.CurrencyCode; + } + } + if (other.invoiceLevelAdjustmentsMicros_ != null) { + if (invoiceLevelAdjustmentsMicros_ == null || other.InvoiceLevelAdjustmentsMicros != 0L) { + InvoiceLevelAdjustmentsMicros = other.InvoiceLevelAdjustmentsMicros; + } + } + if (other.subtotalAmountMicros_ != null) { + if (subtotalAmountMicros_ == null || other.SubtotalAmountMicros != 0L) { + SubtotalAmountMicros = other.SubtotalAmountMicros; + } + } + if (other.taxAmountMicros_ != null) { + if (taxAmountMicros_ == null || other.TaxAmountMicros != 0L) { + TaxAmountMicros = other.TaxAmountMicros; + } + } + if (other.totalAmountMicros_ != null) { + if (totalAmountMicros_ == null || other.TotalAmountMicros != 0L) { + TotalAmountMicros = other.TotalAmountMicros; + } + } + if (other.correctedInvoice_ != null) { + if (correctedInvoice_ == null || other.CorrectedInvoice != "") { + CorrectedInvoice = other.CorrectedInvoice; + } + } + replacedInvoices_.Add(other.replacedInvoices_); + if (other.pdfUrl_ != null) { + if (pdfUrl_ == null || other.PdfUrl != "") { + PdfUrl = other.PdfUrl; + } + } + accountBudgetSummaries_.Add(other.accountBudgetSummaries_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_id_codec.Read(input); + if (id_ == null || value != "") { + Id = value; + } + break; + } + case 24: { + Type = (global::Google.Ads.GoogleAds.V3.Enums.InvoiceTypeEnum.Types.InvoiceType) input.ReadEnum(); + break; + } + case 34: { + string value = _single_billingSetup_codec.Read(input); + if (billingSetup_ == null || value != "") { + BillingSetup = value; + } + break; + } + case 42: { + string value = _single_paymentsAccountId_codec.Read(input); + if (paymentsAccountId_ == null || value != "") { + PaymentsAccountId = value; + } + break; + } + case 50: { + string value = _single_paymentsProfileId_codec.Read(input); + if (paymentsProfileId_ == null || value != "") { + PaymentsProfileId = value; + } + break; + } + case 58: { + string value = _single_issueDate_codec.Read(input); + if (issueDate_ == null || value != "") { + IssueDate = value; + } + break; + } + case 66: { + string value = _single_dueDate_codec.Read(input); + if (dueDate_ == null || value != "") { + DueDate = value; + } + break; + } + case 74: { + if (serviceDateRange_ == null) { + ServiceDateRange = new global::Google.Ads.GoogleAds.V3.Common.DateRange(); + } + input.ReadMessage(ServiceDateRange); + break; + } + case 82: { + string value = _single_currencyCode_codec.Read(input); + if (currencyCode_ == null || value != "") { + CurrencyCode = value; + } + break; + } + case 90: { + long? value = _single_invoiceLevelAdjustmentsMicros_codec.Read(input); + if (invoiceLevelAdjustmentsMicros_ == null || value != 0L) { + InvoiceLevelAdjustmentsMicros = value; + } + break; + } + case 98: { + long? value = _single_subtotalAmountMicros_codec.Read(input); + if (subtotalAmountMicros_ == null || value != 0L) { + SubtotalAmountMicros = value; + } + break; + } + case 106: { + long? value = _single_taxAmountMicros_codec.Read(input); + if (taxAmountMicros_ == null || value != 0L) { + TaxAmountMicros = value; + } + break; + } + case 114: { + long? value = _single_totalAmountMicros_codec.Read(input); + if (totalAmountMicros_ == null || value != 0L) { + TotalAmountMicros = value; + } + break; + } + case 122: { + string value = _single_correctedInvoice_codec.Read(input); + if (correctedInvoice_ == null || value != "") { + CorrectedInvoice = value; + } + break; + } + case 130: { + replacedInvoices_.AddEntriesFrom(input, _repeated_replacedInvoices_codec); + break; + } + case 138: { + string value = _single_pdfUrl_codec.Read(input); + if (pdfUrl_ == null || value != "") { + PdfUrl = value; + } + break; + } + case 146: { + accountBudgetSummaries_.AddEntriesFrom(input, _repeated_accountBudgetSummaries_codec); + break; + } + } + } + } + + #region Nested types + /// Container for nested types declared in the Invoice message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Represents a summarized account budget billable cost. + /// + public sealed partial class AccountBudgetSummary : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new AccountBudgetSummary()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.Invoice.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetSummary() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetSummary(AccountBudgetSummary other) : this() { + Customer = other.Customer; + CustomerDescriptiveName = other.CustomerDescriptiveName; + AccountBudget = other.AccountBudget; + AccountBudgetName = other.AccountBudgetName; + PurchaseOrderNumber = other.PurchaseOrderNumber; + SubtotalAmountMicros = other.SubtotalAmountMicros; + TaxAmountMicros = other.TaxAmountMicros; + TotalAmountMicros = other.TotalAmountMicros; + billableActivityDateRange_ = other.billableActivityDateRange_ != null ? other.billableActivityDateRange_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public AccountBudgetSummary Clone() { + return new AccountBudgetSummary(this); + } + + /// Field number for the "customer" field. + public const int CustomerFieldNumber = 1; + private static readonly pb::FieldCodec _single_customer_codec = pb::FieldCodec.ForClassWrapper(10); + private string customer_; + /// + /// Output only. The resource name of the customer associated with this account budget. + /// This contains the customer ID, which appears on the invoice PDF as + /// "Account ID". + /// Customer resource names have the form: + /// + /// `customers/{customer_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Customer { + get { return customer_; } + set { + customer_ = value; + } + } + + + /// Field number for the "customer_descriptive_name" field. + public const int CustomerDescriptiveNameFieldNumber = 2; + private static readonly pb::FieldCodec _single_customerDescriptiveName_codec = pb::FieldCodec.ForClassWrapper(18); + private string customerDescriptiveName_; + /// + /// Output only. The descriptive name of the account budget’s customer. It appears on the + /// invoice PDF as "Account". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerDescriptiveName { + get { return customerDescriptiveName_; } + set { + customerDescriptiveName_ = value; + } + } + + + /// Field number for the "account_budget" field. + public const int AccountBudgetFieldNumber = 3; + private static readonly pb::FieldCodec _single_accountBudget_codec = pb::FieldCodec.ForClassWrapper(26); + private string accountBudget_; + /// + /// Output only. The resource name of the account budget associated with this summarized + /// billable cost. + /// AccountBudget resource names have the form: + /// + /// `customers/{customer_id}/accountBudgets/{account_budget_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AccountBudget { + get { return accountBudget_; } + set { + accountBudget_ = value; + } + } + + + /// Field number for the "account_budget_name" field. + public const int AccountBudgetNameFieldNumber = 4; + private static readonly pb::FieldCodec _single_accountBudgetName_codec = pb::FieldCodec.ForClassWrapper(34); + private string accountBudgetName_; + /// + /// Output only. The name of the account budget. It appears on the invoice PDF as "Account + /// budget". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string AccountBudgetName { + get { return accountBudgetName_; } + set { + accountBudgetName_ = value; + } + } + + + /// Field number for the "purchase_order_number" field. + public const int PurchaseOrderNumberFieldNumber = 5; + private static readonly pb::FieldCodec _single_purchaseOrderNumber_codec = pb::FieldCodec.ForClassWrapper(42); + private string purchaseOrderNumber_; + /// + /// Output only. The purchase order number of the account budget. It appears on the + /// invoice PDF as "Purchase order". + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string PurchaseOrderNumber { + get { return purchaseOrderNumber_; } + set { + purchaseOrderNumber_ = value; + } + } + + + /// Field number for the "subtotal_amount_micros" field. + public const int SubtotalAmountMicrosFieldNumber = 6; + private static readonly pb::FieldCodec _single_subtotalAmountMicros_codec = pb::FieldCodec.ForStructWrapper(50); + private long? subtotalAmountMicros_; + /// + /// Output only. The pretax subtotal amount attributable to this budget during the service + /// period, in micros. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? SubtotalAmountMicros { + get { return subtotalAmountMicros_; } + set { + subtotalAmountMicros_ = value; + } + } + + + /// Field number for the "tax_amount_micros" field. + public const int TaxAmountMicrosFieldNumber = 7; + private static readonly pb::FieldCodec _single_taxAmountMicros_codec = pb::FieldCodec.ForStructWrapper(58); + private long? taxAmountMicros_; + /// + /// Output only. The tax amount attributable to this budget during the service period, in + /// micros. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TaxAmountMicros { + get { return taxAmountMicros_; } + set { + taxAmountMicros_ = value; + } + } + + + /// Field number for the "total_amount_micros" field. + public const int TotalAmountMicrosFieldNumber = 8; + private static readonly pb::FieldCodec _single_totalAmountMicros_codec = pb::FieldCodec.ForStructWrapper(66); + private long? totalAmountMicros_; + /// + /// Output only. The total amount attributable to this budget during the service period, + /// in micros. This equals the sum of the account budget subtotal amount and + /// the account budget tax amount. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? TotalAmountMicros { + get { return totalAmountMicros_; } + set { + totalAmountMicros_ = value; + } + } + + + /// Field number for the "billable_activity_date_range" field. + public const int BillableActivityDateRangeFieldNumber = 9; + private global::Google.Ads.GoogleAds.V3.Common.DateRange billableActivityDateRange_; + /// + /// Output only. The billable activity date range of the account budget, within the + /// service date range of this invoice. The end date is inclusive. This can + /// be different from the account budget's start and end time. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.DateRange BillableActivityDateRange { + get { return billableActivityDateRange_; } + set { + billableActivityDateRange_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as AccountBudgetSummary); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(AccountBudgetSummary other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Customer != other.Customer) return false; + if (CustomerDescriptiveName != other.CustomerDescriptiveName) return false; + if (AccountBudget != other.AccountBudget) return false; + if (AccountBudgetName != other.AccountBudgetName) return false; + if (PurchaseOrderNumber != other.PurchaseOrderNumber) return false; + if (SubtotalAmountMicros != other.SubtotalAmountMicros) return false; + if (TaxAmountMicros != other.TaxAmountMicros) return false; + if (TotalAmountMicros != other.TotalAmountMicros) return false; + if (!object.Equals(BillableActivityDateRange, other.BillableActivityDateRange)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (customer_ != null) hash ^= Customer.GetHashCode(); + if (customerDescriptiveName_ != null) hash ^= CustomerDescriptiveName.GetHashCode(); + if (accountBudget_ != null) hash ^= AccountBudget.GetHashCode(); + if (accountBudgetName_ != null) hash ^= AccountBudgetName.GetHashCode(); + if (purchaseOrderNumber_ != null) hash ^= PurchaseOrderNumber.GetHashCode(); + if (subtotalAmountMicros_ != null) hash ^= SubtotalAmountMicros.GetHashCode(); + if (taxAmountMicros_ != null) hash ^= TaxAmountMicros.GetHashCode(); + if (totalAmountMicros_ != null) hash ^= TotalAmountMicros.GetHashCode(); + if (billableActivityDateRange_ != null) hash ^= BillableActivityDateRange.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (customer_ != null) { + _single_customer_codec.WriteTagAndValue(output, Customer); + } + if (customerDescriptiveName_ != null) { + _single_customerDescriptiveName_codec.WriteTagAndValue(output, CustomerDescriptiveName); + } + if (accountBudget_ != null) { + _single_accountBudget_codec.WriteTagAndValue(output, AccountBudget); + } + if (accountBudgetName_ != null) { + _single_accountBudgetName_codec.WriteTagAndValue(output, AccountBudgetName); + } + if (purchaseOrderNumber_ != null) { + _single_purchaseOrderNumber_codec.WriteTagAndValue(output, PurchaseOrderNumber); + } + if (subtotalAmountMicros_ != null) { + _single_subtotalAmountMicros_codec.WriteTagAndValue(output, SubtotalAmountMicros); + } + if (taxAmountMicros_ != null) { + _single_taxAmountMicros_codec.WriteTagAndValue(output, TaxAmountMicros); + } + if (totalAmountMicros_ != null) { + _single_totalAmountMicros_codec.WriteTagAndValue(output, TotalAmountMicros); + } + if (billableActivityDateRange_ != null) { + output.WriteRawTag(74); + output.WriteMessage(BillableActivityDateRange); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (customer_ != null) { + size += _single_customer_codec.CalculateSizeWithTag(Customer); + } + if (customerDescriptiveName_ != null) { + size += _single_customerDescriptiveName_codec.CalculateSizeWithTag(CustomerDescriptiveName); + } + if (accountBudget_ != null) { + size += _single_accountBudget_codec.CalculateSizeWithTag(AccountBudget); + } + if (accountBudgetName_ != null) { + size += _single_accountBudgetName_codec.CalculateSizeWithTag(AccountBudgetName); + } + if (purchaseOrderNumber_ != null) { + size += _single_purchaseOrderNumber_codec.CalculateSizeWithTag(PurchaseOrderNumber); + } + if (subtotalAmountMicros_ != null) { + size += _single_subtotalAmountMicros_codec.CalculateSizeWithTag(SubtotalAmountMicros); + } + if (taxAmountMicros_ != null) { + size += _single_taxAmountMicros_codec.CalculateSizeWithTag(TaxAmountMicros); + } + if (totalAmountMicros_ != null) { + size += _single_totalAmountMicros_codec.CalculateSizeWithTag(TotalAmountMicros); + } + if (billableActivityDateRange_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(BillableActivityDateRange); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(AccountBudgetSummary other) { + if (other == null) { + return; + } + if (other.customer_ != null) { + if (customer_ == null || other.Customer != "") { + Customer = other.Customer; + } + } + if (other.customerDescriptiveName_ != null) { + if (customerDescriptiveName_ == null || other.CustomerDescriptiveName != "") { + CustomerDescriptiveName = other.CustomerDescriptiveName; + } + } + if (other.accountBudget_ != null) { + if (accountBudget_ == null || other.AccountBudget != "") { + AccountBudget = other.AccountBudget; + } + } + if (other.accountBudgetName_ != null) { + if (accountBudgetName_ == null || other.AccountBudgetName != "") { + AccountBudgetName = other.AccountBudgetName; + } + } + if (other.purchaseOrderNumber_ != null) { + if (purchaseOrderNumber_ == null || other.PurchaseOrderNumber != "") { + PurchaseOrderNumber = other.PurchaseOrderNumber; + } + } + if (other.subtotalAmountMicros_ != null) { + if (subtotalAmountMicros_ == null || other.SubtotalAmountMicros != 0L) { + SubtotalAmountMicros = other.SubtotalAmountMicros; + } + } + if (other.taxAmountMicros_ != null) { + if (taxAmountMicros_ == null || other.TaxAmountMicros != 0L) { + TaxAmountMicros = other.TaxAmountMicros; + } + } + if (other.totalAmountMicros_ != null) { + if (totalAmountMicros_ == null || other.TotalAmountMicros != 0L) { + TotalAmountMicros = other.TotalAmountMicros; + } + } + if (other.billableActivityDateRange_ != null) { + if (billableActivityDateRange_ == null) { + BillableActivityDateRange = new global::Google.Ads.GoogleAds.V3.Common.DateRange(); + } + BillableActivityDateRange.MergeFrom(other.BillableActivityDateRange); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_customer_codec.Read(input); + if (customer_ == null || value != "") { + Customer = value; + } + break; + } + case 18: { + string value = _single_customerDescriptiveName_codec.Read(input); + if (customerDescriptiveName_ == null || value != "") { + CustomerDescriptiveName = value; + } + break; + } + case 26: { + string value = _single_accountBudget_codec.Read(input); + if (accountBudget_ == null || value != "") { + AccountBudget = value; + } + break; + } + case 34: { + string value = _single_accountBudgetName_codec.Read(input); + if (accountBudgetName_ == null || value != "") { + AccountBudgetName = value; + } + break; + } + case 42: { + string value = _single_purchaseOrderNumber_codec.Read(input); + if (purchaseOrderNumber_ == null || value != "") { + PurchaseOrderNumber = value; + } + break; + } + case 50: { + long? value = _single_subtotalAmountMicros_codec.Read(input); + if (subtotalAmountMicros_ == null || value != 0L) { + SubtotalAmountMicros = value; + } + break; + } + case 58: { + long? value = _single_taxAmountMicros_codec.Read(input); + if (taxAmountMicros_ == null || value != 0L) { + TaxAmountMicros = value; + } + break; + } + case 66: { + long? value = _single_totalAmountMicros_codec.Read(input); + if (totalAmountMicros_ == null || value != 0L) { + TotalAmountMicros = value; + } + break; + } + case 74: { + if (billableActivityDateRange_ == null) { + BillableActivityDateRange = new global::Google.Ads.GoogleAds.V3.Common.DateRange(); + } + input.ReadMessage(BillableActivityDateRange); + break; + } + } + } + } + + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/InvoiceError.cs b/src/V3/Stubs/InvoiceError.cs new file mode 100644 index 000000000..1b5a2cf6f --- /dev/null +++ b/src/V3/Stubs/InvoiceError.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/invoice_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/invoice_error.proto + public static partial class InvoiceErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/invoice_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static InvoiceErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMvaW52b2ljZV9lcnJv", + "ci5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3JzGhxnb29n", + "bGUvYXBpL2Fubm90YXRpb25zLnByb3RvInMKEEludm9pY2VFcnJvckVudW0i", + "XwoMSW52b2ljZUVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThAB", + "EhYKEllFQVJfTU9OVEhfVE9PX09MRBACEhkKFU5PVF9JTlZPSUNFRF9DVVNU", + "T01FUhADQuwBCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZXJyb3Jz", + "QhFJbnZvaWNlRXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5w", + "cm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9y", + "c6ICA0dBQaoCHkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdv", + "b2dsZVxBZHNcR29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpH", + "b29nbGVBZHM6OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.InvoiceErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.InvoiceErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.InvoiceErrorEnum.Types.InvoiceError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible invoice errors. + /// + public sealed partial class InvoiceErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new InvoiceErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.InvoiceErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InvoiceErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InvoiceErrorEnum(InvoiceErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InvoiceErrorEnum Clone() { + return new InvoiceErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as InvoiceErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(InvoiceErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(InvoiceErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the InvoiceErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible invoice errors. + /// + public enum InvoiceError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Cannot request invoices issued before 2019-01-01. + /// + [pbr::OriginalName("YEAR_MONTH_TOO_OLD")] YearMonthTooOld = 2, + /// + /// Cannot request invoices for customer who doesn't receive invoices. + /// + [pbr::OriginalName("NOT_INVOICED_CUSTOMER")] NotInvoicedCustomer = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/InvoiceService.cs b/src/V3/Stubs/InvoiceService.cs new file mode 100644 index 000000000..2f07d0168 --- /dev/null +++ b/src/V3/Stubs/InvoiceService.cs @@ -0,0 +1,426 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/invoice_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/invoice_service.proto + public static partial class InvoiceServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/invoice_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static InvoiceServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9pbnZvaWNlX3Nl", + "cnZpY2UucHJvdG8SIGdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2Vz", + "GjFnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9tb250aF9vZl95ZWFy", + "LnByb3RvGi9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvaW52", + "b2ljZS5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90bxoXZ29v", + "Z2xlL2FwaS9jbGllbnQucHJvdG8aH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZp", + "b3IucHJvdG8iugEKE0xpc3RJbnZvaWNlc1JlcXVlc3QSGAoLY3VzdG9tZXJf", + "aWQYASABKAlCA+BBAhIaCg1iaWxsaW5nX3NldHVwGAIgASgJQgPgQQISFwoK", + "aXNzdWVfeWVhchgDIAEoCUID4EECElQKC2lzc3VlX21vbnRoGAQgASgOMjou", + "Z29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMuTW9udGhPZlllYXJFbnVt", + "Lk1vbnRoT2ZZZWFyQgPgQQIiVAoUTGlzdEludm9pY2VzUmVzcG9uc2USPAoI", + "aW52b2ljZXMYASADKAsyKi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNv", + "dXJjZXMuSW52b2ljZTKQAgoOSW52b2ljZVNlcnZpY2US4AEKDExpc3RJbnZv", + "aWNlcxI1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkxpc3RJ", + "bnZvaWNlc1JlcXVlc3QaNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2", + "aWNlcy5MaXN0SW52b2ljZXNSZXNwb25zZSJhgtPkkwIoEiYvdjMvY3VzdG9t", + "ZXJzL3tjdXN0b21lcl9pZD0qfS9pbnZvaWNlc9pBMGN1c3RvbWVyX2lkLGJp", + "bGxpbmdfc2V0dXAsaXNzdWVfeWVhcixpc3N1ZV9tb250aBobykEYZ29vZ2xl", + "YWRzLmdvb2dsZWFwaXMuY29tQvoBCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXNCE0ludm9pY2VTZXJ2aWNlUHJvdG9QAVpIZ29vZ2xl", + "LmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRz", + "L3YzL3NlcnZpY2VzO3NlcnZpY2VzogIDR0FBqgIgR29vZ2xlLkFkcy5Hb29n", + "bGVBZHMuVjMuU2VydmljZXPKAiBHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xT", + "ZXJ2aWNlc+oCJEdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpTZXJ2aWNl", + "c2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.MonthOfYearReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.InvoiceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ListInvoicesRequest), global::Google.Ads.GoogleAds.V3.Services.ListInvoicesRequest.Parser, new[]{ "CustomerId", "BillingSetup", "IssueYear", "IssueMonth" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ListInvoicesResponse), global::Google.Ads.GoogleAds.V3.Services.ListInvoicesResponse.Parser, new[]{ "Invoices" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for fetching the invoices of a given billing setup that were + /// issued during a given month. + /// + public sealed partial class ListInvoicesRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListInvoicesRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.InvoiceServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListInvoicesRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListInvoicesRequest(ListInvoicesRequest other) : this() { + customerId_ = other.customerId_; + billingSetup_ = other.billingSetup_; + issueYear_ = other.issueYear_; + issueMonth_ = other.issueMonth_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListInvoicesRequest Clone() { + return new ListInvoicesRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer to fetch invoices for. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "billing_setup" field. + public const int BillingSetupFieldNumber = 2; + private string billingSetup_ = ""; + /// + /// Required. The billing setup resource name of the requested invoices. + /// + /// `customers/{customer_id}/billingSetups/{billing_setup_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string BillingSetup { + get { return billingSetup_; } + set { + billingSetup_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "issue_year" field. + public const int IssueYearFieldNumber = 3; + private string issueYear_ = ""; + /// + /// Required. The issue year to retrieve invoices, in yyyy format. Only + /// invoices issued in 2019 or later can be retrieved. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string IssueYear { + get { return issueYear_; } + set { + issueYear_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "issue_month" field. + public const int IssueMonthFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Enums.MonthOfYearEnum.Types.MonthOfYear issueMonth_ = 0; + /// + /// Required. The issue month to retrieve invoices. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.MonthOfYearEnum.Types.MonthOfYear IssueMonth { + get { return issueMonth_; } + set { + issueMonth_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListInvoicesRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListInvoicesRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (BillingSetup != other.BillingSetup) return false; + if (IssueYear != other.IssueYear) return false; + if (IssueMonth != other.IssueMonth) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (BillingSetup.Length != 0) hash ^= BillingSetup.GetHashCode(); + if (IssueYear.Length != 0) hash ^= IssueYear.GetHashCode(); + if (IssueMonth != 0) hash ^= IssueMonth.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (BillingSetup.Length != 0) { + output.WriteRawTag(18); + output.WriteString(BillingSetup); + } + if (IssueYear.Length != 0) { + output.WriteRawTag(26); + output.WriteString(IssueYear); + } + if (IssueMonth != 0) { + output.WriteRawTag(32); + output.WriteEnum((int) IssueMonth); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (BillingSetup.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(BillingSetup); + } + if (IssueYear.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(IssueYear); + } + if (IssueMonth != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) IssueMonth); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListInvoicesRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.BillingSetup.Length != 0) { + BillingSetup = other.BillingSetup; + } + if (other.IssueYear.Length != 0) { + IssueYear = other.IssueYear; + } + if (other.IssueMonth != 0) { + IssueMonth = other.IssueMonth; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + BillingSetup = input.ReadString(); + break; + } + case 26: { + IssueYear = input.ReadString(); + break; + } + case 32: { + IssueMonth = (global::Google.Ads.GoogleAds.V3.Enums.MonthOfYearEnum.Types.MonthOfYear) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Response message for [InvoiceService.ListInvoices][google.ads.googleads.v3.services.InvoiceService.ListInvoices]. + /// + public sealed partial class ListInvoicesResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ListInvoicesResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.InvoiceServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListInvoicesResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListInvoicesResponse(ListInvoicesResponse other) : this() { + invoices_ = other.invoices_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ListInvoicesResponse Clone() { + return new ListInvoicesResponse(this); + } + + /// Field number for the "invoices" field. + public const int InvoicesFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_invoices_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Resources.Invoice.Parser); + private readonly pbc::RepeatedField invoices_ = new pbc::RepeatedField(); + /// + /// The list of invoices that match the billing setup and time period. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Invoices { + get { return invoices_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ListInvoicesResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ListInvoicesResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!invoices_.Equals(other.invoices_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= invoices_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + invoices_.WriteTo(output, _repeated_invoices_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += invoices_.CalculateSize(_repeated_invoices_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ListInvoicesResponse other) { + if (other == null) { + return; + } + invoices_.Add(other.invoices_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + invoices_.AddEntriesFrom(input, _repeated_invoices_codec); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/InvoiceServiceClient.cs b/src/V3/Stubs/InvoiceServiceClient.cs new file mode 100644 index 000000000..58077b991 --- /dev/null +++ b/src/V3/Stubs/InvoiceServiceClient.cs @@ -0,0 +1,615 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagve = Google.Ads.GoogleAds.V3.Enums; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class InvoiceServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static InvoiceServiceSettings GetDefault() => new InvoiceServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public InvoiceServiceSettings() { } + + private InvoiceServiceSettings(InvoiceServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + ListInvoicesSettings = existing.ListInvoicesSettings; + OnCopy(existing); + } + + partial void OnCopy(InvoiceServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// InvoiceServiceClient.ListInvoices and InvoiceServiceClient.ListInvoicesAsync. + /// + /// + /// The default InvoiceServiceClient.ListInvoices and + /// InvoiceServiceClient.ListInvoicesAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings ListInvoicesSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public InvoiceServiceSettings Clone() => new InvoiceServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class InvoiceServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public InvoiceServiceSettings Settings { get; set; } + + /// + public override InvoiceServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return InvoiceServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return InvoiceServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => InvoiceServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => InvoiceServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => InvoiceServiceClient.ChannelPool; + } + + /// + /// InvoiceService client wrapper, for convenient use. + /// + public abstract partial class InvoiceServiceClient + { + /// + /// The default endpoint for the InvoiceService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default InvoiceService scopes. + /// + /// + /// The default InvoiceService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// InvoiceServiceClient client = await InvoiceServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// InvoiceServiceClient.DefaultEndpoint.Host, InvoiceServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// InvoiceServiceClient client = InvoiceServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, InvoiceServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// InvoiceServiceClient client = InvoiceServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// InvoiceServiceClient.DefaultEndpoint.Host, InvoiceServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// InvoiceServiceClient client = InvoiceServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static InvoiceServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, InvoiceServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static InvoiceServiceClient Create(grpccore::Channel channel, InvoiceServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static InvoiceServiceClient Create(grpccore::CallInvoker callInvoker, InvoiceServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + InvoiceService.InvoiceServiceClient grpcClient = new InvoiceService.InvoiceServiceClient(callInvoker); + return new InvoiceServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC InvoiceService client. + /// + public virtual InvoiceService.InvoiceServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// + /// Required. The ID of the customer to fetch invoices for. + /// + /// + /// Required. The billing setup resource name of the requested invoices. + /// + /// `customers/{customer_id}/billingSetups/{billing_setup_id}` + /// + /// + /// Required. The issue year to retrieve invoices, in yyyy format. Only + /// invoices issued in 2019 or later can be retrieved. + /// + /// + /// Required. The issue month to retrieve invoices. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task ListInvoicesAsync( + string customerId, + string billingSetup, + string issueYear, + gagve::MonthOfYearEnum.Types.MonthOfYear issueMonth, + gaxgrpc::CallSettings callSettings = null) => ListInvoicesAsync( + new ListInvoicesRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + BillingSetup = gax::GaxPreconditions.CheckNotNullOrEmpty(billingSetup, nameof(billingSetup)), + IssueYear = gax::GaxPreconditions.CheckNotNullOrEmpty(issueYear, nameof(issueYear)), + IssueMonth = issueMonth, + }, + callSettings); + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// + /// Required. The ID of the customer to fetch invoices for. + /// + /// + /// Required. The billing setup resource name of the requested invoices. + /// + /// `customers/{customer_id}/billingSetups/{billing_setup_id}` + /// + /// + /// Required. The issue year to retrieve invoices, in yyyy format. Only + /// invoices issued in 2019 or later can be retrieved. + /// + /// + /// Required. The issue month to retrieve invoices. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task ListInvoicesAsync( + string customerId, + string billingSetup, + string issueYear, + gagve::MonthOfYearEnum.Types.MonthOfYear issueMonth, + st::CancellationToken cancellationToken) => ListInvoicesAsync( + customerId, + billingSetup, + issueYear, + issueMonth, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// + /// Required. The ID of the customer to fetch invoices for. + /// + /// + /// Required. The billing setup resource name of the requested invoices. + /// + /// `customers/{customer_id}/billingSetups/{billing_setup_id}` + /// + /// + /// Required. The issue year to retrieve invoices, in yyyy format. Only + /// invoices issued in 2019 or later can be retrieved. + /// + /// + /// Required. The issue month to retrieve invoices. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual ListInvoicesResponse ListInvoices( + string customerId, + string billingSetup, + string issueYear, + gagve::MonthOfYearEnum.Types.MonthOfYear issueMonth, + gaxgrpc::CallSettings callSettings = null) => ListInvoices( + new ListInvoicesRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + BillingSetup = gax::GaxPreconditions.CheckNotNullOrEmpty(billingSetup, nameof(billingSetup)), + IssueYear = gax::GaxPreconditions.CheckNotNullOrEmpty(issueYear, nameof(issueYear)), + IssueMonth = issueMonth, + }, + callSettings); + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task ListInvoicesAsync( + ListInvoicesRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task ListInvoicesAsync( + ListInvoicesRequest request, + st::CancellationToken cancellationToken) => ListInvoicesAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual ListInvoicesResponse ListInvoices( + ListInvoicesRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// InvoiceService client wrapper implementation, for convenient use. + /// + public sealed partial class InvoiceServiceClientImpl : InvoiceServiceClient + { + private readonly gaxgrpc::ApiCall _callListInvoices; + + /// + /// Constructs a client wrapper for the InvoiceService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public InvoiceServiceClientImpl(InvoiceService.InvoiceServiceClient grpcClient, InvoiceServiceSettings settings) + { + GrpcClient = grpcClient; + InvoiceServiceSettings effectiveSettings = settings ?? InvoiceServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callListInvoices = clientHelper.BuildApiCall( + GrpcClient.ListInvoicesAsync, GrpcClient.ListInvoices, effectiveSettings.ListInvoicesSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callListInvoices); + Modify_ListInvoicesApiCall(ref _callListInvoices); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_ListInvoicesApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(InvoiceService.InvoiceServiceClient grpcClient, InvoiceServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC InvoiceService client. + /// + public override InvoiceService.InvoiceServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_ListInvoicesRequest(ref ListInvoicesRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task ListInvoicesAsync( + ListInvoicesRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_ListInvoicesRequest(ref request, ref callSettings); + return _callListInvoices.Async(request, callSettings); + } + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override ListInvoicesResponse ListInvoices( + ListInvoicesRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_ListInvoicesRequest(ref request, ref callSettings); + return _callListInvoices.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/InvoiceServiceGrpc.cs b/src/V3/Stubs/InvoiceServiceGrpc.cs new file mode 100644 index 000000000..f5ab85342 --- /dev/null +++ b/src/V3/Stubs/InvoiceServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/invoice_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// A service to fetch invoices issued for a billing setup during a given month. + /// + public static partial class InvoiceService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.InvoiceService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_ListInvoicesRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.ListInvoicesRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_ListInvoicesResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.ListInvoicesResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_ListInvoices = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "ListInvoices", + __Marshaller_google_ads_googleads_v3_services_ListInvoicesRequest, + __Marshaller_google_ads_googleads_v3_services_ListInvoicesResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.InvoiceServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of InvoiceService + public abstract partial class InvoiceServiceBase + { + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task ListInvoices(global::Google.Ads.GoogleAds.V3.Services.ListInvoicesRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for InvoiceService + public partial class InvoiceServiceClient : grpc::ClientBase + { + /// Creates a new client for InvoiceService + /// The channel to use to make remote calls. + public InvoiceServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for InvoiceService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public InvoiceServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected InvoiceServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected InvoiceServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.ListInvoicesResponse ListInvoices(global::Google.Ads.GoogleAds.V3.Services.ListInvoicesRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return ListInvoices(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.ListInvoicesResponse ListInvoices(global::Google.Ads.GoogleAds.V3.Services.ListInvoicesRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_ListInvoices, null, options, request); + } + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall ListInvoicesAsync(global::Google.Ads.GoogleAds.V3.Services.ListInvoicesRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return ListInvoicesAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns all invoices associated with a billing setup, for a given month. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall ListInvoicesAsync(global::Google.Ads.GoogleAds.V3.Services.ListInvoicesRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_ListInvoices, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override InvoiceServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new InvoiceServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(InvoiceServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_ListInvoices, serviceImpl.ListInvoices).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, InvoiceServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_ListInvoices, serviceImpl.ListInvoices); + } + + } +} +#endregion diff --git a/src/V3/Stubs/InvoiceType.cs b/src/V3/Stubs/InvoiceType.cs new file mode 100644 index 000000000..2237ced21 --- /dev/null +++ b/src/V3/Stubs/InvoiceType.cs @@ -0,0 +1,184 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/invoice_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/invoice_type.proto + public static partial class InvoiceTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/invoice_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static InvoiceTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9pbnZvaWNlX3R5cGUu", + "cHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxnb29nbGUv", + "YXBpL2Fubm90YXRpb25zLnByb3RvIlwKD0ludm9pY2VUeXBlRW51bSJJCgtJ", + "bnZvaWNlVHlwZRIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIPCgtD", + "UkVESVRfTUVNTxACEgsKB0lOVk9JQ0UQA0LlAQohY29tLmdvb2dsZS5hZHMu", + "Z29vZ2xlYWRzLnYzLmVudW1zQhBJbnZvaWNlVHlwZVByb3RvUAFaQmdvb2ds", + "ZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFk", + "cy92My9lbnVtcztlbnVtc6ICA0dBQaoCHUdvb2dsZS5BZHMuR29vZ2xlQWRz", + "LlYzLkVudW1zygIdR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcRW51bXPqAiFH", + "b29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RW51bXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.InvoiceTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.InvoiceTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.InvoiceTypeEnum.Types.InvoiceType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing the type of invoices. + /// + public sealed partial class InvoiceTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new InvoiceTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.InvoiceTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InvoiceTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InvoiceTypeEnum(InvoiceTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public InvoiceTypeEnum Clone() { + return new InvoiceTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as InvoiceTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(InvoiceTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(InvoiceTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the InvoiceTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// The possible type of invoices. + /// + public enum InvoiceType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// An invoice with a negative amount. The account receives a credit. + /// + [pbr::OriginalName("CREDIT_MEMO")] CreditMemo = 2, + /// + /// An invoice with a positive amount. The account owes a balance. + /// + [pbr::OriginalName("INVOICE")] Invoice = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/JobPlaceholderField.cs b/src/V3/Stubs/JobPlaceholderField.cs new file mode 100644 index 000000000..8b16edc94 --- /dev/null +++ b/src/V3/Stubs/JobPlaceholderField.cs @@ -0,0 +1,271 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/job_placeholder_field.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/job_placeholder_field.proto + public static partial class JobPlaceholderFieldReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/job_placeholder_field.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static JobPlaceholderFieldReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjlnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9qb2JfcGxhY2Vob2xk", + "ZXJfZmllbGQucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1z", + "Ghxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvECChdKb2JQbGFjZWhv", + "bGRlckZpZWxkRW51bSLVAgoTSm9iUGxhY2Vob2xkZXJGaWVsZBIPCgtVTlNQ", + "RUNJRklFRBAAEgsKB1VOS05PV04QARIKCgZKT0JfSUQQAhIPCgtMT0NBVElP", + "Tl9JRBADEgkKBVRJVExFEAQSDAoIU1VCVElUTEUQBRIPCgtERVNDUklQVElP", + "ThAGEg0KCUlNQUdFX1VSTBAHEgwKCENBVEVHT1JZEAgSFwoTQ09OVEVYVFVB", + "TF9LRVlXT1JEUxAJEgsKB0FERFJFU1MQChIKCgZTQUxBUlkQCxIOCgpGSU5B", + "TF9VUkxTEAwSFQoRRklOQUxfTU9CSUxFX1VSTFMQDhIQCgxUUkFDS0lOR19V", + "UkwQDxIUChBBTkRST0lEX0FQUF9MSU5LEBASEwoPU0lNSUxBUl9KT0JfSURT", + "EBESEAoMSU9TX0FQUF9MSU5LEBISFAoQSU9TX0FQUF9TVE9SRV9JRBATQu4B", + "CiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCGUpvYnNQbGFj", + "ZWhvbGRlckZpZWxkUHJvdG9QAVpCZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zO2VudW1zogID", + "R0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuRW51bXPKAh1Hb29nbGVc", + "QWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2dsZTo6QWRzOjpHb29nbGVB", + "ZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.JobPlaceholderFieldEnum), global::Google.Ads.GoogleAds.V3.Enums.JobPlaceholderFieldEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.JobPlaceholderFieldEnum.Types.JobPlaceholderField) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Values for Job placeholder fields. + /// For more information about dynamic remarketing feeds, see + /// https://support.google.com/google-ads/answer/6053288. + /// + public sealed partial class JobPlaceholderFieldEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new JobPlaceholderFieldEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.JobPlaceholderFieldReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public JobPlaceholderFieldEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public JobPlaceholderFieldEnum(JobPlaceholderFieldEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public JobPlaceholderFieldEnum Clone() { + return new JobPlaceholderFieldEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as JobPlaceholderFieldEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(JobPlaceholderFieldEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(JobPlaceholderFieldEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the JobPlaceholderFieldEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible values for Job placeholder fields. + /// + public enum JobPlaceholderField { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Data Type: STRING. Required. If only JOB_ID is specified, then it must be + /// unique. If both JOB_ID and LOCATION_ID are specified, then the + /// pair must be unique. + /// ID) pair must be unique. + /// + [pbr::OriginalName("JOB_ID")] JobId = 2, + /// + /// Data Type: STRING. Combination of JOB_ID and LOCATION_ID must be unique + /// per offer. + /// + [pbr::OriginalName("LOCATION_ID")] LocationId = 3, + /// + /// Data Type: STRING. Required. Main headline with job title to be shown in + /// dynamic ad. + /// + [pbr::OriginalName("TITLE")] Title = 4, + /// + /// Data Type: STRING. Job subtitle to be shown in dynamic ad. + /// + [pbr::OriginalName("SUBTITLE")] Subtitle = 5, + /// + /// Data Type: STRING. Description of job to be shown in dynamic ad. + /// + [pbr::OriginalName("DESCRIPTION")] Description = 6, + /// + /// Data Type: URL. Image to be displayed in the ad. Highly recommended for + /// image ads. + /// + [pbr::OriginalName("IMAGE_URL")] ImageUrl = 7, + /// + /// Data Type: STRING. Category of property used to group like items together + /// for recommendation engine. + /// + [pbr::OriginalName("CATEGORY")] Category = 8, + /// + /// Data Type: STRING_LIST. Keywords used for product retrieval. + /// + [pbr::OriginalName("CONTEXTUAL_KEYWORDS")] ContextualKeywords = 9, + /// + /// Data Type: STRING. Complete property address, including postal code. + /// + [pbr::OriginalName("ADDRESS")] Address = 10, + /// + /// Data Type: STRING. Salary or salary range of job to be shown in dynamic + /// ad. + /// + [pbr::OriginalName("SALARY")] Salary = 11, + /// + /// Data Type: URL_LIST. Required. Final URLs to be used in ad when using + /// Upgraded URLs; the more specific the better (e.g. the individual URL of a + /// specific job and its location). + /// + [pbr::OriginalName("FINAL_URLS")] FinalUrls = 12, + /// + /// Data Type: URL_LIST. Final mobile URLs for the ad when using Upgraded + /// URLs. + /// + [pbr::OriginalName("FINAL_MOBILE_URLS")] FinalMobileUrls = 14, + /// + /// Data Type: URL. Tracking template for the ad when using Upgraded URLs. + /// + [pbr::OriginalName("TRACKING_URL")] TrackingUrl = 15, + /// + /// Data Type: STRING. Android app link. Must be formatted as: + /// android-app://{package_id}/{scheme}/{host_path}. + /// The components are defined as follows: + /// package_id: app ID as specified in Google Play. + /// scheme: the scheme to pass to the application. Can be HTTP, or a custom + /// scheme. + /// host_path: identifies the specific content within your application. + /// + [pbr::OriginalName("ANDROID_APP_LINK")] AndroidAppLink = 16, + /// + /// Data Type: STRING_LIST. List of recommended job IDs to show together with + /// this item. + /// + [pbr::OriginalName("SIMILAR_JOB_IDS")] SimilarJobIds = 17, + /// + /// Data Type: STRING. iOS app link. + /// + [pbr::OriginalName("IOS_APP_LINK")] IosAppLink = 18, + /// + /// Data Type: INT64. iOS app store ID. + /// + [pbr::OriginalName("IOS_APP_STORE_ID")] IosAppStoreId = 19, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordMatchType.cs b/src/V3/Stubs/KeywordMatchType.cs new file mode 100644 index 000000000..ad941874e --- /dev/null +++ b/src/V3/Stubs/KeywordMatchType.cs @@ -0,0 +1,189 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/keyword_match_type.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/keyword_match_type.proto + public static partial class KeywordMatchTypeReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/keyword_match_type.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordMatchTypeReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjZnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9rZXl3b3JkX21hdGNo", + "X3R5cGUucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zGhxn", + "b29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvImoKFEtleXdvcmRNYXRjaFR5", + "cGVFbnVtIlIKEEtleXdvcmRNYXRjaFR5cGUSDwoLVU5TUEVDSUZJRUQQABIL", + "CgdVTktOT1dOEAESCQoFRVhBQ1QQAhIKCgZQSFJBU0UQAxIJCgVCUk9BRBAE", + "QuoBCiFjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXNCFUtleXdv", + "cmRNYXRjaFR5cGVQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90", + "by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNH", + "QUGqAh1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxB", + "ZHNcR29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFk", + "czo6VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum), global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Message describing Keyword match types. + /// + public sealed partial class KeywordMatchTypeEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordMatchTypeEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordMatchTypeEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordMatchTypeEnum(KeywordMatchTypeEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordMatchTypeEnum Clone() { + return new KeywordMatchTypeEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordMatchTypeEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordMatchTypeEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordMatchTypeEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordMatchTypeEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Possible Keyword match types. + /// + public enum KeywordMatchType { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// Used for return value only. Represents value unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Exact match. + /// + [pbr::OriginalName("EXACT")] Exact = 2, + /// + /// Phrase match. + /// + [pbr::OriginalName("PHRASE")] Phrase = 3, + /// + /// Broad match. + /// + [pbr::OriginalName("BROAD")] Broad = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlan.cs b/src/V3/Stubs/KeywordPlan.cs new file mode 100644 index 000000000..5a0927fe4 --- /dev/null +++ b/src/V3/Stubs/KeywordPlan.cs @@ -0,0 +1,531 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/keyword_plan.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/keyword_plan.proto + public static partial class KeywordPlanReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/keyword_plan.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMva2V5d29yZF9w", + "bGFuLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMa", + "Kmdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9kYXRlcy5wcm90bxpC", + "Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMva2V5d29yZF9wbGFuX2Zv", + "cmVjYXN0X2ludGVydmFsLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2", + "aW9yLnByb3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUv", + "cHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlv", + "bnMucHJvdG8i4AIKC0tleXdvcmRQbGFuEkMKDXJlc291cmNlX25hbWUYASAB", + "KAlCLOBBBfpBJgokZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0tleXdvcmRQ", + "bGFuEiwKAmlkGAIgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0VmFsdWVC", + "A+BBAxIqCgRuYW1lGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1Zh", + "bHVlElUKD2ZvcmVjYXN0X3BlcmlvZBgEIAEoCzI8Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5LZXl3b3JkUGxhbkZvcmVjYXN0UGVyaW9k", + "OlvqQVgKJGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9LZXl3b3JkUGxhbhIw", + "Y3VzdG9tZXJzL3tjdXN0b21lcn0va2V5d29yZFBsYW5zL3trZXl3b3JkX3Bs", + "YW59It0BChlLZXl3b3JkUGxhbkZvcmVjYXN0UGVyaW9kEnMKDWRhdGVfaW50", + "ZXJ2YWwYASABKA4yWi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5L", + "ZXl3b3JkUGxhbkZvcmVjYXN0SW50ZXJ2YWxFbnVtLktleXdvcmRQbGFuRm9y", + "ZWNhc3RJbnRlcnZhbEgAEj8KCmRhdGVfcmFuZ2UYAiABKAsyKS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5jb21tb24uRGF0ZVJhbmdlSABCCgoIaW50ZXJ2", + "YWxC/QEKJWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXNC", + "EEtleXdvcmRQbGFuUHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJv", + "dG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNv", + "dXJjZXOiAgNHQUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJj", + "ZXPKAiFHb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29n", + "bGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.DatesReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanForecastIntervalReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan.Parser, new[]{ "ResourceName", "Id", "Name", "ForecastPeriod" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanForecastPeriod), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanForecastPeriod.Parser, new[]{ "DateInterval", "DateRange" }, new[]{ "Interval" }, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A Keyword Planner plan. + /// Max number of saved keyword plans: 10000. + /// It's possible to remove plans if limit is reached. + /// + public sealed partial class KeywordPlan : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlan()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlan() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlan(KeywordPlan other) : this() { + resourceName_ = other.resourceName_; + Id = other.Id; + Name = other.Name; + forecastPeriod_ = other.forecastPeriod_ != null ? other.forecastPeriod_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlan Clone() { + return new KeywordPlan(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the Keyword Planner plan. + /// KeywordPlan resource names have the form: + /// + /// `customers/{customer_id}/keywordPlans/{kp_plan_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "id" field. + public const int IdFieldNumber = 2; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(18); + private long? id_; + /// + /// Output only. The ID of the keyword plan. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 3; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(26); + private string name_; + /// + /// The name of the keyword plan. + /// + /// This field is required and should not be empty when creating new keyword + /// plans. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "forecast_period" field. + public const int ForecastPeriodFieldNumber = 4; + private global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanForecastPeriod forecastPeriod_; + /// + /// The date period used for forecasting the plan. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanForecastPeriod ForecastPeriod { + get { return forecastPeriod_; } + set { + forecastPeriod_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlan); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlan other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (!object.Equals(ForecastPeriod, other.ForecastPeriod)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (forecastPeriod_ != null) hash ^= ForecastPeriod.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (forecastPeriod_ != null) { + output.WriteRawTag(34); + output.WriteMessage(ForecastPeriod); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (forecastPeriod_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(ForecastPeriod); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlan other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.forecastPeriod_ != null) { + if (forecastPeriod_ == null) { + ForecastPeriod = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanForecastPeriod(); + } + ForecastPeriod.MergeFrom(other.ForecastPeriod); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 26: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 34: { + if (forecastPeriod_ == null) { + ForecastPeriod = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanForecastPeriod(); + } + input.ReadMessage(ForecastPeriod); + break; + } + } + } + } + + } + + /// + /// The forecasting period associated with the keyword plan. + /// + public sealed partial class KeywordPlanForecastPeriod : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanForecastPeriod()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanForecastPeriod() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanForecastPeriod(KeywordPlanForecastPeriod other) : this() { + switch (other.IntervalCase) { + case IntervalOneofCase.DateInterval: + DateInterval = other.DateInterval; + break; + case IntervalOneofCase.DateRange: + DateRange = other.DateRange.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanForecastPeriod Clone() { + return new KeywordPlanForecastPeriod(this); + } + + /// Field number for the "date_interval" field. + public const int DateIntervalFieldNumber = 1; + /// + /// A future date range relative to the current date used for forecasting. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanForecastIntervalEnum.Types.KeywordPlanForecastInterval DateInterval { + get { return intervalCase_ == IntervalOneofCase.DateInterval ? (global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanForecastIntervalEnum.Types.KeywordPlanForecastInterval) interval_ : 0; } + set { + interval_ = value; + intervalCase_ = IntervalOneofCase.DateInterval; + } + } + + /// Field number for the "date_range" field. + public const int DateRangeFieldNumber = 2; + /// + /// The custom date range used for forecasting. + /// The start and end dates must be in the future. Otherwise, an error will + /// be returned when the forecasting action is performed. + /// The start and end dates are inclusive. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.DateRange DateRange { + get { return intervalCase_ == IntervalOneofCase.DateRange ? (global::Google.Ads.GoogleAds.V3.Common.DateRange) interval_ : null; } + set { + interval_ = value; + intervalCase_ = value == null ? IntervalOneofCase.None : IntervalOneofCase.DateRange; + } + } + + private object interval_; + /// Enum of possible cases for the "interval" oneof. + public enum IntervalOneofCase { + None = 0, + DateInterval = 1, + DateRange = 2, + } + private IntervalOneofCase intervalCase_ = IntervalOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public IntervalOneofCase IntervalCase { + get { return intervalCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearInterval() { + intervalCase_ = IntervalOneofCase.None; + interval_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanForecastPeriod); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanForecastPeriod other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (DateInterval != other.DateInterval) return false; + if (!object.Equals(DateRange, other.DateRange)) return false; + if (IntervalCase != other.IntervalCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (intervalCase_ == IntervalOneofCase.DateInterval) hash ^= DateInterval.GetHashCode(); + if (intervalCase_ == IntervalOneofCase.DateRange) hash ^= DateRange.GetHashCode(); + hash ^= (int) intervalCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (intervalCase_ == IntervalOneofCase.DateInterval) { + output.WriteRawTag(8); + output.WriteEnum((int) DateInterval); + } + if (intervalCase_ == IntervalOneofCase.DateRange) { + output.WriteRawTag(18); + output.WriteMessage(DateRange); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (intervalCase_ == IntervalOneofCase.DateInterval) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DateInterval); + } + if (intervalCase_ == IntervalOneofCase.DateRange) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(DateRange); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanForecastPeriod other) { + if (other == null) { + return; + } + switch (other.IntervalCase) { + case IntervalOneofCase.DateInterval: + DateInterval = other.DateInterval; + break; + case IntervalOneofCase.DateRange: + if (DateRange == null) { + DateRange = new global::Google.Ads.GoogleAds.V3.Common.DateRange(); + } + DateRange.MergeFrom(other.DateRange); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + interval_ = input.ReadEnum(); + intervalCase_ = IntervalOneofCase.DateInterval; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Common.DateRange subBuilder = new global::Google.Ads.GoogleAds.V3.Common.DateRange(); + if (intervalCase_ == IntervalOneofCase.DateRange) { + subBuilder.MergeFrom(DateRange); + } + input.ReadMessage(subBuilder); + DateRange = subBuilder; + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanAdGroup.cs b/src/V3/Stubs/KeywordPlanAdGroup.cs new file mode 100644 index 000000000..e8a71c794 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanAdGroup.cs @@ -0,0 +1,355 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/keyword_plan_ad_group.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/keyword_plan_ad_group.proto + public static partial class KeywordPlanAdGroupReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/keyword_plan_ad_group.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanAdGroupReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMva2V5d29yZF9w", + "bGFuX2FkX2dyb3VwLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMaH2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdv", + "b2dsZS9hcGkvcmVzb3VyY2UucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFw", + "cGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLTAwoS", + "S2V5d29yZFBsYW5BZEdyb3VwEkoKDXJlc291cmNlX25hbWUYASABKAlCM+BB", + "BfpBLQorZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0tleXdvcmRQbGFuQWRH", + "cm91cBJuChVrZXl3b3JkX3BsYW5fY2FtcGFpZ24YAiABKAsyHC5nb29nbGUu", + "cHJvdG9idWYuU3RyaW5nVmFsdWVCMfpBLgosZ29vZ2xlYWRzLmdvb2dsZWFw", + "aXMuY29tL0tleXdvcmRQbGFuQ2FtcGFpZ24SLAoCaWQYAyABKAsyGy5nb29n", + "bGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEioKBG5hbWUYBCABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSMwoOY3BjX2JpZF9taWNyb3MY", + "BSABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZTpy6kFvCitnb29n", + "bGVhZHMuZ29vZ2xlYXBpcy5jb20vS2V5d29yZFBsYW5BZEdyb3VwEkBjdXN0", + "b21lcnMve2N1c3RvbWVyfS9rZXl3b3JkUGxhbkFkR3JvdXBzL3trZXl3b3Jk", + "X3BsYW5fYWRfZ3JvdXB9QoQCCiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzQhdLZXl3b3JkUGxhbkFkR3JvdXBQcm90b1ABWkpnb29n", + "bGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVh", + "ZHMvdjMvcmVzb3VyY2VzO3Jlc291cmNlc6ICA0dBQaoCIUdvb2dsZS5BZHMu", + "R29vZ2xlQWRzLlYzLlJlc291cmNlc8oCIUdvb2dsZVxBZHNcR29vZ2xlQWRz", + "XFYzXFJlc291cmNlc+oCJUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpS", + "ZXNvdXJjZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup.Parser, new[]{ "ResourceName", "KeywordPlanCampaign", "Id", "Name", "CpcBidMicros" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A Keyword Planner ad group. + /// Max number of keyword plan ad groups per plan: 200. + /// + public sealed partial class KeywordPlanAdGroup : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanAdGroup()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroupReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroup() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroup(KeywordPlanAdGroup other) : this() { + resourceName_ = other.resourceName_; + KeywordPlanCampaign = other.KeywordPlanCampaign; + Id = other.Id; + Name = other.Name; + CpcBidMicros = other.CpcBidMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroup Clone() { + return new KeywordPlanAdGroup(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the Keyword Planner ad group. + /// KeywordPlanAdGroup resource names have the form: + /// + /// `customers/{customer_id}/keywordPlanAdGroups/{kp_ad_group_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "keyword_plan_campaign" field. + public const int KeywordPlanCampaignFieldNumber = 2; + private static readonly pb::FieldCodec _single_keywordPlanCampaign_codec = pb::FieldCodec.ForClassWrapper(18); + private string keywordPlanCampaign_; + /// + /// The keyword plan campaign to which this ad group belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlanCampaign { + get { return keywordPlanCampaign_; } + set { + keywordPlanCampaign_ = value; + } + } + + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the keyword plan ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// The name of the keyword plan ad group. + /// + /// This field is required and should not be empty when creating keyword plan + /// ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "cpc_bid_micros" field. + public const int CpcBidMicrosFieldNumber = 5; + private static readonly pb::FieldCodec _single_cpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(42); + private long? cpcBidMicros_; + /// + /// A default ad group max cpc bid in micros in account currency for all + /// biddable keywords under the keyword plan ad group. + /// If not set, will inherit from parent campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidMicros { + get { return cpcBidMicros_; } + set { + cpcBidMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanAdGroup); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanAdGroup other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (KeywordPlanCampaign != other.KeywordPlanCampaign) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if (CpcBidMicros != other.CpcBidMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (keywordPlanCampaign_ != null) hash ^= KeywordPlanCampaign.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + if (cpcBidMicros_ != null) hash ^= CpcBidMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (keywordPlanCampaign_ != null) { + _single_keywordPlanCampaign_codec.WriteTagAndValue(output, KeywordPlanCampaign); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + if (cpcBidMicros_ != null) { + _single_cpcBidMicros_codec.WriteTagAndValue(output, CpcBidMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (keywordPlanCampaign_ != null) { + size += _single_keywordPlanCampaign_codec.CalculateSizeWithTag(KeywordPlanCampaign); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + if (cpcBidMicros_ != null) { + size += _single_cpcBidMicros_codec.CalculateSizeWithTag(CpcBidMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanAdGroup other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.keywordPlanCampaign_ != null) { + if (keywordPlanCampaign_ == null || other.KeywordPlanCampaign != "") { + KeywordPlanCampaign = other.KeywordPlanCampaign; + } + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + if (other.cpcBidMicros_ != null) { + if (cpcBidMicros_ == null || other.CpcBidMicros != 0L) { + CpcBidMicros = other.CpcBidMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_keywordPlanCampaign_codec.Read(input); + if (keywordPlanCampaign_ == null || value != "") { + KeywordPlanCampaign = value; + } + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 42: { + long? value = _single_cpcBidMicros_codec.Read(input); + if (cpcBidMicros_ == null || value != 0L) { + CpcBidMicros = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanAdGroupError.cs b/src/V3/Stubs/KeywordPlanAdGroupError.cs new file mode 100644 index 000000000..9d7e2ad53 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanAdGroupError.cs @@ -0,0 +1,189 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/keyword_plan_ad_group_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/keyword_plan_ad_group_error.proto + public static partial class KeywordPlanAdGroupErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/keyword_plan_ad_group_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanAdGroupErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMva2V5d29yZF9wbGFu", + "X2FkX2dyb3VwX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lcnJvcnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ifAobS2V5", + "d29yZFBsYW5BZEdyb3VwRXJyb3JFbnVtIl0KF0tleXdvcmRQbGFuQWRHcm91", + "cEVycm9yEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThABEhAKDElOVkFM", + "SURfTkFNRRACEhIKDkRVUExJQ0FURV9OQU1FEANC9wEKImNvbS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5lcnJvcnNCHEtleXdvcmRQbGFuQWRHcm91cEVy", + "cm9yUHJvdG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5H", + "b29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdv", + "b2dsZUFkc1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanAdGroupErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanAdGroupErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanAdGroupErrorEnum.Types.KeywordPlanAdGroupError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible errors from applying a keyword plan + /// ad group. + /// + public sealed partial class KeywordPlanAdGroupErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanAdGroupErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanAdGroupErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupErrorEnum(KeywordPlanAdGroupErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupErrorEnum Clone() { + return new KeywordPlanAdGroupErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanAdGroupErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanAdGroupErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanAdGroupErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanAdGroupErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible errors from applying a keyword plan ad group. + /// + public enum KeywordPlanAdGroupError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The keyword plan ad group name is missing, empty, longer than allowed + /// limit or contains invalid chars. + /// + [pbr::OriginalName("INVALID_NAME")] InvalidName = 2, + /// + /// The keyword plan ad group name is duplicate to an existing keyword plan + /// AdGroup name or other keyword plan AdGroup name in the request. + /// + [pbr::OriginalName("DUPLICATE_NAME")] DuplicateName = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanAdGroupService.cs b/src/V3/Stubs/KeywordPlanAdGroupService.cs new file mode 100644 index 000000000..73964974e --- /dev/null +++ b/src/V3/Stubs/KeywordPlanAdGroupService.cs @@ -0,0 +1,1038 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_ad_group_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/keyword_plan_ad_group_service.proto + public static partial class KeywordPlanAdGroupServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/keyword_plan_ad_group_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanAdGroupServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9rZXl3b3JkX3Bs", + "YW5fYWRfZ3JvdXBfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMaPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcy9rZXl3b3JkX3BsYW5fYWRfZ3JvdXAucHJvdG8aHGdvb2dsZS9hcGkv", + "YW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9n", + "b29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9i", + "dWYvZmllbGRfbWFzay5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8i", + "OgocR2V0S2V5d29yZFBsYW5BZEdyb3VwUmVxdWVzdBIaCg1yZXNvdXJjZV9u", + "YW1lGAEgASgJQgPgQQIixAEKIE11dGF0ZUtleXdvcmRQbGFuQWRHcm91cHNS", + "ZXF1ZXN0EhgKC2N1c3RvbWVyX2lkGAEgASgJQgPgQQISVgoKb3BlcmF0aW9u", + "cxgCIAMoCzI9Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLktl", + "eXdvcmRQbGFuQWRHcm91cE9wZXJhdGlvbkID4EECEhcKD3BhcnRpYWxfZmFp", + "bHVyZRgDIAEoCBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIv8BChtLZXl3b3Jk", + "UGxhbkFkR3JvdXBPcGVyYXRpb24SLwoLdXBkYXRlX21hc2sYBCABKAsyGi5n", + "b29nbGUucHJvdG9idWYuRmllbGRNYXNrEkcKBmNyZWF0ZRgBIAEoCzI1Lmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5LZXl3b3JkUGxhbkFk", + "R3JvdXBIABJHCgZ1cGRhdGUYAiABKAsyNS5nb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5yZXNvdXJjZXMuS2V5d29yZFBsYW5BZEdyb3VwSAASEAoGcmVtb3Zl", + "GAMgASgJSABCCwoJb3BlcmF0aW9uIqkBCiFNdXRhdGVLZXl3b3JkUGxhbkFk", + "R3JvdXBzUmVzcG9uc2USMQoVcGFydGlhbF9mYWlsdXJlX2Vycm9yGAMgASgL", + "MhIuZ29vZ2xlLnJwYy5TdGF0dXMSUQoHcmVzdWx0cxgCIAMoCzJALmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUtleXdvcmRQbGFu", + "QWRHcm91cFJlc3VsdCI3Ch5NdXRhdGVLZXl3b3JkUGxhbkFkR3JvdXBSZXN1", + "bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTKdBAoZS2V5d29yZFBsYW5BZEdy", + "b3VwU2VydmljZRLdAQoVR2V0S2V5d29yZFBsYW5BZEdyb3VwEj4uZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR2V0S2V5d29yZFBsYW5BZEdy", + "b3VwUmVxdWVzdBo1Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNl", + "cy5LZXl3b3JkUGxhbkFkR3JvdXAiTYLT5JMCNxI1L3YzL3tyZXNvdXJjZV9u", + "YW1lPWN1c3RvbWVycy8qL2tleXdvcmRQbGFuQWRHcm91cHMvKn3aQQ1yZXNv", + "dXJjZV9uYW1lEoICChlNdXRhdGVLZXl3b3JkUGxhbkFkR3JvdXBzEkIuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlS2V5d29yZFBs", + "YW5BZEdyb3Vwc1JlcXVlc3QaQy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5NdXRhdGVLZXl3b3JkUGxhbkFkR3JvdXBzUmVzcG9uc2UiXILT", + "5JMCPSI4L3YzL2N1c3RvbWVycy97Y3VzdG9tZXJfaWQ9Kn0va2V5d29yZFBs", + "YW5BZEdyb3VwczptdXRhdGU6ASraQRZjdXN0b21lcl9pZCxvcGVyYXRpb25z", + "GhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb21ChQIKJGNvbS5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0IeS2V5d29yZFBsYW5BZEdyb3Vw", + "U2VydmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6IC", + "A0dBQaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroupReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanAdGroupRequest), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanAdGroupRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupOperation), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupResult), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [KeywordPlanAdGroupService.GetKeywordPlanAdGroup][google.ads.googleads.v3.services.KeywordPlanAdGroupService.GetKeywordPlanAdGroup]. + /// + public sealed partial class GetKeywordPlanAdGroupRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetKeywordPlanAdGroupRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanAdGroupRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanAdGroupRequest(GetKeywordPlanAdGroupRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanAdGroupRequest Clone() { + return new GetKeywordPlanAdGroupRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the Keyword Plan ad group to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetKeywordPlanAdGroupRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetKeywordPlanAdGroupRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetKeywordPlanAdGroupRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [KeywordPlanAdGroupService.MutateKeywordPlanAdGroups][google.ads.googleads.v3.services.KeywordPlanAdGroupService.MutateKeywordPlanAdGroups]. + /// + public sealed partial class MutateKeywordPlanAdGroupsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanAdGroupsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupsRequest(MutateKeywordPlanAdGroupsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupsRequest Clone() { + return new MutateKeywordPlanAdGroupsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose Keyword Plan ad groups are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual Keyword Plan ad groups. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanAdGroupsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanAdGroupsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanAdGroupsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a Keyword Plan ad group. + /// + public sealed partial class KeywordPlanAdGroupOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanAdGroupOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupOperation(KeywordPlanAdGroupOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupOperation Clone() { + return new KeywordPlanAdGroupOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// The FieldMask that determines which resource fields are modified in an + /// update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new Keyword Plan + /// ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The Keyword Plan ad group is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed Keyword Plan ad group + /// is expected, in this format: + /// + /// `customers/{customer_id}/keywordPlanAdGroups/{kp_ad_group_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanAdGroupOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanAdGroupOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanAdGroupOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a Keyword Plan ad group mutate. + /// + public sealed partial class MutateKeywordPlanAdGroupsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanAdGroupsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupsResponse(MutateKeywordPlanAdGroupsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupsResponse Clone() { + return new MutateKeywordPlanAdGroupsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanAdGroupsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanAdGroupsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanAdGroupsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the Keyword Plan ad group mutate. + /// + public sealed partial class MutateKeywordPlanAdGroupResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanAdGroupResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupResult(MutateKeywordPlanAdGroupResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanAdGroupResult Clone() { + return new MutateKeywordPlanAdGroupResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanAdGroupResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanAdGroupResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanAdGroupResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanAdGroupServiceClient.cs b/src/V3/Stubs/KeywordPlanAdGroupServiceClient.cs new file mode 100644 index 000000000..8705a1291 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanAdGroupServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class KeywordPlanAdGroupServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static KeywordPlanAdGroupServiceSettings GetDefault() => new KeywordPlanAdGroupServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public KeywordPlanAdGroupServiceSettings() { } + + private KeywordPlanAdGroupServiceSettings(KeywordPlanAdGroupServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetKeywordPlanAdGroupSettings = existing.GetKeywordPlanAdGroupSettings; + MutateKeywordPlanAdGroupsSettings = existing.MutateKeywordPlanAdGroupsSettings; + OnCopy(existing); + } + + partial void OnCopy(KeywordPlanAdGroupServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanAdGroupServiceClient.GetKeywordPlanAdGroup and KeywordPlanAdGroupServiceClient.GetKeywordPlanAdGroupAsync. + /// + /// + /// The default KeywordPlanAdGroupServiceClient.GetKeywordPlanAdGroup and + /// KeywordPlanAdGroupServiceClient.GetKeywordPlanAdGroupAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetKeywordPlanAdGroupSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanAdGroupServiceClient.MutateKeywordPlanAdGroups and KeywordPlanAdGroupServiceClient.MutateKeywordPlanAdGroupsAsync. + /// + /// + /// The default KeywordPlanAdGroupServiceClient.MutateKeywordPlanAdGroups and + /// KeywordPlanAdGroupServiceClient.MutateKeywordPlanAdGroupsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateKeywordPlanAdGroupsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public KeywordPlanAdGroupServiceSettings Clone() => new KeywordPlanAdGroupServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class KeywordPlanAdGroupServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public KeywordPlanAdGroupServiceSettings Settings { get; set; } + + /// + public override KeywordPlanAdGroupServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return KeywordPlanAdGroupServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return KeywordPlanAdGroupServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => KeywordPlanAdGroupServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => KeywordPlanAdGroupServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => KeywordPlanAdGroupServiceClient.ChannelPool; + } + + /// + /// KeywordPlanAdGroupService client wrapper, for convenient use. + /// + public abstract partial class KeywordPlanAdGroupServiceClient + { + /// + /// The default endpoint for the KeywordPlanAdGroupService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default KeywordPlanAdGroupService scopes. + /// + /// + /// The default KeywordPlanAdGroupService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanAdGroupServiceClient client = await KeywordPlanAdGroupServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanAdGroupServiceClient.DefaultEndpoint.Host, KeywordPlanAdGroupServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanAdGroupServiceClient client = KeywordPlanAdGroupServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanAdGroupServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanAdGroupServiceClient client = KeywordPlanAdGroupServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanAdGroupServiceClient.DefaultEndpoint.Host, KeywordPlanAdGroupServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanAdGroupServiceClient client = KeywordPlanAdGroupServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static KeywordPlanAdGroupServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanAdGroupServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanAdGroupServiceClient Create(grpccore::Channel channel, KeywordPlanAdGroupServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanAdGroupServiceClient Create(grpccore::CallInvoker callInvoker, KeywordPlanAdGroupServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + KeywordPlanAdGroupService.KeywordPlanAdGroupServiceClient grpcClient = new KeywordPlanAdGroupService.KeywordPlanAdGroupServiceClient(callInvoker); + return new KeywordPlanAdGroupServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC KeywordPlanAdGroupService client. + /// + public virtual KeywordPlanAdGroupService.KeywordPlanAdGroupServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// + /// Required. The resource name of the Keyword Plan ad group to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanAdGroupAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanAdGroupAsync( + new GetKeywordPlanAdGroupRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// + /// Required. The resource name of the Keyword Plan ad group to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanAdGroupAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetKeywordPlanAdGroupAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// + /// Required. The resource name of the Keyword Plan ad group to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlanAdGroup GetKeywordPlanAdGroup( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanAdGroup( + new GetKeywordPlanAdGroupRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanAdGroupAsync( + GetKeywordPlanAdGroupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanAdGroupAsync( + GetKeywordPlanAdGroupRequest request, + st::CancellationToken cancellationToken) => GetKeywordPlanAdGroupAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlanAdGroup GetKeywordPlanAdGroup( + GetKeywordPlanAdGroupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan ad groups. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanAdGroupsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanAdGroupsAsync( + new MutateKeywordPlanAdGroupsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan ad groups. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanAdGroupsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateKeywordPlanAdGroupsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan ad groups. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanAdGroupsResponse MutateKeywordPlanAdGroups( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanAdGroups( + new MutateKeywordPlanAdGroupsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan ad groups. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanAdGroupsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanAdGroupsAsync( + new MutateKeywordPlanAdGroupsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan ad groups. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanAdGroupsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateKeywordPlanAdGroupsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan ad groups are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan ad groups. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanAdGroupsResponse MutateKeywordPlanAdGroups( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanAdGroups( + new MutateKeywordPlanAdGroupsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanAdGroupsAsync( + MutateKeywordPlanAdGroupsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanAdGroupsAsync( + MutateKeywordPlanAdGroupsRequest request, + st::CancellationToken cancellationToken) => MutateKeywordPlanAdGroupsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanAdGroupsResponse MutateKeywordPlanAdGroups( + MutateKeywordPlanAdGroupsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// KeywordPlanAdGroupService client wrapper implementation, for convenient use. + /// + public sealed partial class KeywordPlanAdGroupServiceClientImpl : KeywordPlanAdGroupServiceClient + { + private readonly gaxgrpc::ApiCall _callGetKeywordPlanAdGroup; + private readonly gaxgrpc::ApiCall _callMutateKeywordPlanAdGroups; + + /// + /// Constructs a client wrapper for the KeywordPlanAdGroupService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public KeywordPlanAdGroupServiceClientImpl(KeywordPlanAdGroupService.KeywordPlanAdGroupServiceClient grpcClient, KeywordPlanAdGroupServiceSettings settings) + { + GrpcClient = grpcClient; + KeywordPlanAdGroupServiceSettings effectiveSettings = settings ?? KeywordPlanAdGroupServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetKeywordPlanAdGroup = clientHelper.BuildApiCall( + GrpcClient.GetKeywordPlanAdGroupAsync, GrpcClient.GetKeywordPlanAdGroup, effectiveSettings.GetKeywordPlanAdGroupSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateKeywordPlanAdGroups = clientHelper.BuildApiCall( + GrpcClient.MutateKeywordPlanAdGroupsAsync, GrpcClient.MutateKeywordPlanAdGroups, effectiveSettings.MutateKeywordPlanAdGroupsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetKeywordPlanAdGroup); + Modify_GetKeywordPlanAdGroupApiCall(ref _callGetKeywordPlanAdGroup); + Modify_ApiCall(ref _callMutateKeywordPlanAdGroups); + Modify_MutateKeywordPlanAdGroupsApiCall(ref _callMutateKeywordPlanAdGroups); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetKeywordPlanAdGroupApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateKeywordPlanAdGroupsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(KeywordPlanAdGroupService.KeywordPlanAdGroupServiceClient grpcClient, KeywordPlanAdGroupServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC KeywordPlanAdGroupService client. + /// + public override KeywordPlanAdGroupService.KeywordPlanAdGroupServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetKeywordPlanAdGroupRequest(ref GetKeywordPlanAdGroupRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateKeywordPlanAdGroupsRequest(ref MutateKeywordPlanAdGroupsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetKeywordPlanAdGroupAsync( + GetKeywordPlanAdGroupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanAdGroupRequest(ref request, ref callSettings); + return _callGetKeywordPlanAdGroup.Async(request, callSettings); + } + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::KeywordPlanAdGroup GetKeywordPlanAdGroup( + GetKeywordPlanAdGroupRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanAdGroupRequest(ref request, ref callSettings); + return _callGetKeywordPlanAdGroup.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateKeywordPlanAdGroupsAsync( + MutateKeywordPlanAdGroupsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlanAdGroupsRequest(ref request, ref callSettings); + return _callMutateKeywordPlanAdGroups.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateKeywordPlanAdGroupsResponse MutateKeywordPlanAdGroups( + MutateKeywordPlanAdGroupsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlanAdGroupsRequest(ref request, ref callSettings); + return _callMutateKeywordPlanAdGroups.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/KeywordPlanAdGroupServiceGrpc.cs b/src/V3/Stubs/KeywordPlanAdGroupServiceGrpc.cs new file mode 100644 index 000000000..bf7766a1b --- /dev/null +++ b/src/V3/Stubs/KeywordPlanAdGroupServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_ad_group_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage Keyword Plan ad groups. + /// + public static partial class KeywordPlanAdGroupService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.KeywordPlanAdGroupService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanAdGroupRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanAdGroupRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_KeywordPlanAdGroup = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanAdGroupsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanAdGroupsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetKeywordPlanAdGroup = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetKeywordPlanAdGroup", + __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanAdGroupRequest, + __Marshaller_google_ads_googleads_v3_resources_KeywordPlanAdGroup); + + static readonly grpc::Method __Method_MutateKeywordPlanAdGroups = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateKeywordPlanAdGroups", + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanAdGroupsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanAdGroupsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of KeywordPlanAdGroupService + public abstract partial class KeywordPlanAdGroupServiceBase + { + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetKeywordPlanAdGroup(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanAdGroupRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateKeywordPlanAdGroups(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for KeywordPlanAdGroupService + public partial class KeywordPlanAdGroupServiceClient : grpc::ClientBase + { + /// Creates a new client for KeywordPlanAdGroupService + /// The channel to use to make remote calls. + public KeywordPlanAdGroupServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for KeywordPlanAdGroupService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public KeywordPlanAdGroupServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected KeywordPlanAdGroupServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected KeywordPlanAdGroupServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup GetKeywordPlanAdGroup(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanAdGroupRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanAdGroup(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanAdGroup GetKeywordPlanAdGroup(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanAdGroupRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetKeywordPlanAdGroup, null, options, request); + } + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanAdGroupAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanAdGroupRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanAdGroupAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan ad group in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanAdGroupAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanAdGroupRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetKeywordPlanAdGroup, null, options, request); + } + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsResponse MutateKeywordPlanAdGroups(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlanAdGroups(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsResponse MutateKeywordPlanAdGroups(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateKeywordPlanAdGroups, null, options, request); + } + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlanAdGroupsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlanAdGroupsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes Keyword Plan ad groups. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlanAdGroupsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanAdGroupsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateKeywordPlanAdGroups, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override KeywordPlanAdGroupServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new KeywordPlanAdGroupServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(KeywordPlanAdGroupServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetKeywordPlanAdGroup, serviceImpl.GetKeywordPlanAdGroup) + .AddMethod(__Method_MutateKeywordPlanAdGroups, serviceImpl.MutateKeywordPlanAdGroups).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, KeywordPlanAdGroupServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetKeywordPlanAdGroup, serviceImpl.GetKeywordPlanAdGroup); + serviceBinder.AddMethod(__Method_MutateKeywordPlanAdGroups, serviceImpl.MutateKeywordPlanAdGroups); + } + + } +} +#endregion diff --git a/src/V3/Stubs/KeywordPlanCampaign.cs b/src/V3/Stubs/KeywordPlanCampaign.cs new file mode 100644 index 000000000..bf2006365 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanCampaign.cs @@ -0,0 +1,592 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/keyword_plan_campaign.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/keyword_plan_campaign.proto + public static partial class KeywordPlanCampaignReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/keyword_plan_campaign.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanCampaignReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMva2V5d29yZF9w", + "bGFuX2NhbXBhaWduLnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5y", + "ZXNvdXJjZXMaOGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2tleXdv", + "cmRfcGxhbl9uZXR3b3JrLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2", + "aW9yLnByb3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUv", + "cHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlv", + "bnMucHJvdG8i5gUKE0tleXdvcmRQbGFuQ2FtcGFpZ24SSwoNcmVzb3VyY2Vf", + "bmFtZRgBIAEoCUI04EEF+kEuCixnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20v", + "S2V5d29yZFBsYW5DYW1wYWlnbhJdCgxrZXl3b3JkX3BsYW4YAiABKAsyHC5n", + "b29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWVCKfpBJgokZ29vZ2xlYWRzLmdv", + "b2dsZWFwaXMuY29tL0tleXdvcmRQbGFuEiwKAmlkGAMgASgLMhsuZ29vZ2xl", + "LnByb3RvYnVmLkludDY0VmFsdWVCA+BBAxIqCgRuYW1lGAQgASgLMhwuZ29v", + "Z2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEmgKEmxhbmd1YWdlX2NvbnN0YW50", + "cxgFIAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZUIu+kErCiln", + "b29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vTGFuZ3VhZ2VDb25zdGFudBJmChRr", + "ZXl3b3JkX3BsYW5fbmV0d29yaxgGIAEoDjJILmdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLmVudW1zLktleXdvcmRQbGFuTmV0d29ya0VudW0uS2V5d29yZFBs", + "YW5OZXR3b3JrEjMKDmNwY19iaWRfbWljcm9zGAcgASgLMhsuZ29vZ2xlLnBy", + "b3RvYnVmLkludDY0VmFsdWUSTAoLZ2VvX3RhcmdldHMYCCADKAsyNy5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuS2V5d29yZFBsYW5HZW9U", + "YXJnZXQ6dOpBcQosZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0tleXdvcmRQ", + "bGFuQ2FtcGFpZ24SQWN1c3RvbWVycy97Y3VzdG9tZXJ9L2tleXdvcmRQbGFu", + "Q2FtcGFpZ25zL3trZXl3b3JkX3BsYW5fY2FtcGFpZ259IoIBChRLZXl3b3Jk", + "UGxhbkdlb1RhcmdldBJqChNnZW9fdGFyZ2V0X2NvbnN0YW50GAEgASgLMhwu", + "Z29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQi/6QSwKKmdvb2dsZWFkcy5n", + "b29nbGVhcGlzLmNvbS9HZW9UYXJnZXRDb25zdGFudEKFAgolY29tLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlc0IYS2V5d29yZFBsYW5DYW1w", + "YWlnblByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogID", + "R0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29v", + "Z2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6", + "Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign.Parser, new[]{ "ResourceName", "KeywordPlan", "Id", "Name", "LanguageConstants", "KeywordPlanNetwork", "CpcBidMicros", "GeoTargets" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanGeoTarget), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanGeoTarget.Parser, new[]{ "GeoTargetConstant" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A Keyword Plan campaign. + /// Max number of keyword plan campaigns per plan allowed: 1. + /// + public sealed partial class KeywordPlanCampaign : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanCampaign()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaignReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaign() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaign(KeywordPlanCampaign other) : this() { + resourceName_ = other.resourceName_; + KeywordPlan = other.KeywordPlan; + Id = other.Id; + Name = other.Name; + languageConstants_ = other.languageConstants_.Clone(); + keywordPlanNetwork_ = other.keywordPlanNetwork_; + CpcBidMicros = other.CpcBidMicros; + geoTargets_ = other.geoTargets_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaign Clone() { + return new KeywordPlanCampaign(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the Keyword Plan campaign. + /// KeywordPlanCampaign resource names have the form: + /// + /// `customers/{customer_id}/keywordPlanCampaigns/{kp_campaign_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "keyword_plan" field. + public const int KeywordPlanFieldNumber = 2; + private static readonly pb::FieldCodec _single_keywordPlan_codec = pb::FieldCodec.ForClassWrapper(18); + private string keywordPlan_; + /// + /// The keyword plan this campaign belongs to. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlan { + get { return keywordPlan_; } + set { + keywordPlan_ = value; + } + } + + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the Keyword Plan campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "name" field. + public const int NameFieldNumber = 4; + private static readonly pb::FieldCodec _single_name_codec = pb::FieldCodec.ForClassWrapper(34); + private string name_; + /// + /// The name of the Keyword Plan campaign. + /// + /// This field is required and should not be empty when creating Keyword Plan + /// campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Name { + get { return name_; } + set { + name_ = value; + } + } + + + /// Field number for the "language_constants" field. + public const int LanguageConstantsFieldNumber = 5; + private static readonly pb::FieldCodec _repeated_languageConstants_codec + = pb::FieldCodec.ForClassWrapper(42); + private readonly pbc::RepeatedField languageConstants_ = new pbc::RepeatedField(); + /// + /// The languages targeted for the Keyword Plan campaign. + /// Max allowed: 1. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField LanguageConstants { + get { return languageConstants_; } + } + + /// Field number for the "keyword_plan_network" field. + public const int KeywordPlanNetworkFieldNumber = 6; + private global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types.KeywordPlanNetwork keywordPlanNetwork_ = 0; + /// + /// Targeting network. + /// + /// This field is required and should not be empty when creating Keyword Plan + /// campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types.KeywordPlanNetwork KeywordPlanNetwork { + get { return keywordPlanNetwork_; } + set { + keywordPlanNetwork_ = value; + } + } + + /// Field number for the "cpc_bid_micros" field. + public const int CpcBidMicrosFieldNumber = 7; + private static readonly pb::FieldCodec _single_cpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(58); + private long? cpcBidMicros_; + /// + /// A default max cpc bid in micros, and in the account currency, for all ad + /// groups under the campaign. + /// + /// This field is required and should not be empty when creating Keyword Plan + /// campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidMicros { + get { return cpcBidMicros_; } + set { + cpcBidMicros_ = value; + } + } + + + /// Field number for the "geo_targets" field. + public const int GeoTargetsFieldNumber = 8; + private static readonly pb::FieldCodec _repeated_geoTargets_codec + = pb::FieldCodec.ForMessage(66, global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanGeoTarget.Parser); + private readonly pbc::RepeatedField geoTargets_ = new pbc::RepeatedField(); + /// + /// The geo targets. + /// Max number allowed: 20. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField GeoTargets { + get { return geoTargets_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanCampaign); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanCampaign other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (KeywordPlan != other.KeywordPlan) return false; + if (Id != other.Id) return false; + if (Name != other.Name) return false; + if(!languageConstants_.Equals(other.languageConstants_)) return false; + if (KeywordPlanNetwork != other.KeywordPlanNetwork) return false; + if (CpcBidMicros != other.CpcBidMicros) return false; + if(!geoTargets_.Equals(other.geoTargets_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (keywordPlan_ != null) hash ^= KeywordPlan.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (name_ != null) hash ^= Name.GetHashCode(); + hash ^= languageConstants_.GetHashCode(); + if (KeywordPlanNetwork != 0) hash ^= KeywordPlanNetwork.GetHashCode(); + if (cpcBidMicros_ != null) hash ^= CpcBidMicros.GetHashCode(); + hash ^= geoTargets_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (keywordPlan_ != null) { + _single_keywordPlan_codec.WriteTagAndValue(output, KeywordPlan); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (name_ != null) { + _single_name_codec.WriteTagAndValue(output, Name); + } + languageConstants_.WriteTo(output, _repeated_languageConstants_codec); + if (KeywordPlanNetwork != 0) { + output.WriteRawTag(48); + output.WriteEnum((int) KeywordPlanNetwork); + } + if (cpcBidMicros_ != null) { + _single_cpcBidMicros_codec.WriteTagAndValue(output, CpcBidMicros); + } + geoTargets_.WriteTo(output, _repeated_geoTargets_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (keywordPlan_ != null) { + size += _single_keywordPlan_codec.CalculateSizeWithTag(KeywordPlan); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (name_ != null) { + size += _single_name_codec.CalculateSizeWithTag(Name); + } + size += languageConstants_.CalculateSize(_repeated_languageConstants_codec); + if (KeywordPlanNetwork != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) KeywordPlanNetwork); + } + if (cpcBidMicros_ != null) { + size += _single_cpcBidMicros_codec.CalculateSizeWithTag(CpcBidMicros); + } + size += geoTargets_.CalculateSize(_repeated_geoTargets_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanCampaign other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.keywordPlan_ != null) { + if (keywordPlan_ == null || other.KeywordPlan != "") { + KeywordPlan = other.KeywordPlan; + } + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.name_ != null) { + if (name_ == null || other.Name != "") { + Name = other.Name; + } + } + languageConstants_.Add(other.languageConstants_); + if (other.KeywordPlanNetwork != 0) { + KeywordPlanNetwork = other.KeywordPlanNetwork; + } + if (other.cpcBidMicros_ != null) { + if (cpcBidMicros_ == null || other.CpcBidMicros != 0L) { + CpcBidMicros = other.CpcBidMicros; + } + } + geoTargets_.Add(other.geoTargets_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_keywordPlan_codec.Read(input); + if (keywordPlan_ == null || value != "") { + KeywordPlan = value; + } + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_name_codec.Read(input); + if (name_ == null || value != "") { + Name = value; + } + break; + } + case 42: { + languageConstants_.AddEntriesFrom(input, _repeated_languageConstants_codec); + break; + } + case 48: { + KeywordPlanNetwork = (global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types.KeywordPlanNetwork) input.ReadEnum(); + break; + } + case 58: { + long? value = _single_cpcBidMicros_codec.Read(input); + if (cpcBidMicros_ == null || value != 0L) { + CpcBidMicros = value; + } + break; + } + case 66: { + geoTargets_.AddEntriesFrom(input, _repeated_geoTargets_codec); + break; + } + } + } + } + + } + + /// + /// A geo target. + /// Next ID: 3 + /// + public sealed partial class KeywordPlanGeoTarget : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanGeoTarget()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaignReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanGeoTarget() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanGeoTarget(KeywordPlanGeoTarget other) : this() { + GeoTargetConstant = other.GeoTargetConstant; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanGeoTarget Clone() { + return new KeywordPlanGeoTarget(this); + } + + /// Field number for the "geo_target_constant" field. + public const int GeoTargetConstantFieldNumber = 1; + private static readonly pb::FieldCodec _single_geoTargetConstant_codec = pb::FieldCodec.ForClassWrapper(10); + private string geoTargetConstant_; + /// + /// Required. The resource name of the geo target. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string GeoTargetConstant { + get { return geoTargetConstant_; } + set { + geoTargetConstant_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanGeoTarget); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanGeoTarget other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (GeoTargetConstant != other.GeoTargetConstant) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (geoTargetConstant_ != null) hash ^= GeoTargetConstant.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (geoTargetConstant_ != null) { + _single_geoTargetConstant_codec.WriteTagAndValue(output, GeoTargetConstant); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (geoTargetConstant_ != null) { + size += _single_geoTargetConstant_codec.CalculateSizeWithTag(GeoTargetConstant); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanGeoTarget other) { + if (other == null) { + return; + } + if (other.geoTargetConstant_ != null) { + if (geoTargetConstant_ == null || other.GeoTargetConstant != "") { + GeoTargetConstant = other.GeoTargetConstant; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_geoTargetConstant_codec.Read(input); + if (geoTargetConstant_ == null || value != "") { + GeoTargetConstant = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanCampaignError.cs b/src/V3/Stubs/KeywordPlanCampaignError.cs new file mode 100644 index 000000000..96be7a511 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanCampaignError.cs @@ -0,0 +1,202 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/keyword_plan_campaign_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/keyword_plan_campaign_error.proto + public static partial class KeywordPlanCampaignErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/keyword_plan_campaign_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanCampaignErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMva2V5d29yZF9wbGFu", + "X2NhbXBhaWduX2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5lcnJvcnMaHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ivwEKHEtl", + "eXdvcmRQbGFuQ2FtcGFpZ25FcnJvckVudW0ingEKGEtleXdvcmRQbGFuQ2Ft", + "cGFpZ25FcnJvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIQCgxJ", + "TlZBTElEX05BTUUQAhIVChFJTlZBTElEX0xBTkdVQUdFUxADEhAKDElOVkFM", + "SURfR0VPUxAEEhIKDkRVUExJQ0FURV9OQU1FEAUSFQoRTUFYX0dFT1NfRVhD", + "RUVERUQQBkL4AQoiY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVycm9y", + "c0IdS2V5d29yZFBsYW5DYW1wYWlnbkVycm9yUHJvdG9QAVpEZ29vZ2xlLmdv", + "bGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3Yz", + "L2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2dsZUFkcy5W", + "My5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFcnJvcnPqAiJH", + "b29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJyb3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanCampaignErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanCampaignErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanCampaignErrorEnum.Types.KeywordPlanCampaignError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible errors from applying a keyword plan + /// campaign. + /// + public sealed partial class KeywordPlanCampaignErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanCampaignErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanCampaignErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignErrorEnum(KeywordPlanCampaignErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignErrorEnum Clone() { + return new KeywordPlanCampaignErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanCampaignErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanCampaignErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanCampaignErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanCampaignErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible errors from applying a keyword plan campaign. + /// + public enum KeywordPlanCampaignError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// A keyword plan campaign name is missing, empty, longer than allowed limit + /// or contains invalid chars. + /// + [pbr::OriginalName("INVALID_NAME")] InvalidName = 2, + /// + /// A keyword plan campaign contains one or more untargetable languages. + /// + [pbr::OriginalName("INVALID_LANGUAGES")] InvalidLanguages = 3, + /// + /// A keyword plan campaign contains one or more invalid geo targets. + /// + [pbr::OriginalName("INVALID_GEOS")] InvalidGeos = 4, + /// + /// The keyword plan campaign name is duplicate to an existing keyword plan + /// campaign name or other keyword plan campaign name in the request. + /// + [pbr::OriginalName("DUPLICATE_NAME")] DuplicateName = 5, + /// + /// The number of geo targets in the keyword plan campaign exceeds limits. + /// + [pbr::OriginalName("MAX_GEOS_EXCEEDED")] MaxGeosExceeded = 6, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanCampaignService.cs b/src/V3/Stubs/KeywordPlanCampaignService.cs new file mode 100644 index 000000000..0d11a26cc --- /dev/null +++ b/src/V3/Stubs/KeywordPlanCampaignService.cs @@ -0,0 +1,1040 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_campaign_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/keyword_plan_campaign_service.proto + public static partial class KeywordPlanCampaignServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/keyword_plan_campaign_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanCampaignServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9rZXl3b3JkX3Bs", + "YW5fY2FtcGFpZ25fc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMaPWdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291", + "cmNlcy9rZXl3b3JkX3BsYW5fY2FtcGFpZ24ucHJvdG8aHGdvb2dsZS9hcGkv", + "YW5ub3RhdGlvbnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9n", + "b29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9yLnByb3RvGiBnb29nbGUvcHJvdG9i", + "dWYvZmllbGRfbWFzay5wcm90bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8i", + "OwodR2V0S2V5d29yZFBsYW5DYW1wYWlnblJlcXVlc3QSGgoNcmVzb3VyY2Vf", + "bmFtZRgBIAEoCUID4EECIsYBCiFNdXRhdGVLZXl3b3JkUGxhbkNhbXBhaWdu", + "c1JlcXVlc3QSGAoLY3VzdG9tZXJfaWQYASABKAlCA+BBAhJXCgpvcGVyYXRp", + "b25zGAIgAygLMj4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "S2V5d29yZFBsYW5DYW1wYWlnbk9wZXJhdGlvbkID4EECEhcKD3BhcnRpYWxf", + "ZmFpbHVyZRgDIAEoCBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIoICChxLZXl3", + "b3JkUGxhbkNhbXBhaWduT3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAQgASgL", + "MhouZ29vZ2xlLnByb3RvYnVmLkZpZWxkTWFzaxJICgZjcmVhdGUYASABKAsy", + "Ni5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuS2V5d29yZFBs", + "YW5DYW1wYWlnbkgAEkgKBnVwZGF0ZRgCIAEoCzI2Lmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnJlc291cmNlcy5LZXl3b3JkUGxhbkNhbXBhaWduSAASEAoG", + "cmVtb3ZlGAMgASgJSABCCwoJb3BlcmF0aW9uIqsBCiJNdXRhdGVLZXl3b3Jk", + "UGxhbkNhbXBhaWduc1Jlc3BvbnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJv", + "chgDIAEoCzISLmdvb2dsZS5ycGMuU3RhdHVzElIKB3Jlc3VsdHMYAiADKAsy", + "QS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVLZXl3", + "b3JkUGxhbkNhbXBhaWduUmVzdWx0IjgKH011dGF0ZUtleXdvcmRQbGFuQ2Ft", + "cGFpZ25SZXN1bHQSFQoNcmVzb3VyY2VfbmFtZRgBIAEoCTKmBAoaS2V5d29y", + "ZFBsYW5DYW1wYWlnblNlcnZpY2US4QEKFkdldEtleXdvcmRQbGFuQ2FtcGFp", + "Z24SPy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXRLZXl3", + "b3JkUGxhbkNhbXBhaWduUmVxdWVzdBo2Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnJlc291cmNlcy5LZXl3b3JkUGxhbkNhbXBhaWduIk6C0+STAjgSNi92", + "My97cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9rZXl3b3JkUGxhbkNhbXBh", + "aWducy8qfdpBDXJlc291cmNlX25hbWUShgIKGk11dGF0ZUtleXdvcmRQbGFu", + "Q2FtcGFpZ25zEkMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMu", + "TXV0YXRlS2V5d29yZFBsYW5DYW1wYWlnbnNSZXF1ZXN0GkQuZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0YXRlS2V5d29yZFBsYW5DYW1w", + "YWlnbnNSZXNwb25zZSJdgtPkkwI+IjkvdjMvY3VzdG9tZXJzL3tjdXN0b21l", + "cl9pZD0qfS9rZXl3b3JkUGxhbkNhbXBhaWduczptdXRhdGU6ASraQRZjdXN0", + "b21lcl9pZCxvcGVyYXRpb25zGhvKQRhnb29nbGVhZHMuZ29vZ2xlYXBpcy5j", + "b21ChgIKJGNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlc0If", + "S2V5d29yZFBsYW5DYW1wYWlnblNlcnZpY2VQcm90b1ABWkhnb29nbGUuZ29s", + "YW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMv", + "c2VydmljZXM7c2VydmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdvb2dsZUFk", + "cy5WMy5TZXJ2aWNlc8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZp", + "Y2Vz6gIkR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZpY2VzYgZw", + "cm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaignReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanCampaignRequest), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanCampaignRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignOperation), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignResult), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [KeywordPlanCampaignService.GetKeywordPlanCampaign][google.ads.googleads.v3.services.KeywordPlanCampaignService.GetKeywordPlanCampaign]. + /// + public sealed partial class GetKeywordPlanCampaignRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetKeywordPlanCampaignRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanCampaignRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanCampaignRequest(GetKeywordPlanCampaignRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanCampaignRequest Clone() { + return new GetKeywordPlanCampaignRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the Keyword Plan campaign to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetKeywordPlanCampaignRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetKeywordPlanCampaignRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetKeywordPlanCampaignRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [KeywordPlanCampaignService.MutateKeywordPlanCampaigns][google.ads.googleads.v3.services.KeywordPlanCampaignService.MutateKeywordPlanCampaigns]. + /// + public sealed partial class MutateKeywordPlanCampaignsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanCampaignsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignsRequest(MutateKeywordPlanCampaignsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignsRequest Clone() { + return new MutateKeywordPlanCampaignsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose Keyword Plan campaigns are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual Keyword Plan campaigns. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanCampaignsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanCampaignsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanCampaignsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a Keyword Plan campaign. + /// + public sealed partial class KeywordPlanCampaignOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanCampaignOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignOperation(KeywordPlanCampaignOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignOperation Clone() { + return new KeywordPlanCampaignOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// The FieldMask that determines which resource fields are modified in an + /// update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new Keyword Plan + /// campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The Keyword Plan campaign is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed Keyword Plan campaign + /// is expected, in this format: + /// + /// `customers/{customer_id}/keywordPlanCampaigns/{keywordPlan_campaign_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanCampaignOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanCampaignOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanCampaignOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a Keyword Plan campaign mutate. + /// + public sealed partial class MutateKeywordPlanCampaignsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanCampaignsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignsResponse(MutateKeywordPlanCampaignsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignsResponse Clone() { + return new MutateKeywordPlanCampaignsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanCampaignsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanCampaignsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanCampaignsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the Keyword Plan campaign mutate. + /// + public sealed partial class MutateKeywordPlanCampaignResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanCampaignResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignResult(MutateKeywordPlanCampaignResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanCampaignResult Clone() { + return new MutateKeywordPlanCampaignResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanCampaignResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanCampaignResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanCampaignResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanCampaignServiceClient.cs b/src/V3/Stubs/KeywordPlanCampaignServiceClient.cs new file mode 100644 index 000000000..6ca490eb2 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanCampaignServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class KeywordPlanCampaignServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static KeywordPlanCampaignServiceSettings GetDefault() => new KeywordPlanCampaignServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public KeywordPlanCampaignServiceSettings() { } + + private KeywordPlanCampaignServiceSettings(KeywordPlanCampaignServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetKeywordPlanCampaignSettings = existing.GetKeywordPlanCampaignSettings; + MutateKeywordPlanCampaignsSettings = existing.MutateKeywordPlanCampaignsSettings; + OnCopy(existing); + } + + partial void OnCopy(KeywordPlanCampaignServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanCampaignServiceClient.GetKeywordPlanCampaign and KeywordPlanCampaignServiceClient.GetKeywordPlanCampaignAsync. + /// + /// + /// The default KeywordPlanCampaignServiceClient.GetKeywordPlanCampaign and + /// KeywordPlanCampaignServiceClient.GetKeywordPlanCampaignAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetKeywordPlanCampaignSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanCampaignServiceClient.MutateKeywordPlanCampaigns and KeywordPlanCampaignServiceClient.MutateKeywordPlanCampaignsAsync. + /// + /// + /// The default KeywordPlanCampaignServiceClient.MutateKeywordPlanCampaigns and + /// KeywordPlanCampaignServiceClient.MutateKeywordPlanCampaignsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateKeywordPlanCampaignsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public KeywordPlanCampaignServiceSettings Clone() => new KeywordPlanCampaignServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class KeywordPlanCampaignServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public KeywordPlanCampaignServiceSettings Settings { get; set; } + + /// + public override KeywordPlanCampaignServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return KeywordPlanCampaignServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return KeywordPlanCampaignServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => KeywordPlanCampaignServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => KeywordPlanCampaignServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => KeywordPlanCampaignServiceClient.ChannelPool; + } + + /// + /// KeywordPlanCampaignService client wrapper, for convenient use. + /// + public abstract partial class KeywordPlanCampaignServiceClient + { + /// + /// The default endpoint for the KeywordPlanCampaignService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default KeywordPlanCampaignService scopes. + /// + /// + /// The default KeywordPlanCampaignService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanCampaignServiceClient client = await KeywordPlanCampaignServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanCampaignServiceClient.DefaultEndpoint.Host, KeywordPlanCampaignServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanCampaignServiceClient client = KeywordPlanCampaignServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanCampaignServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanCampaignServiceClient client = KeywordPlanCampaignServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanCampaignServiceClient.DefaultEndpoint.Host, KeywordPlanCampaignServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanCampaignServiceClient client = KeywordPlanCampaignServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static KeywordPlanCampaignServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanCampaignServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanCampaignServiceClient Create(grpccore::Channel channel, KeywordPlanCampaignServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanCampaignServiceClient Create(grpccore::CallInvoker callInvoker, KeywordPlanCampaignServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + KeywordPlanCampaignService.KeywordPlanCampaignServiceClient grpcClient = new KeywordPlanCampaignService.KeywordPlanCampaignServiceClient(callInvoker); + return new KeywordPlanCampaignServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC KeywordPlanCampaignService client. + /// + public virtual KeywordPlanCampaignService.KeywordPlanCampaignServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// + /// Required. The resource name of the Keyword Plan campaign to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanCampaignAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanCampaignAsync( + new GetKeywordPlanCampaignRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// + /// Required. The resource name of the Keyword Plan campaign to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanCampaignAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetKeywordPlanCampaignAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// + /// Required. The resource name of the Keyword Plan campaign to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlanCampaign GetKeywordPlanCampaign( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanCampaign( + new GetKeywordPlanCampaignRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanCampaignAsync( + GetKeywordPlanCampaignRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanCampaignAsync( + GetKeywordPlanCampaignRequest request, + st::CancellationToken cancellationToken) => GetKeywordPlanCampaignAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlanCampaign GetKeywordPlanCampaign( + GetKeywordPlanCampaignRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan campaigns. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanCampaignsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanCampaignsAsync( + new MutateKeywordPlanCampaignsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan campaigns. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanCampaignsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateKeywordPlanCampaignsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan campaigns. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanCampaignsResponse MutateKeywordPlanCampaigns( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanCampaigns( + new MutateKeywordPlanCampaignsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan campaigns. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanCampaignsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanCampaignsAsync( + new MutateKeywordPlanCampaignsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan campaigns. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanCampaignsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateKeywordPlanCampaignsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan campaigns are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan campaigns. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanCampaignsResponse MutateKeywordPlanCampaigns( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanCampaigns( + new MutateKeywordPlanCampaignsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanCampaignsAsync( + MutateKeywordPlanCampaignsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanCampaignsAsync( + MutateKeywordPlanCampaignsRequest request, + st::CancellationToken cancellationToken) => MutateKeywordPlanCampaignsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanCampaignsResponse MutateKeywordPlanCampaigns( + MutateKeywordPlanCampaignsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// KeywordPlanCampaignService client wrapper implementation, for convenient use. + /// + public sealed partial class KeywordPlanCampaignServiceClientImpl : KeywordPlanCampaignServiceClient + { + private readonly gaxgrpc::ApiCall _callGetKeywordPlanCampaign; + private readonly gaxgrpc::ApiCall _callMutateKeywordPlanCampaigns; + + /// + /// Constructs a client wrapper for the KeywordPlanCampaignService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public KeywordPlanCampaignServiceClientImpl(KeywordPlanCampaignService.KeywordPlanCampaignServiceClient grpcClient, KeywordPlanCampaignServiceSettings settings) + { + GrpcClient = grpcClient; + KeywordPlanCampaignServiceSettings effectiveSettings = settings ?? KeywordPlanCampaignServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetKeywordPlanCampaign = clientHelper.BuildApiCall( + GrpcClient.GetKeywordPlanCampaignAsync, GrpcClient.GetKeywordPlanCampaign, effectiveSettings.GetKeywordPlanCampaignSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateKeywordPlanCampaigns = clientHelper.BuildApiCall( + GrpcClient.MutateKeywordPlanCampaignsAsync, GrpcClient.MutateKeywordPlanCampaigns, effectiveSettings.MutateKeywordPlanCampaignsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetKeywordPlanCampaign); + Modify_GetKeywordPlanCampaignApiCall(ref _callGetKeywordPlanCampaign); + Modify_ApiCall(ref _callMutateKeywordPlanCampaigns); + Modify_MutateKeywordPlanCampaignsApiCall(ref _callMutateKeywordPlanCampaigns); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetKeywordPlanCampaignApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateKeywordPlanCampaignsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(KeywordPlanCampaignService.KeywordPlanCampaignServiceClient grpcClient, KeywordPlanCampaignServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC KeywordPlanCampaignService client. + /// + public override KeywordPlanCampaignService.KeywordPlanCampaignServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetKeywordPlanCampaignRequest(ref GetKeywordPlanCampaignRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateKeywordPlanCampaignsRequest(ref MutateKeywordPlanCampaignsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetKeywordPlanCampaignAsync( + GetKeywordPlanCampaignRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanCampaignRequest(ref request, ref callSettings); + return _callGetKeywordPlanCampaign.Async(request, callSettings); + } + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::KeywordPlanCampaign GetKeywordPlanCampaign( + GetKeywordPlanCampaignRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanCampaignRequest(ref request, ref callSettings); + return _callGetKeywordPlanCampaign.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateKeywordPlanCampaignsAsync( + MutateKeywordPlanCampaignsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlanCampaignsRequest(ref request, ref callSettings); + return _callMutateKeywordPlanCampaigns.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateKeywordPlanCampaignsResponse MutateKeywordPlanCampaigns( + MutateKeywordPlanCampaignsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlanCampaignsRequest(ref request, ref callSettings); + return _callMutateKeywordPlanCampaigns.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/KeywordPlanCampaignServiceGrpc.cs b/src/V3/Stubs/KeywordPlanCampaignServiceGrpc.cs new file mode 100644 index 000000000..e9e41c0e7 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanCampaignServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_campaign_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage Keyword Plan campaigns. + /// + public static partial class KeywordPlanCampaignService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.KeywordPlanCampaignService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanCampaignRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanCampaignRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_KeywordPlanCampaign = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanCampaignsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanCampaignsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetKeywordPlanCampaign = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetKeywordPlanCampaign", + __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanCampaignRequest, + __Marshaller_google_ads_googleads_v3_resources_KeywordPlanCampaign); + + static readonly grpc::Method __Method_MutateKeywordPlanCampaigns = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateKeywordPlanCampaigns", + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanCampaignsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanCampaignsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of KeywordPlanCampaignService + public abstract partial class KeywordPlanCampaignServiceBase + { + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetKeywordPlanCampaign(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanCampaignRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateKeywordPlanCampaigns(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for KeywordPlanCampaignService + public partial class KeywordPlanCampaignServiceClient : grpc::ClientBase + { + /// Creates a new client for KeywordPlanCampaignService + /// The channel to use to make remote calls. + public KeywordPlanCampaignServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for KeywordPlanCampaignService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public KeywordPlanCampaignServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected KeywordPlanCampaignServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected KeywordPlanCampaignServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign GetKeywordPlanCampaign(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanCampaignRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanCampaign(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanCampaign GetKeywordPlanCampaign(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanCampaignRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetKeywordPlanCampaign, null, options, request); + } + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanCampaignAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanCampaignRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanCampaignAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan campaign in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanCampaignAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanCampaignRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetKeywordPlanCampaign, null, options, request); + } + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsResponse MutateKeywordPlanCampaigns(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlanCampaigns(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsResponse MutateKeywordPlanCampaigns(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateKeywordPlanCampaigns, null, options, request); + } + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlanCampaignsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlanCampaignsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes Keyword Plan campaigns. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlanCampaignsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanCampaignsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateKeywordPlanCampaigns, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override KeywordPlanCampaignServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new KeywordPlanCampaignServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(KeywordPlanCampaignServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetKeywordPlanCampaign, serviceImpl.GetKeywordPlanCampaign) + .AddMethod(__Method_MutateKeywordPlanCampaigns, serviceImpl.MutateKeywordPlanCampaigns).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, KeywordPlanCampaignServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetKeywordPlanCampaign, serviceImpl.GetKeywordPlanCampaign); + serviceBinder.AddMethod(__Method_MutateKeywordPlanCampaigns, serviceImpl.MutateKeywordPlanCampaigns); + } + + } +} +#endregion diff --git a/src/V3/Stubs/KeywordPlanCommon.cs b/src/V3/Stubs/KeywordPlanCommon.cs new file mode 100644 index 000000000..eb6dfc5e9 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanCommon.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/common/keyword_plan_common.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Common { + + /// Holder for reflection information generated from google/ads/googleads/v3/common/keyword_plan_common.proto + public static partial class KeywordPlanCommonReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/common/keyword_plan_common.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanCommonReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9jb21tb24va2V5d29yZF9wbGFu", + "X2NvbW1vbi5wcm90bxIeZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuY29tbW9u", + "GkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9rZXl3b3JkX3BsYW5f", + "Y29tcGV0aXRpb25fbGV2ZWwucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFw", + "cGVycy5wcm90bxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byLKAQoc", + "S2V5d29yZFBsYW5IaXN0b3JpY2FsTWV0cmljcxI5ChRhdmdfbW9udGhseV9z", + "ZWFyY2hlcxgBIAEoCzIbLmdvb2dsZS5wcm90b2J1Zi5JbnQ2NFZhbHVlEm8K", + "C2NvbXBldGl0aW9uGAIgASgOMlouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "ZW51bXMuS2V5d29yZFBsYW5Db21wZXRpdGlvbkxldmVsRW51bS5LZXl3b3Jk", + "UGxhbkNvbXBldGl0aW9uTGV2ZWxC8QEKImNvbS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5jb21tb25CFktleXdvcmRQbGFuQ29tbW9uUHJvdG9QAVpEZ29v", + "Z2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xl", + "YWRzL3YzL2NvbW1vbjtjb21tb26iAgNHQUGqAh5Hb29nbGUuQWRzLkdvb2ds", + "ZUFkcy5WMy5Db21tb27KAh5Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xDb21t", + "b27qAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6Q29tbW9uYgZwcm90", + "bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanCompetitionLevelReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics), global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics.Parser, new[]{ "AvgMonthlySearches", "Competition" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Historical metrics. + /// + public sealed partial class KeywordPlanHistoricalMetrics : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanHistoricalMetrics()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Common.KeywordPlanCommonReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanHistoricalMetrics() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanHistoricalMetrics(KeywordPlanHistoricalMetrics other) : this() { + AvgMonthlySearches = other.AvgMonthlySearches; + competition_ = other.competition_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanHistoricalMetrics Clone() { + return new KeywordPlanHistoricalMetrics(this); + } + + /// Field number for the "avg_monthly_searches" field. + public const int AvgMonthlySearchesFieldNumber = 1; + private static readonly pb::FieldCodec _single_avgMonthlySearches_codec = pb::FieldCodec.ForStructWrapper(10); + private long? avgMonthlySearches_; + /// + /// Average monthly searches for the past 12 months. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AvgMonthlySearches { + get { return avgMonthlySearches_; } + set { + avgMonthlySearches_ = value; + } + } + + + /// Field number for the "competition" field. + public const int CompetitionFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanCompetitionLevelEnum.Types.KeywordPlanCompetitionLevel competition_ = 0; + /// + /// The competition level for the query. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanCompetitionLevelEnum.Types.KeywordPlanCompetitionLevel Competition { + get { return competition_; } + set { + competition_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanHistoricalMetrics); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanHistoricalMetrics other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (AvgMonthlySearches != other.AvgMonthlySearches) return false; + if (Competition != other.Competition) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (avgMonthlySearches_ != null) hash ^= AvgMonthlySearches.GetHashCode(); + if (Competition != 0) hash ^= Competition.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (avgMonthlySearches_ != null) { + _single_avgMonthlySearches_codec.WriteTagAndValue(output, AvgMonthlySearches); + } + if (Competition != 0) { + output.WriteRawTag(16); + output.WriteEnum((int) Competition); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (avgMonthlySearches_ != null) { + size += _single_avgMonthlySearches_codec.CalculateSizeWithTag(AvgMonthlySearches); + } + if (Competition != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Competition); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanHistoricalMetrics other) { + if (other == null) { + return; + } + if (other.avgMonthlySearches_ != null) { + if (avgMonthlySearches_ == null || other.AvgMonthlySearches != 0L) { + AvgMonthlySearches = other.AvgMonthlySearches; + } + } + if (other.Competition != 0) { + Competition = other.Competition; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + long? value = _single_avgMonthlySearches_codec.Read(input); + if (avgMonthlySearches_ == null || value != 0L) { + AvgMonthlySearches = value; + } + break; + } + case 16: { + Competition = (global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanCompetitionLevelEnum.Types.KeywordPlanCompetitionLevel) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanCompetitionLevel.cs b/src/V3/Stubs/KeywordPlanCompetitionLevel.cs new file mode 100644 index 000000000..e698ad510 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanCompetitionLevel.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/keyword_plan_competition_level.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/keyword_plan_competition_level.proto + public static partial class KeywordPlanCompetitionLevelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/keyword_plan_competition_level.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanCompetitionLevelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9rZXl3b3JkX3BsYW5f", + "Y29tcGV0aXRpb25fbGV2ZWwucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIn0KH0tl", + "eXdvcmRQbGFuQ29tcGV0aXRpb25MZXZlbEVudW0iWgobS2V5d29yZFBsYW5D", + "b21wZXRpdGlvbkxldmVsEg8KC1VOU1BFQ0lGSUVEEAASCwoHVU5LTk9XThAB", + "EgcKA0xPVxACEgoKBk1FRElVTRADEggKBEhJR0gQBEL1AQohY29tLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zQiBLZXl3b3JkUGxhbkNvbXBldGl0", + "aW9uTGV2ZWxQcm90b1ABWkJnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9n", + "b29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZW51bXM7ZW51bXOiAgNHQUGq", + "Ah1Hb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5FbnVtc8oCHUdvb2dsZVxBZHNc", + "R29vZ2xlQWRzXFYzXEVudW1z6gIhR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6", + "VjM6OkVudW1zYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanCompetitionLevelEnum), global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanCompetitionLevelEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanCompetitionLevelEnum.Types.KeywordPlanCompetitionLevel) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enumeration of keyword competition levels. The competition + /// level indicates how competitive ad placement is for a keyword and + /// is determined by the number of advertisers bidding on that keyword relative + /// to all keywords across Google. The competition level can depend on the + /// location and Search Network targeting options you've selected. + /// + public sealed partial class KeywordPlanCompetitionLevelEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanCompetitionLevelEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanCompetitionLevelReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCompetitionLevelEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCompetitionLevelEnum(KeywordPlanCompetitionLevelEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCompetitionLevelEnum Clone() { + return new KeywordPlanCompetitionLevelEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanCompetitionLevelEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanCompetitionLevelEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanCompetitionLevelEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanCompetitionLevelEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Competition level of a keyword. + /// + public enum KeywordPlanCompetitionLevel { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Low competition. + /// + [pbr::OriginalName("LOW")] Low = 2, + /// + /// Medium competition. + /// + [pbr::OriginalName("MEDIUM")] Medium = 3, + /// + /// High competition. + /// + [pbr::OriginalName("HIGH")] High = 4, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanError.cs b/src/V3/Stubs/KeywordPlanError.cs new file mode 100644 index 000000000..b1b75216d --- /dev/null +++ b/src/V3/Stubs/KeywordPlanError.cs @@ -0,0 +1,244 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/keyword_plan_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/keyword_plan_error.proto + public static partial class KeywordPlanErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/keyword_plan_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjdnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMva2V5d29yZF9wbGFu", + "X2Vycm9yLnByb3RvEh5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnMa", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8iyAMKFEtleXdvcmRQbGFu", + "RXJyb3JFbnVtIq8DChBLZXl3b3JkUGxhbkVycm9yEg8KC1VOU1BFQ0lGSUVE", + "EAASCwoHVU5LTk9XThABEh8KG0JJRF9NVUxUSVBMSUVSX09VVF9PRl9SQU5H", + "RRACEhAKDEJJRF9UT09fSElHSBADEg8KC0JJRF9UT09fTE9XEAQSIgoeQklE", + "X1RPT19NQU5ZX0ZSQUNUSU9OQUxfRElHSVRTEAUSGAoUREFJTFlfQlVER0VU", + "X1RPT19MT1cQBhIrCidEQUlMWV9CVURHRVRfVE9PX01BTllfRlJBQ1RJT05B", + "TF9ESUdJVFMQBxIRCg1JTlZBTElEX1ZBTFVFEAgSIAocS0VZV09SRF9QTEFO", + "X0hBU19OT19LRVlXT1JEUxAJEhwKGEtFWVdPUkRfUExBTl9OT1RfRU5BQkxF", + "RBAKEhoKFktFWVdPUkRfUExBTl9OT1RfRk9VTkQQCxIPCgtNSVNTSU5HX0JJ", + "RBANEhsKF01JU1NJTkdfRk9SRUNBU1RfUEVSSU9EEA4SHwobSU5WQUxJRF9G", + "T1JFQ0FTVF9EQVRFX1JBTkdFEA8SEAoMSU5WQUxJRF9OQU1FEBBC8AEKImNv", + "bS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lcnJvcnNCFUtleXdvcmRQbGFu", + "RXJyb3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29n", + "bGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoC", + "Hkdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNc", + "R29vZ2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6", + "OlYzOjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanErrorEnum.Types.KeywordPlanError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible errors from applying a keyword plan + /// resource (keyword plan, keyword plan campaign, keyword plan ad group or + /// keyword plan keyword) or KeywordPlanService RPC. + /// + public sealed partial class KeywordPlanErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanErrorEnum(KeywordPlanErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanErrorEnum Clone() { + return new KeywordPlanErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible errors from applying a keyword plan. + /// + public enum KeywordPlanError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The plan's bid multiplier value is outside the valid range. + /// + [pbr::OriginalName("BID_MULTIPLIER_OUT_OF_RANGE")] BidMultiplierOutOfRange = 2, + /// + /// The plan's bid value is too high. + /// + [pbr::OriginalName("BID_TOO_HIGH")] BidTooHigh = 3, + /// + /// The plan's bid value is too low. + /// + [pbr::OriginalName("BID_TOO_LOW")] BidTooLow = 4, + /// + /// The plan's cpc bid is not a multiple of the minimum billable unit. + /// + [pbr::OriginalName("BID_TOO_MANY_FRACTIONAL_DIGITS")] BidTooManyFractionalDigits = 5, + /// + /// The plan's daily budget value is too low. + /// + [pbr::OriginalName("DAILY_BUDGET_TOO_LOW")] DailyBudgetTooLow = 6, + /// + /// The plan's daily budget is not a multiple of the minimum billable unit. + /// + [pbr::OriginalName("DAILY_BUDGET_TOO_MANY_FRACTIONAL_DIGITS")] DailyBudgetTooManyFractionalDigits = 7, + /// + /// The input has an invalid value. + /// + [pbr::OriginalName("INVALID_VALUE")] InvalidValue = 8, + /// + /// The plan has no keyword. + /// + [pbr::OriginalName("KEYWORD_PLAN_HAS_NO_KEYWORDS")] KeywordPlanHasNoKeywords = 9, + /// + /// The plan is not enabled and API cannot provide mutation, forecast or + /// stats. + /// + [pbr::OriginalName("KEYWORD_PLAN_NOT_ENABLED")] KeywordPlanNotEnabled = 10, + /// + /// The requested plan cannot be found for providing forecast or stats. + /// + [pbr::OriginalName("KEYWORD_PLAN_NOT_FOUND")] KeywordPlanNotFound = 11, + /// + /// The plan is missing a cpc bid. + /// + [pbr::OriginalName("MISSING_BID")] MissingBid = 13, + /// + /// The plan is missing required forecast_period field. + /// + [pbr::OriginalName("MISSING_FORECAST_PERIOD")] MissingForecastPeriod = 14, + /// + /// The plan's forecast_period has invalid forecast date range. + /// + [pbr::OriginalName("INVALID_FORECAST_DATE_RANGE")] InvalidForecastDateRange = 15, + /// + /// The plan's name is invalid. + /// + [pbr::OriginalName("INVALID_NAME")] InvalidName = 16, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanForecastInterval.cs b/src/V3/Stubs/KeywordPlanForecastInterval.cs new file mode 100644 index 000000000..0aae56374 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanForecastInterval.cs @@ -0,0 +1,193 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/keyword_plan_forecast_interval.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/keyword_plan_forecast_interval.proto + public static partial class KeywordPlanForecastIntervalReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/keyword_plan_forecast_interval.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanForecastIntervalReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkJnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9rZXl3b3JkX3BsYW5f", + "Zm9yZWNhc3RfaW50ZXJ2YWwucHJvdG8SHWdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmVudW1zGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIo8BCh9L", + "ZXl3b3JkUGxhbkZvcmVjYXN0SW50ZXJ2YWxFbnVtImwKG0tleXdvcmRQbGFu", + "Rm9yZWNhc3RJbnRlcnZhbBIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04Q", + "ARINCglORVhUX1dFRUsQAxIOCgpORVhUX01PTlRIEAQSEAoMTkVYVF9RVUFS", + "VEVSEAVC9QEKIWNvbS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtc0Ig", + "S2V5d29yZFBsYW5Gb3JlY2FzdEludGVydmFsUHJvdG9QAVpCZ29vZ2xlLmdv", + "bGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29vZ2xlYWRzL3Yz", + "L2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMu", + "RW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVtc+oCIUdvb2ds", + "ZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanForecastIntervalEnum), global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanForecastIntervalEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanForecastIntervalEnum.Types.KeywordPlanForecastInterval) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enumeration of forecast intervals. + /// + public sealed partial class KeywordPlanForecastIntervalEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanForecastIntervalEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanForecastIntervalReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanForecastIntervalEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanForecastIntervalEnum(KeywordPlanForecastIntervalEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanForecastIntervalEnum Clone() { + return new KeywordPlanForecastIntervalEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanForecastIntervalEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanForecastIntervalEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanForecastIntervalEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanForecastIntervalEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Forecast intervals. + /// + public enum KeywordPlanForecastInterval { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// The next week date range for keyword plan. The next week is based + /// on the default locale of the user's account and is mostly SUN-SAT or + /// MON-SUN. + /// This can be different from next-7 days. + /// + [pbr::OriginalName("NEXT_WEEK")] NextWeek = 3, + /// + /// The next month date range for keyword plan. + /// + [pbr::OriginalName("NEXT_MONTH")] NextMonth = 4, + /// + /// The next quarter date range for keyword plan. + /// + [pbr::OriginalName("NEXT_QUARTER")] NextQuarter = 5, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanIdeaError.cs b/src/V3/Stubs/KeywordPlanIdeaError.cs new file mode 100644 index 000000000..a3fc87afe --- /dev/null +++ b/src/V3/Stubs/KeywordPlanIdeaError.cs @@ -0,0 +1,186 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/keyword_plan_idea_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/keyword_plan_idea_error.proto + public static partial class KeywordPlanIdeaErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/keyword_plan_idea_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanIdeaErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMva2V5d29yZF9wbGFu", + "X2lkZWFfZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVy", + "cm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byJ4ChhLZXl3b3Jk", + "UGxhbklkZWFFcnJvckVudW0iXAoUS2V5d29yZFBsYW5JZGVhRXJyb3ISDwoL", + "VU5TUEVDSUZJRUQQABILCgdVTktOT1dOEAESEwoPVVJMX0NSQVdMX0VSUk9S", + "EAISEQoNSU5WQUxJRF9WQUxVRRADQvQBCiJjb20uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuZXJyb3JzQhlLZXl3b3JkUGxhbklkZWFFcnJvclByb3RvUAFa", + "RGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRzL2dv", + "b2dsZWFkcy92My9lcnJvcnM7ZXJyb3JzogIDR0FBqgIeR29vZ2xlLkFkcy5H", + "b29nbGVBZHMuVjMuRXJyb3JzygIeR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNc", + "RXJyb3Jz6gIiR29vZ2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OkVycm9yc2IG", + "cHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanIdeaErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanIdeaErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanIdeaErrorEnum.Types.KeywordPlanIdeaError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible errors from KeywordPlanIdeaService. + /// + public sealed partial class KeywordPlanIdeaErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanIdeaErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanIdeaErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanIdeaErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanIdeaErrorEnum(KeywordPlanIdeaErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanIdeaErrorEnum Clone() { + return new KeywordPlanIdeaErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanIdeaErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanIdeaErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanIdeaErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanIdeaErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible errors from KeywordPlanIdeaService. + /// + public enum KeywordPlanIdeaError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Error when crawling the input URL. + /// + [pbr::OriginalName("URL_CRAWL_ERROR")] UrlCrawlError = 2, + /// + /// The input has an invalid value. + /// + [pbr::OriginalName("INVALID_VALUE")] InvalidValue = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanIdeaService.cs b/src/V3/Stubs/KeywordPlanIdeaService.cs new file mode 100644 index 000000000..b1605182d --- /dev/null +++ b/src/V3/Stubs/KeywordPlanIdeaService.cs @@ -0,0 +1,1207 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_idea_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/keyword_plan_idea_service.proto + public static partial class KeywordPlanIdeaServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/keyword_plan_idea_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanIdeaServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkBnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9rZXl3b3JkX3Bs", + "YW5faWRlYV9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcxo4Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL2tl", + "eXdvcmRfcGxhbl9jb21tb24ucHJvdG8aOGdvb2dsZS9hZHMvZ29vZ2xlYWRz", + "L3YzL2VudW1zL2tleXdvcmRfcGxhbl9uZXR3b3JrLnByb3RvGhxnb29nbGUv", + "YXBpL2Fubm90YXRpb25zLnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBl", + "cnMucHJvdG8aF2dvb2dsZS9hcGkvY2xpZW50LnByb3RvIukDChtHZW5lcmF0", + "ZUtleXdvcmRJZGVhc1JlcXVlc3QSEwoLY3VzdG9tZXJfaWQYASABKAkSLgoI", + "bGFuZ3VhZ2UYByABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUS", + "OgoUZ2VvX3RhcmdldF9jb25zdGFudHMYCCADKAsyHC5nb29nbGUucHJvdG9i", + "dWYuU3RyaW5nVmFsdWUSZgoUa2V5d29yZF9wbGFuX25ldHdvcmsYCSABKA4y", + "SC5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5lbnVtcy5LZXl3b3JkUGxhbk5l", + "dHdvcmtFbnVtLktleXdvcmRQbGFuTmV0d29yaxJTChRrZXl3b3JkX2FuZF91", + "cmxfc2VlZBgCIAEoCzIzLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZp", + "Y2VzLktleXdvcmRBbmRVcmxTZWVkSAASRQoMa2V5d29yZF9zZWVkGAMgASgL", + "Mi0uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuS2V5d29yZFNl", + "ZWRIABI9Cgh1cmxfc2VlZBgFIAEoCzIpLmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLnNlcnZpY2VzLlVybFNlZWRIAEIGCgRzZWVkIm4KEUtleXdvcmRBbmRV", + "cmxTZWVkEikKA3VybBgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdW", + "YWx1ZRIuCghrZXl3b3JkcxgCIAMoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJp", + "bmdWYWx1ZSI9CgtLZXl3b3JkU2VlZBIuCghrZXl3b3JkcxgBIAMoCzIcLmdv", + "b2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSI0CgdVcmxTZWVkEikKA3VybBgB", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZSJrChtHZW5lcmF0", + "ZUtleXdvcmRJZGVhUmVzcG9uc2USTAoHcmVzdWx0cxgBIAMoCzI7Lmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdlbmVyYXRlS2V5d29yZElk", + "ZWFSZXN1bHQiowEKGUdlbmVyYXRlS2V5d29yZElkZWFSZXN1bHQSKgoEdGV4", + "dBgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJaChRrZXl3", + "b3JkX2lkZWFfbWV0cmljcxgDIAEoCzI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRz", + "LnYzLmNvbW1vbi5LZXl3b3JkUGxhbkhpc3RvcmljYWxNZXRyaWNzMosCChZL", + "ZXl3b3JkUGxhbklkZWFTZXJ2aWNlEtMBChRHZW5lcmF0ZUtleXdvcmRJZGVh", + "cxI9Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdlbmVyYXRl", + "S2V5d29yZElkZWFzUmVxdWVzdBo9Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLkdlbmVyYXRlS2V5d29yZElkZWFSZXNwb25zZSI9gtPkkwI3", + "IjIvdjMvY3VzdG9tZXJzL3tjdXN0b21lcl9pZD0qfTpnZW5lcmF0ZUtleXdv", + "cmRJZGVhczoBKhobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQoICCiRj", + "b20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCG0tleXdvcmRQ", + "bGFuSWRlYVNlcnZpY2VQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5w", + "cm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2Vy", + "dmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNl", + "c8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xl", + "OjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.KeywordPlanCommonReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeasRequest), global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeasRequest.Parser, new[]{ "CustomerId", "Language", "GeoTargetConstants", "KeywordPlanNetwork", "KeywordAndUrlSeed", "KeywordSeed", "UrlSeed" }, new[]{ "Seed" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordAndUrlSeed), global::Google.Ads.GoogleAds.V3.Services.KeywordAndUrlSeed.Parser, new[]{ "Url", "Keywords" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordSeed), global::Google.Ads.GoogleAds.V3.Services.KeywordSeed.Parser, new[]{ "Keywords" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.UrlSeed), global::Google.Ads.GoogleAds.V3.Services.UrlSeed.Parser, new[]{ "Url" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeaResponse), global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeaResponse.Parser, new[]{ "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeaResult), global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeaResult.Parser, new[]{ "Text", "KeywordIdeaMetrics" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [KeywordIdeaService.GenerateKeywordIdeas][]. + /// + public sealed partial class GenerateKeywordIdeasRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenerateKeywordIdeasRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanIdeaServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeasRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeasRequest(GenerateKeywordIdeasRequest other) : this() { + customerId_ = other.customerId_; + Language = other.Language; + geoTargetConstants_ = other.geoTargetConstants_.Clone(); + keywordPlanNetwork_ = other.keywordPlanNetwork_; + switch (other.SeedCase) { + case SeedOneofCase.KeywordAndUrlSeed: + KeywordAndUrlSeed = other.KeywordAndUrlSeed.Clone(); + break; + case SeedOneofCase.KeywordSeed: + KeywordSeed = other.KeywordSeed.Clone(); + break; + case SeedOneofCase.UrlSeed: + UrlSeed = other.UrlSeed.Clone(); + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeasRequest Clone() { + return new GenerateKeywordIdeasRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// The ID of the customer with the recommendation. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "language" field. + public const int LanguageFieldNumber = 7; + private static readonly pb::FieldCodec _single_language_codec = pb::FieldCodec.ForClassWrapper(58); + private string language_; + /// + /// The resource name of the language to target. + /// Required + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Language { + get { return language_; } + set { + language_ = value; + } + } + + + /// Field number for the "geo_target_constants" field. + public const int GeoTargetConstantsFieldNumber = 8; + private static readonly pb::FieldCodec _repeated_geoTargetConstants_codec + = pb::FieldCodec.ForClassWrapper(66); + private readonly pbc::RepeatedField geoTargetConstants_ = new pbc::RepeatedField(); + /// + /// The resource names of the location to target. + /// Max 10 + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField GeoTargetConstants { + get { return geoTargetConstants_; } + } + + /// Field number for the "keyword_plan_network" field. + public const int KeywordPlanNetworkFieldNumber = 9; + private global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types.KeywordPlanNetwork keywordPlanNetwork_ = 0; + /// + /// Targeting network. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types.KeywordPlanNetwork KeywordPlanNetwork { + get { return keywordPlanNetwork_; } + set { + keywordPlanNetwork_ = value; + } + } + + /// Field number for the "keyword_and_url_seed" field. + public const int KeywordAndUrlSeedFieldNumber = 2; + /// + /// A Keyword and a specific Url to generate ideas from + /// e.g. cars, www.example.com/cars. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.KeywordAndUrlSeed KeywordAndUrlSeed { + get { return seedCase_ == SeedOneofCase.KeywordAndUrlSeed ? (global::Google.Ads.GoogleAds.V3.Services.KeywordAndUrlSeed) seed_ : null; } + set { + seed_ = value; + seedCase_ = value == null ? SeedOneofCase.None : SeedOneofCase.KeywordAndUrlSeed; + } + } + + /// Field number for the "keyword_seed" field. + public const int KeywordSeedFieldNumber = 3; + /// + /// A Keyword or phrase to generate ideas from, e.g. cars. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.KeywordSeed KeywordSeed { + get { return seedCase_ == SeedOneofCase.KeywordSeed ? (global::Google.Ads.GoogleAds.V3.Services.KeywordSeed) seed_ : null; } + set { + seed_ = value; + seedCase_ = value == null ? SeedOneofCase.None : SeedOneofCase.KeywordSeed; + } + } + + /// Field number for the "url_seed" field. + public const int UrlSeedFieldNumber = 5; + /// + /// A specific url to generate ideas from, e.g. www.example.com/cars. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.UrlSeed UrlSeed { + get { return seedCase_ == SeedOneofCase.UrlSeed ? (global::Google.Ads.GoogleAds.V3.Services.UrlSeed) seed_ : null; } + set { + seed_ = value; + seedCase_ = value == null ? SeedOneofCase.None : SeedOneofCase.UrlSeed; + } + } + + private object seed_; + /// Enum of possible cases for the "seed" oneof. + public enum SeedOneofCase { + None = 0, + KeywordAndUrlSeed = 2, + KeywordSeed = 3, + UrlSeed = 5, + } + private SeedOneofCase seedCase_ = SeedOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public SeedOneofCase SeedCase { + get { return seedCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearSeed() { + seedCase_ = SeedOneofCase.None; + seed_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenerateKeywordIdeasRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenerateKeywordIdeasRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if (Language != other.Language) return false; + if(!geoTargetConstants_.Equals(other.geoTargetConstants_)) return false; + if (KeywordPlanNetwork != other.KeywordPlanNetwork) return false; + if (!object.Equals(KeywordAndUrlSeed, other.KeywordAndUrlSeed)) return false; + if (!object.Equals(KeywordSeed, other.KeywordSeed)) return false; + if (!object.Equals(UrlSeed, other.UrlSeed)) return false; + if (SeedCase != other.SeedCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + if (language_ != null) hash ^= Language.GetHashCode(); + hash ^= geoTargetConstants_.GetHashCode(); + if (KeywordPlanNetwork != 0) hash ^= KeywordPlanNetwork.GetHashCode(); + if (seedCase_ == SeedOneofCase.KeywordAndUrlSeed) hash ^= KeywordAndUrlSeed.GetHashCode(); + if (seedCase_ == SeedOneofCase.KeywordSeed) hash ^= KeywordSeed.GetHashCode(); + if (seedCase_ == SeedOneofCase.UrlSeed) hash ^= UrlSeed.GetHashCode(); + hash ^= (int) seedCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + if (seedCase_ == SeedOneofCase.KeywordAndUrlSeed) { + output.WriteRawTag(18); + output.WriteMessage(KeywordAndUrlSeed); + } + if (seedCase_ == SeedOneofCase.KeywordSeed) { + output.WriteRawTag(26); + output.WriteMessage(KeywordSeed); + } + if (seedCase_ == SeedOneofCase.UrlSeed) { + output.WriteRawTag(42); + output.WriteMessage(UrlSeed); + } + if (language_ != null) { + _single_language_codec.WriteTagAndValue(output, Language); + } + geoTargetConstants_.WriteTo(output, _repeated_geoTargetConstants_codec); + if (KeywordPlanNetwork != 0) { + output.WriteRawTag(72); + output.WriteEnum((int) KeywordPlanNetwork); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + if (language_ != null) { + size += _single_language_codec.CalculateSizeWithTag(Language); + } + size += geoTargetConstants_.CalculateSize(_repeated_geoTargetConstants_codec); + if (KeywordPlanNetwork != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) KeywordPlanNetwork); + } + if (seedCase_ == SeedOneofCase.KeywordAndUrlSeed) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(KeywordAndUrlSeed); + } + if (seedCase_ == SeedOneofCase.KeywordSeed) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(KeywordSeed); + } + if (seedCase_ == SeedOneofCase.UrlSeed) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UrlSeed); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenerateKeywordIdeasRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + if (other.language_ != null) { + if (language_ == null || other.Language != "") { + Language = other.Language; + } + } + geoTargetConstants_.Add(other.geoTargetConstants_); + if (other.KeywordPlanNetwork != 0) { + KeywordPlanNetwork = other.KeywordPlanNetwork; + } + switch (other.SeedCase) { + case SeedOneofCase.KeywordAndUrlSeed: + if (KeywordAndUrlSeed == null) { + KeywordAndUrlSeed = new global::Google.Ads.GoogleAds.V3.Services.KeywordAndUrlSeed(); + } + KeywordAndUrlSeed.MergeFrom(other.KeywordAndUrlSeed); + break; + case SeedOneofCase.KeywordSeed: + if (KeywordSeed == null) { + KeywordSeed = new global::Google.Ads.GoogleAds.V3.Services.KeywordSeed(); + } + KeywordSeed.MergeFrom(other.KeywordSeed); + break; + case SeedOneofCase.UrlSeed: + if (UrlSeed == null) { + UrlSeed = new global::Google.Ads.GoogleAds.V3.Services.UrlSeed(); + } + UrlSeed.MergeFrom(other.UrlSeed); + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Services.KeywordAndUrlSeed subBuilder = new global::Google.Ads.GoogleAds.V3.Services.KeywordAndUrlSeed(); + if (seedCase_ == SeedOneofCase.KeywordAndUrlSeed) { + subBuilder.MergeFrom(KeywordAndUrlSeed); + } + input.ReadMessage(subBuilder); + KeywordAndUrlSeed = subBuilder; + break; + } + case 26: { + global::Google.Ads.GoogleAds.V3.Services.KeywordSeed subBuilder = new global::Google.Ads.GoogleAds.V3.Services.KeywordSeed(); + if (seedCase_ == SeedOneofCase.KeywordSeed) { + subBuilder.MergeFrom(KeywordSeed); + } + input.ReadMessage(subBuilder); + KeywordSeed = subBuilder; + break; + } + case 42: { + global::Google.Ads.GoogleAds.V3.Services.UrlSeed subBuilder = new global::Google.Ads.GoogleAds.V3.Services.UrlSeed(); + if (seedCase_ == SeedOneofCase.UrlSeed) { + subBuilder.MergeFrom(UrlSeed); + } + input.ReadMessage(subBuilder); + UrlSeed = subBuilder; + break; + } + case 58: { + string value = _single_language_codec.Read(input); + if (language_ == null || value != "") { + Language = value; + } + break; + } + case 66: { + geoTargetConstants_.AddEntriesFrom(input, _repeated_geoTargetConstants_codec); + break; + } + case 72: { + KeywordPlanNetwork = (global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types.KeywordPlanNetwork) input.ReadEnum(); + break; + } + } + } + } + + } + + /// + /// Keyword And Url Seed + /// + public sealed partial class KeywordAndUrlSeed : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordAndUrlSeed()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanIdeaServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordAndUrlSeed() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordAndUrlSeed(KeywordAndUrlSeed other) : this() { + Url = other.Url; + keywords_ = other.keywords_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordAndUrlSeed Clone() { + return new KeywordAndUrlSeed(this); + } + + /// Field number for the "url" field. + public const int UrlFieldNumber = 1; + private static readonly pb::FieldCodec _single_url_codec = pb::FieldCodec.ForClassWrapper(10); + private string url_; + /// + /// The URL to crawl in order to generate keyword ideas. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Url { + get { return url_; } + set { + url_ = value; + } + } + + + /// Field number for the "keywords" field. + public const int KeywordsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_keywords_codec + = pb::FieldCodec.ForClassWrapper(18); + private readonly pbc::RepeatedField keywords_ = new pbc::RepeatedField(); + /// + /// Requires at least one keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Keywords { + get { return keywords_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordAndUrlSeed); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordAndUrlSeed other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Url != other.Url) return false; + if(!keywords_.Equals(other.keywords_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (url_ != null) hash ^= Url.GetHashCode(); + hash ^= keywords_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (url_ != null) { + _single_url_codec.WriteTagAndValue(output, Url); + } + keywords_.WriteTo(output, _repeated_keywords_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (url_ != null) { + size += _single_url_codec.CalculateSizeWithTag(Url); + } + size += keywords_.CalculateSize(_repeated_keywords_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordAndUrlSeed other) { + if (other == null) { + return; + } + if (other.url_ != null) { + if (url_ == null || other.Url != "") { + Url = other.Url; + } + } + keywords_.Add(other.keywords_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_url_codec.Read(input); + if (url_ == null || value != "") { + Url = value; + } + break; + } + case 18: { + keywords_.AddEntriesFrom(input, _repeated_keywords_codec); + break; + } + } + } + } + + } + + /// + /// Keyword Seed + /// + public sealed partial class KeywordSeed : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordSeed()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanIdeaServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordSeed() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordSeed(KeywordSeed other) : this() { + keywords_ = other.keywords_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordSeed Clone() { + return new KeywordSeed(this); + } + + /// Field number for the "keywords" field. + public const int KeywordsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_keywords_codec + = pb::FieldCodec.ForClassWrapper(10); + private readonly pbc::RepeatedField keywords_ = new pbc::RepeatedField(); + /// + /// Requires at least one keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Keywords { + get { return keywords_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordSeed); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordSeed other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!keywords_.Equals(other.keywords_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= keywords_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + keywords_.WriteTo(output, _repeated_keywords_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += keywords_.CalculateSize(_repeated_keywords_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordSeed other) { + if (other == null) { + return; + } + keywords_.Add(other.keywords_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + keywords_.AddEntriesFrom(input, _repeated_keywords_codec); + break; + } + } + } + } + + } + + /// + /// Url Seed + /// + public sealed partial class UrlSeed : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new UrlSeed()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanIdeaServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UrlSeed() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UrlSeed(UrlSeed other) : this() { + Url = other.Url; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public UrlSeed Clone() { + return new UrlSeed(this); + } + + /// Field number for the "url" field. + public const int UrlFieldNumber = 1; + private static readonly pb::FieldCodec _single_url_codec = pb::FieldCodec.ForClassWrapper(10); + private string url_; + /// + /// The URL to crawl in order to generate keyword ideas. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Url { + get { return url_; } + set { + url_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as UrlSeed); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(UrlSeed other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Url != other.Url) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (url_ != null) hash ^= Url.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (url_ != null) { + _single_url_codec.WriteTagAndValue(output, Url); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (url_ != null) { + size += _single_url_codec.CalculateSizeWithTag(Url); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(UrlSeed other) { + if (other == null) { + return; + } + if (other.url_ != null) { + if (url_ == null || other.Url != "") { + Url = other.Url; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_url_codec.Read(input); + if (url_ == null || value != "") { + Url = value; + } + break; + } + } + } + } + + } + + /// + /// Response message for [KeywordIdeaService.GenerateKeywordIdeas][]. + /// + public sealed partial class GenerateKeywordIdeaResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenerateKeywordIdeaResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanIdeaServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeaResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeaResponse(GenerateKeywordIdeaResponse other) : this() { + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeaResponse Clone() { + return new GenerateKeywordIdeaResponse(this); + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeaResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// Results of generating keyword ideas. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenerateKeywordIdeaResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenerateKeywordIdeaResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenerateKeywordIdeaResponse other) { + if (other == null) { + return; + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + } + } + } + + } + + /// + /// The result of generating keyword ideas. + /// + public sealed partial class GenerateKeywordIdeaResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenerateKeywordIdeaResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanIdeaServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeaResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeaResult(GenerateKeywordIdeaResult other) : this() { + Text = other.Text; + keywordIdeaMetrics_ = other.keywordIdeaMetrics_ != null ? other.keywordIdeaMetrics_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateKeywordIdeaResult Clone() { + return new GenerateKeywordIdeaResult(this); + } + + /// Field number for the "text" field. + public const int TextFieldNumber = 2; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(18); + private string text_; + /// + /// Text of the keyword idea. + /// As in Keyword Plan historical metrics, this text may not be an actual + /// keyword, but the canonical form of multiple keywords. + /// See KeywordPlanKeywordHistoricalMetrics message in KeywordPlanService. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + /// Field number for the "keyword_idea_metrics" field. + public const int KeywordIdeaMetricsFieldNumber = 3; + private global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics keywordIdeaMetrics_; + /// + /// The historical metrics for the keyword + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics KeywordIdeaMetrics { + get { return keywordIdeaMetrics_; } + set { + keywordIdeaMetrics_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenerateKeywordIdeaResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenerateKeywordIdeaResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Text != other.Text) return false; + if (!object.Equals(KeywordIdeaMetrics, other.KeywordIdeaMetrics)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (text_ != null) hash ^= Text.GetHashCode(); + if (keywordIdeaMetrics_ != null) hash ^= KeywordIdeaMetrics.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (keywordIdeaMetrics_ != null) { + output.WriteRawTag(26); + output.WriteMessage(KeywordIdeaMetrics); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (keywordIdeaMetrics_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(KeywordIdeaMetrics); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenerateKeywordIdeaResult other) { + if (other == null) { + return; + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + if (other.keywordIdeaMetrics_ != null) { + if (keywordIdeaMetrics_ == null) { + KeywordIdeaMetrics = new global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics(); + } + KeywordIdeaMetrics.MergeFrom(other.KeywordIdeaMetrics); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + case 26: { + if (keywordIdeaMetrics_ == null) { + KeywordIdeaMetrics = new global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics(); + } + input.ReadMessage(KeywordIdeaMetrics); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanIdeaServiceClient.cs b/src/V3/Stubs/KeywordPlanIdeaServiceClient.cs new file mode 100644 index 000000000..3b128b5cd --- /dev/null +++ b/src/V3/Stubs/KeywordPlanIdeaServiceClient.cs @@ -0,0 +1,612 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagve = Google.Ads.GoogleAds.V3.Enums; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class KeywordPlanIdeaServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static KeywordPlanIdeaServiceSettings GetDefault() => new KeywordPlanIdeaServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public KeywordPlanIdeaServiceSettings() { } + + private KeywordPlanIdeaServiceSettings(KeywordPlanIdeaServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GenerateKeywordIdeasSettings = existing.GenerateKeywordIdeasSettings; + OnCopy(existing); + } + + partial void OnCopy(KeywordPlanIdeaServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanIdeaServiceClient.GenerateKeywordIdeas and KeywordPlanIdeaServiceClient.GenerateKeywordIdeasAsync. + /// + /// + /// The default KeywordPlanIdeaServiceClient.GenerateKeywordIdeas and + /// KeywordPlanIdeaServiceClient.GenerateKeywordIdeasAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GenerateKeywordIdeasSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public KeywordPlanIdeaServiceSettings Clone() => new KeywordPlanIdeaServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class KeywordPlanIdeaServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public KeywordPlanIdeaServiceSettings Settings { get; set; } + + /// + public override KeywordPlanIdeaServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return KeywordPlanIdeaServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return KeywordPlanIdeaServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => KeywordPlanIdeaServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => KeywordPlanIdeaServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => KeywordPlanIdeaServiceClient.ChannelPool; + } + + /// + /// KeywordPlanIdeaService client wrapper, for convenient use. + /// + public abstract partial class KeywordPlanIdeaServiceClient + { + /// + /// The default endpoint for the KeywordPlanIdeaService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default KeywordPlanIdeaService scopes. + /// + /// + /// The default KeywordPlanIdeaService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanIdeaServiceClient client = await KeywordPlanIdeaServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanIdeaServiceClient.DefaultEndpoint.Host, KeywordPlanIdeaServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanIdeaServiceClient client = KeywordPlanIdeaServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanIdeaServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanIdeaServiceClient client = KeywordPlanIdeaServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanIdeaServiceClient.DefaultEndpoint.Host, KeywordPlanIdeaServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanIdeaServiceClient client = KeywordPlanIdeaServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static KeywordPlanIdeaServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanIdeaServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanIdeaServiceClient Create(grpccore::Channel channel, KeywordPlanIdeaServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanIdeaServiceClient Create(grpccore::CallInvoker callInvoker, KeywordPlanIdeaServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + KeywordPlanIdeaService.KeywordPlanIdeaServiceClient grpcClient = new KeywordPlanIdeaService.KeywordPlanIdeaServiceClient(callInvoker); + return new KeywordPlanIdeaServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC KeywordPlanIdeaService client. + /// + public virtual KeywordPlanIdeaService.KeywordPlanIdeaServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns a list of keyword ideas. + /// + /// + /// The ID of the customer with the recommendation. + /// + /// + /// The resource name of the language to target. + /// Required + /// + /// + /// The resource names of the location to target. + /// Max 10 + /// + /// + /// Targeting network. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateKeywordIdeasAsync( + string customerId, + string language, + scg::IEnumerable geoTargetConstants, + gagve::KeywordPlanNetworkEnum.Types.KeywordPlanNetwork keywordPlanNetwork, + gaxgrpc::CallSettings callSettings = null) => GenerateKeywordIdeasAsync( + new GenerateKeywordIdeasRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Language = gax::GaxPreconditions.CheckNotNullOrEmpty(language, nameof(language)), + GeoTargetConstants = { gax::GaxPreconditions.CheckNotNull(geoTargetConstants, nameof(geoTargetConstants)) }, + KeywordPlanNetwork = keywordPlanNetwork, + }, + callSettings); + + /// + /// Returns a list of keyword ideas. + /// + /// + /// The ID of the customer with the recommendation. + /// + /// + /// The resource name of the language to target. + /// Required + /// + /// + /// The resource names of the location to target. + /// Max 10 + /// + /// + /// Targeting network. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateKeywordIdeasAsync( + string customerId, + string language, + scg::IEnumerable geoTargetConstants, + gagve::KeywordPlanNetworkEnum.Types.KeywordPlanNetwork keywordPlanNetwork, + st::CancellationToken cancellationToken) => GenerateKeywordIdeasAsync( + customerId, + language, + geoTargetConstants, + keywordPlanNetwork, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns a list of keyword ideas. + /// + /// + /// The ID of the customer with the recommendation. + /// + /// + /// The resource name of the language to target. + /// Required + /// + /// + /// The resource names of the location to target. + /// Max 10 + /// + /// + /// Targeting network. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual GenerateKeywordIdeaResponse GenerateKeywordIdeas( + string customerId, + string language, + scg::IEnumerable geoTargetConstants, + gagve::KeywordPlanNetworkEnum.Types.KeywordPlanNetwork keywordPlanNetwork, + gaxgrpc::CallSettings callSettings = null) => GenerateKeywordIdeas( + new GenerateKeywordIdeasRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Language = gax::GaxPreconditions.CheckNotNullOrEmpty(language, nameof(language)), + GeoTargetConstants = { gax::GaxPreconditions.CheckNotNull(geoTargetConstants, nameof(geoTargetConstants)) }, + KeywordPlanNetwork = keywordPlanNetwork, + }, + callSettings); + + /// + /// Returns a list of keyword ideas. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateKeywordIdeasAsync( + GenerateKeywordIdeasRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns a list of keyword ideas. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateKeywordIdeasAsync( + GenerateKeywordIdeasRequest request, + st::CancellationToken cancellationToken) => GenerateKeywordIdeasAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns a list of keyword ideas. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual GenerateKeywordIdeaResponse GenerateKeywordIdeas( + GenerateKeywordIdeasRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// KeywordPlanIdeaService client wrapper implementation, for convenient use. + /// + public sealed partial class KeywordPlanIdeaServiceClientImpl : KeywordPlanIdeaServiceClient + { + private readonly gaxgrpc::ApiCall _callGenerateKeywordIdeas; + + /// + /// Constructs a client wrapper for the KeywordPlanIdeaService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public KeywordPlanIdeaServiceClientImpl(KeywordPlanIdeaService.KeywordPlanIdeaServiceClient grpcClient, KeywordPlanIdeaServiceSettings settings) + { + GrpcClient = grpcClient; + KeywordPlanIdeaServiceSettings effectiveSettings = settings ?? KeywordPlanIdeaServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGenerateKeywordIdeas = clientHelper.BuildApiCall( + GrpcClient.GenerateKeywordIdeasAsync, GrpcClient.GenerateKeywordIdeas, effectiveSettings.GenerateKeywordIdeasSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGenerateKeywordIdeas); + Modify_GenerateKeywordIdeasApiCall(ref _callGenerateKeywordIdeas); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GenerateKeywordIdeasApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(KeywordPlanIdeaService.KeywordPlanIdeaServiceClient grpcClient, KeywordPlanIdeaServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC KeywordPlanIdeaService client. + /// + public override KeywordPlanIdeaService.KeywordPlanIdeaServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GenerateKeywordIdeasRequest(ref GenerateKeywordIdeasRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns a list of keyword ideas. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GenerateKeywordIdeasAsync( + GenerateKeywordIdeasRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GenerateKeywordIdeasRequest(ref request, ref callSettings); + return _callGenerateKeywordIdeas.Async(request, callSettings); + } + + /// + /// Returns a list of keyword ideas. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override GenerateKeywordIdeaResponse GenerateKeywordIdeas( + GenerateKeywordIdeasRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GenerateKeywordIdeasRequest(ref request, ref callSettings); + return _callGenerateKeywordIdeas.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/KeywordPlanIdeaServiceGrpc.cs b/src/V3/Stubs/KeywordPlanIdeaServiceGrpc.cs new file mode 100644 index 000000000..49535caaf --- /dev/null +++ b/src/V3/Stubs/KeywordPlanIdeaServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_idea_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to generate keyword ideas. + /// + public static partial class KeywordPlanIdeaService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.KeywordPlanIdeaService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GenerateKeywordIdeasRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeasRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GenerateKeywordIdeaResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeaResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GenerateKeywordIdeas = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GenerateKeywordIdeas", + __Marshaller_google_ads_googleads_v3_services_GenerateKeywordIdeasRequest, + __Marshaller_google_ads_googleads_v3_services_GenerateKeywordIdeaResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanIdeaServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of KeywordPlanIdeaService + public abstract partial class KeywordPlanIdeaServiceBase + { + /// + /// Returns a list of keyword ideas. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GenerateKeywordIdeas(global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeasRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for KeywordPlanIdeaService + public partial class KeywordPlanIdeaServiceClient : grpc::ClientBase + { + /// Creates a new client for KeywordPlanIdeaService + /// The channel to use to make remote calls. + public KeywordPlanIdeaServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for KeywordPlanIdeaService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public KeywordPlanIdeaServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected KeywordPlanIdeaServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected KeywordPlanIdeaServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns a list of keyword ideas. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeaResponse GenerateKeywordIdeas(global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeasRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GenerateKeywordIdeas(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns a list of keyword ideas. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeaResponse GenerateKeywordIdeas(global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeasRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GenerateKeywordIdeas, null, options, request); + } + /// + /// Returns a list of keyword ideas. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GenerateKeywordIdeasAsync(global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeasRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GenerateKeywordIdeasAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns a list of keyword ideas. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GenerateKeywordIdeasAsync(global::Google.Ads.GoogleAds.V3.Services.GenerateKeywordIdeasRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GenerateKeywordIdeas, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override KeywordPlanIdeaServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new KeywordPlanIdeaServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(KeywordPlanIdeaServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GenerateKeywordIdeas, serviceImpl.GenerateKeywordIdeas).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, KeywordPlanIdeaServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GenerateKeywordIdeas, serviceImpl.GenerateKeywordIdeas); + } + + } +} +#endregion diff --git a/src/V3/Stubs/KeywordPlanKeyword.cs b/src/V3/Stubs/KeywordPlanKeyword.cs new file mode 100644 index 000000000..b9ed35b4b --- /dev/null +++ b/src/V3/Stubs/KeywordPlanKeyword.cs @@ -0,0 +1,385 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/keyword_plan_keyword.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/keyword_plan_keyword.proto + public static partial class KeywordPlanKeywordReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/keyword_plan_keyword.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanKeywordReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMva2V5d29yZF9w", + "bGFuX2tleXdvcmQucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJl", + "c291cmNlcxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51bXMva2V5d29y", + "ZF9tYXRjaF90eXBlLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2JlaGF2aW9y", + "LnByb3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5nb29nbGUvcHJv", + "dG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMu", + "cHJvdG8iqwQKEktleXdvcmRQbGFuS2V5d29yZBJKCg1yZXNvdXJjZV9uYW1l", + "GAEgASgJQjPgQQX6QS0KK2dvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9LZXl3", + "b3JkUGxhbktleXdvcmQSbQoVa2V5d29yZF9wbGFuX2FkX2dyb3VwGAIgASgL", + "MhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlQjD6QS0KK2dvb2dsZWFk", + "cy5nb29nbGVhcGlzLmNvbS9LZXl3b3JkUGxhbkFkR3JvdXASLAoCaWQYAyAB", + "KAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZUID4EEDEioKBHRleHQY", + "BCABKAsyHC5nb29nbGUucHJvdG9idWYuU3RyaW5nVmFsdWUSWAoKbWF0Y2hf", + "dHlwZRgFIAEoDjJELmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmVudW1zLktl", + "eXdvcmRNYXRjaFR5cGVFbnVtLktleXdvcmRNYXRjaFR5cGUSMwoOY3BjX2Jp", + "ZF9taWNyb3MYBiABKAsyGy5nb29nbGUucHJvdG9idWYuSW50NjRWYWx1ZTpx", + "6kFuCitnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vS2V5d29yZFBsYW5LZXl3", + "b3JkEj9jdXN0b21lcnMve2N1c3RvbWVyfS9rZXl3b3JkUGxhbktleXdvcmRz", + "L3trZXl3b3JkX3BsYW5fa2V5d29yZH1ChAIKJWNvbS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5yZXNvdXJjZXNCF0tleXdvcmRQbGFuS2V5d29yZFByb3Rv", + "UAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2VzogIDR0FBqgIhR29v", + "Z2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIhR29vZ2xlXEFkc1xH", + "b29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpBZHM6Okdvb2dsZUFk", + "czo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword.Parser, new[]{ "ResourceName", "KeywordPlanAdGroup", "Id", "Text", "MatchType", "CpcBidMicros" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A Keyword Plan ad group keyword. + /// Max number of keyword plan keywords per plan: 2500. + /// + public sealed partial class KeywordPlanKeyword : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanKeyword()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeywordReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeyword() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeyword(KeywordPlanKeyword other) : this() { + resourceName_ = other.resourceName_; + KeywordPlanAdGroup = other.KeywordPlanAdGroup; + Id = other.Id; + Text = other.Text; + matchType_ = other.matchType_; + CpcBidMicros = other.CpcBidMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeyword Clone() { + return new KeywordPlanKeyword(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the Keyword Plan ad group keyword. + /// KeywordPlanKeyword resource names have the form: + /// + /// `customers/{customer_id}/keywordPlanKeywords/{kp_ad_group_keyword_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "keyword_plan_ad_group" field. + public const int KeywordPlanAdGroupFieldNumber = 2; + private static readonly pb::FieldCodec _single_keywordPlanAdGroup_codec = pb::FieldCodec.ForClassWrapper(18); + private string keywordPlanAdGroup_; + /// + /// The Keyword Plan ad group to which this keyword belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlanAdGroup { + get { return keywordPlanAdGroup_; } + set { + keywordPlanAdGroup_ = value; + } + } + + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the Keyword Plan keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "text" field. + public const int TextFieldNumber = 4; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(34); + private string text_; + /// + /// The keyword text. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + /// Field number for the "match_type" field. + public const int MatchTypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType matchType_ = 0; + /// + /// The keyword match type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType MatchType { + get { return matchType_; } + set { + matchType_ = value; + } + } + + /// Field number for the "cpc_bid_micros" field. + public const int CpcBidMicrosFieldNumber = 6; + private static readonly pb::FieldCodec _single_cpcBidMicros_codec = pb::FieldCodec.ForStructWrapper(50); + private long? cpcBidMicros_; + /// + /// A keyword level max cpc bid in micros, in the account currency, that + /// overrides the keyword plan ad group cpc bid. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CpcBidMicros { + get { return cpcBidMicros_; } + set { + cpcBidMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanKeyword); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanKeyword other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (KeywordPlanAdGroup != other.KeywordPlanAdGroup) return false; + if (Id != other.Id) return false; + if (Text != other.Text) return false; + if (MatchType != other.MatchType) return false; + if (CpcBidMicros != other.CpcBidMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (keywordPlanAdGroup_ != null) hash ^= KeywordPlanAdGroup.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (text_ != null) hash ^= Text.GetHashCode(); + if (MatchType != 0) hash ^= MatchType.GetHashCode(); + if (cpcBidMicros_ != null) hash ^= CpcBidMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (keywordPlanAdGroup_ != null) { + _single_keywordPlanAdGroup_codec.WriteTagAndValue(output, KeywordPlanAdGroup); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (MatchType != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) MatchType); + } + if (cpcBidMicros_ != null) { + _single_cpcBidMicros_codec.WriteTagAndValue(output, CpcBidMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (keywordPlanAdGroup_ != null) { + size += _single_keywordPlanAdGroup_codec.CalculateSizeWithTag(KeywordPlanAdGroup); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (MatchType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MatchType); + } + if (cpcBidMicros_ != null) { + size += _single_cpcBidMicros_codec.CalculateSizeWithTag(CpcBidMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanKeyword other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.keywordPlanAdGroup_ != null) { + if (keywordPlanAdGroup_ == null || other.KeywordPlanAdGroup != "") { + KeywordPlanAdGroup = other.KeywordPlanAdGroup; + } + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + if (other.MatchType != 0) { + MatchType = other.MatchType; + } + if (other.cpcBidMicros_ != null) { + if (cpcBidMicros_ == null || other.CpcBidMicros != 0L) { + CpcBidMicros = other.CpcBidMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_keywordPlanAdGroup_codec.Read(input); + if (keywordPlanAdGroup_ == null || value != "") { + KeywordPlanAdGroup = value; + } + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + case 40: { + MatchType = (global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType) input.ReadEnum(); + break; + } + case 50: { + long? value = _single_cpcBidMicros_codec.Read(input); + if (cpcBidMicros_ == null || value != 0L) { + CpcBidMicros = value; + } + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanKeywordError.cs b/src/V3/Stubs/KeywordPlanKeywordError.cs new file mode 100644 index 000000000..9805aeab8 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanKeywordError.cs @@ -0,0 +1,207 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/keyword_plan_keyword_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/keyword_plan_keyword_error.proto + public static partial class KeywordPlanKeywordErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/keyword_plan_keyword_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanKeywordErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cj9nb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMva2V5d29yZF9wbGFu", + "X2tleXdvcmRfZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LmVycm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90byKCAgobS2V5", + "d29yZFBsYW5LZXl3b3JkRXJyb3JFbnVtIuIBChdLZXl3b3JkUGxhbktleXdv", + "cmRFcnJvchIPCgtVTlNQRUNJRklFRBAAEgsKB1VOS05PV04QARIeChpJTlZB", + "TElEX0tFWVdPUkRfTUFUQ0hfVFlQRRACEhUKEURVUExJQ0FURV9LRVlXT1JE", + "EAMSGQoVS0VZV09SRF9URVhUX1RPT19MT05HEAQSHQoZS0VZV09SRF9IQVNf", + "SU5WQUxJRF9DSEFSUxAFEh4KGktFWVdPUkRfSEFTX1RPT19NQU5ZX1dPUkRT", + "EAYSGAoUSU5WQUxJRF9LRVlXT1JEX1RFWFQQB0L3AQoiY29tLmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLmVycm9yc0IcS2V5d29yZFBsYW5LZXl3b3JkRXJy", + "b3JQcm90b1ABWkRnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVh", + "cGlzL2Fkcy9nb29nbGVhZHMvdjMvZXJyb3JzO2Vycm9yc6ICA0dBQaoCHkdv", + "b2dsZS5BZHMuR29vZ2xlQWRzLlYzLkVycm9yc8oCHkdvb2dsZVxBZHNcR29v", + "Z2xlQWRzXFYzXEVycm9yc+oCIkdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYz", + "OjpFcnJvcnNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanKeywordErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanKeywordErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanKeywordErrorEnum.Types.KeywordPlanKeywordError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible errors from applying a keyword or a + /// negative keyword from a keyword plan. + /// + public sealed partial class KeywordPlanKeywordErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanKeywordErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanKeywordErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordErrorEnum(KeywordPlanKeywordErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordErrorEnum Clone() { + return new KeywordPlanKeywordErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanKeywordErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanKeywordErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanKeywordErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanKeywordErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible errors from applying a keyword plan keyword. + /// + public enum KeywordPlanKeywordError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// A keyword or negative keyword has invalid match type. + /// + [pbr::OriginalName("INVALID_KEYWORD_MATCH_TYPE")] InvalidKeywordMatchType = 2, + /// + /// A keyword or negative keyword with same text and match type already + /// exists. + /// + [pbr::OriginalName("DUPLICATE_KEYWORD")] DuplicateKeyword = 3, + /// + /// Keyword or negative keyword text exceeds the allowed limit. + /// + [pbr::OriginalName("KEYWORD_TEXT_TOO_LONG")] KeywordTextTooLong = 4, + /// + /// Keyword or negative keyword text has invalid characters or symbols. + /// + [pbr::OriginalName("KEYWORD_HAS_INVALID_CHARS")] KeywordHasInvalidChars = 5, + /// + /// Keyword or negative keyword text has too many words. + /// + [pbr::OriginalName("KEYWORD_HAS_TOO_MANY_WORDS")] KeywordHasTooManyWords = 6, + /// + /// Keyword or negative keyword has invalid text. + /// + [pbr::OriginalName("INVALID_KEYWORD_TEXT")] InvalidKeywordText = 7, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanKeywordService.cs b/src/V3/Stubs/KeywordPlanKeywordService.cs new file mode 100644 index 000000000..153244334 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanKeywordService.cs @@ -0,0 +1,1038 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_keyword_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/keyword_plan_keyword_service.proto + public static partial class KeywordPlanKeywordServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/keyword_plan_keyword_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanKeywordServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkNnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9rZXl3b3JkX3Bs", + "YW5fa2V5d29yZF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRzLmdvb2dsZWFk", + "cy52My5zZXJ2aWNlcxo8Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvcmVzb3Vy", + "Y2VzL2tleXdvcmRfcGxhbl9rZXl3b3JkLnByb3RvGhxnb29nbGUvYXBpL2Fu", + "bm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29v", + "Z2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29vZ2xlL3Byb3RvYnVm", + "L2ZpZWxkX21hc2sucHJvdG8aF2dvb2dsZS9ycGMvc3RhdHVzLnByb3RvIjoK", + "HEdldEtleXdvcmRQbGFuS2V5d29yZFJlcXVlc3QSGgoNcmVzb3VyY2VfbmFt", + "ZRgBIAEoCUID4EECIsQBCiBNdXRhdGVLZXl3b3JkUGxhbktleXdvcmRzUmVx", + "dWVzdBIYCgtjdXN0b21lcl9pZBgBIAEoCUID4EECElYKCm9wZXJhdGlvbnMY", + "AiADKAsyPS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5LZXl3", + "b3JkUGxhbktleXdvcmRPcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1", + "cmUYAyABKAgSFQoNdmFsaWRhdGVfb25seRgEIAEoCCL/AQobS2V5d29yZFBs", + "YW5LZXl3b3JkT3BlcmF0aW9uEi8KC3VwZGF0ZV9tYXNrGAQgASgLMhouZ29v", + "Z2xlLnByb3RvYnVmLkZpZWxkTWFzaxJHCgZjcmVhdGUYASABKAsyNS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMuS2V5d29yZFBsYW5LZXl3", + "b3JkSAASRwoGdXBkYXRlGAIgASgLMjUuZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMucmVzb3VyY2VzLktleXdvcmRQbGFuS2V5d29yZEgAEhAKBnJlbW92ZRgD", + "IAEoCUgAQgsKCW9wZXJhdGlvbiKpAQohTXV0YXRlS2V5d29yZFBsYW5LZXl3", + "b3Jkc1Jlc3BvbnNlEjEKFXBhcnRpYWxfZmFpbHVyZV9lcnJvchgDIAEoCzIS", + "Lmdvb2dsZS5ycGMuU3RhdHVzElEKB3Jlc3VsdHMYAiADKAsyQC5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVLZXl3b3JkUGxhbktl", + "eXdvcmRSZXN1bHQiNwoeTXV0YXRlS2V5d29yZFBsYW5LZXl3b3JkUmVzdWx0", + "EhUKDXJlc291cmNlX25hbWUYASABKAkynQQKGUtleXdvcmRQbGFuS2V5d29y", + "ZFNlcnZpY2US3QEKFUdldEtleXdvcmRQbGFuS2V5d29yZBI+Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLkdldEtleXdvcmRQbGFuS2V5d29y", + "ZFJlcXVlc3QaNS5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMu", + "S2V5d29yZFBsYW5LZXl3b3JkIk2C0+STAjcSNS92My97cmVzb3VyY2VfbmFt", + "ZT1jdXN0b21lcnMvKi9rZXl3b3JkUGxhbktleXdvcmRzLyp92kENcmVzb3Vy", + "Y2VfbmFtZRKCAgoZTXV0YXRlS2V5d29yZFBsYW5LZXl3b3JkcxJCLmdvb2ds", + "ZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUtleXdvcmRQbGFu", + "S2V5d29yZHNSZXF1ZXN0GkMuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuTXV0YXRlS2V5d29yZFBsYW5LZXl3b3Jkc1Jlc3BvbnNlIlyC0+ST", + "Aj0iOC92My9jdXN0b21lcnMve2N1c3RvbWVyX2lkPSp9L2tleXdvcmRQbGFu", + "S2V5d29yZHM6bXV0YXRlOgEq2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9ucxob", + "ykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQoUCCiRjb20uZ29vZ2xlLmFk", + "cy5nb29nbGVhZHMudjMuc2VydmljZXNCHktleXdvcmRQbGFuS2V5d29yZFNl", + "cnZpY2VQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29n", + "bGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2VydmljZXOiAgNH", + "QUGqAiBHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNlc8oCIEdvb2ds", + "ZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xlOjpBZHM6Okdv", + "b2dsZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeywordReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanKeywordRequest), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanKeywordRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordOperation), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordResult), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [KeywordPlanKeywordService.GetKeywordPlanKeyword][google.ads.googleads.v3.services.KeywordPlanKeywordService.GetKeywordPlanKeyword]. + /// + public sealed partial class GetKeywordPlanKeywordRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetKeywordPlanKeywordRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanKeywordRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanKeywordRequest(GetKeywordPlanKeywordRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanKeywordRequest Clone() { + return new GetKeywordPlanKeywordRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the ad group keyword to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetKeywordPlanKeywordRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetKeywordPlanKeywordRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetKeywordPlanKeywordRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [KeywordPlanKeywordService.MutateKeywordPlanKeywords][google.ads.googleads.v3.services.KeywordPlanKeywordService.MutateKeywordPlanKeywords]. + /// + public sealed partial class MutateKeywordPlanKeywordsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanKeywordsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordsRequest(MutateKeywordPlanKeywordsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordsRequest Clone() { + return new MutateKeywordPlanKeywordsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose Keyword Plan keywords are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual Keyword Plan keywords. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanKeywordsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanKeywordsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanKeywordsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a Keyword Plan keyword. + /// + public sealed partial class KeywordPlanKeywordOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanKeywordOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordOperation(KeywordPlanKeywordOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordOperation Clone() { + return new KeywordPlanKeywordOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// The FieldMask that determines which resource fields are modified in an + /// update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new Keyword Plan + /// ad group keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The Keyword Plan keyword is expected to have a valid + /// resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed Keyword Plan keyword is + /// expected, in this format: + /// + /// `customers/{customer_id}/keywordPlanKeywords/{kp_ad_group_keyword_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanKeywordOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanKeywordOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanKeywordOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a Keyword Plan keyword mutate. + /// + public sealed partial class MutateKeywordPlanKeywordsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanKeywordsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordsResponse(MutateKeywordPlanKeywordsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordsResponse Clone() { + return new MutateKeywordPlanKeywordsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanKeywordsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanKeywordsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanKeywordsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the Keyword Plan keyword mutate. + /// + public sealed partial class MutateKeywordPlanKeywordResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanKeywordResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordResult(MutateKeywordPlanKeywordResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanKeywordResult Clone() { + return new MutateKeywordPlanKeywordResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanKeywordResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanKeywordResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanKeywordResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanKeywordServiceClient.cs b/src/V3/Stubs/KeywordPlanKeywordServiceClient.cs new file mode 100644 index 000000000..239ea46b8 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanKeywordServiceClient.cs @@ -0,0 +1,898 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class KeywordPlanKeywordServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static KeywordPlanKeywordServiceSettings GetDefault() => new KeywordPlanKeywordServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public KeywordPlanKeywordServiceSettings() { } + + private KeywordPlanKeywordServiceSettings(KeywordPlanKeywordServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetKeywordPlanKeywordSettings = existing.GetKeywordPlanKeywordSettings; + MutateKeywordPlanKeywordsSettings = existing.MutateKeywordPlanKeywordsSettings; + OnCopy(existing); + } + + partial void OnCopy(KeywordPlanKeywordServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanKeywordServiceClient.GetKeywordPlanKeyword and KeywordPlanKeywordServiceClient.GetKeywordPlanKeywordAsync. + /// + /// + /// The default KeywordPlanKeywordServiceClient.GetKeywordPlanKeyword and + /// KeywordPlanKeywordServiceClient.GetKeywordPlanKeywordAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetKeywordPlanKeywordSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanKeywordServiceClient.MutateKeywordPlanKeywords and KeywordPlanKeywordServiceClient.MutateKeywordPlanKeywordsAsync. + /// + /// + /// The default KeywordPlanKeywordServiceClient.MutateKeywordPlanKeywords and + /// KeywordPlanKeywordServiceClient.MutateKeywordPlanKeywordsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateKeywordPlanKeywordsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public KeywordPlanKeywordServiceSettings Clone() => new KeywordPlanKeywordServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class KeywordPlanKeywordServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public KeywordPlanKeywordServiceSettings Settings { get; set; } + + /// + public override KeywordPlanKeywordServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return KeywordPlanKeywordServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return KeywordPlanKeywordServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => KeywordPlanKeywordServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => KeywordPlanKeywordServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => KeywordPlanKeywordServiceClient.ChannelPool; + } + + /// + /// KeywordPlanKeywordService client wrapper, for convenient use. + /// + public abstract partial class KeywordPlanKeywordServiceClient + { + /// + /// The default endpoint for the KeywordPlanKeywordService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default KeywordPlanKeywordService scopes. + /// + /// + /// The default KeywordPlanKeywordService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanKeywordServiceClient client = await KeywordPlanKeywordServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanKeywordServiceClient.DefaultEndpoint.Host, KeywordPlanKeywordServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanKeywordServiceClient client = KeywordPlanKeywordServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanKeywordServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanKeywordServiceClient client = KeywordPlanKeywordServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanKeywordServiceClient.DefaultEndpoint.Host, KeywordPlanKeywordServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanKeywordServiceClient client = KeywordPlanKeywordServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static KeywordPlanKeywordServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanKeywordServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanKeywordServiceClient Create(grpccore::Channel channel, KeywordPlanKeywordServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanKeywordServiceClient Create(grpccore::CallInvoker callInvoker, KeywordPlanKeywordServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + KeywordPlanKeywordService.KeywordPlanKeywordServiceClient grpcClient = new KeywordPlanKeywordService.KeywordPlanKeywordServiceClient(callInvoker); + return new KeywordPlanKeywordServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC KeywordPlanKeywordService client. + /// + public virtual KeywordPlanKeywordService.KeywordPlanKeywordServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// + /// Required. The resource name of the ad group keyword to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanKeywordAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanKeywordAsync( + new GetKeywordPlanKeywordRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// + /// Required. The resource name of the ad group keyword to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanKeywordAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetKeywordPlanKeywordAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// + /// Required. The resource name of the ad group keyword to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlanKeyword GetKeywordPlanKeyword( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanKeyword( + new GetKeywordPlanKeywordRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanKeywordAsync( + GetKeywordPlanKeywordRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanKeywordAsync( + GetKeywordPlanKeywordRequest request, + st::CancellationToken cancellationToken) => GetKeywordPlanKeywordAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlanKeyword GetKeywordPlanKeyword( + GetKeywordPlanKeywordRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan keywords. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanKeywordsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanKeywordsAsync( + new MutateKeywordPlanKeywordsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan keywords. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanKeywordsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateKeywordPlanKeywordsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan keywords. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanKeywordsResponse MutateKeywordPlanKeywords( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanKeywords( + new MutateKeywordPlanKeywordsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan keywords. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanKeywordsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanKeywordsAsync( + new MutateKeywordPlanKeywordsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan keywords. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanKeywordsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateKeywordPlanKeywordsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose Keyword Plan keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan keywords. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanKeywordsResponse MutateKeywordPlanKeywords( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanKeywords( + new MutateKeywordPlanKeywordsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanKeywordsAsync( + MutateKeywordPlanKeywordsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanKeywordsAsync( + MutateKeywordPlanKeywordsRequest request, + st::CancellationToken cancellationToken) => MutateKeywordPlanKeywordsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanKeywordsResponse MutateKeywordPlanKeywords( + MutateKeywordPlanKeywordsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// KeywordPlanKeywordService client wrapper implementation, for convenient use. + /// + public sealed partial class KeywordPlanKeywordServiceClientImpl : KeywordPlanKeywordServiceClient + { + private readonly gaxgrpc::ApiCall _callGetKeywordPlanKeyword; + private readonly gaxgrpc::ApiCall _callMutateKeywordPlanKeywords; + + /// + /// Constructs a client wrapper for the KeywordPlanKeywordService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public KeywordPlanKeywordServiceClientImpl(KeywordPlanKeywordService.KeywordPlanKeywordServiceClient grpcClient, KeywordPlanKeywordServiceSettings settings) + { + GrpcClient = grpcClient; + KeywordPlanKeywordServiceSettings effectiveSettings = settings ?? KeywordPlanKeywordServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetKeywordPlanKeyword = clientHelper.BuildApiCall( + GrpcClient.GetKeywordPlanKeywordAsync, GrpcClient.GetKeywordPlanKeyword, effectiveSettings.GetKeywordPlanKeywordSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateKeywordPlanKeywords = clientHelper.BuildApiCall( + GrpcClient.MutateKeywordPlanKeywordsAsync, GrpcClient.MutateKeywordPlanKeywords, effectiveSettings.MutateKeywordPlanKeywordsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetKeywordPlanKeyword); + Modify_GetKeywordPlanKeywordApiCall(ref _callGetKeywordPlanKeyword); + Modify_ApiCall(ref _callMutateKeywordPlanKeywords); + Modify_MutateKeywordPlanKeywordsApiCall(ref _callMutateKeywordPlanKeywords); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetKeywordPlanKeywordApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateKeywordPlanKeywordsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(KeywordPlanKeywordService.KeywordPlanKeywordServiceClient grpcClient, KeywordPlanKeywordServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC KeywordPlanKeywordService client. + /// + public override KeywordPlanKeywordService.KeywordPlanKeywordServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetKeywordPlanKeywordRequest(ref GetKeywordPlanKeywordRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateKeywordPlanKeywordsRequest(ref MutateKeywordPlanKeywordsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetKeywordPlanKeywordAsync( + GetKeywordPlanKeywordRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanKeywordRequest(ref request, ref callSettings); + return _callGetKeywordPlanKeyword.Async(request, callSettings); + } + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::KeywordPlanKeyword GetKeywordPlanKeyword( + GetKeywordPlanKeywordRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanKeywordRequest(ref request, ref callSettings); + return _callGetKeywordPlanKeyword.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateKeywordPlanKeywordsAsync( + MutateKeywordPlanKeywordsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlanKeywordsRequest(ref request, ref callSettings); + return _callMutateKeywordPlanKeywords.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateKeywordPlanKeywordsResponse MutateKeywordPlanKeywords( + MutateKeywordPlanKeywordsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlanKeywordsRequest(ref request, ref callSettings); + return _callMutateKeywordPlanKeywords.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/KeywordPlanKeywordServiceGrpc.cs b/src/V3/Stubs/KeywordPlanKeywordServiceGrpc.cs new file mode 100644 index 000000000..3de05dff4 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanKeywordServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_keyword_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage Keyword Plan ad group keywords. + /// + public static partial class KeywordPlanKeywordService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.KeywordPlanKeywordService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanKeywordRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanKeywordRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_KeywordPlanKeyword = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanKeywordsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanKeywordsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetKeywordPlanKeyword = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetKeywordPlanKeyword", + __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanKeywordRequest, + __Marshaller_google_ads_googleads_v3_resources_KeywordPlanKeyword); + + static readonly grpc::Method __Method_MutateKeywordPlanKeywords = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateKeywordPlanKeywords", + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanKeywordsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanKeywordsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of KeywordPlanKeywordService + public abstract partial class KeywordPlanKeywordServiceBase + { + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetKeywordPlanKeyword(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanKeywordRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateKeywordPlanKeywords(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for KeywordPlanKeywordService + public partial class KeywordPlanKeywordServiceClient : grpc::ClientBase + { + /// Creates a new client for KeywordPlanKeywordService + /// The channel to use to make remote calls. + public KeywordPlanKeywordServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for KeywordPlanKeywordService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public KeywordPlanKeywordServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected KeywordPlanKeywordServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected KeywordPlanKeywordServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword GetKeywordPlanKeyword(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanKeywordRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanKeyword(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanKeyword GetKeywordPlanKeyword(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanKeywordRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetKeywordPlanKeyword, null, options, request); + } + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanKeywordAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanKeywordRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanKeywordAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan keyword in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanKeywordAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanKeywordRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetKeywordPlanKeyword, null, options, request); + } + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsResponse MutateKeywordPlanKeywords(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlanKeywords(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsResponse MutateKeywordPlanKeywords(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateKeywordPlanKeywords, null, options, request); + } + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlanKeywordsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlanKeywordsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes Keyword Plan keywords. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlanKeywordsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanKeywordsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateKeywordPlanKeywords, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override KeywordPlanKeywordServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new KeywordPlanKeywordServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(KeywordPlanKeywordServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetKeywordPlanKeyword, serviceImpl.GetKeywordPlanKeyword) + .AddMethod(__Method_MutateKeywordPlanKeywords, serviceImpl.MutateKeywordPlanKeywords).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, KeywordPlanKeywordServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetKeywordPlanKeyword, serviceImpl.GetKeywordPlanKeyword); + serviceBinder.AddMethod(__Method_MutateKeywordPlanKeywords, serviceImpl.MutateKeywordPlanKeywords); + } + + } +} +#endregion diff --git a/src/V3/Stubs/KeywordPlanNegativeKeyword.cs b/src/V3/Stubs/KeywordPlanNegativeKeyword.cs new file mode 100644 index 000000000..4c8209e86 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanNegativeKeyword.cs @@ -0,0 +1,347 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/keyword_plan_negative_keyword.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/keyword_plan_negative_keyword.proto + public static partial class KeywordPlanNegativeKeywordReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/keyword_plan_negative_keyword.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanNegativeKeywordReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CkVnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMva2V5d29yZF9w", + "bGFuX25lZ2F0aXZlX2tleXdvcmQucHJvdG8SIWdvb2dsZS5hZHMuZ29vZ2xl", + "YWRzLnYzLnJlc291cmNlcxo2Z29vZ2xlL2Fkcy9nb29nbGVhZHMvdjMvZW51", + "bXMva2V5d29yZF9tYXRjaF90eXBlLnByb3RvGh9nb29nbGUvYXBpL2ZpZWxk", + "X2JlaGF2aW9yLnByb3RvGhlnb29nbGUvYXBpL3Jlc291cmNlLnByb3RvGh5n", + "b29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8aHGdvb2dsZS9hcGkvYW5u", + "b3RhdGlvbnMucHJvdG8iogQKGktleXdvcmRQbGFuTmVnYXRpdmVLZXl3b3Jk", + "ElIKDXJlc291cmNlX25hbWUYASABKAlCO+BBBfpBNQozZ29vZ2xlYWRzLmdv", + "b2dsZWFwaXMuY29tL0tleXdvcmRQbGFuTmVnYXRpdmVLZXl3b3JkEm4KFWtl", + "eXdvcmRfcGxhbl9jYW1wYWlnbhgCIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5T", + "dHJpbmdWYWx1ZUIx+kEuCixnb29nbGVhZHMuZ29vZ2xlYXBpcy5jb20vS2V5", + "d29yZFBsYW5DYW1wYWlnbhIsCgJpZBgDIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQ2NFZhbHVlQgPgQQMSKgoEdGV4dBgEIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZRJYCgptYXRjaF90eXBlGAUgASgOMkQuZ29vZ2xl", + "LmFkcy5nb29nbGVhZHMudjMuZW51bXMuS2V5d29yZE1hdGNoVHlwZUVudW0u", + "S2V5d29yZE1hdGNoVHlwZTqLAepBhwEKM2dvb2dsZWFkcy5nb29nbGVhcGlz", + "LmNvbS9LZXl3b3JkUGxhbk5lZ2F0aXZlS2V5d29yZBJQY3VzdG9tZXJzL3tj", + "dXN0b21lcn0va2V5d29yZFBsYW5OZWdhdGl2ZUtleXdvcmRzL3trZXl3b3Jk", + "X3BsYW5fbmVnYXRpdmVfa2V5d29yZH1CjAIKJWNvbS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5yZXNvdXJjZXNCH0tleXdvcmRQbGFuTmVnYXRpdmVLZXl3", + "b3JkUHJvdG9QAVpKZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xl", + "YXBpcy9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcztyZXNvdXJjZXOiAgNH", + "QUGqAiFHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5SZXNvdXJjZXPKAiFHb29n", + "bGVcQWRzXEdvb2dsZUFkc1xWM1xSZXNvdXJjZXPqAiVHb29nbGU6OkFkczo6", + "R29vZ2xlQWRzOjpWMzo6UmVzb3VyY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword.Parser, new[]{ "ResourceName", "KeywordPlanCampaign", "Id", "Text", "MatchType" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A Keyword Plan negative keyword. + /// Max number of keyword plan negative keywords per plan: 1000. + /// + public sealed partial class KeywordPlanNegativeKeyword : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanNegativeKeyword()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeywordReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeyword() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeyword(KeywordPlanNegativeKeyword other) : this() { + resourceName_ = other.resourceName_; + KeywordPlanCampaign = other.KeywordPlanCampaign; + Id = other.Id; + Text = other.Text; + matchType_ = other.matchType_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeyword Clone() { + return new KeywordPlanNegativeKeyword(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the Keyword Plan negative keyword. + /// KeywordPlanNegativeKeyword resource names have the form: + /// + /// `customers/{customer_id}/keywordPlanNegativeKeywords/{kp_negative_keyword_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "keyword_plan_campaign" field. + public const int KeywordPlanCampaignFieldNumber = 2; + private static readonly pb::FieldCodec _single_keywordPlanCampaign_codec = pb::FieldCodec.ForClassWrapper(18); + private string keywordPlanCampaign_; + /// + /// The Keyword Plan campaign to which this negative keyword belongs. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlanCampaign { + get { return keywordPlanCampaign_; } + set { + keywordPlanCampaign_ = value; + } + } + + + /// Field number for the "id" field. + public const int IdFieldNumber = 3; + private static readonly pb::FieldCodec _single_id_codec = pb::FieldCodec.ForStructWrapper(26); + private long? id_; + /// + /// Output only. The ID of the Keyword Plan negative keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? Id { + get { return id_; } + set { + id_ = value; + } + } + + + /// Field number for the "text" field. + public const int TextFieldNumber = 4; + private static readonly pb::FieldCodec _single_text_codec = pb::FieldCodec.ForClassWrapper(34); + private string text_; + /// + /// The keyword text. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Text { + get { return text_; } + set { + text_ = value; + } + } + + + /// Field number for the "match_type" field. + public const int MatchTypeFieldNumber = 5; + private global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType matchType_ = 0; + /// + /// The keyword match type. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType MatchType { + get { return matchType_; } + set { + matchType_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanNegativeKeyword); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanNegativeKeyword other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + if (KeywordPlanCampaign != other.KeywordPlanCampaign) return false; + if (Id != other.Id) return false; + if (Text != other.Text) return false; + if (MatchType != other.MatchType) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (keywordPlanCampaign_ != null) hash ^= KeywordPlanCampaign.GetHashCode(); + if (id_ != null) hash ^= Id.GetHashCode(); + if (text_ != null) hash ^= Text.GetHashCode(); + if (MatchType != 0) hash ^= MatchType.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (keywordPlanCampaign_ != null) { + _single_keywordPlanCampaign_codec.WriteTagAndValue(output, KeywordPlanCampaign); + } + if (id_ != null) { + _single_id_codec.WriteTagAndValue(output, Id); + } + if (text_ != null) { + _single_text_codec.WriteTagAndValue(output, Text); + } + if (MatchType != 0) { + output.WriteRawTag(40); + output.WriteEnum((int) MatchType); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (keywordPlanCampaign_ != null) { + size += _single_keywordPlanCampaign_codec.CalculateSizeWithTag(KeywordPlanCampaign); + } + if (id_ != null) { + size += _single_id_codec.CalculateSizeWithTag(Id); + } + if (text_ != null) { + size += _single_text_codec.CalculateSizeWithTag(Text); + } + if (MatchType != 0) { + size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MatchType); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanNegativeKeyword other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + if (other.keywordPlanCampaign_ != null) { + if (keywordPlanCampaign_ == null || other.KeywordPlanCampaign != "") { + KeywordPlanCampaign = other.KeywordPlanCampaign; + } + } + if (other.id_ != null) { + if (id_ == null || other.Id != 0L) { + Id = other.Id; + } + } + if (other.text_ != null) { + if (text_ == null || other.Text != "") { + Text = other.Text; + } + } + if (other.MatchType != 0) { + MatchType = other.MatchType; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + case 18: { + string value = _single_keywordPlanCampaign_codec.Read(input); + if (keywordPlanCampaign_ == null || value != "") { + KeywordPlanCampaign = value; + } + break; + } + case 26: { + long? value = _single_id_codec.Read(input); + if (id_ == null || value != 0L) { + Id = value; + } + break; + } + case 34: { + string value = _single_text_codec.Read(input); + if (text_ == null || value != "") { + Text = value; + } + break; + } + case 40: { + MatchType = (global::Google.Ads.GoogleAds.V3.Enums.KeywordMatchTypeEnum.Types.KeywordMatchType) input.ReadEnum(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanNegativeKeywordError.cs b/src/V3/Stubs/KeywordPlanNegativeKeywordError.cs new file mode 100644 index 000000000..4eeb4446d --- /dev/null +++ b/src/V3/Stubs/KeywordPlanNegativeKeywordError.cs @@ -0,0 +1,180 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/errors/keyword_plan_negative_keyword_error.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Errors { + + /// Holder for reflection information generated from google/ads/googleads/v3/errors/keyword_plan_negative_keyword_error.proto + public static partial class KeywordPlanNegativeKeywordErrorReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/errors/keyword_plan_negative_keyword_error.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanNegativeKeywordErrorReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lcnJvcnMva2V5d29yZF9wbGFu", + "X25lZ2F0aXZlX2tleXdvcmRfZXJyb3IucHJvdG8SHmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLmVycm9ycxocZ29vZ2xlL2FwaS9hbm5vdGF0aW9ucy5wcm90", + "byJmCiNLZXl3b3JkUGxhbk5lZ2F0aXZlS2V5d29yZEVycm9yRW51bSI/Ch9L", + "ZXl3b3JkUGxhbk5lZ2F0aXZlS2V5d29yZEVycm9yEg8KC1VOU1BFQ0lGSUVE", + "EAASCwoHVU5LTk9XThABQv8BCiJjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMu", + "djMuZXJyb3JzQiRLZXl3b3JkUGxhbk5lZ2F0aXZlS2V5d29yZEVycm9yUHJv", + "dG9QAVpEZ29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9h", + "ZHMvZ29vZ2xlYWRzL3YzL2Vycm9ycztlcnJvcnOiAgNHQUGqAh5Hb29nbGUu", + "QWRzLkdvb2dsZUFkcy5WMy5FcnJvcnPKAh5Hb29nbGVcQWRzXEdvb2dsZUFk", + "c1xWM1xFcnJvcnPqAiJHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpWMzo6RXJy", + "b3JzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanNegativeKeywordErrorEnum), global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanNegativeKeywordErrorEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanNegativeKeywordErrorEnum.Types.KeywordPlanNegativeKeywordError) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enum describing possible errors from applying a keyword plan + /// negative keyword. + /// + public sealed partial class KeywordPlanNegativeKeywordErrorEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanNegativeKeywordErrorEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Errors.KeywordPlanNegativeKeywordErrorReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeywordErrorEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeywordErrorEnum(KeywordPlanNegativeKeywordErrorEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeywordErrorEnum Clone() { + return new KeywordPlanNegativeKeywordErrorEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanNegativeKeywordErrorEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanNegativeKeywordErrorEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanNegativeKeywordErrorEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanNegativeKeywordErrorEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enum describing possible errors from applying a keyword plan negative + /// keyword. + /// + public enum KeywordPlanNegativeKeywordError { + /// + /// Enum unspecified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The received error code is not known in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanNegativeKeywordService.cs b/src/V3/Stubs/KeywordPlanNegativeKeywordService.cs new file mode 100644 index 000000000..7326bf4fa --- /dev/null +++ b/src/V3/Stubs/KeywordPlanNegativeKeywordService.cs @@ -0,0 +1,1046 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_negative_keyword_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/keyword_plan_negative_keyword_service.proto + public static partial class KeywordPlanNegativeKeywordServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/keyword_plan_negative_keyword_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanNegativeKeywordServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ckxnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9rZXl3b3JkX3Bs", + "YW5fbmVnYXRpdmVfa2V5d29yZF9zZXJ2aWNlLnByb3RvEiBnb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5zZXJ2aWNlcxpFZ29vZ2xlL2Fkcy9nb29nbGVhZHMv", + "djMvcmVzb3VyY2VzL2tleXdvcmRfcGxhbl9uZWdhdGl2ZV9rZXl3b3JkLnBy", + "b3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvGhdnb29nbGUvYXBp", + "L2NsaWVudC5wcm90bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90", + "bxogZ29vZ2xlL3Byb3RvYnVmL2ZpZWxkX21hc2sucHJvdG8aF2dvb2dsZS9y", + "cGMvc3RhdHVzLnByb3RvIkIKJEdldEtleXdvcmRQbGFuTmVnYXRpdmVLZXl3", + "b3JkUmVxdWVzdBIaCg1yZXNvdXJjZV9uYW1lGAEgASgJQgPgQQIi1AEKKE11", + "dGF0ZUtleXdvcmRQbGFuTmVnYXRpdmVLZXl3b3Jkc1JlcXVlc3QSGAoLY3Vz", + "dG9tZXJfaWQYASABKAlCA+BBAhJeCgpvcGVyYXRpb25zGAIgAygLMkUuZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuS2V5d29yZFBsYW5OZWdh", + "dGl2ZUtleXdvcmRPcGVyYXRpb25CA+BBAhIXCg9wYXJ0aWFsX2ZhaWx1cmUY", + "AyABKAgSFQoNdmFsaWRhdGVfb25seRgEIAEoCCKXAgojS2V5d29yZFBsYW5O", + "ZWdhdGl2ZUtleXdvcmRPcGVyYXRpb24SLwoLdXBkYXRlX21hc2sYBCABKAsy", + "Gi5nb29nbGUucHJvdG9idWYuRmllbGRNYXNrEk8KBmNyZWF0ZRgBIAEoCzI9", + "Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5LZXl3b3JkUGxh", + "bk5lZ2F0aXZlS2V5d29yZEgAEk8KBnVwZGF0ZRgCIAEoCzI9Lmdvb2dsZS5h", + "ZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcy5LZXl3b3JkUGxhbk5lZ2F0aXZl", + "S2V5d29yZEgAEhAKBnJlbW92ZRgDIAEoCUgAQgsKCW9wZXJhdGlvbiK5AQop", + "TXV0YXRlS2V5d29yZFBsYW5OZWdhdGl2ZUtleXdvcmRzUmVzcG9uc2USMQoV", + "cGFydGlhbF9mYWlsdXJlX2Vycm9yGAMgASgLMhIuZ29vZ2xlLnJwYy5TdGF0", + "dXMSWQoHcmVzdWx0cxgCIAMoCzJILmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYz", + "LnNlcnZpY2VzLk11dGF0ZUtleXdvcmRQbGFuTmVnYXRpdmVLZXl3b3JkUmVz", + "dWx0Ij8KJk11dGF0ZUtleXdvcmRQbGFuTmVnYXRpdmVLZXl3b3JkUmVzdWx0", + "EhUKDXJlc291cmNlX25hbWUYASABKAky5QQKIUtleXdvcmRQbGFuTmVnYXRp", + "dmVLZXl3b3JkU2VydmljZRL9AQodR2V0S2V5d29yZFBsYW5OZWdhdGl2ZUtl", + "eXdvcmQSRi5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZXRL", + "ZXl3b3JkUGxhbk5lZ2F0aXZlS2V5d29yZFJlcXVlc3QaPS5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5yZXNvdXJjZXMuS2V5d29yZFBsYW5OZWdhdGl2ZUtl", + "eXdvcmQiVYLT5JMCPxI9L3YzL3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8q", + "L2tleXdvcmRQbGFuTmVnYXRpdmVLZXl3b3Jkcy8qfdpBDXJlc291cmNlX25h", + "bWUSogIKIU11dGF0ZUtleXdvcmRQbGFuTmVnYXRpdmVLZXl3b3JkcxJKLmdv", + "b2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzLk11dGF0ZUtleXdvcmRQ", + "bGFuTmVnYXRpdmVLZXl3b3Jkc1JlcXVlc3QaSy5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVLZXl3b3JkUGxhbk5lZ2F0aXZlS2V5", + "d29yZHNSZXNwb25zZSJkgtPkkwJFIkAvdjMvY3VzdG9tZXJzL3tjdXN0b21l", + "cl9pZD0qfS9rZXl3b3JkUGxhbk5lZ2F0aXZlS2V5d29yZHM6bXV0YXRlOgEq", + "2kEWY3VzdG9tZXJfaWQsb3BlcmF0aW9ucxobykEYZ29vZ2xlYWRzLmdvb2ds", + "ZWFwaXMuY29tQo0CCiRjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXNCJktleXdvcmRQbGFuTmVnYXRpdmVLZXl3b3JkU2VydmljZVByb3Rv", + "UAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvYWRz", + "L2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dBQaoCIEdvb2ds", + "ZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xlXEFkc1xHb29n", + "bGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29vZ2xlQWRzOjpW", + "Mzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeywordReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanNegativeKeywordRequest), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanNegativeKeywordRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsRequest), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordOperation), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsResponse), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordResult), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordResult.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for + /// [KeywordPlanNegativeKeywordService.GetKeywordPlanNegativeKeyword][google.ads.googleads.v3.services.KeywordPlanNegativeKeywordService.GetKeywordPlanNegativeKeyword]. + /// + public sealed partial class GetKeywordPlanNegativeKeywordRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetKeywordPlanNegativeKeywordRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanNegativeKeywordRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanNegativeKeywordRequest(GetKeywordPlanNegativeKeywordRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanNegativeKeywordRequest Clone() { + return new GetKeywordPlanNegativeKeywordRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the plan to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetKeywordPlanNegativeKeywordRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetKeywordPlanNegativeKeywordRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetKeywordPlanNegativeKeywordRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for + /// [KeywordPlanNegativeKeywordService.MutateKeywordPlanNegativeKeywords][google.ads.googleads.v3.services.KeywordPlanNegativeKeywordService.MutateKeywordPlanNegativeKeywords]. + /// + public sealed partial class MutateKeywordPlanNegativeKeywordsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanNegativeKeywordsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordsRequest(MutateKeywordPlanNegativeKeywordsRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordsRequest Clone() { + return new MutateKeywordPlanNegativeKeywordsRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose negative keywords are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual Keyword Plan negative + /// keywords. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanNegativeKeywordsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanNegativeKeywordsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanNegativeKeywordsRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a Keyword Plan negative + /// keyword. + /// + public sealed partial class KeywordPlanNegativeKeywordOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanNegativeKeywordOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeywordOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeywordOperation(KeywordPlanNegativeKeywordOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNegativeKeywordOperation Clone() { + return new KeywordPlanNegativeKeywordOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// The FieldMask that determines which resource fields are modified in an + /// update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new Keyword Plan + /// negative keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The Keyword Plan negative keyword expected to have a + /// valid resource name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed Keyword Plan negative + /// keywords expected in this format: + /// + /// `customers/{customer_id}/keywordPlanNegativeKeywords/{kp_negative_keyword_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanNegativeKeywordOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanNegativeKeywordOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanNegativeKeywordOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a Keyword Plan negative keyword mutate. + /// + public sealed partial class MutateKeywordPlanNegativeKeywordsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanNegativeKeywordsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordsResponse(MutateKeywordPlanNegativeKeywordsResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordsResponse Clone() { + return new MutateKeywordPlanNegativeKeywordsResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanNegativeKeywordsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanNegativeKeywordsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanNegativeKeywordsResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the Keyword Plan negative keyword mutate. + /// + public sealed partial class MutateKeywordPlanNegativeKeywordResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlanNegativeKeywordResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordResult(MutateKeywordPlanNegativeKeywordResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlanNegativeKeywordResult Clone() { + return new MutateKeywordPlanNegativeKeywordResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlanNegativeKeywordResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlanNegativeKeywordResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlanNegativeKeywordResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanNegativeKeywordServiceClient.cs b/src/V3/Stubs/KeywordPlanNegativeKeywordServiceClient.cs new file mode 100644 index 000000000..ad524c059 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanNegativeKeywordServiceClient.cs @@ -0,0 +1,904 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class KeywordPlanNegativeKeywordServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static KeywordPlanNegativeKeywordServiceSettings GetDefault() => new KeywordPlanNegativeKeywordServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public KeywordPlanNegativeKeywordServiceSettings() { } + + private KeywordPlanNegativeKeywordServiceSettings(KeywordPlanNegativeKeywordServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetKeywordPlanNegativeKeywordSettings = existing.GetKeywordPlanNegativeKeywordSettings; + MutateKeywordPlanNegativeKeywordsSettings = existing.MutateKeywordPlanNegativeKeywordsSettings; + OnCopy(existing); + } + + partial void OnCopy(KeywordPlanNegativeKeywordServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanNegativeKeywordServiceClient.GetKeywordPlanNegativeKeyword and KeywordPlanNegativeKeywordServiceClient.GetKeywordPlanNegativeKeywordAsync. + /// + /// + /// The default KeywordPlanNegativeKeywordServiceClient.GetKeywordPlanNegativeKeyword and + /// KeywordPlanNegativeKeywordServiceClient.GetKeywordPlanNegativeKeywordAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetKeywordPlanNegativeKeywordSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanNegativeKeywordServiceClient.MutateKeywordPlanNegativeKeywords and KeywordPlanNegativeKeywordServiceClient.MutateKeywordPlanNegativeKeywordsAsync. + /// + /// + /// The default KeywordPlanNegativeKeywordServiceClient.MutateKeywordPlanNegativeKeywords and + /// KeywordPlanNegativeKeywordServiceClient.MutateKeywordPlanNegativeKeywordsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateKeywordPlanNegativeKeywordsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public KeywordPlanNegativeKeywordServiceSettings Clone() => new KeywordPlanNegativeKeywordServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class KeywordPlanNegativeKeywordServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public KeywordPlanNegativeKeywordServiceSettings Settings { get; set; } + + /// + public override KeywordPlanNegativeKeywordServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return KeywordPlanNegativeKeywordServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return KeywordPlanNegativeKeywordServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => KeywordPlanNegativeKeywordServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => KeywordPlanNegativeKeywordServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => KeywordPlanNegativeKeywordServiceClient.ChannelPool; + } + + /// + /// KeywordPlanNegativeKeywordService client wrapper, for convenient use. + /// + public abstract partial class KeywordPlanNegativeKeywordServiceClient + { + /// + /// The default endpoint for the KeywordPlanNegativeKeywordService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default KeywordPlanNegativeKeywordService scopes. + /// + /// + /// The default KeywordPlanNegativeKeywordService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanNegativeKeywordServiceClient client = await KeywordPlanNegativeKeywordServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanNegativeKeywordServiceClient.DefaultEndpoint.Host, KeywordPlanNegativeKeywordServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanNegativeKeywordServiceClient client = KeywordPlanNegativeKeywordServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanNegativeKeywordServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanNegativeKeywordServiceClient client = KeywordPlanNegativeKeywordServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanNegativeKeywordServiceClient.DefaultEndpoint.Host, KeywordPlanNegativeKeywordServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanNegativeKeywordServiceClient client = KeywordPlanNegativeKeywordServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static KeywordPlanNegativeKeywordServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanNegativeKeywordServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanNegativeKeywordServiceClient Create(grpccore::Channel channel, KeywordPlanNegativeKeywordServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanNegativeKeywordServiceClient Create(grpccore::CallInvoker callInvoker, KeywordPlanNegativeKeywordServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + KeywordPlanNegativeKeywordService.KeywordPlanNegativeKeywordServiceClient grpcClient = new KeywordPlanNegativeKeywordService.KeywordPlanNegativeKeywordServiceClient(callInvoker); + return new KeywordPlanNegativeKeywordServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC KeywordPlanNegativeKeywordService client. + /// + public virtual KeywordPlanNegativeKeywordService.KeywordPlanNegativeKeywordServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested plan in full detail. + /// + /// + /// Required. The resource name of the plan to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanNegativeKeywordAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanNegativeKeywordAsync( + new GetKeywordPlanNegativeKeywordRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// Required. The resource name of the plan to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanNegativeKeywordAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetKeywordPlanNegativeKeywordAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// Required. The resource name of the plan to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlanNegativeKeyword GetKeywordPlanNegativeKeyword( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanNegativeKeyword( + new GetKeywordPlanNegativeKeywordRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanNegativeKeywordAsync( + GetKeywordPlanNegativeKeywordRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanNegativeKeywordAsync( + GetKeywordPlanNegativeKeywordRequest request, + st::CancellationToken cancellationToken) => GetKeywordPlanNegativeKeywordAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlanNegativeKeyword GetKeywordPlanNegativeKeyword( + GetKeywordPlanNegativeKeywordRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose negative keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan negative + /// keywords. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanNegativeKeywordsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanNegativeKeywordsAsync( + new MutateKeywordPlanNegativeKeywordsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose negative keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan negative + /// keywords. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanNegativeKeywordsAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateKeywordPlanNegativeKeywordsAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose negative keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan negative + /// keywords. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanNegativeKeywordsResponse MutateKeywordPlanNegativeKeywords( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanNegativeKeywords( + new MutateKeywordPlanNegativeKeywordsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose negative keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan negative + /// keywords. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanNegativeKeywordsAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanNegativeKeywordsAsync( + new MutateKeywordPlanNegativeKeywordsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose negative keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan negative + /// keywords. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanNegativeKeywordsAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateKeywordPlanNegativeKeywordsAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// Required. The ID of the customer whose negative keywords are being modified. + /// + /// + /// Required. The list of operations to perform on individual Keyword Plan negative + /// keywords. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanNegativeKeywordsResponse MutateKeywordPlanNegativeKeywords( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlanNegativeKeywords( + new MutateKeywordPlanNegativeKeywordsRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanNegativeKeywordsAsync( + MutateKeywordPlanNegativeKeywordsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlanNegativeKeywordsAsync( + MutateKeywordPlanNegativeKeywordsRequest request, + st::CancellationToken cancellationToken) => MutateKeywordPlanNegativeKeywordsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlanNegativeKeywordsResponse MutateKeywordPlanNegativeKeywords( + MutateKeywordPlanNegativeKeywordsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// KeywordPlanNegativeKeywordService client wrapper implementation, for convenient use. + /// + public sealed partial class KeywordPlanNegativeKeywordServiceClientImpl : KeywordPlanNegativeKeywordServiceClient + { + private readonly gaxgrpc::ApiCall _callGetKeywordPlanNegativeKeyword; + private readonly gaxgrpc::ApiCall _callMutateKeywordPlanNegativeKeywords; + + /// + /// Constructs a client wrapper for the KeywordPlanNegativeKeywordService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public KeywordPlanNegativeKeywordServiceClientImpl(KeywordPlanNegativeKeywordService.KeywordPlanNegativeKeywordServiceClient grpcClient, KeywordPlanNegativeKeywordServiceSettings settings) + { + GrpcClient = grpcClient; + KeywordPlanNegativeKeywordServiceSettings effectiveSettings = settings ?? KeywordPlanNegativeKeywordServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetKeywordPlanNegativeKeyword = clientHelper.BuildApiCall( + GrpcClient.GetKeywordPlanNegativeKeywordAsync, GrpcClient.GetKeywordPlanNegativeKeyword, effectiveSettings.GetKeywordPlanNegativeKeywordSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateKeywordPlanNegativeKeywords = clientHelper.BuildApiCall( + GrpcClient.MutateKeywordPlanNegativeKeywordsAsync, GrpcClient.MutateKeywordPlanNegativeKeywords, effectiveSettings.MutateKeywordPlanNegativeKeywordsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + Modify_ApiCall(ref _callGetKeywordPlanNegativeKeyword); + Modify_GetKeywordPlanNegativeKeywordApiCall(ref _callGetKeywordPlanNegativeKeyword); + Modify_ApiCall(ref _callMutateKeywordPlanNegativeKeywords); + Modify_MutateKeywordPlanNegativeKeywordsApiCall(ref _callMutateKeywordPlanNegativeKeywords); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetKeywordPlanNegativeKeywordApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateKeywordPlanNegativeKeywordsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(KeywordPlanNegativeKeywordService.KeywordPlanNegativeKeywordServiceClient grpcClient, KeywordPlanNegativeKeywordServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC KeywordPlanNegativeKeywordService client. + /// + public override KeywordPlanNegativeKeywordService.KeywordPlanNegativeKeywordServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetKeywordPlanNegativeKeywordRequest(ref GetKeywordPlanNegativeKeywordRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateKeywordPlanNegativeKeywordsRequest(ref MutateKeywordPlanNegativeKeywordsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetKeywordPlanNegativeKeywordAsync( + GetKeywordPlanNegativeKeywordRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanNegativeKeywordRequest(ref request, ref callSettings); + return _callGetKeywordPlanNegativeKeyword.Async(request, callSettings); + } + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::KeywordPlanNegativeKeyword GetKeywordPlanNegativeKeyword( + GetKeywordPlanNegativeKeywordRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanNegativeKeywordRequest(ref request, ref callSettings); + return _callGetKeywordPlanNegativeKeyword.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateKeywordPlanNegativeKeywordsAsync( + MutateKeywordPlanNegativeKeywordsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlanNegativeKeywordsRequest(ref request, ref callSettings); + return _callMutateKeywordPlanNegativeKeywords.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateKeywordPlanNegativeKeywordsResponse MutateKeywordPlanNegativeKeywords( + MutateKeywordPlanNegativeKeywordsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlanNegativeKeywordsRequest(ref request, ref callSettings); + return _callMutateKeywordPlanNegativeKeywords.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/KeywordPlanNegativeKeywordServiceGrpc.cs b/src/V3/Stubs/KeywordPlanNegativeKeywordServiceGrpc.cs new file mode 100644 index 000000000..bd1eda0e4 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanNegativeKeywordServiceGrpc.cs @@ -0,0 +1,229 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_negative_keyword_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage Keyword Plan negative keywords. + /// + public static partial class KeywordPlanNegativeKeywordService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.KeywordPlanNegativeKeywordService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanNegativeKeywordRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanNegativeKeywordRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_KeywordPlanNegativeKeyword = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanNegativeKeywordsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanNegativeKeywordsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetKeywordPlanNegativeKeyword = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetKeywordPlanNegativeKeyword", + __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanNegativeKeywordRequest, + __Marshaller_google_ads_googleads_v3_resources_KeywordPlanNegativeKeyword); + + static readonly grpc::Method __Method_MutateKeywordPlanNegativeKeywords = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateKeywordPlanNegativeKeywords", + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanNegativeKeywordsRequest, + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlanNegativeKeywordsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanNegativeKeywordServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of KeywordPlanNegativeKeywordService + public abstract partial class KeywordPlanNegativeKeywordServiceBase + { + /// + /// Returns the requested plan in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetKeywordPlanNegativeKeyword(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanNegativeKeywordRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateKeywordPlanNegativeKeywords(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for KeywordPlanNegativeKeywordService + public partial class KeywordPlanNegativeKeywordServiceClient : grpc::ClientBase + { + /// Creates a new client for KeywordPlanNegativeKeywordService + /// The channel to use to make remote calls. + public KeywordPlanNegativeKeywordServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for KeywordPlanNegativeKeywordService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public KeywordPlanNegativeKeywordServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected KeywordPlanNegativeKeywordServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected KeywordPlanNegativeKeywordServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested plan in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword GetKeywordPlanNegativeKeyword(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanNegativeKeywordRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanNegativeKeyword(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested plan in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanNegativeKeyword GetKeywordPlanNegativeKeyword(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanNegativeKeywordRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetKeywordPlanNegativeKeyword, null, options, request); + } + /// + /// Returns the requested plan in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanNegativeKeywordAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanNegativeKeywordRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanNegativeKeywordAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested plan in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanNegativeKeywordAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanNegativeKeywordRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetKeywordPlanNegativeKeyword, null, options, request); + } + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsResponse MutateKeywordPlanNegativeKeywords(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlanNegativeKeywords(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsResponse MutateKeywordPlanNegativeKeywords(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateKeywordPlanNegativeKeywords, null, options, request); + } + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlanNegativeKeywordsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlanNegativeKeywordsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes Keyword Plan negative keywords. Operation + /// statuses are returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlanNegativeKeywordsAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlanNegativeKeywordsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateKeywordPlanNegativeKeywords, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override KeywordPlanNegativeKeywordServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new KeywordPlanNegativeKeywordServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(KeywordPlanNegativeKeywordServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetKeywordPlanNegativeKeyword, serviceImpl.GetKeywordPlanNegativeKeyword) + .AddMethod(__Method_MutateKeywordPlanNegativeKeywords, serviceImpl.MutateKeywordPlanNegativeKeywords).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, KeywordPlanNegativeKeywordServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetKeywordPlanNegativeKeyword, serviceImpl.GetKeywordPlanNegativeKeyword); + serviceBinder.AddMethod(__Method_MutateKeywordPlanNegativeKeywords, serviceImpl.MutateKeywordPlanNegativeKeywords); + } + + } +} +#endregion diff --git a/src/V3/Stubs/KeywordPlanNetwork.cs b/src/V3/Stubs/KeywordPlanNetwork.cs new file mode 100644 index 000000000..78a76c923 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanNetwork.cs @@ -0,0 +1,185 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/enums/keyword_plan_network.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Enums { + + /// Holder for reflection information generated from google/ads/googleads/v3/enums/keyword_plan_network.proto + public static partial class KeywordPlanNetworkReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/enums/keyword_plan_network.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanNetworkReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjhnb29nbGUvYWRzL2dvb2dsZWFkcy92My9lbnVtcy9rZXl3b3JkX3BsYW5f", + "bmV0d29yay5wcm90bxIdZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuZW51bXMa", + "HGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8ifwoWS2V5d29yZFBsYW5O", + "ZXR3b3JrRW51bSJlChJLZXl3b3JkUGxhbk5ldHdvcmsSDwoLVU5TUEVDSUZJ", + "RUQQABILCgdVTktOT1dOEAESEQoNR09PR0xFX1NFQVJDSBACEh4KGkdPT0dM", + "RV9TRUFSQ0hfQU5EX1BBUlRORVJTEANC7AEKIWNvbS5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5lbnVtc0IXS2V5d29yZFBsYW5OZXR3b3JrUHJvdG9QAVpC", + "Z29vZ2xlLmdvbGFuZy5vcmcvZ2VucHJvdG8vZ29vZ2xlYXBpcy9hZHMvZ29v", + "Z2xlYWRzL3YzL2VudW1zO2VudW1zogIDR0FBqgIdR29vZ2xlLkFkcy5Hb29n", + "bGVBZHMuVjMuRW51bXPKAh1Hb29nbGVcQWRzXEdvb2dsZUFkc1xWM1xFbnVt", + "c+oCIUdvb2dsZTo6QWRzOjpHb29nbGVBZHM6OlYzOjpFbnVtc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum), global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Parser, null, null, new[]{ typeof(global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkEnum.Types.KeywordPlanNetwork) }, null) + })); + } + #endregion + + } + #region Messages + /// + /// Container for enumeration of keyword plan forecastable network types. + /// + public sealed partial class KeywordPlanNetworkEnum : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanNetworkEnum()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Enums.KeywordPlanNetworkReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNetworkEnum() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNetworkEnum(KeywordPlanNetworkEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanNetworkEnum Clone() { + return new KeywordPlanNetworkEnum(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanNetworkEnum); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanNetworkEnum other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanNetworkEnum other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + #region Nested types + /// Container for nested types declared in the KeywordPlanNetworkEnum message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static partial class Types { + /// + /// Enumerates keyword plan forecastable network types. + /// + public enum KeywordPlanNetwork { + /// + /// Not specified. + /// + [pbr::OriginalName("UNSPECIFIED")] Unspecified = 0, + /// + /// The value is unknown in this version. + /// + [pbr::OriginalName("UNKNOWN")] Unknown = 1, + /// + /// Google Search. + /// + [pbr::OriginalName("GOOGLE_SEARCH")] GoogleSearch = 2, + /// + /// Google Search + Search partners. + /// + [pbr::OriginalName("GOOGLE_SEARCH_AND_PARTNERS")] GoogleSearchAndPartners = 3, + } + + } + #endregion + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanService.cs b/src/V3/Stubs/KeywordPlanService.cs new file mode 100644 index 000000000..8b392a689 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanService.cs @@ -0,0 +1,2676 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/keyword_plan_service.proto + public static partial class KeywordPlanServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/keyword_plan_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordPlanServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9rZXl3b3JkX3Bs", + "YW5fc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMaOGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2NvbW1vbi9rZXl3b3Jk", + "X3BsYW5fY29tbW9uLnByb3RvGjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9y", + "ZXNvdXJjZXMva2V5d29yZF9wbGFuLnByb3RvGhxnb29nbGUvYXBpL2Fubm90", + "YXRpb25zLnByb3RvGhdnb29nbGUvYXBpL2NsaWVudC5wcm90bxofZ29vZ2xl", + "L2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxogZ29vZ2xlL3Byb3RvYnVmL2Zp", + "ZWxkX21hc2sucHJvdG8aHmdvb2dsZS9wcm90b2J1Zi93cmFwcGVycy5wcm90", + "bxoXZ29vZ2xlL3JwYy9zdGF0dXMucHJvdG8iMwoVR2V0S2V5d29yZFBsYW5S", + "ZXF1ZXN0EhoKDXJlc291cmNlX25hbWUYASABKAlCA+BBAiK2AQoZTXV0YXRl", + "S2V5d29yZFBsYW5zUmVxdWVzdBIYCgtjdXN0b21lcl9pZBgBIAEoCUID4EEC", + "Ek8KCm9wZXJhdGlvbnMYAiADKAsyNi5nb29nbGUuYWRzLmdvb2dsZWFkcy52", + "My5zZXJ2aWNlcy5LZXl3b3JkUGxhbk9wZXJhdGlvbkID4EECEhcKD3BhcnRp", + "YWxfZmFpbHVyZRgDIAEoCBIVCg12YWxpZGF0ZV9vbmx5GAQgASgIIuoBChRL", + "ZXl3b3JkUGxhbk9wZXJhdGlvbhIvCgt1cGRhdGVfbWFzaxgEIAEoCzIaLmdv", + "b2dsZS5wcm90b2J1Zi5GaWVsZE1hc2sSQAoGY3JlYXRlGAEgASgLMi4uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzLktleXdvcmRQbGFuSAAS", + "QAoGdXBkYXRlGAIgASgLMi4uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzLktleXdvcmRQbGFuSAASEAoGcmVtb3ZlGAMgASgJSABCCwoJb3Bl", + "cmF0aW9uIpwBChpNdXRhdGVLZXl3b3JkUGxhbnNSZXNwb25zZRIxChVwYXJ0", + "aWFsX2ZhaWx1cmVfZXJyb3IYAyABKAsyEi5nb29nbGUucnBjLlN0YXR1cxJL", + "CgdyZXN1bHRzGAIgAygLMjouZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuTXV0YXRlS2V5d29yZFBsYW5zUmVzdWx0IjEKGE11dGF0ZUtleXdv", + "cmRQbGFuc1Jlc3VsdBIVCg1yZXNvdXJjZV9uYW1lGAEgASgJIjsKHkdlbmVy", + "YXRlRm9yZWNhc3RNZXRyaWNzUmVxdWVzdBIZCgxrZXl3b3JkX3BsYW4YASAB", + "KAlCA+BBAiKvAgofR2VuZXJhdGVGb3JlY2FzdE1ldHJpY3NSZXNwb25zZRJZ", + "ChJjYW1wYWlnbl9mb3JlY2FzdHMYASADKAsyPS5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5LZXl3b3JkUGxhbkNhbXBhaWduRm9yZWNhc3QS", + "WAoSYWRfZ3JvdXBfZm9yZWNhc3RzGAIgAygLMjwuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuc2VydmljZXMuS2V5d29yZFBsYW5BZEdyb3VwRm9yZWNhc3QS", + "VwoRa2V5d29yZF9mb3JlY2FzdHMYAyADKAsyPC5nb29nbGUuYWRzLmdvb2ds", + "ZWFkcy52My5zZXJ2aWNlcy5LZXl3b3JkUGxhbktleXdvcmRGb3JlY2FzdCKo", + "AQobS2V5d29yZFBsYW5DYW1wYWlnbkZvcmVjYXN0EjsKFWtleXdvcmRfcGxh", + "bl9jYW1wYWlnbhgBIAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1", + "ZRJMChFjYW1wYWlnbl9mb3JlY2FzdBgCIAEoCzIxLmdvb2dsZS5hZHMuZ29v", + "Z2xlYWRzLnYzLnNlcnZpY2VzLkZvcmVjYXN0TWV0cmljcyKnAQoaS2V5d29y", + "ZFBsYW5BZEdyb3VwRm9yZWNhc3QSOwoVa2V5d29yZF9wbGFuX2FkX2dyb3Vw", + "GAEgASgLMhwuZ29vZ2xlLnByb3RvYnVmLlN0cmluZ1ZhbHVlEkwKEWFkX2dy", + "b3VwX2ZvcmVjYXN0GAIgASgLMjEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMu", + "c2VydmljZXMuRm9yZWNhc3RNZXRyaWNzIq4BChpLZXl3b3JkUGxhbktleXdv", + "cmRGb3JlY2FzdBJDCh1rZXl3b3JkX3BsYW5fYWRfZ3JvdXBfa2V5d29yZBgB", + "IAEoCzIcLmdvb2dsZS5wcm90b2J1Zi5TdHJpbmdWYWx1ZRJLChBrZXl3b3Jk", + "X2ZvcmVjYXN0GAIgASgLMjEuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuRm9yZWNhc3RNZXRyaWNzIoECCg9Gb3JlY2FzdE1ldHJpY3MSMQoL", + "aW1wcmVzc2lvbnMYASABKAsyHC5nb29nbGUucHJvdG9idWYuRG91YmxlVmFs", + "dWUSKQoDY3RyGAIgASgLMhwuZ29vZ2xlLnByb3RvYnVmLkRvdWJsZVZhbHVl", + "EjAKC2F2ZXJhZ2VfY3BjGAMgASgLMhsuZ29vZ2xlLnByb3RvYnVmLkludDY0", + "VmFsdWUSLAoGY2xpY2tzGAUgASgLMhwuZ29vZ2xlLnByb3RvYnVmLkRvdWJs", + "ZVZhbHVlEjAKC2Nvc3RfbWljcm9zGAYgASgLMhsuZ29vZ2xlLnByb3RvYnVm", + "LkludDY0VmFsdWUiPQogR2VuZXJhdGVIaXN0b3JpY2FsTWV0cmljc1JlcXVl", + "c3QSGQoMa2V5d29yZF9wbGFuGAEgASgJQgPgQQIiewohR2VuZXJhdGVIaXN0", + "b3JpY2FsTWV0cmljc1Jlc3BvbnNlElYKB21ldHJpY3MYASADKAsyRS5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5LZXl3b3JkUGxhbktleXdv", + "cmRIaXN0b3JpY2FsTWV0cmljcyKwAQojS2V5d29yZFBsYW5LZXl3b3JkSGlz", + "dG9yaWNhbE1ldHJpY3MSMgoMc2VhcmNoX3F1ZXJ5GAEgASgLMhwuZ29vZ2xl", + "LnByb3RvYnVmLlN0cmluZ1ZhbHVlElUKD2tleXdvcmRfbWV0cmljcxgCIAEo", + "CzI8Lmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLmNvbW1vbi5LZXl3b3JkUGxh", + "bkhpc3RvcmljYWxNZXRyaWNzMuoHChJLZXl3b3JkUGxhblNlcnZpY2USwQEK", + "DkdldEtleXdvcmRQbGFuEjcuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMuR2V0S2V5d29yZFBsYW5SZXF1ZXN0Gi4uZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMucmVzb3VyY2VzLktleXdvcmRQbGFuIkaC0+STAjASLi92My97", + "cmVzb3VyY2VfbmFtZT1jdXN0b21lcnMvKi9rZXl3b3JkUGxhbnMvKn3aQQ1y", + "ZXNvdXJjZV9uYW1lEuYBChJNdXRhdGVLZXl3b3JkUGxhbnMSOy5nb29nbGUu", + "YWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5NdXRhdGVLZXl3b3JkUGxhbnNS", + "ZXF1ZXN0GjwuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuTXV0", + "YXRlS2V5d29yZFBsYW5zUmVzcG9uc2UiVYLT5JMCNiIxL3YzL2N1c3RvbWVy", + "cy97Y3VzdG9tZXJfaWQ9Kn0va2V5d29yZFBsYW5zOm11dGF0ZToBKtpBFmN1", + "c3RvbWVyX2lkLG9wZXJhdGlvbnMS/wEKF0dlbmVyYXRlRm9yZWNhc3RNZXRy", + "aWNzEkAuZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXMuR2VuZXJh", + "dGVGb3JlY2FzdE1ldHJpY3NSZXF1ZXN0GkEuZ29vZ2xlLmFkcy5nb29nbGVh", + "ZHMudjMuc2VydmljZXMuR2VuZXJhdGVGb3JlY2FzdE1ldHJpY3NSZXNwb25z", + "ZSJfgtPkkwJKIkUvdjMve2tleXdvcmRfcGxhbj1jdXN0b21lcnMvKi9rZXl3", + "b3JkUGxhbnMvKn06Z2VuZXJhdGVGb3JlY2FzdE1ldHJpY3M6ASraQQxrZXl3", + "b3JkX3BsYW4ShwIKGUdlbmVyYXRlSGlzdG9yaWNhbE1ldHJpY3MSQi5nb29n", + "bGUuYWRzLmdvb2dsZWFkcy52My5zZXJ2aWNlcy5HZW5lcmF0ZUhpc3Rvcmlj", + "YWxNZXRyaWNzUmVxdWVzdBpDLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNl", + "cnZpY2VzLkdlbmVyYXRlSGlzdG9yaWNhbE1ldHJpY3NSZXNwb25zZSJhgtPk", + "kwJMIkcvdjMve2tleXdvcmRfcGxhbj1jdXN0b21lcnMvKi9rZXl3b3JkUGxh", + "bnMvKn06Z2VuZXJhdGVIaXN0b3JpY2FsTWV0cmljczoBKtpBDGtleXdvcmRf", + "cGxhbhobykEYZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tQv4BCiRjb20uZ29v", + "Z2xlLmFkcy5nb29nbGVhZHMudjMuc2VydmljZXNCF0tleXdvcmRQbGFuU2Vy", + "dmljZVByb3RvUAFaSGdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2ds", + "ZWFwaXMvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcztzZXJ2aWNlc6ICA0dB", + "QaoCIEdvb2dsZS5BZHMuR29vZ2xlQWRzLlYzLlNlcnZpY2VzygIgR29vZ2xl", + "XEFkc1xHb29nbGVBZHNcVjNcU2VydmljZXPqAiRHb29nbGU6OkFkczo6R29v", + "Z2xlQWRzOjpWMzo6U2VydmljZXNiBnByb3RvMw==")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.KeywordPlanCommonReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Resources.KeywordPlanReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Rpc.StatusReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanRequest), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanRequest.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansRequest), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansRequest.Parser, new[]{ "CustomerId", "Operations", "PartialFailure", "ValidateOnly" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanOperation), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanOperation.Parser, new[]{ "UpdateMask", "Create", "Update", "Remove" }, new[]{ "Operation" }, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansResponse), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansResponse.Parser, new[]{ "PartialFailureError", "Results" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansResult), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansResult.Parser, new[]{ "ResourceName" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsRequest), global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsRequest.Parser, new[]{ "KeywordPlan" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsResponse), global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsResponse.Parser, new[]{ "CampaignForecasts", "AdGroupForecasts", "KeywordForecasts" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignForecast), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignForecast.Parser, new[]{ "KeywordPlanCampaign", "CampaignForecast" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupForecast), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupForecast.Parser, new[]{ "KeywordPlanAdGroup", "AdGroupForecast" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordForecast), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordForecast.Parser, new[]{ "KeywordPlanAdGroupKeyword", "KeywordForecast" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics), global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics.Parser, new[]{ "Impressions", "Ctr", "AverageCpc", "Clicks", "CostMicros" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsRequest), global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsRequest.Parser, new[]{ "KeywordPlan" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsResponse), global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsResponse.Parser, new[]{ "Metrics" }, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordHistoricalMetrics), global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordHistoricalMetrics.Parser, new[]{ "SearchQuery", "KeywordMetrics" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [KeywordPlanService.GetKeywordPlan][google.ads.googleads.v3.services.KeywordPlanService.GetKeywordPlan]. + /// + public sealed partial class GetKeywordPlanRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetKeywordPlanRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanRequest(GetKeywordPlanRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordPlanRequest Clone() { + return new GetKeywordPlanRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the plan to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetKeywordPlanRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetKeywordPlanRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetKeywordPlanRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [KeywordPlanService.MutateKeywordPlans][google.ads.googleads.v3.services.KeywordPlanService.MutateKeywordPlans]. + /// + public sealed partial class MutateKeywordPlansRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlansRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[1]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansRequest(MutateKeywordPlansRequest other) : this() { + customerId_ = other.customerId_; + operations_ = other.operations_.Clone(); + partialFailure_ = other.partialFailure_; + validateOnly_ = other.validateOnly_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansRequest Clone() { + return new MutateKeywordPlansRequest(this); + } + + /// Field number for the "customer_id" field. + public const int CustomerIdFieldNumber = 1; + private string customerId_ = ""; + /// + /// Required. The ID of the customer whose keyword plans are being modified. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string CustomerId { + get { return customerId_; } + set { + customerId_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + /// Field number for the "operations" field. + public const int OperationsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_operations_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanOperation.Parser); + private readonly pbc::RepeatedField operations_ = new pbc::RepeatedField(); + /// + /// Required. The list of operations to perform on individual keyword plans. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Operations { + get { return operations_; } + } + + /// Field number for the "partial_failure" field. + public const int PartialFailureFieldNumber = 3; + private bool partialFailure_; + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool PartialFailure { + get { return partialFailure_; } + set { + partialFailure_ = value; + } + } + + /// Field number for the "validate_only" field. + public const int ValidateOnlyFieldNumber = 4; + private bool validateOnly_; + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool ValidateOnly { + get { return validateOnly_; } + set { + validateOnly_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlansRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlansRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (CustomerId != other.CustomerId) return false; + if(!operations_.Equals(other.operations_)) return false; + if (PartialFailure != other.PartialFailure) return false; + if (ValidateOnly != other.ValidateOnly) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (CustomerId.Length != 0) hash ^= CustomerId.GetHashCode(); + hash ^= operations_.GetHashCode(); + if (PartialFailure != false) hash ^= PartialFailure.GetHashCode(); + if (ValidateOnly != false) hash ^= ValidateOnly.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (CustomerId.Length != 0) { + output.WriteRawTag(10); + output.WriteString(CustomerId); + } + operations_.WriteTo(output, _repeated_operations_codec); + if (PartialFailure != false) { + output.WriteRawTag(24); + output.WriteBool(PartialFailure); + } + if (ValidateOnly != false) { + output.WriteRawTag(32); + output.WriteBool(ValidateOnly); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (CustomerId.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(CustomerId); + } + size += operations_.CalculateSize(_repeated_operations_codec); + if (PartialFailure != false) { + size += 1 + 1; + } + if (ValidateOnly != false) { + size += 1 + 1; + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlansRequest other) { + if (other == null) { + return; + } + if (other.CustomerId.Length != 0) { + CustomerId = other.CustomerId; + } + operations_.Add(other.operations_); + if (other.PartialFailure != false) { + PartialFailure = other.PartialFailure; + } + if (other.ValidateOnly != false) { + ValidateOnly = other.ValidateOnly; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + CustomerId = input.ReadString(); + break; + } + case 18: { + operations_.AddEntriesFrom(input, _repeated_operations_codec); + break; + } + case 24: { + PartialFailure = input.ReadBool(); + break; + } + case 32: { + ValidateOnly = input.ReadBool(); + break; + } + } + } + } + + } + + /// + /// A single operation (create, update, remove) on a keyword plan. + /// + public sealed partial class KeywordPlanOperation : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanOperation()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[2]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanOperation() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanOperation(KeywordPlanOperation other) : this() { + updateMask_ = other.updateMask_ != null ? other.updateMask_.Clone() : null; + switch (other.OperationCase) { + case OperationOneofCase.Create: + Create = other.Create.Clone(); + break; + case OperationOneofCase.Update: + Update = other.Update.Clone(); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanOperation Clone() { + return new KeywordPlanOperation(this); + } + + /// Field number for the "update_mask" field. + public const int UpdateMaskFieldNumber = 4; + private global::Google.Protobuf.WellKnownTypes.FieldMask updateMask_; + /// + /// The FieldMask that determines which resource fields are modified in an + /// update. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Protobuf.WellKnownTypes.FieldMask UpdateMask { + get { return updateMask_; } + set { + updateMask_ = value; + } + } + + /// Field number for the "create" field. + public const int CreateFieldNumber = 1; + /// + /// Create operation: No resource name is expected for the new keyword plan. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan Create { + get { return operationCase_ == OperationOneofCase.Create ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Create; + } + } + + /// Field number for the "update" field. + public const int UpdateFieldNumber = 2; + /// + /// Update operation: The keyword plan is expected to have a valid resource + /// name. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan Update { + get { return operationCase_ == OperationOneofCase.Update ? (global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan) operation_ : null; } + set { + operation_ = value; + operationCase_ = value == null ? OperationOneofCase.None : OperationOneofCase.Update; + } + } + + /// Field number for the "remove" field. + public const int RemoveFieldNumber = 3; + /// + /// Remove operation: A resource name for the removed keyword plan is + /// expected in this format: + /// + /// `customers/{customer_id}/keywordPlans/{keyword_plan_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string Remove { + get { return operationCase_ == OperationOneofCase.Remove ? (string) operation_ : ""; } + set { + operation_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + operationCase_ = OperationOneofCase.Remove; + } + } + + private object operation_; + /// Enum of possible cases for the "operation" oneof. + public enum OperationOneofCase { + None = 0, + Create = 1, + Update = 2, + Remove = 3, + } + private OperationOneofCase operationCase_ = OperationOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public OperationOneofCase OperationCase { + get { return operationCase_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void ClearOperation() { + operationCase_ = OperationOneofCase.None; + operation_ = null; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanOperation); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanOperation other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(UpdateMask, other.UpdateMask)) return false; + if (!object.Equals(Create, other.Create)) return false; + if (!object.Equals(Update, other.Update)) return false; + if (Remove != other.Remove) return false; + if (OperationCase != other.OperationCase) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (updateMask_ != null) hash ^= UpdateMask.GetHashCode(); + if (operationCase_ == OperationOneofCase.Create) hash ^= Create.GetHashCode(); + if (operationCase_ == OperationOneofCase.Update) hash ^= Update.GetHashCode(); + if (operationCase_ == OperationOneofCase.Remove) hash ^= Remove.GetHashCode(); + hash ^= (int) operationCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (operationCase_ == OperationOneofCase.Create) { + output.WriteRawTag(10); + output.WriteMessage(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + output.WriteRawTag(18); + output.WriteMessage(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + output.WriteRawTag(26); + output.WriteString(Remove); + } + if (updateMask_ != null) { + output.WriteRawTag(34); + output.WriteMessage(UpdateMask); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (updateMask_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(UpdateMask); + } + if (operationCase_ == OperationOneofCase.Create) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Create); + } + if (operationCase_ == OperationOneofCase.Update) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(Update); + } + if (operationCase_ == OperationOneofCase.Remove) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(Remove); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanOperation other) { + if (other == null) { + return; + } + if (other.updateMask_ != null) { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + UpdateMask.MergeFrom(other.UpdateMask); + } + switch (other.OperationCase) { + case OperationOneofCase.Create: + if (Create == null) { + Create = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan(); + } + Create.MergeFrom(other.Create); + break; + case OperationOneofCase.Update: + if (Update == null) { + Update = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan(); + } + Update.MergeFrom(other.Update); + break; + case OperationOneofCase.Remove: + Remove = other.Remove; + break; + } + + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan(); + if (operationCase_ == OperationOneofCase.Create) { + subBuilder.MergeFrom(Create); + } + input.ReadMessage(subBuilder); + Create = subBuilder; + break; + } + case 18: { + global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan subBuilder = new global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan(); + if (operationCase_ == OperationOneofCase.Update) { + subBuilder.MergeFrom(Update); + } + input.ReadMessage(subBuilder); + Update = subBuilder; + break; + } + case 26: { + Remove = input.ReadString(); + break; + } + case 34: { + if (updateMask_ == null) { + UpdateMask = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + input.ReadMessage(UpdateMask); + break; + } + } + } + } + + } + + /// + /// Response message for a keyword plan mutate. + /// + public sealed partial class MutateKeywordPlansResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlansResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[3]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansResponse(MutateKeywordPlansResponse other) : this() { + partialFailureError_ = other.partialFailureError_ != null ? other.partialFailureError_.Clone() : null; + results_ = other.results_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansResponse Clone() { + return new MutateKeywordPlansResponse(this); + } + + /// Field number for the "partial_failure_error" field. + public const int PartialFailureErrorFieldNumber = 3; + private global::Google.Rpc.Status partialFailureError_; + /// + /// Errors that pertain to operation failures in the partial failure mode. + /// Returned only when partial_failure = true and all errors occur inside the + /// operations. If any errors occur outside the operations (e.g. auth errors), + /// we return an RPC level error. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Rpc.Status PartialFailureError { + get { return partialFailureError_; } + set { + partialFailureError_ = value; + } + } + + /// Field number for the "results" field. + public const int ResultsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_results_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansResult.Parser); + private readonly pbc::RepeatedField results_ = new pbc::RepeatedField(); + /// + /// All results for the mutate. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Results { + get { return results_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlansResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlansResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!object.Equals(PartialFailureError, other.PartialFailureError)) return false; + if(!results_.Equals(other.results_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (partialFailureError_ != null) hash ^= PartialFailureError.GetHashCode(); + hash ^= results_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + results_.WriteTo(output, _repeated_results_codec); + if (partialFailureError_ != null) { + output.WriteRawTag(26); + output.WriteMessage(PartialFailureError); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (partialFailureError_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(PartialFailureError); + } + size += results_.CalculateSize(_repeated_results_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlansResponse other) { + if (other == null) { + return; + } + if (other.partialFailureError_ != null) { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + PartialFailureError.MergeFrom(other.PartialFailureError); + } + results_.Add(other.results_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 18: { + results_.AddEntriesFrom(input, _repeated_results_codec); + break; + } + case 26: { + if (partialFailureError_ == null) { + PartialFailureError = new global::Google.Rpc.Status(); + } + input.ReadMessage(PartialFailureError); + break; + } + } + } + } + + } + + /// + /// The result for the keyword plan mutate. + /// + public sealed partial class MutateKeywordPlansResult : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new MutateKeywordPlansResult()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[4]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansResult() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansResult(MutateKeywordPlansResult other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public MutateKeywordPlansResult Clone() { + return new MutateKeywordPlansResult(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Returned for successful operations. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as MutateKeywordPlansResult); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(MutateKeywordPlansResult other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(MutateKeywordPlansResult other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Request message for [KeywordPlanService.GenerateForecastMetrics][google.ads.googleads.v3.services.KeywordPlanService.GenerateForecastMetrics]. + /// + public sealed partial class GenerateForecastMetricsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenerateForecastMetricsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[5]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateForecastMetricsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateForecastMetricsRequest(GenerateForecastMetricsRequest other) : this() { + keywordPlan_ = other.keywordPlan_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateForecastMetricsRequest Clone() { + return new GenerateForecastMetricsRequest(this); + } + + /// Field number for the "keyword_plan" field. + public const int KeywordPlanFieldNumber = 1; + private string keywordPlan_ = ""; + /// + /// Required. The resource name of the keyword plan to be forecasted. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlan { + get { return keywordPlan_; } + set { + keywordPlan_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenerateForecastMetricsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenerateForecastMetricsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (KeywordPlan != other.KeywordPlan) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (KeywordPlan.Length != 0) hash ^= KeywordPlan.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (KeywordPlan.Length != 0) { + output.WriteRawTag(10); + output.WriteString(KeywordPlan); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (KeywordPlan.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(KeywordPlan); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenerateForecastMetricsRequest other) { + if (other == null) { + return; + } + if (other.KeywordPlan.Length != 0) { + KeywordPlan = other.KeywordPlan; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + KeywordPlan = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for [KeywordPlanService.GenerateForecastMetrics][google.ads.googleads.v3.services.KeywordPlanService.GenerateForecastMetrics]. + /// + public sealed partial class GenerateForecastMetricsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenerateForecastMetricsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[6]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateForecastMetricsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateForecastMetricsResponse(GenerateForecastMetricsResponse other) : this() { + campaignForecasts_ = other.campaignForecasts_.Clone(); + adGroupForecasts_ = other.adGroupForecasts_.Clone(); + keywordForecasts_ = other.keywordForecasts_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateForecastMetricsResponse Clone() { + return new GenerateForecastMetricsResponse(this); + } + + /// Field number for the "campaign_forecasts" field. + public const int CampaignForecastsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_campaignForecasts_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanCampaignForecast.Parser); + private readonly pbc::RepeatedField campaignForecasts_ = new pbc::RepeatedField(); + /// + /// List of campaign forecasts. + /// One maximum. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField CampaignForecasts { + get { return campaignForecasts_; } + } + + /// Field number for the "ad_group_forecasts" field. + public const int AdGroupForecastsFieldNumber = 2; + private static readonly pb::FieldCodec _repeated_adGroupForecasts_codec + = pb::FieldCodec.ForMessage(18, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanAdGroupForecast.Parser); + private readonly pbc::RepeatedField adGroupForecasts_ = new pbc::RepeatedField(); + /// + /// List of ad group forecasts. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField AdGroupForecasts { + get { return adGroupForecasts_; } + } + + /// Field number for the "keyword_forecasts" field. + public const int KeywordForecastsFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_keywordForecasts_codec + = pb::FieldCodec.ForMessage(26, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordForecast.Parser); + private readonly pbc::RepeatedField keywordForecasts_ = new pbc::RepeatedField(); + /// + /// List of keyword forecasts. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField KeywordForecasts { + get { return keywordForecasts_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenerateForecastMetricsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenerateForecastMetricsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!campaignForecasts_.Equals(other.campaignForecasts_)) return false; + if(!adGroupForecasts_.Equals(other.adGroupForecasts_)) return false; + if(!keywordForecasts_.Equals(other.keywordForecasts_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= campaignForecasts_.GetHashCode(); + hash ^= adGroupForecasts_.GetHashCode(); + hash ^= keywordForecasts_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + campaignForecasts_.WriteTo(output, _repeated_campaignForecasts_codec); + adGroupForecasts_.WriteTo(output, _repeated_adGroupForecasts_codec); + keywordForecasts_.WriteTo(output, _repeated_keywordForecasts_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += campaignForecasts_.CalculateSize(_repeated_campaignForecasts_codec); + size += adGroupForecasts_.CalculateSize(_repeated_adGroupForecasts_codec); + size += keywordForecasts_.CalculateSize(_repeated_keywordForecasts_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenerateForecastMetricsResponse other) { + if (other == null) { + return; + } + campaignForecasts_.Add(other.campaignForecasts_); + adGroupForecasts_.Add(other.adGroupForecasts_); + keywordForecasts_.Add(other.keywordForecasts_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + campaignForecasts_.AddEntriesFrom(input, _repeated_campaignForecasts_codec); + break; + } + case 18: { + adGroupForecasts_.AddEntriesFrom(input, _repeated_adGroupForecasts_codec); + break; + } + case 26: { + keywordForecasts_.AddEntriesFrom(input, _repeated_keywordForecasts_codec); + break; + } + } + } + } + + } + + /// + /// A campaign forecast. + /// + public sealed partial class KeywordPlanCampaignForecast : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanCampaignForecast()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[7]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignForecast() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignForecast(KeywordPlanCampaignForecast other) : this() { + KeywordPlanCampaign = other.KeywordPlanCampaign; + campaignForecast_ = other.campaignForecast_ != null ? other.campaignForecast_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanCampaignForecast Clone() { + return new KeywordPlanCampaignForecast(this); + } + + /// Field number for the "keyword_plan_campaign" field. + public const int KeywordPlanCampaignFieldNumber = 1; + private static readonly pb::FieldCodec _single_keywordPlanCampaign_codec = pb::FieldCodec.ForClassWrapper(10); + private string keywordPlanCampaign_; + /// + /// The resource name of the Keyword Plan campaign related to the forecast. + /// + /// `customers/{customer_id}/keywordPlanCampaigns/{keyword+plan_campaign_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlanCampaign { + get { return keywordPlanCampaign_; } + set { + keywordPlanCampaign_ = value; + } + } + + + /// Field number for the "campaign_forecast" field. + public const int CampaignForecastFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics campaignForecast_; + /// + /// The forecast for the Keyword Plan campaign. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics CampaignForecast { + get { return campaignForecast_; } + set { + campaignForecast_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanCampaignForecast); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanCampaignForecast other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (KeywordPlanCampaign != other.KeywordPlanCampaign) return false; + if (!object.Equals(CampaignForecast, other.CampaignForecast)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (keywordPlanCampaign_ != null) hash ^= KeywordPlanCampaign.GetHashCode(); + if (campaignForecast_ != null) hash ^= CampaignForecast.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (keywordPlanCampaign_ != null) { + _single_keywordPlanCampaign_codec.WriteTagAndValue(output, KeywordPlanCampaign); + } + if (campaignForecast_ != null) { + output.WriteRawTag(18); + output.WriteMessage(CampaignForecast); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (keywordPlanCampaign_ != null) { + size += _single_keywordPlanCampaign_codec.CalculateSizeWithTag(KeywordPlanCampaign); + } + if (campaignForecast_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(CampaignForecast); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanCampaignForecast other) { + if (other == null) { + return; + } + if (other.keywordPlanCampaign_ != null) { + if (keywordPlanCampaign_ == null || other.KeywordPlanCampaign != "") { + KeywordPlanCampaign = other.KeywordPlanCampaign; + } + } + if (other.campaignForecast_ != null) { + if (campaignForecast_ == null) { + CampaignForecast = new global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics(); + } + CampaignForecast.MergeFrom(other.CampaignForecast); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_keywordPlanCampaign_codec.Read(input); + if (keywordPlanCampaign_ == null || value != "") { + KeywordPlanCampaign = value; + } + break; + } + case 18: { + if (campaignForecast_ == null) { + CampaignForecast = new global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics(); + } + input.ReadMessage(CampaignForecast); + break; + } + } + } + } + + } + + /// + /// An ad group forecast. + /// + public sealed partial class KeywordPlanAdGroupForecast : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanAdGroupForecast()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[8]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupForecast() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupForecast(KeywordPlanAdGroupForecast other) : this() { + KeywordPlanAdGroup = other.KeywordPlanAdGroup; + adGroupForecast_ = other.adGroupForecast_ != null ? other.adGroupForecast_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanAdGroupForecast Clone() { + return new KeywordPlanAdGroupForecast(this); + } + + /// Field number for the "keyword_plan_ad_group" field. + public const int KeywordPlanAdGroupFieldNumber = 1; + private static readonly pb::FieldCodec _single_keywordPlanAdGroup_codec = pb::FieldCodec.ForClassWrapper(10); + private string keywordPlanAdGroup_; + /// + /// The resource name of the Keyword Plan ad group related to the forecast. + /// + /// `customers/{customer_id}/keywordPlanAdGroups/{keyword_plan_ad_group_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlanAdGroup { + get { return keywordPlanAdGroup_; } + set { + keywordPlanAdGroup_ = value; + } + } + + + /// Field number for the "ad_group_forecast" field. + public const int AdGroupForecastFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics adGroupForecast_; + /// + /// The forecast for the Keyword Plan ad group. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics AdGroupForecast { + get { return adGroupForecast_; } + set { + adGroupForecast_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanAdGroupForecast); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanAdGroupForecast other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (KeywordPlanAdGroup != other.KeywordPlanAdGroup) return false; + if (!object.Equals(AdGroupForecast, other.AdGroupForecast)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (keywordPlanAdGroup_ != null) hash ^= KeywordPlanAdGroup.GetHashCode(); + if (adGroupForecast_ != null) hash ^= AdGroupForecast.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (keywordPlanAdGroup_ != null) { + _single_keywordPlanAdGroup_codec.WriteTagAndValue(output, KeywordPlanAdGroup); + } + if (adGroupForecast_ != null) { + output.WriteRawTag(18); + output.WriteMessage(AdGroupForecast); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (keywordPlanAdGroup_ != null) { + size += _single_keywordPlanAdGroup_codec.CalculateSizeWithTag(KeywordPlanAdGroup); + } + if (adGroupForecast_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(AdGroupForecast); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanAdGroupForecast other) { + if (other == null) { + return; + } + if (other.keywordPlanAdGroup_ != null) { + if (keywordPlanAdGroup_ == null || other.KeywordPlanAdGroup != "") { + KeywordPlanAdGroup = other.KeywordPlanAdGroup; + } + } + if (other.adGroupForecast_ != null) { + if (adGroupForecast_ == null) { + AdGroupForecast = new global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics(); + } + AdGroupForecast.MergeFrom(other.AdGroupForecast); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_keywordPlanAdGroup_codec.Read(input); + if (keywordPlanAdGroup_ == null || value != "") { + KeywordPlanAdGroup = value; + } + break; + } + case 18: { + if (adGroupForecast_ == null) { + AdGroupForecast = new global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics(); + } + input.ReadMessage(AdGroupForecast); + break; + } + } + } + } + + } + + /// + /// A keyword forecast. + /// + public sealed partial class KeywordPlanKeywordForecast : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanKeywordForecast()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[9]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordForecast() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordForecast(KeywordPlanKeywordForecast other) : this() { + KeywordPlanAdGroupKeyword = other.KeywordPlanAdGroupKeyword; + keywordForecast_ = other.keywordForecast_ != null ? other.keywordForecast_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordForecast Clone() { + return new KeywordPlanKeywordForecast(this); + } + + /// Field number for the "keyword_plan_ad_group_keyword" field. + public const int KeywordPlanAdGroupKeywordFieldNumber = 1; + private static readonly pb::FieldCodec _single_keywordPlanAdGroupKeyword_codec = pb::FieldCodec.ForClassWrapper(10); + private string keywordPlanAdGroupKeyword_; + /// + /// The resource name of the Keyword Plan keyword related to the forecast. + /// + /// `customers/{customer_id}/keywordPlanAdGroupKeywords/{keyword_plan_ad_group_keyword_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlanAdGroupKeyword { + get { return keywordPlanAdGroupKeyword_; } + set { + keywordPlanAdGroupKeyword_ = value; + } + } + + + /// Field number for the "keyword_forecast" field. + public const int KeywordForecastFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics keywordForecast_; + /// + /// The forecast for the Keyword Plan keyword. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics KeywordForecast { + get { return keywordForecast_; } + set { + keywordForecast_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanKeywordForecast); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanKeywordForecast other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (KeywordPlanAdGroupKeyword != other.KeywordPlanAdGroupKeyword) return false; + if (!object.Equals(KeywordForecast, other.KeywordForecast)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (keywordPlanAdGroupKeyword_ != null) hash ^= KeywordPlanAdGroupKeyword.GetHashCode(); + if (keywordForecast_ != null) hash ^= KeywordForecast.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (keywordPlanAdGroupKeyword_ != null) { + _single_keywordPlanAdGroupKeyword_codec.WriteTagAndValue(output, KeywordPlanAdGroupKeyword); + } + if (keywordForecast_ != null) { + output.WriteRawTag(18); + output.WriteMessage(KeywordForecast); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (keywordPlanAdGroupKeyword_ != null) { + size += _single_keywordPlanAdGroupKeyword_codec.CalculateSizeWithTag(KeywordPlanAdGroupKeyword); + } + if (keywordForecast_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(KeywordForecast); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanKeywordForecast other) { + if (other == null) { + return; + } + if (other.keywordPlanAdGroupKeyword_ != null) { + if (keywordPlanAdGroupKeyword_ == null || other.KeywordPlanAdGroupKeyword != "") { + KeywordPlanAdGroupKeyword = other.KeywordPlanAdGroupKeyword; + } + } + if (other.keywordForecast_ != null) { + if (keywordForecast_ == null) { + KeywordForecast = new global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics(); + } + KeywordForecast.MergeFrom(other.KeywordForecast); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_keywordPlanAdGroupKeyword_codec.Read(input); + if (keywordPlanAdGroupKeyword_ == null || value != "") { + KeywordPlanAdGroupKeyword = value; + } + break; + } + case 18: { + if (keywordForecast_ == null) { + KeywordForecast = new global::Google.Ads.GoogleAds.V3.Services.ForecastMetrics(); + } + input.ReadMessage(KeywordForecast); + break; + } + } + } + } + + } + + /// + /// Forecast metrics. + /// + public sealed partial class ForecastMetrics : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ForecastMetrics()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[10]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ForecastMetrics() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ForecastMetrics(ForecastMetrics other) : this() { + Impressions = other.Impressions; + Ctr = other.Ctr; + AverageCpc = other.AverageCpc; + Clicks = other.Clicks; + CostMicros = other.CostMicros; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public ForecastMetrics Clone() { + return new ForecastMetrics(this); + } + + /// Field number for the "impressions" field. + public const int ImpressionsFieldNumber = 1; + private static readonly pb::FieldCodec _single_impressions_codec = pb::FieldCodec.ForStructWrapper(10); + private double? impressions_; + /// + /// Impressions + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? Impressions { + get { return impressions_; } + set { + impressions_ = value; + } + } + + + /// Field number for the "ctr" field. + public const int CtrFieldNumber = 2; + private static readonly pb::FieldCodec _single_ctr_codec = pb::FieldCodec.ForStructWrapper(18); + private double? ctr_; + /// + /// Ctr + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? Ctr { + get { return ctr_; } + set { + ctr_ = value; + } + } + + + /// Field number for the "average_cpc" field. + public const int AverageCpcFieldNumber = 3; + private static readonly pb::FieldCodec _single_averageCpc_codec = pb::FieldCodec.ForStructWrapper(26); + private long? averageCpc_; + /// + /// AVG cpc + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? AverageCpc { + get { return averageCpc_; } + set { + averageCpc_ = value; + } + } + + + /// Field number for the "clicks" field. + public const int ClicksFieldNumber = 5; + private static readonly pb::FieldCodec _single_clicks_codec = pb::FieldCodec.ForStructWrapper(42); + private double? clicks_; + /// + /// Clicks + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public double? Clicks { + get { return clicks_; } + set { + clicks_ = value; + } + } + + + /// Field number for the "cost_micros" field. + public const int CostMicrosFieldNumber = 6; + private static readonly pb::FieldCodec _single_costMicros_codec = pb::FieldCodec.ForStructWrapper(50); + private long? costMicros_; + /// + /// Cost + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long? CostMicros { + get { return costMicros_; } + set { + costMicros_ = value; + } + } + + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as ForecastMetrics); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(ForecastMetrics other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(Impressions, other.Impressions)) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(Ctr, other.Ctr)) return false; + if (AverageCpc != other.AverageCpc) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(Clicks, other.Clicks)) return false; + if (CostMicros != other.CostMicros) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (impressions_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(Impressions); + if (ctr_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(Ctr); + if (averageCpc_ != null) hash ^= AverageCpc.GetHashCode(); + if (clicks_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(Clicks); + if (costMicros_ != null) hash ^= CostMicros.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (impressions_ != null) { + _single_impressions_codec.WriteTagAndValue(output, Impressions); + } + if (ctr_ != null) { + _single_ctr_codec.WriteTagAndValue(output, Ctr); + } + if (averageCpc_ != null) { + _single_averageCpc_codec.WriteTagAndValue(output, AverageCpc); + } + if (clicks_ != null) { + _single_clicks_codec.WriteTagAndValue(output, Clicks); + } + if (costMicros_ != null) { + _single_costMicros_codec.WriteTagAndValue(output, CostMicros); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (impressions_ != null) { + size += _single_impressions_codec.CalculateSizeWithTag(Impressions); + } + if (ctr_ != null) { + size += _single_ctr_codec.CalculateSizeWithTag(Ctr); + } + if (averageCpc_ != null) { + size += _single_averageCpc_codec.CalculateSizeWithTag(AverageCpc); + } + if (clicks_ != null) { + size += _single_clicks_codec.CalculateSizeWithTag(Clicks); + } + if (costMicros_ != null) { + size += _single_costMicros_codec.CalculateSizeWithTag(CostMicros); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(ForecastMetrics other) { + if (other == null) { + return; + } + if (other.impressions_ != null) { + if (impressions_ == null || other.Impressions != 0D) { + Impressions = other.Impressions; + } + } + if (other.ctr_ != null) { + if (ctr_ == null || other.Ctr != 0D) { + Ctr = other.Ctr; + } + } + if (other.averageCpc_ != null) { + if (averageCpc_ == null || other.AverageCpc != 0L) { + AverageCpc = other.AverageCpc; + } + } + if (other.clicks_ != null) { + if (clicks_ == null || other.Clicks != 0D) { + Clicks = other.Clicks; + } + } + if (other.costMicros_ != null) { + if (costMicros_ == null || other.CostMicros != 0L) { + CostMicros = other.CostMicros; + } + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + double? value = _single_impressions_codec.Read(input); + if (impressions_ == null || value != 0D) { + Impressions = value; + } + break; + } + case 18: { + double? value = _single_ctr_codec.Read(input); + if (ctr_ == null || value != 0D) { + Ctr = value; + } + break; + } + case 26: { + long? value = _single_averageCpc_codec.Read(input); + if (averageCpc_ == null || value != 0L) { + AverageCpc = value; + } + break; + } + case 42: { + double? value = _single_clicks_codec.Read(input); + if (clicks_ == null || value != 0D) { + Clicks = value; + } + break; + } + case 50: { + long? value = _single_costMicros_codec.Read(input); + if (costMicros_ == null || value != 0L) { + CostMicros = value; + } + break; + } + } + } + } + + } + + /// + /// Request message for [KeywordPlanService.GenerateHistoricalMetrics][google.ads.googleads.v3.services.KeywordPlanService.GenerateHistoricalMetrics]. + /// + public sealed partial class GenerateHistoricalMetricsRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenerateHistoricalMetricsRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[11]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateHistoricalMetricsRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateHistoricalMetricsRequest(GenerateHistoricalMetricsRequest other) : this() { + keywordPlan_ = other.keywordPlan_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateHistoricalMetricsRequest Clone() { + return new GenerateHistoricalMetricsRequest(this); + } + + /// Field number for the "keyword_plan" field. + public const int KeywordPlanFieldNumber = 1; + private string keywordPlan_ = ""; + /// + /// Required. The resource name of the keyword plan of which historical metrics are + /// requested. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string KeywordPlan { + get { return keywordPlan_; } + set { + keywordPlan_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenerateHistoricalMetricsRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenerateHistoricalMetricsRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (KeywordPlan != other.KeywordPlan) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (KeywordPlan.Length != 0) hash ^= KeywordPlan.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (KeywordPlan.Length != 0) { + output.WriteRawTag(10); + output.WriteString(KeywordPlan); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (KeywordPlan.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(KeywordPlan); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenerateHistoricalMetricsRequest other) { + if (other == null) { + return; + } + if (other.KeywordPlan.Length != 0) { + KeywordPlan = other.KeywordPlan; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + KeywordPlan = input.ReadString(); + break; + } + } + } + } + + } + + /// + /// Response message for [KeywordPlanService.GenerateHistoricalMetrics][google.ads.googleads.v3.services.KeywordPlanService.GenerateHistoricalMetrics]. + /// + public sealed partial class GenerateHistoricalMetricsResponse : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GenerateHistoricalMetricsResponse()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[12]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateHistoricalMetricsResponse() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateHistoricalMetricsResponse(GenerateHistoricalMetricsResponse other) : this() { + metrics_ = other.metrics_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GenerateHistoricalMetricsResponse Clone() { + return new GenerateHistoricalMetricsResponse(this); + } + + /// Field number for the "metrics" field. + public const int MetricsFieldNumber = 1; + private static readonly pb::FieldCodec _repeated_metrics_codec + = pb::FieldCodec.ForMessage(10, global::Google.Ads.GoogleAds.V3.Services.KeywordPlanKeywordHistoricalMetrics.Parser); + private readonly pbc::RepeatedField metrics_ = new pbc::RepeatedField(); + /// + /// List of keyword historical metrics. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public pbc::RepeatedField Metrics { + get { return metrics_; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GenerateHistoricalMetricsResponse); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GenerateHistoricalMetricsResponse other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if(!metrics_.Equals(other.metrics_)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + hash ^= metrics_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + metrics_.WriteTo(output, _repeated_metrics_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + size += metrics_.CalculateSize(_repeated_metrics_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GenerateHistoricalMetricsResponse other) { + if (other == null) { + return; + } + metrics_.Add(other.metrics_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + metrics_.AddEntriesFrom(input, _repeated_metrics_codec); + break; + } + } + } + } + + } + + /// + /// A keyword historical metrics. + /// + public sealed partial class KeywordPlanKeywordHistoricalMetrics : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordPlanKeywordHistoricalMetrics()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.MessageTypes[13]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordHistoricalMetrics() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordHistoricalMetrics(KeywordPlanKeywordHistoricalMetrics other) : this() { + SearchQuery = other.SearchQuery; + keywordMetrics_ = other.keywordMetrics_ != null ? other.keywordMetrics_.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordPlanKeywordHistoricalMetrics Clone() { + return new KeywordPlanKeywordHistoricalMetrics(this); + } + + /// Field number for the "search_query" field. + public const int SearchQueryFieldNumber = 1; + private static readonly pb::FieldCodec _single_searchQuery_codec = pb::FieldCodec.ForClassWrapper(10); + private string searchQuery_; + /// + /// The text of the query associated with one or more ad_group_keywords in the + /// plan. + /// + /// Note that we de-dupe your keywords list, eliminating close variants before + /// returning the plan's keywords as text. For example, if your plan originally + /// contained the keywords 'car' and 'cars', the returned search query will + /// only contain 'car'. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string SearchQuery { + get { return searchQuery_; } + set { + searchQuery_ = value; + } + } + + + /// Field number for the "keyword_metrics" field. + public const int KeywordMetricsFieldNumber = 2; + private global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics keywordMetrics_; + /// + /// The historical metrics for the query associated with one or more + /// ad_group_keywords in the plan. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics KeywordMetrics { + get { return keywordMetrics_; } + set { + keywordMetrics_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordPlanKeywordHistoricalMetrics); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordPlanKeywordHistoricalMetrics other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (SearchQuery != other.SearchQuery) return false; + if (!object.Equals(KeywordMetrics, other.KeywordMetrics)) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (searchQuery_ != null) hash ^= SearchQuery.GetHashCode(); + if (keywordMetrics_ != null) hash ^= KeywordMetrics.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (searchQuery_ != null) { + _single_searchQuery_codec.WriteTagAndValue(output, SearchQuery); + } + if (keywordMetrics_ != null) { + output.WriteRawTag(18); + output.WriteMessage(KeywordMetrics); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (searchQuery_ != null) { + size += _single_searchQuery_codec.CalculateSizeWithTag(SearchQuery); + } + if (keywordMetrics_ != null) { + size += 1 + pb::CodedOutputStream.ComputeMessageSize(KeywordMetrics); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordPlanKeywordHistoricalMetrics other) { + if (other == null) { + return; + } + if (other.searchQuery_ != null) { + if (searchQuery_ == null || other.SearchQuery != "") { + SearchQuery = other.SearchQuery; + } + } + if (other.keywordMetrics_ != null) { + if (keywordMetrics_ == null) { + KeywordMetrics = new global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics(); + } + KeywordMetrics.MergeFrom(other.KeywordMetrics); + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + string value = _single_searchQuery_codec.Read(input); + if (searchQuery_ == null || value != "") { + SearchQuery = value; + } + break; + } + case 18: { + if (keywordMetrics_ == null) { + KeywordMetrics = new global::Google.Ads.GoogleAds.V3.Common.KeywordPlanHistoricalMetrics(); + } + input.ReadMessage(KeywordMetrics); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordPlanServiceClient.cs b/src/V3/Stubs/KeywordPlanServiceClient.cs new file mode 100644 index 000000000..5c028d237 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanServiceClient.cs @@ -0,0 +1,1291 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class KeywordPlanServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static KeywordPlanServiceSettings GetDefault() => new KeywordPlanServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public KeywordPlanServiceSettings() { } + + private KeywordPlanServiceSettings(KeywordPlanServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetKeywordPlanSettings = existing.GetKeywordPlanSettings; + MutateKeywordPlansSettings = existing.MutateKeywordPlansSettings; + GenerateForecastMetricsSettings = existing.GenerateForecastMetricsSettings; + GenerateHistoricalMetricsSettings = existing.GenerateHistoricalMetricsSettings; + OnCopy(existing); + } + + partial void OnCopy(KeywordPlanServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanServiceClient.GetKeywordPlan and KeywordPlanServiceClient.GetKeywordPlanAsync. + /// + /// + /// The default KeywordPlanServiceClient.GetKeywordPlan and + /// KeywordPlanServiceClient.GetKeywordPlanAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetKeywordPlanSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanServiceClient.MutateKeywordPlans and KeywordPlanServiceClient.MutateKeywordPlansAsync. + /// + /// + /// The default KeywordPlanServiceClient.MutateKeywordPlans and + /// KeywordPlanServiceClient.MutateKeywordPlansAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// No status codes + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings MutateKeywordPlansSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: NonIdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanServiceClient.GenerateForecastMetrics and KeywordPlanServiceClient.GenerateForecastMetricsAsync. + /// + /// + /// The default KeywordPlanServiceClient.GenerateForecastMetrics and + /// KeywordPlanServiceClient.GenerateForecastMetricsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GenerateForecastMetricsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// for synchronous and asynchronous calls to + /// KeywordPlanServiceClient.GenerateHistoricalMetrics and KeywordPlanServiceClient.GenerateHistoricalMetricsAsync. + /// + /// + /// The default KeywordPlanServiceClient.GenerateHistoricalMetrics and + /// KeywordPlanServiceClient.GenerateHistoricalMetricsAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GenerateHistoricalMetricsSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public KeywordPlanServiceSettings Clone() => new KeywordPlanServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class KeywordPlanServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public KeywordPlanServiceSettings Settings { get; set; } + + /// + public override KeywordPlanServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return KeywordPlanServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return KeywordPlanServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => KeywordPlanServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => KeywordPlanServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => KeywordPlanServiceClient.ChannelPool; + } + + /// + /// KeywordPlanService client wrapper, for convenient use. + /// + public abstract partial class KeywordPlanServiceClient + { + /// + /// The default endpoint for the KeywordPlanService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default KeywordPlanService scopes. + /// + /// + /// The default KeywordPlanService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanServiceClient client = await KeywordPlanServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanServiceClient.DefaultEndpoint.Host, KeywordPlanServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanServiceClient client = KeywordPlanServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordPlanServiceClient client = KeywordPlanServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordPlanServiceClient.DefaultEndpoint.Host, KeywordPlanServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordPlanServiceClient client = KeywordPlanServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static KeywordPlanServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, KeywordPlanServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanServiceClient Create(grpccore::Channel channel, KeywordPlanServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordPlanServiceClient Create(grpccore::CallInvoker callInvoker, KeywordPlanServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + KeywordPlanService.KeywordPlanServiceClient grpcClient = new KeywordPlanService.KeywordPlanServiceClient(callInvoker); + return new KeywordPlanServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC KeywordPlanService client. + /// + public virtual KeywordPlanService.KeywordPlanServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested plan in full detail. + /// + /// + /// Required. The resource name of the plan to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlanAsync( + new GetKeywordPlanRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// Required. The resource name of the plan to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetKeywordPlanAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// Required. The resource name of the plan to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlan GetKeywordPlan( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordPlan( + new GetKeywordPlanRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanAsync( + GetKeywordPlanRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordPlanAsync( + GetKeywordPlanRequest request, + st::CancellationToken cancellationToken) => GetKeywordPlanAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordPlan GetKeywordPlan( + GetKeywordPlanRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose keyword plans are being modified. + /// + /// + /// Required. The list of operations to perform on individual keyword plans. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlansAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlansAsync( + new MutateKeywordPlansRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose keyword plans are being modified. + /// + /// + /// Required. The list of operations to perform on individual keyword plans. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlansAsync( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + st::CancellationToken cancellationToken) => MutateKeywordPlansAsync( + customerId, + operations, + partialFailure, + validateOnly, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose keyword plans are being modified. + /// + /// + /// Required. The list of operations to perform on individual keyword plans. + /// + /// + /// If true, successful operations will be carried out and invalid + /// operations will return errors. If false, all operations will be carried + /// out in one transaction if and only if they are all valid. + /// Default is false. + /// + /// + /// If true, the request is validated but not executed. Only errors are + /// returned, not results. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlansResponse MutateKeywordPlans( + string customerId, + scg::IEnumerable operations, + bool? partialFailure, + bool? validateOnly, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlans( + new MutateKeywordPlansRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + PartialFailure = partialFailure ?? false, // Optional + ValidateOnly = validateOnly ?? false, // Optional + }, + callSettings); + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose keyword plans are being modified. + /// + /// + /// Required. The list of operations to perform on individual keyword plans. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlansAsync( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlansAsync( + new MutateKeywordPlansRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose keyword plans are being modified. + /// + /// + /// Required. The list of operations to perform on individual keyword plans. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlansAsync( + string customerId, + scg::IEnumerable operations, + st::CancellationToken cancellationToken) => MutateKeywordPlansAsync( + customerId, + operations, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// Required. The ID of the customer whose keyword plans are being modified. + /// + /// + /// Required. The list of operations to perform on individual keyword plans. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlansResponse MutateKeywordPlans( + string customerId, + scg::IEnumerable operations, + gaxgrpc::CallSettings callSettings = null) => MutateKeywordPlans( + new MutateKeywordPlansRequest + { + CustomerId = gax::GaxPreconditions.CheckNotNullOrEmpty(customerId, nameof(customerId)), + Operations = { gax::GaxPreconditions.CheckNotNull(operations, nameof(operations)) }, + }, + callSettings); + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlansAsync( + MutateKeywordPlansRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task MutateKeywordPlansAsync( + MutateKeywordPlansRequest request, + st::CancellationToken cancellationToken) => MutateKeywordPlansAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual MutateKeywordPlansResponse MutateKeywordPlans( + MutateKeywordPlansRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// + /// Required. The resource name of the keyword plan to be forecasted. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateForecastMetricsAsync( + string keywordPlan, + gaxgrpc::CallSettings callSettings = null) => GenerateForecastMetricsAsync( + new GenerateForecastMetricsRequest + { + KeywordPlan = gax::GaxPreconditions.CheckNotNullOrEmpty(keywordPlan, nameof(keywordPlan)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// + /// Required. The resource name of the keyword plan to be forecasted. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateForecastMetricsAsync( + string keywordPlan, + st::CancellationToken cancellationToken) => GenerateForecastMetricsAsync( + keywordPlan, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// + /// Required. The resource name of the keyword plan to be forecasted. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual GenerateForecastMetricsResponse GenerateForecastMetrics( + string keywordPlan, + gaxgrpc::CallSettings callSettings = null) => GenerateForecastMetrics( + new GenerateForecastMetricsRequest + { + KeywordPlan = gax::GaxPreconditions.CheckNotNullOrEmpty(keywordPlan, nameof(keywordPlan)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateForecastMetricsAsync( + GenerateForecastMetricsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateForecastMetricsAsync( + GenerateForecastMetricsRequest request, + st::CancellationToken cancellationToken) => GenerateForecastMetricsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual GenerateForecastMetricsResponse GenerateForecastMetrics( + GenerateForecastMetricsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// + /// Required. The resource name of the keyword plan of which historical metrics are + /// requested. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateHistoricalMetricsAsync( + string keywordPlan, + gaxgrpc::CallSettings callSettings = null) => GenerateHistoricalMetricsAsync( + new GenerateHistoricalMetricsRequest + { + KeywordPlan = gax::GaxPreconditions.CheckNotNullOrEmpty(keywordPlan, nameof(keywordPlan)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// + /// Required. The resource name of the keyword plan of which historical metrics are + /// requested. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateHistoricalMetricsAsync( + string keywordPlan, + st::CancellationToken cancellationToken) => GenerateHistoricalMetricsAsync( + keywordPlan, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// + /// Required. The resource name of the keyword plan of which historical metrics are + /// requested. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual GenerateHistoricalMetricsResponse GenerateHistoricalMetrics( + string keywordPlan, + gaxgrpc::CallSettings callSettings = null) => GenerateHistoricalMetrics( + new GenerateHistoricalMetricsRequest + { + KeywordPlan = gax::GaxPreconditions.CheckNotNullOrEmpty(keywordPlan, nameof(keywordPlan)), + }, + callSettings); + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateHistoricalMetricsAsync( + GenerateHistoricalMetricsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GenerateHistoricalMetricsAsync( + GenerateHistoricalMetricsRequest request, + st::CancellationToken cancellationToken) => GenerateHistoricalMetricsAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual GenerateHistoricalMetricsResponse GenerateHistoricalMetrics( + GenerateHistoricalMetricsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// KeywordPlanService client wrapper implementation, for convenient use. + /// + public sealed partial class KeywordPlanServiceClientImpl : KeywordPlanServiceClient + { + private readonly gaxgrpc::ApiCall _callGetKeywordPlan; + private readonly gaxgrpc::ApiCall _callMutateKeywordPlans; + private readonly gaxgrpc::ApiCall _callGenerateForecastMetrics; + private readonly gaxgrpc::ApiCall _callGenerateHistoricalMetrics; + + /// + /// Constructs a client wrapper for the KeywordPlanService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public KeywordPlanServiceClientImpl(KeywordPlanService.KeywordPlanServiceClient grpcClient, KeywordPlanServiceSettings settings) + { + GrpcClient = grpcClient; + KeywordPlanServiceSettings effectiveSettings = settings ?? KeywordPlanServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetKeywordPlan = clientHelper.BuildApiCall( + GrpcClient.GetKeywordPlanAsync, GrpcClient.GetKeywordPlan, effectiveSettings.GetKeywordPlanSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + _callMutateKeywordPlans = clientHelper.BuildApiCall( + GrpcClient.MutateKeywordPlansAsync, GrpcClient.MutateKeywordPlans, effectiveSettings.MutateKeywordPlansSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"customer_id={request.CustomerId}")); + _callGenerateForecastMetrics = clientHelper.BuildApiCall( + GrpcClient.GenerateForecastMetricsAsync, GrpcClient.GenerateForecastMetrics, effectiveSettings.GenerateForecastMetricsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"keyword_plan={request.KeywordPlan}")); + _callGenerateHistoricalMetrics = clientHelper.BuildApiCall( + GrpcClient.GenerateHistoricalMetricsAsync, GrpcClient.GenerateHistoricalMetrics, effectiveSettings.GenerateHistoricalMetricsSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"keyword_plan={request.KeywordPlan}")); + Modify_ApiCall(ref _callGetKeywordPlan); + Modify_GetKeywordPlanApiCall(ref _callGetKeywordPlan); + Modify_ApiCall(ref _callMutateKeywordPlans); + Modify_MutateKeywordPlansApiCall(ref _callMutateKeywordPlans); + Modify_ApiCall(ref _callGenerateForecastMetrics); + Modify_GenerateForecastMetricsApiCall(ref _callGenerateForecastMetrics); + Modify_ApiCall(ref _callGenerateHistoricalMetrics); + Modify_GenerateHistoricalMetricsApiCall(ref _callGenerateHistoricalMetrics); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetKeywordPlanApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_MutateKeywordPlansApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_GenerateForecastMetricsApiCall(ref gaxgrpc::ApiCall call); + partial void Modify_GenerateHistoricalMetricsApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(KeywordPlanService.KeywordPlanServiceClient grpcClient, KeywordPlanServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC KeywordPlanService client. + /// + public override KeywordPlanService.KeywordPlanServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetKeywordPlanRequest(ref GetKeywordPlanRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_MutateKeywordPlansRequest(ref MutateKeywordPlansRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_GenerateForecastMetricsRequest(ref GenerateForecastMetricsRequest request, ref gaxgrpc::CallSettings settings); + partial void Modify_GenerateHistoricalMetricsRequest(ref GenerateHistoricalMetricsRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetKeywordPlanAsync( + GetKeywordPlanRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanRequest(ref request, ref callSettings); + return _callGetKeywordPlan.Async(request, callSettings); + } + + /// + /// Returns the requested plan in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::KeywordPlan GetKeywordPlan( + GetKeywordPlanRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordPlanRequest(ref request, ref callSettings); + return _callGetKeywordPlan.Sync(request, callSettings); + } + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task MutateKeywordPlansAsync( + MutateKeywordPlansRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlansRequest(ref request, ref callSettings); + return _callMutateKeywordPlans.Async(request, callSettings); + } + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override MutateKeywordPlansResponse MutateKeywordPlans( + MutateKeywordPlansRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_MutateKeywordPlansRequest(ref request, ref callSettings); + return _callMutateKeywordPlans.Sync(request, callSettings); + } + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GenerateForecastMetricsAsync( + GenerateForecastMetricsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GenerateForecastMetricsRequest(ref request, ref callSettings); + return _callGenerateForecastMetrics.Async(request, callSettings); + } + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override GenerateForecastMetricsResponse GenerateForecastMetrics( + GenerateForecastMetricsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GenerateForecastMetricsRequest(ref request, ref callSettings); + return _callGenerateForecastMetrics.Sync(request, callSettings); + } + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GenerateHistoricalMetricsAsync( + GenerateHistoricalMetricsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GenerateHistoricalMetricsRequest(ref request, ref callSettings); + return _callGenerateHistoricalMetrics.Async(request, callSettings); + } + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override GenerateHistoricalMetricsResponse GenerateHistoricalMetrics( + GenerateHistoricalMetricsRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GenerateHistoricalMetricsRequest(ref request, ref callSettings); + return _callGenerateHistoricalMetrics.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/KeywordPlanServiceGrpc.cs b/src/V3/Stubs/KeywordPlanServiceGrpc.cs new file mode 100644 index 000000000..d61281970 --- /dev/null +++ b/src/V3/Stubs/KeywordPlanServiceGrpc.cs @@ -0,0 +1,361 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_plan_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage keyword plans. + /// + public static partial class KeywordPlanService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.KeywordPlanService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_KeywordPlan = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlansRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlansResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GenerateForecastMetricsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GenerateForecastMetricsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsResponse.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GenerateHistoricalMetricsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GenerateHistoricalMetricsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsResponse.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetKeywordPlan = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetKeywordPlan", + __Marshaller_google_ads_googleads_v3_services_GetKeywordPlanRequest, + __Marshaller_google_ads_googleads_v3_resources_KeywordPlan); + + static readonly grpc::Method __Method_MutateKeywordPlans = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "MutateKeywordPlans", + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlansRequest, + __Marshaller_google_ads_googleads_v3_services_MutateKeywordPlansResponse); + + static readonly grpc::Method __Method_GenerateForecastMetrics = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GenerateForecastMetrics", + __Marshaller_google_ads_googleads_v3_services_GenerateForecastMetricsRequest, + __Marshaller_google_ads_googleads_v3_services_GenerateForecastMetricsResponse); + + static readonly grpc::Method __Method_GenerateHistoricalMetrics = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GenerateHistoricalMetrics", + __Marshaller_google_ads_googleads_v3_services_GenerateHistoricalMetricsRequest, + __Marshaller_google_ads_googleads_v3_services_GenerateHistoricalMetricsResponse); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordPlanServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of KeywordPlanService + public abstract partial class KeywordPlanServiceBase + { + /// + /// Returns the requested plan in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetKeywordPlan(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task MutateKeywordPlans(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GenerateForecastMetrics(global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GenerateHistoricalMetrics(global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for KeywordPlanService + public partial class KeywordPlanServiceClient : grpc::ClientBase + { + /// Creates a new client for KeywordPlanService + /// The channel to use to make remote calls. + public KeywordPlanServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for KeywordPlanService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public KeywordPlanServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected KeywordPlanServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected KeywordPlanServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested plan in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan GetKeywordPlan(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlan(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested plan in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordPlan GetKeywordPlan(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetKeywordPlan, null, options, request); + } + /// + /// Returns the requested plan in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordPlanAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested plan in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordPlanAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordPlanRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetKeywordPlan, null, options, request); + } + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansResponse MutateKeywordPlans(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlans(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansResponse MutateKeywordPlans(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_MutateKeywordPlans, null, options, request); + } + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlansAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return MutateKeywordPlansAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Creates, updates, or removes keyword plans. Operation statuses are + /// returned. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall MutateKeywordPlansAsync(global::Google.Ads.GoogleAds.V3.Services.MutateKeywordPlansRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_MutateKeywordPlans, null, options, request); + } + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsResponse GenerateForecastMetrics(global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GenerateForecastMetrics(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsResponse GenerateForecastMetrics(global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GenerateForecastMetrics, null, options, request); + } + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GenerateForecastMetricsAsync(global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GenerateForecastMetricsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan forecasts. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GenerateForecastMetricsAsync(global::Google.Ads.GoogleAds.V3.Services.GenerateForecastMetricsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GenerateForecastMetrics, null, options, request); + } + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsResponse GenerateHistoricalMetrics(global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GenerateHistoricalMetrics(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsResponse GenerateHistoricalMetrics(global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GenerateHistoricalMetrics, null, options, request); + } + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GenerateHistoricalMetricsAsync(global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GenerateHistoricalMetricsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested Keyword Plan historical metrics. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GenerateHistoricalMetricsAsync(global::Google.Ads.GoogleAds.V3.Services.GenerateHistoricalMetricsRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GenerateHistoricalMetrics, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override KeywordPlanServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new KeywordPlanServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(KeywordPlanServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetKeywordPlan, serviceImpl.GetKeywordPlan) + .AddMethod(__Method_MutateKeywordPlans, serviceImpl.MutateKeywordPlans) + .AddMethod(__Method_GenerateForecastMetrics, serviceImpl.GenerateForecastMetrics) + .AddMethod(__Method_GenerateHistoricalMetrics, serviceImpl.GenerateHistoricalMetrics).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, KeywordPlanServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetKeywordPlan, serviceImpl.GetKeywordPlan); + serviceBinder.AddMethod(__Method_MutateKeywordPlans, serviceImpl.MutateKeywordPlans); + serviceBinder.AddMethod(__Method_GenerateForecastMetrics, serviceImpl.GenerateForecastMetrics); + serviceBinder.AddMethod(__Method_GenerateHistoricalMetrics, serviceImpl.GenerateHistoricalMetrics); + } + + } +} +#endregion diff --git a/src/V3/Stubs/KeywordView.cs b/src/V3/Stubs/KeywordView.cs new file mode 100644 index 000000000..d5ca55d3a --- /dev/null +++ b/src/V3/Stubs/KeywordView.cs @@ -0,0 +1,193 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/keyword_view.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/keyword_view.proto + public static partial class KeywordViewReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/keyword_view.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordViewReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CjRnb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMva2V5d29yZF92", + "aWV3LnByb3RvEiFnb29nbGUuYWRzLmdvb2dsZWFkcy52My5yZXNvdXJjZXMa", + "H2dvb2dsZS9hcGkvZmllbGRfYmVoYXZpb3IucHJvdG8aGWdvb2dsZS9hcGkv", + "cmVzb3VyY2UucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8i", + "rwEKC0tleXdvcmRWaWV3EkMKDXJlc291cmNlX25hbWUYASABKAlCLOBBBfpB", + "JgokZ29vZ2xlYWRzLmdvb2dsZWFwaXMuY29tL0tleXdvcmRWaWV3OlvqQVgK", + "JGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbS9LZXl3b3JkVmlldxIwY3VzdG9t", + "ZXJzL3tjdXN0b21lcn0va2V5d29yZFZpZXdzL3trZXl3b3JkX3ZpZXd9Qv0B", + "CiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVzb3VyY2VzQhBLZXl3", + "b3JkVmlld1Byb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dv", + "b2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVzb3VyY2Vz", + "ogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3VyY2VzygIh", + "R29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29vZ2xlOjpB", + "ZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.KeywordView), global::Google.Ads.GoogleAds.V3.Resources.KeywordView.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A keyword view. + /// + public sealed partial class KeywordView : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new KeywordView()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Resources.KeywordViewReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordView() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordView(KeywordView other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public KeywordView Clone() { + return new KeywordView(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Immutable. The resource name of the keyword view. + /// Keyword view resource names have the form: + /// + /// `customers/{customer_id}/keywordViews/{ad_group_id}~{criterion_id}` + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as KeywordView); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(KeywordView other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(KeywordView other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordViewService.cs b/src/V3/Stubs/KeywordViewService.cs new file mode 100644 index 000000000..fe3d9b72e --- /dev/null +++ b/src/V3/Stubs/KeywordViewService.cs @@ -0,0 +1,194 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_view_service.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Services { + + /// Holder for reflection information generated from google/ads/googleads/v3/services/keyword_view_service.proto + public static partial class KeywordViewServiceReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/services/keyword_view_service.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static KeywordViewServiceReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cjtnb29nbGUvYWRzL2dvb2dsZWFkcy92My9zZXJ2aWNlcy9rZXl3b3JkX3Zp", + "ZXdfc2VydmljZS5wcm90bxIgZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMuc2Vy", + "dmljZXMaNGdvb2dsZS9hZHMvZ29vZ2xlYWRzL3YzL3Jlc291cmNlcy9rZXl3", + "b3JkX3ZpZXcucHJvdG8aHGdvb2dsZS9hcGkvYW5ub3RhdGlvbnMucHJvdG8a", + "F2dvb2dsZS9hcGkvY2xpZW50LnByb3RvGh9nb29nbGUvYXBpL2ZpZWxkX2Jl", + "aGF2aW9yLnByb3RvIjMKFUdldEtleXdvcmRWaWV3UmVxdWVzdBIaCg1yZXNv", + "dXJjZV9uYW1lGAEgASgJQgPgQQIy9QEKEktleXdvcmRWaWV3U2VydmljZRLB", + "AQoOR2V0S2V5d29yZFZpZXcSNy5nb29nbGUuYWRzLmdvb2dsZWFkcy52My5z", + "ZXJ2aWNlcy5HZXRLZXl3b3JkVmlld1JlcXVlc3QaLi5nb29nbGUuYWRzLmdv", + "b2dsZWFkcy52My5yZXNvdXJjZXMuS2V5d29yZFZpZXciRoLT5JMCMBIuL3Yz", + "L3tyZXNvdXJjZV9uYW1lPWN1c3RvbWVycy8qL2tleXdvcmRWaWV3cy8qfdpB", + "DXJlc291cmNlX25hbWUaG8pBGGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbUL+", + "AQokY29tLmdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnNlcnZpY2VzQhdLZXl3", + "b3JkVmlld1NlcnZpY2VQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5w", + "cm90by9nb29nbGVhcGlzL2Fkcy9nb29nbGVhZHMvdjMvc2VydmljZXM7c2Vy", + "dmljZXOiAgNHQUGqAiBHb29nbGUuQWRzLkdvb2dsZUFkcy5WMy5TZXJ2aWNl", + "c8oCIEdvb2dsZVxBZHNcR29vZ2xlQWRzXFYzXFNlcnZpY2Vz6gIkR29vZ2xl", + "OjpBZHM6Okdvb2dsZUFkczo6VjM6OlNlcnZpY2VzYgZwcm90bzM=")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Resources.KeywordViewReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, global::Google.Api.ClientReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Services.GetKeywordViewRequest), global::Google.Ads.GoogleAds.V3.Services.GetKeywordViewRequest.Parser, new[]{ "ResourceName" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// Request message for [KeywordViewService.GetKeywordView][google.ads.googleads.v3.services.KeywordViewService.GetKeywordView]. + /// + public sealed partial class GetKeywordViewRequest : pb::IMessage { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetKeywordViewRequest()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordViewServiceReflection.Descriptor.MessageTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordViewRequest() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordViewRequest(GetKeywordViewRequest other) : this() { + resourceName_ = other.resourceName_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public GetKeywordViewRequest Clone() { + return new GetKeywordViewRequest(this); + } + + /// Field number for the "resource_name" field. + public const int ResourceNameFieldNumber = 1; + private string resourceName_ = ""; + /// + /// Required. The resource name of the keyword view to fetch. + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public string ResourceName { + get { return resourceName_; } + set { + resourceName_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as GetKeywordViewRequest); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(GetKeywordViewRequest other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (ResourceName != other.ResourceName) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (ResourceName.Length != 0) hash ^= ResourceName.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (ResourceName.Length != 0) { + output.WriteRawTag(10); + output.WriteString(ResourceName); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (ResourceName.Length != 0) { + size += 1 + pb::CodedOutputStream.ComputeStringSize(ResourceName); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(GetKeywordViewRequest other) { + if (other == null) { + return; + } + if (other.ResourceName.Length != 0) { + ResourceName = other.ResourceName; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 10: { + ResourceName = input.ReadString(); + break; + } + } + } + } + + } + + #endregion + +} + +#endregion Designer generated code diff --git a/src/V3/Stubs/KeywordViewServiceClient.cs b/src/V3/Stubs/KeywordViewServiceClient.cs new file mode 100644 index 000000000..0f2545b0a --- /dev/null +++ b/src/V3/Stubs/KeywordViewServiceClient.cs @@ -0,0 +1,561 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Generated code. DO NOT EDIT! + +using gagvr = Google.Ads.GoogleAds.V3.Resources; +using gax = Google.Api.Gax; +using gaxgrpc = Google.Api.Gax.Grpc; +using pb = Google.Protobuf; +using pbwkt = Google.Protobuf.WellKnownTypes; +using grpccore = Grpc.Core; +using sys = System; +using sc = System.Collections; +using scg = System.Collections.Generic; +using sco = System.Collections.ObjectModel; +using st = System.Threading; +using stt = System.Threading.Tasks; + +namespace Google.Ads.GoogleAds.V3.Services +{ + /// + /// Settings for a . + /// + public sealed partial class KeywordViewServiceSettings : gaxgrpc::ServiceSettingsBase + { + /// + /// Get a new instance of the default . + /// + /// + /// A new instance of the default . + /// + public static KeywordViewServiceSettings GetDefault() => new KeywordViewServiceSettings(); + + /// + /// Constructs a new object with default settings. + /// + public KeywordViewServiceSettings() { } + + private KeywordViewServiceSettings(KeywordViewServiceSettings existing) : base(existing) + { + gax::GaxPreconditions.CheckNotNull(existing, nameof(existing)); + GetKeywordViewSettings = existing.GetKeywordViewSettings; + OnCopy(existing); + } + + partial void OnCopy(KeywordViewServiceSettings existing); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "Idempotent" RPC methods. + /// + /// + /// The eligible RPC s for retry for "Idempotent" RPC methods are: + /// + /// + /// + /// + /// + public static sys::Predicate IdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(grpccore::StatusCode.DeadlineExceeded, grpccore::StatusCode.Unavailable); + + /// + /// The filter specifying which RPC s are eligible for retry + /// for "NonIdempotent" RPC methods. + /// + /// + /// There are no RPC s eligible for retry for "NonIdempotent" RPC methods. + /// + public static sys::Predicate NonIdempotentRetryFilter { get; } = + gaxgrpc::RetrySettings.FilterForStatusCodes(); + + /// + /// "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods. + /// + /// + /// The "Default" retry backoff for RPC methods is defined as: + /// + /// Initial delay: 5000 milliseconds + /// Maximum delay: 60000 milliseconds + /// Delay multiplier: 1.3 + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultRetryBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(5000), + maxDelay: sys::TimeSpan.FromMilliseconds(60000), + delayMultiplier: 1.3 + ); + + /// + /// "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods. + /// + /// + /// The "Default" timeout backoff for RPC methods is defined as: + /// + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Maximum timeout: 3600000 milliseconds + /// + /// + public static gaxgrpc::BackoffSettings GetDefaultTimeoutBackoff() => new gaxgrpc::BackoffSettings( + delay: sys::TimeSpan.FromMilliseconds(3600000), + maxDelay: sys::TimeSpan.FromMilliseconds(3600000), + delayMultiplier: 1.0 + ); + + /// + /// for synchronous and asynchronous calls to + /// KeywordViewServiceClient.GetKeywordView and KeywordViewServiceClient.GetKeywordViewAsync. + /// + /// + /// The default KeywordViewServiceClient.GetKeywordView and + /// KeywordViewServiceClient.GetKeywordViewAsync are: + /// + /// Initial retry delay: 5000 milliseconds + /// Retry delay multiplier: 1.3 + /// Retry maximum delay: 60000 milliseconds + /// Initial timeout: 3600000 milliseconds + /// Timeout multiplier: 1.0 + /// Timeout maximum delay: 3600000 milliseconds + /// + /// Retry will be attempted on the following response status codes: + /// + /// + /// + /// + /// Default RPC expiration is 3600000 milliseconds. + /// + public gaxgrpc::CallSettings GetKeywordViewSettings { get; set; } = gaxgrpc::CallSettings.FromCallTiming( + gaxgrpc::CallTiming.FromRetry(new gaxgrpc::RetrySettings( + retryBackoff: GetDefaultRetryBackoff(), + timeoutBackoff: GetDefaultTimeoutBackoff(), + totalExpiration: gax::Expiration.FromTimeout(sys::TimeSpan.FromMilliseconds(3600000)), + retryFilter: IdempotentRetryFilter + ))); + + /// + /// Creates a deep clone of this object, with all the same property values. + /// + /// A deep clone of this object. + public KeywordViewServiceSettings Clone() => new KeywordViewServiceSettings(this); + } + + /// + /// Builder class for to provide simple configuration of credentials, endpoint etc. + /// + public sealed partial class KeywordViewServiceClientBuilder : gaxgrpc::ClientBuilderBase + { + /// + /// The settings to use for RPCs, or null for the default settings. + /// + public KeywordViewServiceSettings Settings { get; set; } + + /// + public override KeywordViewServiceClient Build() + { + Validate(); + grpccore::CallInvoker callInvoker = CreateCallInvoker(); + return KeywordViewServiceClient.Create(callInvoker, Settings); + } + + /// + public override async stt::Task BuildAsync(st::CancellationToken cancellationToken = default) + { + Validate(); + grpccore::CallInvoker callInvoker = await CreateCallInvokerAsync(cancellationToken).ConfigureAwait(false); + return KeywordViewServiceClient.Create(callInvoker, Settings); + } + + /// + protected override gaxgrpc::ServiceEndpoint GetDefaultEndpoint() => KeywordViewServiceClient.DefaultEndpoint; + + /// + protected override scg::IReadOnlyList GetDefaultScopes() => KeywordViewServiceClient.DefaultScopes; + + /// + protected override gaxgrpc::ChannelPool GetChannelPool() => KeywordViewServiceClient.ChannelPool; + } + + /// + /// KeywordViewService client wrapper, for convenient use. + /// + public abstract partial class KeywordViewServiceClient + { + /// + /// The default endpoint for the KeywordViewService service, which is a host of "googleads.googleapis.com" and a port of 443. + /// + public static gaxgrpc::ServiceEndpoint DefaultEndpoint { get; } = new gaxgrpc::ServiceEndpoint("googleads.googleapis.com", 443); + + /// + /// The default KeywordViewService scopes. + /// + /// + /// The default KeywordViewService scopes are: + /// + /// + /// + public static scg::IReadOnlyList DefaultScopes { get; } = new sco::ReadOnlyCollection(new string[] { + }); + + private static readonly gaxgrpc::ChannelPool s_channelPool = new gaxgrpc::ChannelPool(DefaultScopes); + + internal static gaxgrpc::ChannelPool ChannelPool => s_channelPool; + + /// + /// Asynchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordViewServiceClient client = await KeywordViewServiceClient.CreateAsync(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordViewServiceClient.DefaultEndpoint.Host, KeywordViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordViewServiceClient client = KeywordViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// await channel.ShutdownAsync(); + /// + /// + /// Optional . + /// Optional . + /// The task representing the created . + public static async stt::Task CreateAsync(gaxgrpc::ServiceEndpoint endpoint = null, KeywordViewServiceSettings settings = null) + { + grpccore::Channel channel = await s_channelPool.GetChannelAsync(endpoint ?? DefaultEndpoint).ConfigureAwait(false); + return Create(channel, settings); + } + + /// + /// Synchronously creates a , applying defaults for all unspecified settings, + /// and creating a channel connecting to the given endpoint with application default credentials where + /// necessary. See the example for how to use custom credentials. + /// + /// + /// This sample shows how to create a client using default credentials: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// ... + /// // When running on Google Cloud Platform this will use the project Compute Credential. + /// // Or set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of a JSON + /// // credential file to use that credential. + /// KeywordViewServiceClient client = KeywordViewServiceClient.Create(); + /// + /// This sample shows how to create a client using credentials loaded from a JSON file: + /// + /// using Google.Ads.GoogleAds.V3.Services; + /// using Google.Apis.Auth.OAuth2; + /// using Grpc.Auth; + /// using Grpc.Core; + /// ... + /// GoogleCredential cred = GoogleCredential.FromFile("/path/to/credentials.json"); + /// Channel channel = new Channel( + /// KeywordViewServiceClient.DefaultEndpoint.Host, KeywordViewServiceClient.DefaultEndpoint.Port, cred.ToChannelCredentials()); + /// KeywordViewServiceClient client = KeywordViewServiceClient.Create(channel); + /// ... + /// // Shutdown the channel when it is no longer required. + /// channel.ShutdownAsync().Wait(); + /// + /// + /// Optional . + /// Optional . + /// The created . + public static KeywordViewServiceClient Create(gaxgrpc::ServiceEndpoint endpoint = null, KeywordViewServiceSettings settings = null) + { + grpccore::Channel channel = s_channelPool.GetChannel(endpoint ?? DefaultEndpoint); + return Create(channel, settings); + } + + /// + /// Creates a which uses the specified channel for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordViewServiceClient Create(grpccore::Channel channel, KeywordViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(channel, nameof(channel)); + return Create(new grpccore::DefaultCallInvoker(channel), settings); + } + + /// + /// Creates a which uses the specified call invoker for remote operations. + /// + /// The for remote operations. Must not be null. + /// Optional . + /// The created . + public static KeywordViewServiceClient Create(grpccore::CallInvoker callInvoker, KeywordViewServiceSettings settings = null) + { + gax::GaxPreconditions.CheckNotNull(callInvoker, nameof(callInvoker)); + grpccore::Interceptors.Interceptor interceptor = settings?.Interceptor; + if (interceptor != null) + { + callInvoker = grpccore::Interceptors.CallInvokerExtensions.Intercept(callInvoker, interceptor); + } + KeywordViewService.KeywordViewServiceClient grpcClient = new KeywordViewService.KeywordViewServiceClient(callInvoker); + return new KeywordViewServiceClientImpl(grpcClient, settings); + } + + /// + /// Shuts down any channels automatically created by + /// and . Channels which weren't automatically + /// created are not affected. + /// + /// After calling this method, further calls to + /// and will create new channels, which could + /// in turn be shut down by another call to this method. + /// A task representing the asynchronous shutdown operation. + public static stt::Task ShutdownDefaultChannelsAsync() => s_channelPool.ShutdownChannelsAsync(); + + /// + /// The underlying gRPC KeywordViewService client. + /// + public virtual KeywordViewService.KeywordViewServiceClient GrpcClient + { + get { throw new sys::NotImplementedException(); } + } + + /// + /// Returns the requested keyword view in full detail. + /// + /// + /// Required. The resource name of the keyword view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordViewAsync( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordViewAsync( + new GetKeywordViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested keyword view in full detail. + /// + /// + /// Required. The resource name of the keyword view to fetch. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordViewAsync( + string resourceName, + st::CancellationToken cancellationToken) => GetKeywordViewAsync( + resourceName, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested keyword view in full detail. + /// + /// + /// Required. The resource name of the keyword view to fetch. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordView GetKeywordView( + string resourceName, + gaxgrpc::CallSettings callSettings = null) => GetKeywordView( + new GetKeywordViewRequest + { + ResourceName = gax::GaxPreconditions.CheckNotNullOrEmpty(resourceName, nameof(resourceName)), + }, + callSettings); + + /// + /// Returns the requested keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordViewAsync( + GetKeywordViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + /// + /// Returns the requested keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// A to use for this RPC. + /// + /// + /// A Task containing the RPC response. + /// + public virtual stt::Task GetKeywordViewAsync( + GetKeywordViewRequest request, + st::CancellationToken cancellationToken) => GetKeywordViewAsync( + request, + gaxgrpc::CallSettings.FromCancellationToken(cancellationToken)); + + /// + /// Returns the requested keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public virtual gagvr::KeywordView GetKeywordView( + GetKeywordViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + throw new sys::NotImplementedException(); + } + + } + + /// + /// KeywordViewService client wrapper implementation, for convenient use. + /// + public sealed partial class KeywordViewServiceClientImpl : KeywordViewServiceClient + { + private readonly gaxgrpc::ApiCall _callGetKeywordView; + + /// + /// Constructs a client wrapper for the KeywordViewService service, with the specified gRPC client and settings. + /// + /// The underlying gRPC client. + /// The base used within this client + public KeywordViewServiceClientImpl(KeywordViewService.KeywordViewServiceClient grpcClient, KeywordViewServiceSettings settings) + { + GrpcClient = grpcClient; + KeywordViewServiceSettings effectiveSettings = settings ?? KeywordViewServiceSettings.GetDefault(); + gaxgrpc::ClientHelper clientHelper = new gaxgrpc::ClientHelper(effectiveSettings); + _callGetKeywordView = clientHelper.BuildApiCall( + GrpcClient.GetKeywordViewAsync, GrpcClient.GetKeywordView, effectiveSettings.GetKeywordViewSettings) + .WithCallSettingsOverlay(request => gaxgrpc::CallSettings.FromHeader("x-goog-request-params", $"resource_name={request.ResourceName}")); + Modify_ApiCall(ref _callGetKeywordView); + Modify_GetKeywordViewApiCall(ref _callGetKeywordView); + OnConstruction(grpcClient, effectiveSettings, clientHelper); + } + + // Partial methods are named to (mostly) ensure there cannot be conflicts with RPC method names. + + // Partial methods called for every ApiCall on construction. + // Allows modification of all the underlying ApiCall objects. + partial void Modify_ApiCall(ref gaxgrpc::ApiCall call) + where TRequest : class, pb::IMessage + where TResponse : class, pb::IMessage; + + // Partial methods called for each ApiCall on construction. + // Allows per-RPC-method modification of the underlying ApiCall object. + partial void Modify_GetKeywordViewApiCall(ref gaxgrpc::ApiCall call); + partial void OnConstruction(KeywordViewService.KeywordViewServiceClient grpcClient, KeywordViewServiceSettings effectiveSettings, gaxgrpc::ClientHelper clientHelper); + + /// + /// The underlying gRPC KeywordViewService client. + /// + public override KeywordViewService.KeywordViewServiceClient GrpcClient { get; } + + // Partial methods called on each request. + // Allows per-RPC-call modification to the request and CallSettings objects, + // before the underlying RPC is performed. + partial void Modify_GetKeywordViewRequest(ref GetKeywordViewRequest request, ref gaxgrpc::CallSettings settings); + + /// + /// Returns the requested keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// A Task containing the RPC response. + /// + public override stt::Task GetKeywordViewAsync( + GetKeywordViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordViewRequest(ref request, ref callSettings); + return _callGetKeywordView.Async(request, callSettings); + } + + /// + /// Returns the requested keyword view in full detail. + /// + /// + /// The request object containing all of the parameters for the API call. + /// + /// + /// If not null, applies overrides to this RPC call. + /// + /// + /// The RPC response. + /// + public override gagvr::KeywordView GetKeywordView( + GetKeywordViewRequest request, + gaxgrpc::CallSettings callSettings = null) + { + Modify_GetKeywordViewRequest(ref request, ref callSettings); + return _callGetKeywordView.Sync(request, callSettings); + } + + } + + // Partial classes to enable page-streaming + + +} diff --git a/src/V3/Stubs/KeywordViewServiceGrpc.cs b/src/V3/Stubs/KeywordViewServiceGrpc.cs new file mode 100644 index 000000000..7d028a478 --- /dev/null +++ b/src/V3/Stubs/KeywordViewServiceGrpc.cs @@ -0,0 +1,158 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/services/keyword_view_service.proto +// +// Original file comments: +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#pragma warning disable 0414, 1591 +#region Designer generated code + +using grpc = global::Grpc.Core; + +namespace Google.Ads.GoogleAds.V3.Services { + /// + /// Service to manage keyword views. + /// + public static partial class KeywordViewService + { + static readonly string __ServiceName = "google.ads.googleads.v3.services.KeywordViewService"; + + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_services_GetKeywordViewRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Services.GetKeywordViewRequest.Parser.ParseFrom); + static readonly grpc::Marshaller __Marshaller_google_ads_googleads_v3_resources_KeywordView = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Google.Ads.GoogleAds.V3.Resources.KeywordView.Parser.ParseFrom); + + static readonly grpc::Method __Method_GetKeywordView = new grpc::Method( + grpc::MethodType.Unary, + __ServiceName, + "GetKeywordView", + __Marshaller_google_ads_googleads_v3_services_GetKeywordViewRequest, + __Marshaller_google_ads_googleads_v3_resources_KeywordView); + + /// Service descriptor + public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor + { + get { return global::Google.Ads.GoogleAds.V3.Services.KeywordViewServiceReflection.Descriptor.Services[0]; } + } + + /// Base class for server-side implementations of KeywordViewService + public abstract partial class KeywordViewServiceBase + { + /// + /// Returns the requested keyword view in full detail. + /// + /// The request received from the client. + /// The context of the server-side call handler being invoked. + /// The response to send back to the client (wrapped by a task). + public virtual global::System.Threading.Tasks.Task GetKeywordView(global::Google.Ads.GoogleAds.V3.Services.GetKeywordViewRequest request, grpc::ServerCallContext context) + { + throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); + } + + } + + /// Client for KeywordViewService + public partial class KeywordViewServiceClient : grpc::ClientBase + { + /// Creates a new client for KeywordViewService + /// The channel to use to make remote calls. + public KeywordViewServiceClient(grpc::Channel channel) : base(channel) + { + } + /// Creates a new client for KeywordViewService that uses a custom CallInvoker. + /// The callInvoker to use to make remote calls. + public KeywordViewServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) + { + } + /// Protected parameterless constructor to allow creation of test doubles. + protected KeywordViewServiceClient() : base() + { + } + /// Protected constructor to allow creation of configured clients. + /// The client configuration. + protected KeywordViewServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + /// + /// Returns the requested keyword view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordView GetKeywordView(global::Google.Ads.GoogleAds.V3.Services.GetKeywordViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordView(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested keyword view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The response received from the server. + public virtual global::Google.Ads.GoogleAds.V3.Resources.KeywordView GetKeywordView(global::Google.Ads.GoogleAds.V3.Services.GetKeywordViewRequest request, grpc::CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_GetKeywordView, null, options, request); + } + /// + /// Returns the requested keyword view in full detail. + /// + /// The request to send to the server. + /// The initial metadata to send with the call. This parameter is optional. + /// An optional deadline for the call. The call will be cancelled if deadline is hit. + /// An optional token for canceling the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordViewRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) + { + return GetKeywordViewAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); + } + /// + /// Returns the requested keyword view in full detail. + /// + /// The request to send to the server. + /// The options for the call. + /// The call object. + public virtual grpc::AsyncUnaryCall GetKeywordViewAsync(global::Google.Ads.GoogleAds.V3.Services.GetKeywordViewRequest request, grpc::CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_GetKeywordView, null, options, request); + } + /// Creates a new instance of client from given ClientBaseConfiguration. + protected override KeywordViewServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new KeywordViewServiceClient(configuration); + } + } + + /// Creates service definition that can be registered with a server + /// An object implementing the server-side handling logic. + public static grpc::ServerServiceDefinition BindService(KeywordViewServiceBase serviceImpl) + { + return grpc::ServerServiceDefinition.CreateBuilder() + .AddMethod(__Method_GetKeywordView, serviceImpl.GetKeywordView).Build(); + } + + /// Register service method implementations with a service binder. Useful when customizing the service binding logic. + /// Note: this method is part of an experimental API that can change or be removed without any prior notice. + /// Service methods will be bound by calling AddMethod on this object. + /// An object implementing the server-side handling logic. + public static void BindService(grpc::ServiceBinderBase serviceBinder, KeywordViewServiceBase serviceImpl) + { + serviceBinder.AddMethod(__Method_GetKeywordView, serviceImpl.GetKeywordView); + } + + } +} +#endregion diff --git a/src/V3/Stubs/Label.cs b/src/V3/Stubs/Label.cs new file mode 100644 index 000000000..bcc09487d --- /dev/null +++ b/src/V3/Stubs/Label.cs @@ -0,0 +1,345 @@ +// +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/ads/googleads/v3/resources/label.proto +// +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.Protobuf; +using pbc = global::Google.Protobuf.Collections; +using pbr = global::Google.Protobuf.Reflection; +using scg = global::System.Collections.Generic; +namespace Google.Ads.GoogleAds.V3.Resources { + + /// Holder for reflection information generated from google/ads/googleads/v3/resources/label.proto + public static partial class LabelReflection { + + #region Descriptor + /// File descriptor for google/ads/googleads/v3/resources/label.proto + public static pbr::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbr::FileDescriptor descriptor; + + static LabelReflection() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ci1nb29nbGUvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXMvbGFiZWwucHJv", + "dG8SIWdvb2dsZS5hZHMuZ29vZ2xlYWRzLnYzLnJlc291cmNlcxovZ29vZ2xl", + "L2Fkcy9nb29nbGVhZHMvdjMvY29tbW9uL3RleHRfbGFiZWwucHJvdG8aMGdv", + "b2dsZS9hZHMvZ29vZ2xlYWRzL3YzL2VudW1zL2xhYmVsX3N0YXR1cy5wcm90", + "bxofZ29vZ2xlL2FwaS9maWVsZF9iZWhhdmlvci5wcm90bxoZZ29vZ2xlL2Fw", + "aS9yZXNvdXJjZS5wcm90bxoeZ29vZ2xlL3Byb3RvYnVmL3dyYXBwZXJzLnBy", + "b3RvGhxnb29nbGUvYXBpL2Fubm90YXRpb25zLnByb3RvIvoCCgVMYWJlbBI9", + "Cg1yZXNvdXJjZV9uYW1lGAEgASgJQibgQQX6QSAKHmdvb2dsZWFkcy5nb29n", + "bGVhcGlzLmNvbS9MYWJlbBIsCgJpZBgCIAEoCzIbLmdvb2dsZS5wcm90b2J1", + "Zi5JbnQ2NFZhbHVlQgPgQQMSKgoEbmFtZRgDIAEoCzIcLmdvb2dsZS5wcm90", + "b2J1Zi5TdHJpbmdWYWx1ZRJPCgZzdGF0dXMYBCABKA4yOi5nb29nbGUuYWRz", + "Lmdvb2dsZWFkcy52My5lbnVtcy5MYWJlbFN0YXR1c0VudW0uTGFiZWxTdGF0", + "dXNCA+BBAxI9Cgp0ZXh0X2xhYmVsGAUgASgLMikuZ29vZ2xlLmFkcy5nb29n", + "bGVhZHMudjMuY29tbW9uLlRleHRMYWJlbDpI6kFFCh5nb29nbGVhZHMuZ29v", + "Z2xlYXBpcy5jb20vTGFiZWwSI2N1c3RvbWVycy97Y3VzdG9tZXJ9L2xhYmVs", + "cy97bGFiZWx9QvcBCiVjb20uZ29vZ2xlLmFkcy5nb29nbGVhZHMudjMucmVz", + "b3VyY2VzQgpMYWJlbFByb3RvUAFaSmdvb2dsZS5nb2xhbmcub3JnL2dlbnBy", + "b3RvL2dvb2dsZWFwaXMvYWRzL2dvb2dsZWFkcy92My9yZXNvdXJjZXM7cmVz", + "b3VyY2VzogIDR0FBqgIhR29vZ2xlLkFkcy5Hb29nbGVBZHMuVjMuUmVzb3Vy", + "Y2VzygIhR29vZ2xlXEFkc1xHb29nbGVBZHNcVjNcUmVzb3VyY2Vz6gIlR29v", + "Z2xlOjpBZHM6Okdvb2dsZUFkczo6VjM6OlJlc291cmNlc2IGcHJvdG8z")); + descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, + new pbr::FileDescriptor[] { global::Google.Ads.GoogleAds.V3.Common.TextLabelReflection.Descriptor, global::Google.Ads.GoogleAds.V3.Enums.LabelStatusReflection.Descriptor, global::Google.Api.FieldBehaviorReflection.Descriptor, global::Google.Api.ResourceReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, global::Google.Api.AnnotationsReflection.Descriptor, }, + new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Ads.GoogleAds.V3.Resources.Label), global::Google.Ads.GoogleAds.V3.Resources.Label.Parser, new[]{ "ResourceName", "Id", "Name", "Status", "TextLabel" }, null, null, null) + })); + } + #endregion + + } + #region Messages + /// + /// A label. + /// + public sealed partial class Label : pb::IMessage